---
title: "space.site-config@1 · OpenVibe.Services"
canonical: "https://openvibe.services/docs/contracts/space.site-config"
updated: null
---

# space.site-config@1 · OpenVibe.Services

HTML: [space.site-config@1 · OpenVibe.Services](https://openvibe.services/docs/contracts/space.site-config)

# SpaceSiteConfig `space.site-config@1`

Generated at 2026-12-01 05:42:00 UTC from [`openvibe-contracts v0.454.0`](https://github.com/OpenVibers/OpenVibe.Contracts/tree/v0.454.0) and [`openvibe-sdk v0.193.0`](https://github.com/OpenVibers/OpenVibe.SDK/tree/v0.193.0).

- Version: 1.0.0
- Owner: space
- Visibility: first-party
- Status: active
- Compatibility: backward
- Schema: [`https://openvibe.network/contracts/space/site-config.v1.json`](/docs/contracts/space.site-config.json)

space.site-config@1: one Host site's serving configuration (plan T12 J3). headers are applied to every response of the site before the platform's own, which always win; the platform's security, routing, caching, scope and transport headers (Content-Security-Policy, Strict-Transport-Security, Set-Cookie, Cache-Control, Content-Type, Location, Service-Worker-Allowed, Alt-Svc and the rest of Host's reserved list) and every X-Forwarded-\* header are refused. redirects are local paths only (no scheme, host, protocol-relative URL, backslash or control character, also after percent-decoding). spa serves /index.html for an extensionless path that has no file. A site with no configuration answers { headers: {}, redirects: \[\], spa: false }.

## Fields

| Field | Type | Required | Description | Constraints |
| --- | --- | --- | --- | --- |
| `headers` | object | yes |  |  |
| `redirects` | array of object | yes |  | - `maxItems 200`<br>- `items: no other fields` |
| `redirects[].from` | string | yes |  | - `pattern ^/(?!/)`<br>- `maxLength 1024` |
| `redirects[].to` | string | yes |  | - `pattern ^/(?!/)`<br>- `maxLength 1024` |
| `redirects[].status` | enum | yes |  | - `one of 301, 302, 307, 308` |
| `spa` | boolean | yes |  |  |

## Examples

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

 Valid: configured

~~~~
{
  "headers": {
    "X-Frame-Options": "DENY",
    "Access-Control-Allow-Origin": "*"
  },
  "redirects": [
    {
      "from": "/old",
      "to": "/new",
      "status": 301
    }
  ],
  "spa": true
}
~~~~

Valid: defaults

~~~~
{
  "headers": {},
  "redirects": [],
  "spa": false
}
~~~~

Rejected: protocol-relative

~~~~
{
  "headers": {},
  "redirects": [
    {
      "from": "/a",
      "to": "//evil.example/",
      "status": 301
    }
  ],
  "spa": false
}
~~~~

## Validate

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