SpaceDeployFailedPayload space.deploy.failed@1
Generated at from
openvibe-contracts v0.150.0 and
openvibe-sdk v0.44.0.
- Version
- 1.0.0
- Owner
- space
- Visibility
- first-party
- Status
- active
- Compatibility
- backward
- Decision
- ADR-004
- Schema
https://openvibe.network/contracts/events/payloads/space.deploy.failed.v1.json
space.deploy.failed v1 (OpenVibe.Space, subject deploy dpl_…, visibility internal): an upload was refused and recorded as a failed deploy with its log, so the owner can see why. Problem codes only, at most ten; never file contents.
Fields
| Field | Type | Required | Description | Constraints |
|---|---|---|---|---|
project_id | string | yes |
| |
site_id | string | yes |
| |
site | string | yes | the site name (one DNS label; the site is served at <site>.openvibe.website) |
|
code | string | yes | the refusal problem code (for example deploy.too_large or storage.space_full) |
|
problems | array of string | yes | the problem codes of the files that were refused |
|
Examples
From the contract's own test fixtures: valid ones validate, rejected ones must fail.
Valid: disk-full
{
"project_id": "prj_01JAB2C3D4E5F6G7H8J9K0MNPQ",
"site_id": "sit_01JAB2C3D4E5F6G7H8J9K0MNPR",
"site": "alpha-site",
"code": "storage.space_full",
"problems": []
}Valid: too-large
{
"project_id": "prj_01JAB2C3D4E5F6G7H8J9K0MNPQ",
"site_id": "sit_01JAB2C3D4E5F6G7H8J9K0MNPR",
"site": "alpha-site",
"code": "deploy.too_large",
"problems": [
"file.too_large"
]
}Rejected: eleven-problems
{
"project_id": "prj_01JAB2C3D4E5F6G7H8J9K0MNPQ",
"site_id": "sit_01JAB2C3D4E5F6G7H8J9K0MNPR",
"site": "alpha-site",
"code": "deploy.invalid",
"problems": [
"file.bad_path",
"file.bad_path",
"file.bad_path",
"file.bad_path",
"file.bad_path",
"file.bad_path",
"file.bad_path",
"file.bad_path",
"file.bad_path",
"file.bad_path",
"file.bad_path"
]
}Rejected: file-contents
{
"project_id": "prj_01JAB2C3D4E5F6G7H8J9K0MNPQ",
"site_id": "sit_01JAB2C3D4E5F6G7H8J9K0MNPR",
"site": "alpha-site",
"code": "deploy.too_large",
"problems": [
"file.too_large"
],
"content": "<html>"
}Validate
const contracts = require('openvibe-contracts');
contracts.validate('space.deploy.failed@1', value); // { valid, errors: [{ path, message }] }