NetworkAccountExportPart network.account-export-part@1

Generated at from openvibe-contracts v0.76.0 and openvibe-sdk v0.20.1.

Version
1.0.0
Owner
network
Visibility
first-party
Status
active
Compatibility
backward
Decision
ADR-033
Schema
https://openvibe.network/contracts/network/account-export-part.v1.json

network.account-export-part@1 (OpenVibe.Network; roadmap WS-B task 7, ADR-033): one service's part of a person's data export, POST /internal/account-exports/{export_id}/parts with capability network.account.export.contribute (a token speaks only for its own service). Files are JSON documents of the subject's own rows (never another person's data), at most 20 MB in all; each lands in the archive as <service>/<name>. A second part from the same service replaces the first.

Fields

FieldTypeRequiredDescriptionConstraints
subjectstringyesMust be the export's subject.
  • pattern ^usr_[0-9A-HJKMNP-TV-Z]{26}$
filesarray of objectyes
  • maxItems 64
  • items: no other fields
files[].namestringyesA flat file name ending in .json.
  • pattern ^[a-z0-9][a-z0-9_.-]{0,62}\.json$
files[].contentanyyesAny JSON value: the rows, as the service describes them.
truncatedarray of stringFiles cut at the service's own row limit, named so the README says so.
  • maxItems 64
  • items: maxLength 64
notestringA line for the README, such as where media files are downloaded.
  • maxLength 500

Examples

From the contract's own test fixtures: valid ones validate, rejected ones must fail.

Valid: live
{
  "subject": "usr_01JAB2C3D4E5F6G7H8J9K0MNPQ",
  "files": [
    {
      "name": "follows.json",
      "content": [
        {
          "channel": "xena",
          "since": "2026-01-02T03:04:05.000Z"
        }
      ]
    },
    {
      "name": "profile.json",
      "content": {
        "username": "keep",
        "bio": "hi"
      }
    }
  ],
  "truncated": [],
  "note": "Stream recordings are Media's part."
}
Rejected: not-json-name
{
  "subject": "usr_01JAB2C3D4E5F6G7H8J9K0MNPQ",
  "files": [
    {
      "name": "avatar.png",
      "content": "iVBOR"
    }
  ]
}
Rejected: path-in-name
{
  "subject": "usr_01JAB2C3D4E5F6G7H8J9K0MNPQ",
  "files": [
    {
      "name": "../network/profile.json",
      "content": {}
    }
  ]
}

Validate

const contracts = require('openvibe-contracts');
contracts.validate('network.account-export-part@1', value);   // { valid, errors: [{ path, message }] }