HostDeploy host.deploy@1

Generated at from openvibe-contracts v0.53.0 and openvibe-sdk v0.11.0.

Version
1.0.0
Owner
host
Visibility
first-party
Status
active
Compatibility
backward
Schema
https://openvibe.network/contracts/host/deploy.v1.json

host.deploy@1: one immutable static deploy on OpenVibe.Host (server/http/serialize.js deploy): ready (validated and stored, never executed) or failed (refused, with its failure code and log), whether the site serves it, its size and manifest hash. GET /api/v1/deploys/:id adds the files; the upload answer adds the log.

Fields

FieldTypeRequiredDescriptionConstraints
idstringyes
  • pattern ^dpl_[0-9A-HJKMNP-TV-Z]{26}$
site_idstringyes
  • pattern ^site_[0-9A-HJKMNP-TV-Z]{26}$
project_idstringyes
  • pattern ^prj_[0-9A-HJKMNP-TV-Z]{26}$
stateenumyes
  • one of "ready", "failed", "deleted"
activebooleanyes
sourceenumyes
  • one of "archive", "files"
file_countintegeryes
  • minimum 0
total_bytesintegeryes
  • minimum 0
new_bytesintegeryesBytes this deploy added to the project's store.
  • minimum 0
manifest_sha256string | nullyes
  • pattern ^[0-9a-f]{64}$
failure_codestring | nullyes
created_bystringyes
created_atstringyes
  • format date-time
filesarray of object
files[].pathstringyes
files[].sha256stringyes
  • pattern ^[0-9a-f]{64}$
files[].sizeintegeryes
  • minimum 0
files[].content_typestringyes
logarray of object
log[].levelenumyes
  • one of "info", "warn", "error"
log[].messagestringyes
log[].atstringyes
  • format date-time

Examples

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

Valid: failed
{
  "id": "dpl_01JAD3D4E5F6G7H8J9K0M1N2P3",
  "site_id": "site_01JAD2S3T4V5W6X7Y8Z9A0B1C2",
  "project_id": "prj_01JAD1P2R3J4K5M6N7P8Q9R0S1",
  "state": "failed",
  "active": false,
  "source": "files",
  "file_count": 0,
  "total_bytes": 0,
  "new_bytes": 0,
  "manifest_sha256": null,
  "failure_code": "deploy.server_code",
  "created_by": "app:app_01JAD7A8B9C0D1E2F3G4H5J6K7",
  "created_at": "2026-09-24T09:40:12.000Z",
  "log": [
    {
      "level": "error",
      "message": "deploy.server_code: api/index.php is server-side code; Host serves static files only",
      "at": "2026-09-24T08:15:00.000Z"
    }
  ]
}
Valid: ready
{
  "id": "dpl_01JAD4D4E5F6G7H8J9K0M1N2P3",
  "site_id": "site_01JAD2S3T4V5W6X7Y8Z9A0B1C2",
  "project_id": "prj_01JAD1P2R3J4K5M6N7P8Q9R0S1",
  "state": "ready",
  "active": true,
  "source": "archive",
  "file_count": 37,
  "total_bytes": 482113,
  "new_bytes": 20411,
  "manifest_sha256": "a3f1c9e0b4d2e6f8a1c3e5f7091b2d4f6a8c0e2f4a6b8d0f2e4c6a8b0d2f4e6a",
  "failure_code": null,
  "created_by": "app:app_01JAD7A8B9C0D1E2F3G4H5J6K7",
  "created_at": "2026-09-24T09:40:12.000Z"
}
Rejected: bad-source
{
  "id": "dpl_01JAD4D4E5F6G7H8J9K0M1N2P3",
  "site_id": "site_01JAD2S3T4V5W6X7Y8Z9A0B1C2",
  "project_id": "prj_01JAD1P2R3J4K5M6N7P8Q9R0S1",
  "state": "ready",
  "active": true,
  "source": "git",
  "file_count": 37,
  "total_bytes": 482113,
  "new_bytes": 20411,
  "manifest_sha256": "a3f1c9e0b4d2e6f8a1c3e5f7091b2d4f6a8c0e2f4a6b8d0f2e4c6a8b0d2f4e6a",
  "failure_code": null,
  "created_by": "app:app_01JAD7A8B9C0D1E2F3G4H5J6K7",
  "created_at": "2026-09-24T09:40:12.000Z"
}

Validate

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