HostSiteConfigResult host.site-config-result@1
Generated at from
openvibe-contracts v0.84.0 and
openvibe-sdk v0.26.0.
- Version
- 1.0.0
- Owner
- host
- Visibility
- first-party
- Status
- active
- Compatibility
- backward
- Schema
https://openvibe.network/contracts/host/site-config-result.v1.json
host.site-config-result@1: every answer of host.site.config on OpenVibe.Host. GET, PUT and DELETE /api/v1/sites/:id/config → { config } (after a PUT, the configuration as stored; after a DELETE, the defaults).
Fields
| Field | Type | Required | Description | Constraints |
|---|---|---|---|---|
config | host.site-config | yes |
Examples
From the contract's own test fixtures: valid ones validate, rejected ones must fail.
Valid: stored
{
"config": {
"headers": {
"X-Frame-Options": "DENY"
},
"redirects": [],
"spa": false
}
}Rejected: missing-spa
{
"config": {
"headers": {},
"redirects": []
}
}Validate
const contracts = require('openvibe-contracts');
contracts.validate('host.site-config-result@1', value); // { valid, errors: [{ path, message }] }