{
  "openapi": "3.1.0",
  "info": {
    "title": "CMS Orbit management API",
    "version": "1",
    "summary": "Change what is in CMS Orbit from scripts and integrations: pages, media, content types, menus, redirects, keys and settings.",
    "description": "The management API is how scripts and integrations change what is in CMS Orbit, with the same permissions as the screens. Send a management token (cms_mt_) as Authorization: Bearer. A token acts as the person who created it, works for one organisation and lasts 1 to 365 days; a read-only token gets 403 on every write.\n\nBodies are JSON with Content-Type: application/json, except uploads, which are multipart/form-data. PATCH changes only the fields you send; PUT replaces the whole setting. Answers are { data } with 200 or 201, or empty with 204. Lists return every item at once. Errors are { error: { code, message, details } }.",
    "contact": {
      "name": "Bifröst Orbit",
      "url": "https://docs.bifrostorbit.com/",
      "email": "hello@bifrostorbit.com"
    },
    "termsOfService": "https://bifrostorbit.com/legal/terms/"
  },
  "servers": [
    {
      "url": "https://api.bifrostorbit.com/cms/manage/v1",
      "description": "Production"
    },
    {
      "url": "https://api-stage.bifrostorbit.com/cms/manage/v1",
      "description": "Staging"
    }
  ],
  "tags": [
    {
      "name": "Organisation",
      "description": "Organisation in the management API."
    },
    {
      "name": "Management tokens",
      "description": "Management tokens in the management API."
    },
    {
      "name": "Command-line sign-ins",
      "description": "Command-line sign-ins in the management API."
    },
    {
      "name": "Members and roles",
      "description": "Members and roles in the management API."
    },
    {
      "name": "Spaces",
      "description": "Spaces in the management API."
    },
    {
      "name": "SEO and accessibility settings",
      "description": "SEO and accessibility settings in the management API."
    },
    {
      "name": "Delivery keys",
      "description": "Delivery keys in the management API."
    },
    {
      "name": "Connected satellites",
      "description": "Connected satellites in the management API."
    },
    {
      "name": "Content types and components",
      "description": "Content types and components in the management API."
    },
    {
      "name": "Domains",
      "description": "Domains in the management API."
    },
    {
      "name": "Environments, regions and languages",
      "description": "Environments, regions and languages in the management API."
    },
    {
      "name": "Content",
      "description": "Content in the management API."
    },
    {
      "name": "Publishing",
      "description": "Publishing in the management API."
    },
    {
      "name": "Reviews",
      "description": "Reviews in the management API."
    },
    {
      "name": "Copying and translating",
      "description": "Copying and translating in the management API."
    },
    {
      "name": "Folders",
      "description": "Folders in the management API."
    },
    {
      "name": "Experiments",
      "description": "Experiments in the management API."
    },
    {
      "name": "Feature flags",
      "description": "Feature flags in the management API."
    },
    {
      "name": "Media",
      "description": "Media in the management API."
    },
    {
      "name": "Menus",
      "description": "Menus in the management API."
    },
    {
      "name": "Redirects",
      "description": "Redirects in the management API."
    },
    {
      "name": "Releases",
      "description": "Releases in the management API."
    },
    {
      "name": "Taxonomies",
      "description": "Taxonomies in the management API."
    },
    {
      "name": "Webhooks",
      "description": "Webhooks in the management API."
    }
  ],
  "externalDocs": {
    "url": "https://docs.bifrostorbit.com/cms/developers/management-api/",
    "description": "The management API guide"
  },
  "paths": {
    "/organisations/{organisationId}": {
      "get": {
        "operationId": "getOrganisation",
        "tags": [
          "Organisation"
        ],
        "summary": "The organisation",
        "description": "The organisation. Permission: organisation:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          }
        ],
        "responses": {
          "200": {
            "description": "{ id, name, slug, settings, createdAt }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Organisation"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a01",
                    "name": "Northwilds",
                    "slug": "northwilds",
                    "settings": {
                      "defaultLocaleCode": null,
                      "featureFlags": {}
                    },
                    "createdAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks organisation:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such organisation, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Organisation not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchOrganisation",
        "tags": [
          "Organisation"
        ],
        "summary": "Changes its name, slug or settings",
        "description": "Changes its name, slug or settings. Permission: organisation:update.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "slug": {
                    "type": "string",
                    "description": "Lowercase letters, digits and single hyphens."
                  },
                  "settings": {
                    "type": "object",
                    "properties": {
                      "defaultLocaleCode": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "minLength": 2,
                        "maxLength": 35,
                        "default": null
                      },
                      "featureFlags": {
                        "default": {},
                        "type": "object",
                        "additionalProperties": {
                          "type": "boolean"
                        }
                      }
                    },
                    "description": "defaultLocaleCode is the language new regions start with. featureFlags replaces the stored flags."
                  }
                }
              },
              "example": {
                "name": "Northwilds",
                "settings": {
                  "defaultLocaleCode": "en-GB"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Organisation"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a01",
                    "name": "Northwilds",
                    "slug": "northwilds",
                    "settings": {
                      "defaultLocaleCode": null,
                      "featureFlags": {}
                    },
                    "createdAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks organisation:update, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such organisation, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Organisation not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "Another organisation has the slug.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/audit/export": {
      "get": {
        "operationId": "getOrganisationAuditExport",
        "tags": [
          "Organisation"
        ],
        "summary": "The audit log as CSV",
        "description": "The audit log as CSV. Permission: audit:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "query",
            "required": false,
            "description": "Only this space.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "actorId",
            "in": "query",
            "required": false,
            "description": "Only this person's changes.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "action",
            "in": "query",
            "required": false,
            "description": "Only this action, exactly, such as content.published.",
            "schema": {
              "type": "string"
            },
            "example": "content.published"
          },
          {
            "name": "from",
            "in": "query",
            "required": false,
            "description": "From this day, YYYY-MM-DD in UTC, included.",
            "schema": {
              "type": "string"
            },
            "example": "2026-11-01"
          },
          {
            "name": "to",
            "in": "query",
            "required": false,
            "description": "To this day, YYYY-MM-DD in UTC, included.",
            "schema": {
              "type": "string"
            },
            "example": "2026-11-30"
          }
        ],
        "responses": {
          "200": {
            "description": "At most 10,000 rows within the plan's history, with the columns time, who, kind, action, space, resource, detail and IP address.",
            "content": {
              "text/csv": {
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks audit:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such organisation, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Organisation not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/management-tokens": {
      "get": {
        "operationId": "getManagementTokensManagementTokens",
        "tags": [
          "Management tokens"
        ],
        "summary": "Your tokens, or every token in the organisation with apikey:manage",
        "description": "Your tokens, or every token in the organisation with apikey:manage. Permission: None.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          }
        ],
        "responses": {
          "200": {
            "description": "[{ id, name, person, readOnly, prefix, expiresAt, lastUsedAt, revokedAt, createdAt, mine }].",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/ManagementToken"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a4f",
                      "name": "Northwilds gear import",
                      "person": "Ingrid Berg",
                      "readOnly": false,
                      "prefix": "cms_mt_8kQ2",
                      "expiresAt": "2026-11-02T09:30:00.000Z",
                      "lastUsedAt": "2026-11-02T09:30:00.000Z",
                      "revokedAt": "2026-11-02T09:30:00.000Z",
                      "createdAt": "2026-11-02T09:30:00.000Z",
                      "mine": true
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "The token's person can't reach it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such organisation, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Organisation not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postManagementTokensManagementTokens",
        "tags": [
          "Management tokens"
        ],
        "summary": "Creates a token",
        "description": "Creates a token. Signed-in people only. Permission: apikey:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 80,
                    "description": "What uses it, such as Northwilds gear import."
                  },
                  "readOnly": {
                    "default": false,
                    "type": "boolean",
                    "description": "Keep only the permissions that read. Every write then answers 403."
                  },
                  "expiresInDays": {
                    "default": 90,
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 365,
                    "description": "How many days it lasts."
                  }
                },
                "required": [
                  "name"
                ]
              },
              "example": {
                "name": "Northwilds gear import",
                "readOnly": false,
                "expiresInDays": 90
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "{ token, secret }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "token": {
                          "$ref": "#/components/schemas/ManagementToken"
                        },
                        "secret": {
                          "type": "string",
                          "description": "The token, starting with cms_mt_. Shown only in this answer."
                        }
                      },
                      "required": [
                        "token",
                        "secret"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "token": {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "name": "Lofoten sea kayaking",
                      "person": "Ingrid Berg",
                      "readOnly": false,
                      "prefix": "…",
                      "expiresAt": "2026-11-02T09:30:00.000Z",
                      "lastUsedAt": "2026-11-02T09:30:00.000Z",
                      "revokedAt": "2026-11-02T09:30:00.000Z",
                      "createdAt": "2026-11-02T09:30:00.000Z",
                      "mine": true
                    },
                    "secret": "whsec_…"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks apikey:manage, called with a token rather than a signed-in person, or the plan's active tokens are used up.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such organisation, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Organisation not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/management-tokens/{tokenId}": {
      "delete": {
        "operationId": "deleteManagementTokensManagementTokensByTokenId",
        "tags": [
          "Management tokens"
        ],
        "summary": "Revokes a token",
        "description": "Revokes a token. Signed-in people only. Revoking twice is fine. Permission: Your own, or apikey:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "tokenId",
            "in": "path",
            "required": true,
            "description": "The token's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Not your token and no apikey:manage, or called with a token rather than a signed-in person.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such token, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Token not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/management-tokens/{tokenId}/remove": {
      "post": {
        "operationId": "postManagementTokensManagementTokensByTokenIdRemove",
        "tags": [
          "Management tokens"
        ],
        "summary": "Removes a revoked token from the list",
        "description": "Removes a revoked token from the list. Permission: apikey:delete.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "tokenId",
            "in": "path",
            "required": true,
            "description": "The token's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "400": {
            "description": "Revoke the token first.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks apikey:delete, which Admins and Owners have.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such token, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Token not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/management-tokens/{tokenId}/restore": {
      "post": {
        "operationId": "postManagementTokensManagementTokensByTokenIdRestore",
        "tags": [
          "Management tokens"
        ],
        "summary": "Puts a removed token back in the list, still revoked",
        "description": "Puts a removed token back in the list, still revoked. Permission: apikey:delete.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "tokenId",
            "in": "path",
            "required": true,
            "description": "The token's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks apikey:delete, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such token, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Token not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/cli-sign-ins": {
      "get": {
        "operationId": "getCommandLineSignInsCliSignIns",
        "tags": [
          "Command-line sign-ins"
        ],
        "summary": "Where people in the organisation are signed in with cms-orbit login",
        "description": "Where people in the organisation are signed in with cms-orbit login. Signed-in people only. Permission: member:remove.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          }
        ],
        "responses": {
          "200": {
            "description": "[{ id, name, personId, person, signedInAt, lastUsedAt, endsAt, mine, canSignOut }].",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/CliSignIn"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a49",
                      "name": "CMS Orbit CLI on Ingrid's MacBook",
                      "personId": "6650f1c2a9e4b1d2c3f40a58",
                      "person": "Ingrid Berg",
                      "signedInAt": "2026-11-02T09:30:00.000Z",
                      "lastUsedAt": "2026-11-02T09:30:00.000Z",
                      "endsAt": "2026-11-02T09:30:00.000Z",
                      "mine": true,
                      "canSignOut": false
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks member:remove, which Admins and Owners have, or called with a token rather than a signed-in person.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such organisation, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Organisation not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/cli-sign-ins/{signInId}": {
      "delete": {
        "operationId": "deleteCommandLineSignInsCliSignInsBySignInId",
        "tags": [
          "Command-line sign-ins"
        ],
        "summary": "Signs one out at once, in every organisation its person belongs to",
        "description": "Signs one out at once, in every organisation its person belongs to. Signed-in people only. Signing out twice is fine. Permission: member:remove, for someone ranked below you or yourself.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "signInId",
            "in": "path",
            "required": true,
            "description": "The sign in's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks member:remove, the person ranks at or above you, or called with a token rather than a signed-in person.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such sign-in for anyone in the organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Sign-in not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/members": {
      "get": {
        "operationId": "getMembersAndRolesMembers",
        "tags": [
          "Members and roles"
        ],
        "summary": "Everyone in the organisation and its spaces",
        "description": "Everyone in the organisation and its spaces. Permission: member:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          }
        ],
        "responses": {
          "200": {
            "description": "List of members.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Member"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "membershipId": "6650f1c2a9e4b1d2c3f40a31",
                      "userId": "6650f1c2a9e4b1d2c3f40a30",
                      "email": "ingrid.berg@northwilds.com",
                      "name": "Ingrid Berg",
                      "role": "editor",
                      "roleName": "Editor",
                      "spaceId": null,
                      "spaceName": null,
                      "status": "active",
                      "createdAt": "2026-11-02T09:30:00.000Z"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks member:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such organisation, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Organisation not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postMembersAndRolesMembers",
        "tags": [
          "Members and roles"
        ],
        "summary": "Invites a person, or gives them a role in a space",
        "description": "Invites a person, or gives them a role in a space. Permission: member:invite.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "email": {
                    "type": "string",
                    "description": "The person's email address. New people get an invitation email."
                  },
                  "role": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 64,
                    "pattern": "^[a-z][a-z0-9_-]*$",
                    "description": "A role key, ranked below your own."
                  },
                  "spaceId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "A space, for a role in that space only. Leave it out for the whole organisation."
                  }
                },
                "required": [
                  "email",
                  "role"
                ]
              },
              "example": {
                "email": "ingrid.berg@northwilds.com",
                "role": "editor"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The member.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Member"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "membershipId": "6650f1c2a9e4b1d2c3f40a31",
                    "userId": "6650f1c2a9e4b1d2c3f40a30",
                    "email": "ingrid.berg@northwilds.com",
                    "name": "Ingrid Berg",
                    "role": "editor",
                    "roleName": "Editor",
                    "spaceId": null,
                    "spaceName": null,
                    "status": "active",
                    "createdAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or the role is the owner's or ranks at or above yours, or the email's domain is not allowed in the organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks member:invite, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such organisation, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Organisation not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "The person already has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/members/{membershipId}": {
      "delete": {
        "operationId": "deleteMembersAndRolesMembersByMembershipId",
        "tags": [
          "Members and roles"
        ],
        "summary": "Removes access",
        "description": "Removes access. Removing someone from the organisation removes them from its spaces too. Permission: member:remove.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "membershipId",
            "in": "path",
            "required": true,
            "description": "The membership's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "400": {
            "description": "Your own access, the owner, or a person ranked at or above you.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks member:remove, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such membership, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Membership not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchMembersAndRolesMembersByMembershipId",
        "tags": [
          "Members and roles"
        ],
        "summary": "Changes a role or region limits",
        "description": "Changes a role or region limits. Permission: member:update.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "membershipId",
            "in": "path",
            "required": true,
            "description": "The membership's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "role": {
                    "type": "string",
                    "description": "A role key, ranked below your own."
                  },
                  "regionKeys": {
                    "type": [
                      "array",
                      "null"
                    ],
                    "items": {
                      "type": "string"
                    },
                    "description": "Region keys the person may change, or null for every region."
                  }
                },
                "required": []
              },
              "example": {
                "role": "publisher",
                "regionKeys": [
                  "norway"
                ]
              }
            }
          }
        },
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "400": {
            "description": "The body isn't valid JSON. Or your own access, the owner, or a role change your rank doesn't allow.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks member:update, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such membership, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Membership not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "role isn't a role key.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/roles": {
      "get": {
        "operationId": "getMembersAndRolesRoles",
        "tags": [
          "Members and roles"
        ],
        "summary": "Built-in and custom roles with their permissions",
        "description": "Built-in and custom roles with their permissions. Permission: role:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          }
        ],
        "responses": {
          "200": {
            "description": "[{ id, key, name, description, permissions, isSystem, rank }].",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Role"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a44",
                      "key": "editor",
                      "name": "Editor",
                      "description": "Writes and changes content.",
                      "permissions": [
                        "content:read",
                        "content:update"
                      ],
                      "isSystem": true,
                      "rank": 1
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks role:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such organisation, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Organisation not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postMembersAndRolesRoles",
        "tags": [
          "Members and roles"
        ],
        "summary": "Adds a custom role",
        "description": "Adds a custom role. Permission: role:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 64,
                    "pattern": "^[a-z][a-z0-9_-]*$",
                    "description": "Lowercase letters, digits, _ or -, starting with a letter."
                  },
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "description": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 500
                  },
                  "permissions": {
                    "minItems": 1,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "minLength": 3,
                      "maxLength": 64
                    },
                    "description": "At least one, and only permissions you hold."
                  },
                  "rank": {
                    "default": 10,
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 100,
                    "description": "0 to 100, at most your own."
                  }
                },
                "required": [
                  "key",
                  "name",
                  "permissions"
                ]
              },
              "example": {
                "key": "trip-writer",
                "name": "Trip writer",
                "description": "Writes and updates trip pages.",
                "permissions": [
                  "content:read",
                  "content:create",
                  "content:update"
                ],
                "rank": 20
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The role.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Role"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a44",
                    "key": "editor",
                    "name": "Editor",
                    "description": "Writes and changes content.",
                    "permissions": [
                      "content:read",
                      "content:update"
                    ],
                    "isSystem": true,
                    "rank": 1
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or a permission you don't hold or that doesn't exist, or a rank above your own.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks role:manage, or the plan has no custom roles.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such organisation, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Organisation not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "A role with the key exists.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/roles/{roleKey}": {
      "delete": {
        "operationId": "deleteMembersAndRolesRolesByRoleKey",
        "tags": [
          "Members and roles"
        ],
        "summary": "Deletes a custom role nobody has",
        "description": "Deletes a custom role nobody has. Permission: role:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "roleKey",
            "in": "path",
            "required": true,
            "description": "The role's key, such as editor.",
            "schema": {
              "type": "string"
            },
            "example": "editor"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "400": {
            "description": "A built-in role.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks role:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such role, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Role not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "Someone still has the role.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchMembersAndRolesRolesByRoleKey",
        "tags": [
          "Members and roles"
        ],
        "summary": "Changes a role",
        "description": "Changes a role. Permission: role:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "roleKey",
            "in": "path",
            "required": true,
            "description": "The role's key, such as editor.",
            "schema": {
              "type": "string"
            },
            "example": "editor"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200,
                    "description": "Built-in roles keep their name."
                  },
                  "description": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 500
                  },
                  "permissions": {
                    "minItems": 1,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "minLength": 3,
                      "maxLength": 64
                    }
                  },
                  "rank": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 100,
                    "description": "Built-in roles keep their rank."
                  }
                }
              },
              "example": {
                "permissions": [
                  "content:read",
                  "content:create",
                  "content:update",
                  "content:publish"
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The role.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Role"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a44",
                    "key": "editor",
                    "name": "Editor",
                    "description": "Writes and changes content.",
                    "permissions": [
                      "content:read",
                      "content:update"
                    ],
                    "isSystem": true,
                    "rank": 1
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or a permission you don't hold, a built-in role's name or rank, or a role ranked at or above yours.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks role:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such role, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Role not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/search": {
      "get": {
        "operationId": "getOrganisationSearch",
        "tags": [
          "Organisation"
        ],
        "summary": "Searches pages in every space the token reaches, by name, address and text",
        "description": "Searches pages in every space the token reaches, by name, address and text. The text is the draft with content:read_draft, otherwise the published page. q needs 2 characters. Up to 20 results. Permission: space:read and content:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "q",
            "in": "query",
            "required": true,
            "description": "What to look for, at least 2 characters. Shorter answers an empty list.",
            "schema": {
              "type": "string"
            },
            "example": "kayak"
          },
          {
            "name": "spaceId",
            "in": "query",
            "required": false,
            "description": "With localeId, search one language of one space, up to 200 results.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "localeId",
            "in": "query",
            "required": false,
            "description": "With spaceId.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "[{ id, name, url, where, snippet, href }].",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string",
                            "description": "An id."
                          },
                          "name": {
                            "type": "string"
                          },
                          "url": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "where": {
                            "type": "string",
                            "description": "The space, region and language, such as Website · Norway · Norwegian."
                          },
                          "snippet": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "description": "The text around the match."
                          },
                          "href": {
                            "type": "string",
                            "description": "Where the page opens in CMS Orbit."
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "url",
                          "where",
                          "snippet",
                          "href"
                        ]
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "name": "Lofoten sea kayaking",
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "where": "…",
                      "snippet": null,
                      "href": "/trips/lofoten-sea-kayaking"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:read and content:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such organisation, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Organisation not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/setup": {
      "post": {
        "operationId": "postSpacesSetup",
        "tags": [
          "Spaces"
        ],
        "summary": "Creates a website in one go: space, environments, regions and languages",
        "description": "Creates a website in one go: space, environments, regions and languages. Permission: space:create.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 80
                  },
                  "template": {
                    "default": "business",
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 40
                  },
                  "environments": {
                    "minItems": 1,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "enum": [
                        "staging",
                        "production"
                      ]
                    },
                    "description": "Any of staging and production."
                  },
                  "regions": {
                    "minItems": 1,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "minLength": 1
                        },
                        "languages": {
                          "minItems": 1,
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "code": {
                                "type": "string",
                                "minLength": 2,
                                "maxLength": 20
                              },
                              "name": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 60
                              }
                            },
                            "required": [
                              "code",
                              "name"
                            ]
                          }
                        }
                      },
                      "required": [
                        "key",
                        "languages"
                      ]
                    },
                    "description": "Each region key must already exist in the organisation in Bifröst Orbit."
                  },
                  "previewUrl": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "format": "uri"
                  }
                },
                "required": [
                  "name",
                  "environments",
                  "regions"
                ]
              },
              "example": {
                "name": "Northwilds",
                "template": "business",
                "environments": [
                  "staging",
                  "production"
                ],
                "regions": [
                  {
                    "key": "norway",
                    "languages": [
                      {
                        "code": "nb-NO",
                        "name": "Norsk"
                      },
                      {
                        "code": "en-GB",
                        "name": "English"
                      }
                    ]
                  }
                ],
                "previewUrl": "https://northwilds.com/api/preview"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "{ spaceId, environmentId }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "spaceId": {
                          "type": "string",
                          "description": "An id."
                        },
                        "environmentId": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "description": "The first environment's id."
                        }
                      },
                      "required": [
                        "spaceId",
                        "environmentId"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:create, or the plan's websites or environments are used up.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such organisation, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Organisation not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema, or a region key the organisation doesn't have.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces": {
      "get": {
        "operationId": "getSpacesSpaces",
        "tags": [
          "Spaces"
        ],
        "summary": "The spaces the token reaches",
        "description": "The spaces the token reaches. include=summary adds environments, counts and page totals. Permission: space:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "include",
            "in": "query",
            "required": false,
            "description": "summary adds environments, region and language counts, page totals and a snapshot of the website.",
            "schema": {
              "type": "string",
              "enum": [
                "summary"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List of spaces.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "anyOf": [
                          {
                            "$ref": "#/components/schemas/Space"
                          },
                          {
                            "$ref": "#/components/schemas/SpaceSummary"
                          }
                        ]
                      },
                      "description": "Spaces, or with include=summary, SpaceSummary objects."
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                      "name": "Lofoten sea kayaking",
                      "slug": "lofoten-sea-kayaking",
                      "description": "Six days of paddling between the peaks of Lofoten.",
                      "logoUrl": null,
                      "defaultEnvironmentId": null,
                      "settings": {
                        "autoRedirectOnUrlChange": true,
                        "localeFallbackEnabled": true,
                        "machineTranslation": true,
                        "previewUrl": null,
                        "previewUrls": [
                          {
                            "name": "Lofoten sea kayaking",
                            "url": "https://northwilds.com/trips/lofoten-sea-kayaking"
                          }
                        ],
                        "previewDevices": [
                          {
                            "name": "Lofoten sea kayaking",
                            "width": 1
                          }
                        ],
                        "timezone": "Europe/Oslo",
                        "regionFallback": null,
                        "trashRetentionDays": 30,
                        "seo": {
                          "xDefaultRegion": null,
                          "organisationName": null,
                          "socialProfiles": [
                            "…"
                          ],
                          "robotsTxt": null,
                          "titleTemplate": null,
                          "defaultDescription": null,
                          "defaultImage": null,
                          "twitterHandle": null,
                          "verification": {
                            "google": null,
                            "bing": null
                          },
                          "websitePaths": [
                            "…"
                          ],
                          "indexNow": false
                        },
                        "indexNowKey": "…",
                        "accessibility": {
                          "publish": "off",
                          "tags": [
                            "…"
                          ]
                        },
                        "insights": {
                          "site": "…",
                          "name": "Lofoten sea kayaking"
                        },
                        "workflowStages": [
                          {
                            "id": "6650f1c2a9e4b1d2c3f40a40",
                            "name": "Lofoten sea kayaking",
                            "colour": "…"
                          }
                        ],
                        "travel": {
                          "brandId": "6650f1c2a9e4b1d2c3f40a57",
                          "bookingSlug": "…",
                          "brandName": "Northwilds",
                          "siteUrl": "https://northwilds.com",
                          "connectedAt": "2026-11-02T09:30:00.000Z",
                          "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                        },
                        "commerce": {
                          "storeSlug": "…",
                          "brandName": "Northwilds",
                          "siteUrl": "https://northwilds.com",
                          "connectedAt": "2026-11-02T09:30:00.000Z",
                          "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                        },
                        "booking": {
                          "locationId": "6650f1c2a9e4b1d2c3f40a5a",
                          "slug": "lofoten-sea-kayaking",
                          "locationName": "…",
                          "siteUrl": "https://northwilds.com",
                          "connectedAt": "2026-11-02T09:30:00.000Z",
                          "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                        },
                        "presenceOrbit": {
                          "siteSlug": "…",
                          "brandName": "Northwilds",
                          "connectedAt": "2026-11-02T09:30:00.000Z",
                          "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                        },
                        "careers": {
                          "siteSlug": "…",
                          "name": "Lofoten sea kayaking",
                          "siteUrl": "https://northwilds.com",
                          "connectedAt": "2026-11-02T09:30:00.000Z",
                          "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                        },
                        "experiments": {
                          "assignment": "cookieless"
                        }
                      },
                      "createdAt": "2026-11-02T09:30:00.000Z",
                      "updatedAt": "2026-11-02T09:30:00.000Z"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such organisation, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Organisation not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postSpacesSpaces",
        "tags": [
          "Spaces"
        ],
        "summary": "Creates a space",
        "description": "Creates a space. Permission: space:create.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200,
                    "description": "The website's name, such as Northwilds."
                  },
                  "template": {
                    "type": "string",
                    "description": "One of business, blog, landing, shop, travel, local, careers, help or blank. Each adds a content model with sample pages; blank adds only the Page type."
                  },
                  "slug": {
                    "type": "string"
                  },
                  "description": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 2000
                  },
                  "settings": {
                    "type": "object",
                    "properties": {
                      "autoRedirectOnUrlChange": {
                        "default": true,
                        "type": "boolean"
                      },
                      "localeFallbackEnabled": {
                        "default": true,
                        "type": "boolean"
                      },
                      "machineTranslation": {
                        "default": true,
                        "type": "boolean"
                      },
                      "previewUrl": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "format": "uri",
                        "default": null
                      },
                      "previewUrls": {
                        "default": [],
                        "maxItems": 10,
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "name": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 60
                            },
                            "url": {
                              "type": "string",
                              "format": "uri"
                            }
                          },
                          "required": [
                            "name",
                            "url"
                          ]
                        }
                      },
                      "previewDevices": {
                        "default": [],
                        "maxItems": 6,
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "name": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 30
                            },
                            "width": {
                              "type": "integer",
                              "minimum": 240,
                              "maximum": 3840
                            }
                          },
                          "required": [
                            "name",
                            "width"
                          ]
                        }
                      },
                      "timezone": {
                        "default": "UTC",
                        "type": "string",
                        "minLength": 1
                      },
                      "regionFallback": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 60,
                        "default": null
                      },
                      "trashRetentionDays": {
                        "type": [
                          "number",
                          "null"
                        ],
                        "enum": [
                          30,
                          60,
                          90,
                          null
                        ],
                        "default": null
                      }
                    }
                  },
                  "environments": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string"
                        },
                        "name": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 200
                        },
                        "kind": {
                          "default": "custom",
                          "type": "string",
                          "enum": [
                            "staging",
                            "production",
                            "custom"
                          ]
                        }
                      },
                      "required": [
                        "key",
                        "name"
                      ]
                    },
                    "description": "Defaults to Staging and Production. Production is protected."
                  }
                },
                "required": [
                  "name"
                ]
              },
              "example": {
                "name": "Northwilds",
                "description": "Trips and gear for the far north.",
                "settings": {
                  "timezone": "Europe/Oslo"
                }
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The space and its environments.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "description": "The space, with its environments.",
                      "properties": {
                        "id": {
                          "type": "string",
                          "description": "An id."
                        },
                        "organisationId": {
                          "type": "string",
                          "description": "An id."
                        },
                        "name": {
                          "type": "string"
                        },
                        "slug": {
                          "type": "string"
                        },
                        "description": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "logoUrl": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "defaultEnvironmentId": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "description": "An id."
                        },
                        "settings": {
                          "$ref": "#/components/schemas/SpaceSettings"
                        },
                        "createdAt": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "updatedAt": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "environments": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/Environment"
                          }
                        }
                      },
                      "required": [
                        "id",
                        "organisationId",
                        "name",
                        "slug",
                        "description",
                        "logoUrl",
                        "defaultEnvironmentId",
                        "settings",
                        "createdAt",
                        "updatedAt",
                        "environments"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a40",
                    "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                    "name": "Lofoten sea kayaking",
                    "slug": "lofoten-sea-kayaking",
                    "description": "Six days of paddling between the peaks of Lofoten.",
                    "logoUrl": null,
                    "defaultEnvironmentId": null,
                    "settings": {
                      "autoRedirectOnUrlChange": true,
                      "localeFallbackEnabled": true,
                      "machineTranslation": true,
                      "previewUrl": null,
                      "previewUrls": [
                        {
                          "name": "Lofoten sea kayaking",
                          "url": "https://northwilds.com/trips/lofoten-sea-kayaking"
                        }
                      ],
                      "previewDevices": [
                        {
                          "name": "Lofoten sea kayaking",
                          "width": 1
                        }
                      ],
                      "timezone": "Europe/Oslo",
                      "regionFallback": null,
                      "trashRetentionDays": 30,
                      "seo": {
                        "xDefaultRegion": null,
                        "organisationName": null,
                        "socialProfiles": [
                          "…"
                        ],
                        "robotsTxt": null,
                        "titleTemplate": null,
                        "defaultDescription": null,
                        "defaultImage": null,
                        "twitterHandle": null,
                        "verification": {
                          "google": null,
                          "bing": null
                        },
                        "websitePaths": [
                          "…"
                        ],
                        "indexNow": false
                      },
                      "indexNowKey": "…",
                      "accessibility": {
                        "publish": "off",
                        "tags": [
                          "…"
                        ]
                      },
                      "insights": {
                        "site": "…",
                        "name": "Lofoten sea kayaking"
                      },
                      "workflowStages": [
                        {
                          "id": "6650f1c2a9e4b1d2c3f40a40",
                          "name": "Lofoten sea kayaking",
                          "colour": "…"
                        }
                      ],
                      "travel": {
                        "brandId": "6650f1c2a9e4b1d2c3f40a57",
                        "bookingSlug": "…",
                        "brandName": "Northwilds",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "commerce": {
                        "storeSlug": "…",
                        "brandName": "Northwilds",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "booking": {
                        "locationId": "6650f1c2a9e4b1d2c3f40a5a",
                        "slug": "lofoten-sea-kayaking",
                        "locationName": "…",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "presenceOrbit": {
                        "siteSlug": "…",
                        "brandName": "Northwilds",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "careers": {
                        "siteSlug": "…",
                        "name": "Lofoten sea kayaking",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "experiments": {
                        "assignment": "cookieless"
                      }
                    },
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z",
                    "environments": [
                      {
                        "id": "6650f1c2a9e4b1d2c3f40a13",
                        "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                        "key": "production",
                        "name": "Production",
                        "kind": "production",
                        "isDefault": true,
                        "protected": false,
                        "sortOrder": 1
                      }
                    ]
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:create, or the plan's websites are used up.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such organisation, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Organisation not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "A space with the slug exists.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}": {
      "delete": {
        "operationId": "deleteSpaces",
        "tags": [
          "Spaces"
        ],
        "summary": "Moves the space to the bin",
        "description": "Moves the space to the bin. Permission: space:delete.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:delete, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "get": {
        "operationId": "getSpaces",
        "tags": [
          "Spaces"
        ],
        "summary": "One space",
        "description": "One space. Permission: space:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "The space.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Space"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a02",
                    "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                    "name": "Northwilds website",
                    "slug": "northwilds-website",
                    "description": "Trips and gear for the far north.",
                    "logoUrl": null,
                    "defaultEnvironmentId": null,
                    "settings": {
                      "autoRedirectOnUrlChange": true,
                      "localeFallbackEnabled": true,
                      "machineTranslation": true,
                      "previewUrl": null,
                      "previewUrls": [
                        {
                          "name": "Lofoten sea kayaking",
                          "url": "https://northwilds.com/trips/lofoten-sea-kayaking"
                        }
                      ],
                      "previewDevices": [
                        {
                          "name": "Lofoten sea kayaking",
                          "width": 1
                        }
                      ],
                      "timezone": "Europe/Oslo",
                      "regionFallback": null,
                      "trashRetentionDays": 30,
                      "seo": {
                        "xDefaultRegion": null,
                        "organisationName": null,
                        "socialProfiles": [
                          "…"
                        ],
                        "robotsTxt": null,
                        "titleTemplate": null,
                        "defaultDescription": null,
                        "defaultImage": null,
                        "twitterHandle": null,
                        "verification": {
                          "google": null,
                          "bing": null
                        },
                        "websitePaths": [
                          "…"
                        ],
                        "indexNow": false
                      },
                      "indexNowKey": "…",
                      "accessibility": {
                        "publish": "off",
                        "tags": [
                          "…"
                        ]
                      },
                      "insights": {
                        "site": "…",
                        "name": "Lofoten sea kayaking"
                      },
                      "workflowStages": [
                        {
                          "id": "6650f1c2a9e4b1d2c3f40a40",
                          "name": "Lofoten sea kayaking",
                          "colour": "…"
                        }
                      ],
                      "travel": {
                        "brandId": "6650f1c2a9e4b1d2c3f40a57",
                        "bookingSlug": "…",
                        "brandName": "Northwilds",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "commerce": {
                        "storeSlug": "…",
                        "brandName": "Northwilds",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "booking": {
                        "locationId": "6650f1c2a9e4b1d2c3f40a5a",
                        "slug": "lofoten-sea-kayaking",
                        "locationName": "…",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "presenceOrbit": {
                        "siteSlug": "…",
                        "brandName": "Northwilds",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "careers": {
                        "siteSlug": "…",
                        "name": "Lofoten sea kayaking",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "experiments": {
                        "assignment": "cookieless"
                      }
                    },
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchSpaces",
        "tags": [
          "Spaces"
        ],
        "summary": "Changes its name, description, default environment or settings",
        "description": "Changes its name, description, default environment or settings. Permission: space:update.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "description": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 2000
                  },
                  "defaultEnvironmentId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "An id."
                  },
                  "settings": {
                    "type": "object",
                    "properties": {
                      "autoRedirectOnUrlChange": {
                        "type": "boolean"
                      },
                      "localeFallbackEnabled": {
                        "type": "boolean"
                      },
                      "machineTranslation": {
                        "type": "boolean"
                      },
                      "previewUrl": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "format": "uri"
                      },
                      "previewUrls": {
                        "maxItems": 10,
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "name": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 60
                            },
                            "url": {
                              "type": "string",
                              "format": "uri"
                            }
                          },
                          "required": [
                            "name",
                            "url"
                          ]
                        }
                      },
                      "previewDevices": {
                        "maxItems": 6,
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "name": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 30
                            },
                            "width": {
                              "type": "integer",
                              "minimum": 240,
                              "maximum": 3840
                            }
                          },
                          "required": [
                            "name",
                            "width"
                          ]
                        }
                      },
                      "timezone": {
                        "type": "string",
                        "minLength": 1
                      },
                      "regionFallback": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 60
                      },
                      "trashRetentionDays": {
                        "type": [
                          "number",
                          "null"
                        ],
                        "enum": [
                          30,
                          60,
                          90,
                          null
                        ]
                      },
                      "workflowStages": {
                        "maxItems": 12,
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "id": {
                              "type": "string",
                              "pattern": "^[a-z0-9-]{1,40}$"
                            },
                            "name": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 40
                            },
                            "colour": {
                              "type": "string",
                              "pattern": "^#[0-9a-f]{6}$"
                            }
                          },
                          "required": [
                            "id",
                            "name",
                            "colour"
                          ]
                        }
                      }
                    },
                    "description": "Merged into the existing settings."
                  }
                }
              },
              "example": {
                "description": "Trips and gear for the far north.",
                "settings": {
                  "timezone": "Europe/Oslo",
                  "previewUrl": "https://northwilds.com/api/preview"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The space.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Space"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a02",
                    "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                    "name": "Northwilds website",
                    "slug": "northwilds-website",
                    "description": "Trips and gear for the far north.",
                    "logoUrl": null,
                    "defaultEnvironmentId": null,
                    "settings": {
                      "autoRedirectOnUrlChange": true,
                      "localeFallbackEnabled": true,
                      "machineTranslation": true,
                      "previewUrl": null,
                      "previewUrls": [
                        {
                          "name": "Lofoten sea kayaking",
                          "url": "https://northwilds.com/trips/lofoten-sea-kayaking"
                        }
                      ],
                      "previewDevices": [
                        {
                          "name": "Lofoten sea kayaking",
                          "width": 1
                        }
                      ],
                      "timezone": "Europe/Oslo",
                      "regionFallback": null,
                      "trashRetentionDays": 30,
                      "seo": {
                        "xDefaultRegion": null,
                        "organisationName": null,
                        "socialProfiles": [
                          "…"
                        ],
                        "robotsTxt": null,
                        "titleTemplate": null,
                        "defaultDescription": null,
                        "defaultImage": null,
                        "twitterHandle": null,
                        "verification": {
                          "google": null,
                          "bing": null
                        },
                        "websitePaths": [
                          "…"
                        ],
                        "indexNow": false
                      },
                      "indexNowKey": "…",
                      "accessibility": {
                        "publish": "off",
                        "tags": [
                          "…"
                        ]
                      },
                      "insights": {
                        "site": "…",
                        "name": "Lofoten sea kayaking"
                      },
                      "workflowStages": [
                        {
                          "id": "6650f1c2a9e4b1d2c3f40a40",
                          "name": "Lofoten sea kayaking",
                          "colour": "…"
                        }
                      ],
                      "travel": {
                        "brandId": "6650f1c2a9e4b1d2c3f40a57",
                        "bookingSlug": "…",
                        "brandName": "Northwilds",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "commerce": {
                        "storeSlug": "…",
                        "brandName": "Northwilds",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "booking": {
                        "locationId": "6650f1c2a9e4b1d2c3f40a5a",
                        "slug": "lofoten-sea-kayaking",
                        "locationName": "…",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "presenceOrbit": {
                        "siteSlug": "…",
                        "brandName": "Northwilds",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "careers": {
                        "siteSlug": "…",
                        "name": "Lofoten sea kayaking",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "experiments": {
                        "assignment": "cookieless"
                      }
                    },
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:update, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/access": {
      "get": {
        "operationId": "getMembersAndRolesAccess",
        "tags": [
          "Members and roles"
        ],
        "summary": "Who can open a space, including organisation members whose role sees every space",
        "description": "Who can open a space, including organisation members whose role sees every space. Permission: member:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "List of members.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/SpaceMember"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "membershipId": "6650f1c2a9e4b1d2c3f40a31",
                      "userId": "6650f1c2a9e4b1d2c3f40a30",
                      "email": "ingrid.berg@northwilds.com",
                      "name": "Ingrid Berg",
                      "role": "editor",
                      "roleName": "Editor",
                      "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                      "spaceName": "Northwilds website",
                      "status": "active",
                      "createdAt": "2026-11-02T09:30:00.000Z",
                      "viaOrganisation": false,
                      "regionKeys": [
                        "…"
                      ]
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks member:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postMembersAndRolesAccess",
        "tags": [
          "Members and roles"
        ],
        "summary": "Invites a person to one space",
        "description": "Invites a person to one space. Permission: member:invite.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "email": {
                    "type": "string"
                  },
                  "role": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 64,
                    "pattern": "^[a-z][a-z0-9_-]*$"
                  },
                  "spaceId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "Ignored: the space in the address is used."
                  }
                },
                "required": [
                  "email",
                  "role"
                ]
              },
              "example": {
                "email": "ingrid.berg@northwilds.com",
                "role": "editor"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The member.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Member"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "membershipId": "6650f1c2a9e4b1d2c3f40a31",
                    "userId": "6650f1c2a9e4b1d2c3f40a30",
                    "email": "ingrid.berg@northwilds.com",
                    "name": "Ingrid Berg",
                    "role": "editor",
                    "roleName": "Editor",
                    "spaceId": null,
                    "spaceName": null,
                    "status": "active",
                    "createdAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or the role is the owner's or ranks at or above yours, or the email's domain is not allowed.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks member:invite, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "The person already has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/accessibility": {
      "get": {
        "operationId": "getSEOAndAccessibilitySettingsAccessibility",
        "tags": [
          "SEO and accessibility settings"
        ],
        "summary": "When accessibility problems warn or block publishing, and which guidelines apply",
        "description": "When accessibility problems warn or block publishing, and which guidelines apply. Permission: None.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "{ publish, tags }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/AccessibilitySettings"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "publish": "off",
                    "tags": [
                      "…"
                    ]
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "The token's person can't reach it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchSEOAndAccessibilitySettingsAccessibility",
        "tags": [
          "SEO and accessibility settings"
        ],
        "summary": "Changes them: publish is off, warn or block",
        "description": "Changes them: publish is off, warn or block. Permission: space:update.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "publish": {
                    "type": "string",
                    "enum": [
                      "off",
                      "warn",
                      "block"
                    ],
                    "description": "off, warn or block: what accessibility problems do to publishing."
                  },
                  "tags": {
                    "minItems": 1,
                    "maxItems": 7,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "enum": [
                        "wcag2a",
                        "wcag2aa",
                        "wcag21a",
                        "wcag21aa",
                        "wcag22aa",
                        "best-practice",
                        "wcag2aaa"
                      ]
                    },
                    "description": "The rule sets that apply, such as wcag2aa and best-practice."
                  }
                }
              },
              "example": {
                "publish": "block",
                "tags": [
                  "wcag2a",
                  "wcag2aa",
                  "wcag21aa"
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The settings.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/AccessibilitySettings"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "publish": "off",
                    "tags": [
                      "…"
                    ]
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:update, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/api-keys": {
      "get": {
        "operationId": "getDeliveryKeysApiKeys",
        "tags": [
          "Delivery keys"
        ],
        "summary": "The space's delivery keys",
        "description": "The space's delivery keys. Permission: apikey:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "List of keys.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/ApiKey"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a46",
                      "name": "northwilds.com",
                      "prefix": "cms_pk_3f9a",
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "environmentName": "Production",
                      "scopes": [
                        "content:read"
                      ],
                      "allowDraft": true,
                      "regionIds": [
                        "6650f1c2a9e4b1d2c3f40a17"
                      ],
                      "localeIds": [
                        "6650f1c2a9e4b1d2c3f40a18"
                      ],
                      "expiresAt": "2026-11-02T09:30:00.000Z",
                      "lastUsedAt": "2026-11-02T09:30:00.000Z",
                      "revokedAt": "2026-11-02T09:30:00.000Z",
                      "createdAt": "2026-11-02T09:30:00.000Z"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks apikey:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postDeliveryKeysApiKeys",
        "tags": [
          "Delivery keys"
        ],
        "summary": "Creates a key",
        "description": "Creates a key. Permission: apikey:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200,
                    "description": "Such as northwilds.com."
                  },
                  "environmentId": {
                    "type": "string",
                    "description": "The environment it reads."
                  },
                  "scopes": {
                    "default": [
                      "content:read"
                    ],
                    "minItems": 1,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "enum": [
                        "content:read",
                        "content:read_draft"
                      ]
                    },
                    "description": "Add content:read_draft for a secret key that reads drafts. Not for a production environment."
                  },
                  "regionIds": {
                    "type": [
                      "array",
                      "null"
                    ],
                    "items": {
                      "type": "string",
                      "description": "An id."
                    },
                    "description": "Only these regions, or null for all."
                  },
                  "localeIds": {
                    "type": [
                      "array",
                      "null"
                    ],
                    "items": {
                      "type": "string",
                      "description": "An id."
                    },
                    "description": "Only these languages, or null for all."
                  },
                  "expiresAt": {
                    "default": null,
                    "description": "In the future, or null for never."
                  }
                },
                "required": [
                  "name",
                  "environmentId"
                ]
              },
              "example": {
                "name": "northwilds.com",
                "environmentId": "6650f1c2a9e4b1d2c3f40a13"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "{ key, token }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "$ref": "#/components/schemas/ApiKey"
                        },
                        "token": {
                          "type": "string",
                          "description": "The key, starting with cms_pk_ (public) or cms_sk_ (secret). Shown only in this answer."
                        }
                      },
                      "required": [
                        "key",
                        "token"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "key": {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "name": "Lofoten sea kayaking",
                      "prefix": "…",
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "environmentName": "…",
                      "scopes": [
                        "content:read"
                      ],
                      "allowDraft": true,
                      "regionIds": [
                        "6650f1c2a9e4b1d2c3f40a17"
                      ],
                      "localeIds": [
                        "6650f1c2a9e4b1d2c3f40a18"
                      ],
                      "expiresAt": "2026-11-02T09:30:00.000Z",
                      "lastUsedAt": "2026-11-02T09:30:00.000Z",
                      "revokedAt": "2026-11-02T09:30:00.000Z",
                      "createdAt": "2026-11-02T09:30:00.000Z"
                    },
                    "token": "cms_pk_…"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or a draft-reading key for production, or an expiry in the past.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks apikey:manage, or the plan's active keys are used up.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/api-keys/{apiKeyId}": {
      "delete": {
        "operationId": "deleteDeliveryKeysApiKeysByApiKeyId",
        "tags": [
          "Delivery keys"
        ],
        "summary": "Revokes it, at once and for good",
        "description": "Revokes it, at once and for good. Permission: apikey:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "apiKeyId",
            "in": "path",
            "required": true,
            "description": "The api key's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks apikey:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such api key, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "API key not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchDeliveryKeysApiKeysByApiKeyId",
        "tags": [
          "Delivery keys"
        ],
        "summary": "Renames it: { \"name\": \"…\" }",
        "description": "Renames it: { \"name\": \"…\" }. Permission: apikey:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "apiKeyId",
            "in": "path",
            "required": true,
            "description": "The api key's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  }
                },
                "required": [
                  "name"
                ]
              },
              "example": {
                "name": "northwilds.com website"
              }
            }
          }
        },
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks apikey:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such api key, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "API key not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/api-keys/{apiKeyId}/remove": {
      "post": {
        "operationId": "postDeliveryKeysApiKeysByApiKeyIdRemove",
        "tags": [
          "Delivery keys"
        ],
        "summary": "Removes a revoked key from the list",
        "description": "Removes a revoked key from the list. Permission: apikey:delete.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "apiKeyId",
            "in": "path",
            "required": true,
            "description": "The api key's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "400": {
            "description": "Revoke the key first.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks apikey:delete, which Admins and Owners have.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such api key, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "API key not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/api-keys/{apiKeyId}/restore": {
      "post": {
        "operationId": "postDeliveryKeysApiKeysByApiKeyIdRestore",
        "tags": [
          "Delivery keys"
        ],
        "summary": "Puts a removed key back in the list, still revoked",
        "description": "Puts a removed key back in the list, still revoked. Permission: apikey:delete.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "apiKeyId",
            "in": "path",
            "required": true,
            "description": "The api key's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks apikey:delete, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such api key, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "API key not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/booking": {
      "get": {
        "operationId": "getConnectedSatellitesBooking",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Reads the booking Orbit connection: { connected, locationId }",
        "description": "Reads the booking Orbit connection: { connected, locationId }. Permission: space:update to change.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "The connection.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/BookingConnection"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "reachable": true,
                    "location": {
                      "locationId": "6650f1c2a9e4b1d2c3f40a5a",
                      "slug": "lofoten-sea-kayaking",
                      "name": "Lofoten sea kayaking",
                      "siteUrl": "https://northwilds.com",
                      "kind": "place",
                      "timeZone": "Europe/Oslo",
                      "currency": "NOK",
                      "logoUrl": null
                    },
                    "locations": [
                      {
                        "locationId": "6650f1c2a9e4b1d2c3f40a5a",
                        "slug": "lofoten-sea-kayaking",
                        "name": "Lofoten sea kayaking",
                        "siteUrl": "https://northwilds.com",
                        "kind": "place",
                        "timeZone": "Europe/Oslo",
                        "currency": "NOK",
                        "logoUrl": null
                      }
                    ],
                    "connection": {
                      "locationId": "6650f1c2a9e4b1d2c3f40a5a",
                      "slug": "lofoten-sea-kayaking",
                      "locationName": "…",
                      "siteUrl": "https://northwilds.com",
                      "connectedAt": "2026-11-02T09:30:00.000Z",
                      "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                    },
                    "canManage": true
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:update to change.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "put": {
        "operationId": "putConnectedSatellitesBooking",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Changes the booking Orbit connection: { connected, locationId }",
        "description": "Changes the booking Orbit connection: { connected, locationId }. Permission: space:update to change.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "connected": {
                    "type": "boolean"
                  },
                  "locationId": {
                    "type": "string",
                    "maxLength": 80,
                    "description": "Which location the space shows. Needed when the organisation has more than one."
                  }
                },
                "required": [
                  "connected"
                ]
              },
              "example": {
                "connected": true,
                "locationId": "loc_tromso"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The connection.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/BookingConnection"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "reachable": true,
                    "location": {
                      "locationId": "6650f1c2a9e4b1d2c3f40a5a",
                      "slug": "lofoten-sea-kayaking",
                      "name": "Lofoten sea kayaking",
                      "siteUrl": "https://northwilds.com",
                      "kind": "place",
                      "timeZone": "Europe/Oslo",
                      "currency": "NOK",
                      "logoUrl": null
                    },
                    "locations": [
                      {
                        "locationId": "6650f1c2a9e4b1d2c3f40a5a",
                        "slug": "lofoten-sea-kayaking",
                        "name": "Lofoten sea kayaking",
                        "siteUrl": "https://northwilds.com",
                        "kind": "place",
                        "timeZone": "Europe/Oslo",
                        "currency": "NOK",
                        "logoUrl": null
                      }
                    ],
                    "connection": {
                      "locationId": "6650f1c2a9e4b1d2c3f40a5a",
                      "slug": "lofoten-sea-kayaking",
                      "locationName": "…",
                      "siteUrl": "https://northwilds.com",
                      "connectedAt": "2026-11-02T09:30:00.000Z",
                      "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                    },
                    "canManage": true
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or booking Orbit could not be reached, or no location to connect.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:update to change, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/booking/services": {
      "get": {
        "operationId": "getConnectedSatellitesBookingServices",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Booking Orbit services",
        "description": "Booking Orbit services. A satellite that is not connected answers 400. Permission: Space access.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "locale",
            "in": "query",
            "required": false,
            "description": "The language to list in, such as nb-NO. Leave it out for the satellite's default.",
            "schema": {
              "type": "string"
            },
            "example": "nb-NO"
          }
        ],
        "responses": {
          "200": {
            "description": "List.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "summary": {
                            "type": "string"
                          },
                          "image": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "durationMinutes": {
                            "type": "integer"
                          },
                          "price": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "priceKind": {
                            "type": "string"
                          },
                          "currency": {
                            "type": "string"
                          },
                          "online": {
                            "type": "boolean"
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "summary",
                          "image",
                          "durationMinutes",
                          "price",
                          "priceKind",
                          "currency",
                          "online"
                        ]
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "name": "Lofoten sea kayaking",
                      "summary": "Six days of paddling between the peaks of Lofoten.",
                      "image": null,
                      "durationMinutes": 1,
                      "price": 1,
                      "priceKind": "…",
                      "currency": "NOK",
                      "online": false
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The satellite is not connected to this space, or could not be reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks Space access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/booking/staff": {
      "get": {
        "operationId": "getConnectedSatellitesBookingStaff",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Booking Orbit people",
        "description": "Booking Orbit people. A satellite that is not connected answers 400. Permission: Space access.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "List.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "title": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "photo": {
                            "type": [
                              "string",
                              "null"
                            ]
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "title",
                          "photo"
                        ]
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "name": "Lofoten sea kayaking",
                      "title": "Lofoten sea kayaking",
                      "photo": null
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The satellite is not connected to this space, or could not be reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks Space access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/careers": {
      "get": {
        "operationId": "getConnectedSatellitesCareers",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Reads the careers Orbit connection: { connected }",
        "description": "Reads the careers Orbit connection: { connected }. Permission: space:update to change.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "The connection.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/CareersConnection"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "reachable": true,
                    "site": {
                      "slug": "lofoten-sea-kayaking",
                      "name": "Lofoten sea kayaking",
                      "siteUrl": "https://northwilds.com",
                      "logoUrl": null,
                      "languages": [
                        "…"
                      ],
                      "defaultLanguage": "…"
                    },
                    "connection": {
                      "siteSlug": "…",
                      "name": "Lofoten sea kayaking",
                      "siteUrl": "https://northwilds.com",
                      "connectedAt": "2026-11-02T09:30:00.000Z",
                      "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                    },
                    "canManage": true
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:update to change.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "put": {
        "operationId": "putConnectedSatellitesCareers",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Changes the careers Orbit connection: { connected }",
        "description": "Changes the careers Orbit connection: { connected }. Permission: space:update to change.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "connected": {
                    "type": "boolean"
                  }
                },
                "required": [
                  "connected"
                ]
              },
              "example": {
                "connected": true
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The connection.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/CareersConnection"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "reachable": true,
                    "site": {
                      "slug": "lofoten-sea-kayaking",
                      "name": "Lofoten sea kayaking",
                      "siteUrl": "https://northwilds.com",
                      "logoUrl": null,
                      "languages": [
                        "…"
                      ],
                      "defaultLanguage": "…"
                    },
                    "connection": {
                      "siteSlug": "…",
                      "name": "Lofoten sea kayaking",
                      "siteUrl": "https://northwilds.com",
                      "connectedAt": "2026-11-02T09:30:00.000Z",
                      "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                    },
                    "canManage": true
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or careers Orbit could not be reached, or the organisation has no career site.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:update to change, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/careers/filters": {
      "get": {
        "operationId": "getConnectedSatellitesCareersFilters",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Careers Orbit job filters",
        "description": "Careers Orbit job filters. A satellite that is not connected answers 400. Permission: Space access.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "locale",
            "in": "query",
            "required": false,
            "description": "The language to list in, such as nb-NO. Leave it out for the satellite's default.",
            "schema": {
              "type": "string"
            },
            "example": "nb-NO"
          }
        ],
        "responses": {
          "200": {
            "description": "List.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "description": "The career site's job filters, such as departments and locations, as Careers Orbit answers them."
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": null
                }
              }
            }
          },
          "400": {
            "description": "The satellite is not connected to this space, or could not be reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks Space access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/careers/jobs": {
      "get": {
        "operationId": "getConnectedSatellitesCareersJobs",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Careers Orbit jobs, up to 100",
        "description": "Careers Orbit jobs, up to 100. A satellite that is not connected answers 400. Permission: Space access.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "locale",
            "in": "query",
            "required": false,
            "description": "The language to list in, such as nb-NO. Leave it out for the satellite's default.",
            "schema": {
              "type": "string"
            },
            "example": "nb-NO"
          }
        ],
        "responses": {
          "200": {
            "description": "List.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "meta": {
                            "type": "string",
                            "description": "Such as Tromsø · Full time."
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "meta"
                        ]
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "name": "Lofoten sea kayaking",
                      "meta": "…"
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The satellite is not connected to this space, or could not be reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks Space access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/clone": {
      "post": {
        "operationId": "postSpacesClone",
        "tags": [
          "Spaces"
        ],
        "summary": "Copies a space",
        "description": "Copies a space. Permission: space:clone.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "description": "The copy's name. Required."
                  },
                  "schema": {
                    "type": "boolean",
                    "description": "Copy content types, components and taxonomies. Default true."
                  },
                  "structure": {
                    "type": "boolean",
                    "description": "Copy regions and languages. Default true."
                  },
                  "content": {
                    "type": "boolean",
                    "description": "Copy pages, as drafts. Default false."
                  }
                },
                "required": [
                  "name"
                ]
              },
              "example": {
                "name": "Northwilds winter campaign",
                "content": true
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "What was copied.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "spaceId": {
                          "type": "string",
                          "description": "The new space's id."
                        },
                        "name": {
                          "type": "string"
                        },
                        "copied": {
                          "type": "object",
                          "additionalProperties": {
                            "type": "integer"
                          },
                          "description": "How many of each were copied, such as contentTypes and content."
                        }
                      },
                      "required": [
                        "spaceId",
                        "name",
                        "copied"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                    "name": "Lofoten sea kayaking",
                    "copied": {}
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or no name.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:clone, or the plan's websites are used up.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/commerce": {
      "get": {
        "operationId": "getConnectedSatellitesCommerce",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Reads the commerce Orbit connection: { connected, storeSlug }",
        "description": "Reads the commerce Orbit connection: { connected, storeSlug }. Permission: space:update to change.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "The connection.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/CommerceConnection"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "reachable": true,
                    "store": {
                      "shopId": "6650f1c2a9e4b1d2c3f40a56",
                      "storeSlug": "…",
                      "brandName": "Northwilds",
                      "siteUrl": "https://northwilds.com",
                      "locales": [
                        "nb-NO"
                      ],
                      "defaultLocale": "…",
                      "currency": "NOK",
                      "currencies": [
                        "…"
                      ]
                    },
                    "stores": [
                      {
                        "shopId": "6650f1c2a9e4b1d2c3f40a56",
                        "storeSlug": "…",
                        "brandName": "Northwilds",
                        "siteUrl": "https://northwilds.com",
                        "locales": [
                          "nb-NO"
                        ],
                        "defaultLocale": "…",
                        "currency": "NOK",
                        "currencies": [
                          "…"
                        ]
                      }
                    ],
                    "connection": {
                      "storeSlug": "…",
                      "brandName": "Northwilds",
                      "siteUrl": "https://northwilds.com",
                      "connectedAt": "2026-11-02T09:30:00.000Z",
                      "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                    },
                    "canManage": true
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:update to change.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "put": {
        "operationId": "putConnectedSatellitesCommerce",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Changes the commerce Orbit connection: { connected, storeSlug }",
        "description": "Changes the commerce Orbit connection: { connected, storeSlug }. Permission: space:update to change.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "connected": {
                    "type": "boolean"
                  },
                  "storeSlug": {
                    "type": "string",
                    "maxLength": 80,
                    "description": "Which shop the space shows. Needed when the organisation has more than one."
                  }
                },
                "required": [
                  "connected"
                ]
              },
              "example": {
                "connected": true,
                "storeSlug": "northwilds"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The connection.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/CommerceConnection"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "reachable": true,
                    "store": {
                      "shopId": "6650f1c2a9e4b1d2c3f40a56",
                      "storeSlug": "…",
                      "brandName": "Northwilds",
                      "siteUrl": "https://northwilds.com",
                      "locales": [
                        "nb-NO"
                      ],
                      "defaultLocale": "…",
                      "currency": "NOK",
                      "currencies": [
                        "…"
                      ]
                    },
                    "stores": [
                      {
                        "shopId": "6650f1c2a9e4b1d2c3f40a56",
                        "storeSlug": "…",
                        "brandName": "Northwilds",
                        "siteUrl": "https://northwilds.com",
                        "locales": [
                          "nb-NO"
                        ],
                        "defaultLocale": "…",
                        "currency": "NOK",
                        "currencies": [
                          "…"
                        ]
                      }
                    ],
                    "connection": {
                      "storeSlug": "…",
                      "brandName": "Northwilds",
                      "siteUrl": "https://northwilds.com",
                      "connectedAt": "2026-11-02T09:30:00.000Z",
                      "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                    },
                    "canManage": true
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or commerce Orbit could not be reached, or no shop to connect.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:update to change, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/commerce/collections": {
      "get": {
        "operationId": "getConnectedSatellitesCommerceCollections",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Commerce Orbit collections",
        "description": "Commerce Orbit collections. A satellite that is not connected answers 400. Permission: Space access.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "locale",
            "in": "query",
            "required": false,
            "description": "The language to list in, such as nb-NO. Leave it out for the satellite's default.",
            "schema": {
              "type": "string"
            },
            "example": "nb-NO"
          }
        ],
        "responses": {
          "200": {
            "description": "List.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "image": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "productCount": {
                            "type": "integer"
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "image",
                          "productCount"
                        ]
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "name": "Lofoten sea kayaking",
                      "image": null,
                      "productCount": 4
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The satellite is not connected to this space, or could not be reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks Space access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/commerce/products": {
      "get": {
        "operationId": "getConnectedSatellitesCommerceProducts",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Commerce Orbit products, up to 250; query to search",
        "description": "Commerce Orbit products, up to 250; query to search. A satellite that is not connected answers 400. Permission: Space access.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "locale",
            "in": "query",
            "required": false,
            "description": "The language to list in, such as nb-NO. Leave it out for the satellite's default.",
            "schema": {
              "type": "string"
            },
            "example": "nb-NO"
          },
          {
            "name": "query",
            "in": "query",
            "required": false,
            "description": "Only products matching this text.",
            "schema": {
              "type": "string"
            },
            "example": "fjell"
          }
        ],
        "responses": {
          "200": {
            "description": "List.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "summary": {
                            "type": "string"
                          },
                          "image": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "price": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "currency": {
                            "type": "string"
                          },
                          "available": {
                            "type": "boolean"
                          },
                          "stock": {
                            "type": [
                              "integer",
                              "null"
                            ]
                          },
                          "variants": {
                            "type": "integer"
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "summary",
                          "image",
                          "price",
                          "currency",
                          "available",
                          "stock",
                          "variants"
                        ]
                      },
                      "description": "Up to 250."
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "name": "Lofoten sea kayaking",
                      "summary": "Six days of paddling between the peaks of Lofoten.",
                      "image": null,
                      "price": 1,
                      "currency": "NOK",
                      "available": false,
                      "stock": 1,
                      "variants": 1
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The satellite is not connected to this space, or could not be reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks Space access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/shopify/products": {
      "get": {
        "operationId": "getConnectedSatellitesShopifyProducts",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Products from the organisation's Shopify shop, up to 25; q to search",
        "description": "Products from the organisation's Shopify shop, up to 25; q to search. Answers 400 when Shopify isn't connected in Orbit or the plan is below Growth. Permission: content:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "q",
            "in": "query",
            "required": false,
            "description": "Only products matching this text, such as a title or a tag.",
            "schema": {
              "type": "string"
            },
            "example": "down jacket"
          }
        ],
        "responses": {
          "200": {
            "description": "List.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string",
                            "description": "Shopify's id, such as gid://shopify/Product/7982301462741."
                          },
                          "handle": {
                            "type": "string",
                            "description": "Such as arctic-down-jacket."
                          },
                          "title": {
                            "type": "string"
                          },
                          "priceRange": {
                            "type": "object",
                            "properties": {
                              "min": {
                                "type": "object",
                                "properties": {
                                  "amount": {
                                    "type": "string",
                                    "description": "A decimal string, such as 249.0."
                                  },
                                  "currencyCode": {
                                    "type": "string",
                                    "description": "Such as NOK."
                                  }
                                },
                                "required": [
                                  "amount",
                                  "currencyCode"
                                ]
                              },
                              "max": {
                                "type": "object",
                                "properties": {
                                  "amount": {
                                    "type": "string",
                                    "description": "A decimal string, such as 249.0."
                                  },
                                  "currencyCode": {
                                    "type": "string",
                                    "description": "Such as NOK."
                                  }
                                },
                                "required": [
                                  "amount",
                                  "currencyCode"
                                ]
                              }
                            },
                            "required": [
                              "min",
                              "max"
                            ]
                          },
                          "image": {
                            "type": [
                              "object",
                              "null"
                            ],
                            "properties": {
                              "url": {
                                "type": "string"
                              },
                              "altText": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              },
                              "width": {
                                "type": [
                                  "integer",
                                  "null"
                                ]
                              },
                              "height": {
                                "type": [
                                  "integer",
                                  "null"
                                ]
                              }
                            },
                            "required": [
                              "url",
                              "altText",
                              "width",
                              "height"
                            ]
                          },
                          "url": {
                            "type": "string",
                            "description": "The product's page in the shop."
                          }
                        },
                        "required": [
                          "id",
                          "handle",
                          "title",
                          "priceRange",
                          "image",
                          "url"
                        ]
                      },
                      "description": "Up to 25, the best matches first, or by title without q."
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "handle": "…",
                      "title": "Lofoten sea kayaking",
                      "priceRange": {
                        "min": {
                          "amount": "…",
                          "currencyCode": "…"
                        },
                        "max": {
                          "amount": "…",
                          "currencyCode": "…"
                        }
                      },
                      "image": {
                        "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                        "altText": null,
                        "width": 1,
                        "height": 1
                      },
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking"
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Shopify isn't connected in Orbit, the plan is below Growth, or Shopify didn't answer.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/components": {
      "get": {
        "operationId": "getContentTypesAndComponentsComponents",
        "tags": [
          "Content types and components"
        ],
        "summary": "Every component (block type)",
        "description": "Every component (block type). Permission: schema:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "List.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Component"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a49",
                      "key": "hero",
                      "name": "Hero",
                      "description": "Six days of paddling between the peaks of Lofoten.",
                      "icon": null,
                      "group": "Page top",
                      "fields": [
                        {
                          "key": "title",
                          "name": "Title",
                          "type": "text",
                          "description": "Six days of paddling between the peaks of Lofoten.",
                          "required": true,
                          "default": null,
                          "validation": {
                            "min": 1,
                            "max": 1,
                            "minLength": 1,
                            "maxLength": 1,
                            "pattern": "…",
                            "message": "…"
                          },
                          "options": [
                            {
                              "label": "Kayaking",
                              "value": "…"
                            }
                          ],
                          "allowedComponents": [
                            "…"
                          ],
                          "allowedContentTypes": [
                            "…"
                          ],
                          "allowedMimeTypes": [
                            "…"
                          ],
                          "taxonomyKey": "…",
                          "localised": false,
                          "regional": false,
                          "protects": "none",
                          "group": "…",
                          "hidden": false,
                          "showWhen": {
                            "field": "…",
                            "equals": null
                          },
                          "step": 1,
                          "unit": "…",
                          "halfStars": false,
                          "languages": [
                            "text"
                          ],
                          "defaultLanguage": "text"
                        }
                      ],
                      "allowedChildren": [
                        "…"
                      ],
                      "isRoot": true,
                      "isNestable": true,
                      "previewImage": null,
                      "mainHeading": null,
                      "mainHeadingWhen": null,
                      "hiddenFromLibrary": false,
                      "schemaVersion": 12,
                      "deprecated": false,
                      "updatedAt": "2026-11-02T09:30:00.000Z"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postContentTypesAndComponentsComponents",
        "tags": [
          "Content types and components"
        ],
        "summary": "Adds one",
        "description": "Adds one. Permission: schema:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 64,
                    "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$",
                    "description": "Such as hero. Never changes."
                  },
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "description": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 500
                  },
                  "icon": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 60
                  },
                  "group": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 60
                  },
                  "fields": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 64,
                          "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                        },
                        "name": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 200
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "text",
                            "textarea",
                            "richtext",
                            "number",
                            "boolean",
                            "select",
                            "multiselect",
                            "color",
                            "slider",
                            "rating",
                            "code",
                            "palette",
                            "date",
                            "time",
                            "datetime",
                            "asset",
                            "assets",
                            "link",
                            "targets",
                            "reference",
                            "references",
                            "taxonomy",
                            "taxonomyTerms",
                            "claims",
                            "component",
                            "components",
                            "trip",
                            "trips",
                            "destination",
                            "departure",
                            "product",
                            "products",
                            "collection",
                            "bookingService",
                            "bookingServices",
                            "bookingStaff",
                            "reviewLocation",
                            "job",
                            "jobFilter",
                            "shopifyProduct",
                            "shopifyProducts"
                          ]
                        },
                        "description": {
                          "type": "string",
                          "maxLength": 300
                        },
                        "required": {
                          "default": false,
                          "type": "boolean"
                        },
                        "default": {
                          "description": "Any JSON value."
                        },
                        "validation": {
                          "type": "object",
                          "properties": {
                            "min": {
                              "type": "number"
                            },
                            "max": {
                              "type": "number"
                            },
                            "minLength": {
                              "type": "integer",
                              "minimum": 0
                            },
                            "maxLength": {
                              "type": "integer",
                              "minimum": 1
                            },
                            "pattern": {
                              "type": "string",
                              "maxLength": 200
                            },
                            "message": {
                              "type": "string",
                              "maxLength": 200
                            }
                          }
                        },
                        "options": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "label": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 120
                              },
                              "value": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 120
                              }
                            },
                            "required": [
                              "label",
                              "value"
                            ]
                          }
                        },
                        "allowedComponents": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 64,
                            "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                          }
                        },
                        "allowedContentTypes": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 64,
                            "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                          }
                        },
                        "allowedMimeTypes": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "maxLength": 100
                          }
                        },
                        "taxonomyKey": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 64,
                          "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                        },
                        "localised": {
                          "type": "boolean"
                        },
                        "regional": {
                          "type": "boolean"
                        },
                        "protects": {
                          "type": "string",
                          "enum": [
                            "none",
                            "price",
                            "promotion"
                          ]
                        },
                        "group": {
                          "type": "string",
                          "maxLength": 60
                        },
                        "hidden": {
                          "type": "boolean"
                        },
                        "showWhen": {
                          "type": "object",
                          "properties": {
                            "field": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 64,
                              "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                            },
                            "equals": {
                              "anyOf": [
                                {
                                  "type": "boolean"
                                },
                                {
                                  "type": "string",
                                  "maxLength": 120
                                },
                                {
                                  "minItems": 1,
                                  "maxItems": 50,
                                  "type": "array",
                                  "items": {
                                    "type": "string",
                                    "maxLength": 120
                                  }
                                }
                              ]
                            }
                          },
                          "required": [
                            "field",
                            "equals"
                          ]
                        },
                        "step": {
                          "type": "number",
                          "exclusiveMinimum": 0
                        },
                        "unit": {
                          "type": "string",
                          "maxLength": 20
                        },
                        "halfStars": {
                          "type": "boolean"
                        },
                        "languages": {
                          "maxItems": 22,
                          "type": "array",
                          "items": {
                            "type": "string",
                            "enum": [
                              "text",
                              "ts",
                              "tsx",
                              "js",
                              "json",
                              "html",
                              "xml",
                              "yaml",
                              "graphql",
                              "bash",
                              "python",
                              "php",
                              "java",
                              "kotlin",
                              "swift",
                              "vue",
                              "svelte",
                              "astro",
                              "blade",
                              "twig",
                              "dockerfile",
                              "http"
                            ]
                          }
                        },
                        "defaultLanguage": {
                          "type": "string",
                          "enum": [
                            "text",
                            "ts",
                            "tsx",
                            "js",
                            "json",
                            "html",
                            "xml",
                            "yaml",
                            "graphql",
                            "bash",
                            "python",
                            "php",
                            "java",
                            "kotlin",
                            "swift",
                            "vue",
                            "svelte",
                            "astro",
                            "blade",
                            "twig",
                            "dockerfile",
                            "http"
                          ]
                        }
                      },
                      "required": [
                        "key",
                        "name",
                        "type"
                      ]
                    },
                    "description": "The fields. See the Field schema and the field types guide."
                  },
                  "allowedChildren": {
                    "default": [],
                    "anyOf": [
                      {
                        "type": "string",
                        "const": "*"
                      },
                      {
                        "type": "array",
                        "items": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 64,
                          "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                        }
                      }
                    ],
                    "description": "* or the keys of blocks its slots may hold."
                  },
                  "isRoot": {
                    "default": true,
                    "type": "boolean",
                    "description": "May sit at the top of a page."
                  },
                  "isNestable": {
                    "default": true,
                    "type": "boolean",
                    "description": "May sit inside another block."
                  },
                  "previewImage": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 500
                  },
                  "mainHeading": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 64
                  },
                  "mainHeadingWhen": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 64
                  },
                  "hiddenFromLibrary": {
                    "type": "boolean"
                  }
                },
                "required": [
                  "key",
                  "name"
                ]
              },
              "example": {
                "key": "tripHighlights",
                "name": "Trip highlights",
                "group": "Trips",
                "fields": [
                  {
                    "key": "heading",
                    "name": "Heading",
                    "type": "text",
                    "required": true
                  },
                  {
                    "key": "items",
                    "name": "Highlights",
                    "type": "textarea"
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The new item.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Component"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a49",
                    "key": "hero",
                    "name": "Hero",
                    "description": "Six days of paddling between the peaks of Lofoten.",
                    "icon": null,
                    "group": "Page top",
                    "fields": [
                      {
                        "key": "title",
                        "name": "Title",
                        "type": "text",
                        "description": "Six days of paddling between the peaks of Lofoten.",
                        "required": true,
                        "default": null,
                        "validation": {
                          "min": 1,
                          "max": 1,
                          "minLength": 1,
                          "maxLength": 1,
                          "pattern": "…",
                          "message": "…"
                        },
                        "options": [
                          {
                            "label": "Kayaking",
                            "value": "…"
                          }
                        ],
                        "allowedComponents": [
                          "…"
                        ],
                        "allowedContentTypes": [
                          "…"
                        ],
                        "allowedMimeTypes": [
                          "…"
                        ],
                        "taxonomyKey": "…",
                        "localised": false,
                        "regional": false,
                        "protects": "none",
                        "group": "…",
                        "hidden": false,
                        "showWhen": {
                          "field": "…",
                          "equals": null
                        },
                        "step": 1,
                        "unit": "…",
                        "halfStars": false,
                        "languages": [
                          "text"
                        ],
                        "defaultLanguage": "text"
                      }
                    ],
                    "allowedChildren": [
                      "…"
                    ],
                    "isRoot": true,
                    "isNestable": true,
                    "previewImage": null,
                    "mainHeading": null,
                    "mainHeadingWhen": null,
                    "hiddenFromLibrary": false,
                    "schemaVersion": 12,
                    "deprecated": false,
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or a field nests components in a way that loops, or a main heading that isn't a text field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "A component with the key exists.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/components/{key}": {
      "delete": {
        "operationId": "deleteContentTypesAndComponentsComponentsByKey",
        "tags": [
          "Content types and components"
        ],
        "summary": "Deletes one no page or component uses",
        "description": "Deletes one no page or component uses. Permission: schema:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "key",
            "in": "path",
            "required": true,
            "description": "The key, such as trip, hero or activity.",
            "schema": {
              "type": "string"
            },
            "example": "trip"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such item with that key, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Component not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "Pages or other components still use it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "get": {
        "operationId": "getContentTypesAndComponentsComponentsByKey",
        "tags": [
          "Content types and components"
        ],
        "summary": "One component",
        "description": "One component. Permission: schema:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "key",
            "in": "path",
            "required": true,
            "description": "The key, such as trip, hero or activity.",
            "schema": {
              "type": "string"
            },
            "example": "trip"
          }
        ],
        "responses": {
          "200": {
            "description": "The component.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Component"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a49",
                    "key": "hero",
                    "name": "Hero",
                    "description": "Six days of paddling between the peaks of Lofoten.",
                    "icon": null,
                    "group": "Page top",
                    "fields": [
                      {
                        "key": "title",
                        "name": "Title",
                        "type": "text",
                        "description": "Six days of paddling between the peaks of Lofoten.",
                        "required": true,
                        "default": null,
                        "validation": {
                          "min": 1,
                          "max": 1,
                          "minLength": 1,
                          "maxLength": 1,
                          "pattern": "…",
                          "message": "…"
                        },
                        "options": [
                          {
                            "label": "Kayaking",
                            "value": "…"
                          }
                        ],
                        "allowedComponents": [
                          "…"
                        ],
                        "allowedContentTypes": [
                          "…"
                        ],
                        "allowedMimeTypes": [
                          "…"
                        ],
                        "taxonomyKey": "…",
                        "localised": false,
                        "regional": false,
                        "protects": "none",
                        "group": "…",
                        "hidden": false,
                        "showWhen": {
                          "field": "…",
                          "equals": null
                        },
                        "step": 1,
                        "unit": "…",
                        "halfStars": false,
                        "languages": [
                          "text"
                        ],
                        "defaultLanguage": "text"
                      }
                    ],
                    "allowedChildren": [
                      "…"
                    ],
                    "isRoot": true,
                    "isNestable": true,
                    "previewImage": null,
                    "mainHeading": null,
                    "mainHeadingWhen": null,
                    "hiddenFromLibrary": false,
                    "schemaVersion": 12,
                    "deprecated": false,
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such item with that key, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Component not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchContentTypesAndComponentsComponentsByKey",
        "tags": [
          "Content types and components"
        ],
        "summary": "Changes one, or marks it deprecated",
        "description": "Changes one, or marks it deprecated. Permission: schema:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "key",
            "in": "path",
            "required": true,
            "description": "The key, such as trip, hero or activity.",
            "schema": {
              "type": "string"
            },
            "example": "trip"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "description": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 500
                  },
                  "icon": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 60
                  },
                  "group": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 60
                  },
                  "fields": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 64,
                          "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                        },
                        "name": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 200
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "text",
                            "textarea",
                            "richtext",
                            "number",
                            "boolean",
                            "select",
                            "multiselect",
                            "color",
                            "slider",
                            "rating",
                            "code",
                            "palette",
                            "date",
                            "time",
                            "datetime",
                            "asset",
                            "assets",
                            "link",
                            "targets",
                            "reference",
                            "references",
                            "taxonomy",
                            "taxonomyTerms",
                            "claims",
                            "component",
                            "components",
                            "trip",
                            "trips",
                            "destination",
                            "departure",
                            "product",
                            "products",
                            "collection",
                            "bookingService",
                            "bookingServices",
                            "bookingStaff",
                            "reviewLocation",
                            "job",
                            "jobFilter",
                            "shopifyProduct",
                            "shopifyProducts"
                          ]
                        },
                        "description": {
                          "type": "string",
                          "maxLength": 300
                        },
                        "required": {
                          "default": false,
                          "type": "boolean"
                        },
                        "default": {
                          "description": "Any JSON value."
                        },
                        "validation": {
                          "type": "object",
                          "properties": {
                            "min": {
                              "type": "number"
                            },
                            "max": {
                              "type": "number"
                            },
                            "minLength": {
                              "type": "integer",
                              "minimum": 0
                            },
                            "maxLength": {
                              "type": "integer",
                              "minimum": 1
                            },
                            "pattern": {
                              "type": "string",
                              "maxLength": 200
                            },
                            "message": {
                              "type": "string",
                              "maxLength": 200
                            }
                          }
                        },
                        "options": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "label": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 120
                              },
                              "value": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 120
                              }
                            },
                            "required": [
                              "label",
                              "value"
                            ]
                          }
                        },
                        "allowedComponents": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 64,
                            "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                          }
                        },
                        "allowedContentTypes": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 64,
                            "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                          }
                        },
                        "allowedMimeTypes": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "maxLength": 100
                          }
                        },
                        "taxonomyKey": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 64,
                          "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                        },
                        "localised": {
                          "type": "boolean"
                        },
                        "regional": {
                          "type": "boolean"
                        },
                        "protects": {
                          "type": "string",
                          "enum": [
                            "none",
                            "price",
                            "promotion"
                          ]
                        },
                        "group": {
                          "type": "string",
                          "maxLength": 60
                        },
                        "hidden": {
                          "type": "boolean"
                        },
                        "showWhen": {
                          "type": "object",
                          "properties": {
                            "field": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 64,
                              "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                            },
                            "equals": {
                              "anyOf": [
                                {
                                  "type": "boolean"
                                },
                                {
                                  "type": "string",
                                  "maxLength": 120
                                },
                                {
                                  "minItems": 1,
                                  "maxItems": 50,
                                  "type": "array",
                                  "items": {
                                    "type": "string",
                                    "maxLength": 120
                                  }
                                }
                              ]
                            }
                          },
                          "required": [
                            "field",
                            "equals"
                          ]
                        },
                        "step": {
                          "type": "number",
                          "exclusiveMinimum": 0
                        },
                        "unit": {
                          "type": "string",
                          "maxLength": 20
                        },
                        "halfStars": {
                          "type": "boolean"
                        },
                        "languages": {
                          "maxItems": 22,
                          "type": "array",
                          "items": {
                            "type": "string",
                            "enum": [
                              "text",
                              "ts",
                              "tsx",
                              "js",
                              "json",
                              "html",
                              "xml",
                              "yaml",
                              "graphql",
                              "bash",
                              "python",
                              "php",
                              "java",
                              "kotlin",
                              "swift",
                              "vue",
                              "svelte",
                              "astro",
                              "blade",
                              "twig",
                              "dockerfile",
                              "http"
                            ]
                          }
                        },
                        "defaultLanguage": {
                          "type": "string",
                          "enum": [
                            "text",
                            "ts",
                            "tsx",
                            "js",
                            "json",
                            "html",
                            "xml",
                            "yaml",
                            "graphql",
                            "bash",
                            "python",
                            "php",
                            "java",
                            "kotlin",
                            "swift",
                            "vue",
                            "svelte",
                            "astro",
                            "blade",
                            "twig",
                            "dockerfile",
                            "http"
                          ]
                        }
                      },
                      "required": [
                        "key",
                        "name",
                        "type"
                      ]
                    }
                  },
                  "allowedChildren": {
                    "anyOf": [
                      {
                        "type": "string",
                        "const": "*"
                      },
                      {
                        "type": "array",
                        "items": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 64,
                          "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                        }
                      }
                    ]
                  },
                  "isRoot": {
                    "type": "boolean"
                  },
                  "isNestable": {
                    "type": "boolean"
                  },
                  "previewImage": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 500
                  },
                  "deprecated": {
                    "type": "boolean"
                  },
                  "mainHeading": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 64
                  },
                  "mainHeadingWhen": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 64
                  },
                  "hiddenFromLibrary": {
                    "type": "boolean"
                  }
                }
              },
              "example": {
                "name": "Trip highlights",
                "deprecated": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The component.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Component"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a49",
                    "key": "hero",
                    "name": "Hero",
                    "description": "Six days of paddling between the peaks of Lofoten.",
                    "icon": null,
                    "group": "Page top",
                    "fields": [
                      {
                        "key": "title",
                        "name": "Title",
                        "type": "text",
                        "description": "Six days of paddling between the peaks of Lofoten.",
                        "required": true,
                        "default": null,
                        "validation": {
                          "min": 1,
                          "max": 1,
                          "minLength": 1,
                          "maxLength": 1,
                          "pattern": "…",
                          "message": "…"
                        },
                        "options": [
                          {
                            "label": "Kayaking",
                            "value": "…"
                          }
                        ],
                        "allowedComponents": [
                          "…"
                        ],
                        "allowedContentTypes": [
                          "…"
                        ],
                        "allowedMimeTypes": [
                          "…"
                        ],
                        "taxonomyKey": "…",
                        "localised": false,
                        "regional": false,
                        "protects": "none",
                        "group": "…",
                        "hidden": false,
                        "showWhen": {
                          "field": "…",
                          "equals": null
                        },
                        "step": 1,
                        "unit": "…",
                        "halfStars": false,
                        "languages": [
                          "text"
                        ],
                        "defaultLanguage": "text"
                      }
                    ],
                    "allowedChildren": [
                      "…"
                    ],
                    "isRoot": true,
                    "isNestable": true,
                    "previewImage": null,
                    "mainHeading": null,
                    "mainHeadingWhen": null,
                    "hiddenFromLibrary": false,
                    "schemaVersion": 12,
                    "deprecated": false,
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or a field nests components in a way that loops, or a main heading that isn't a text field.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such item with that key, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Component not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/components/{key}/brand": {
      "put": {
        "operationId": "putContentTypesAndComponentsComponentsByKeyBrand",
        "tags": [
          "Content types and components"
        ],
        "summary": "Locks it, or asks for brand sign-off: { locked, brandApproval }",
        "description": "Locks it, or asks for brand sign-off: { locked, brandApproval }. Permission: brand:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "key",
            "in": "path",
            "required": true,
            "description": "The key, such as trip, hero or activity.",
            "schema": {
              "type": "string"
            },
            "example": "trip"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "locked": {
                    "type": "boolean",
                    "description": "Only people with brand:manage can change its fields."
                  },
                  "brandApproval": {
                    "type": "boolean",
                    "description": "Changes need brand sign-off before publishing."
                  }
                },
                "required": []
              },
              "example": {
                "locked": true,
                "brandApproval": true
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "{ locked, brandApproval }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "locked": {
                          "type": "boolean"
                        },
                        "brandApproval": {
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "locked",
                        "brandApproval"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "locked": false,
                    "brandApproval": false
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks brand:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such item with that key, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Component not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/content-types": {
      "get": {
        "operationId": "getContentTypesAndComponentsContentTypes",
        "tags": [
          "Content types and components"
        ],
        "summary": "Every content type",
        "description": "Every content type. Permission: schema:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "List.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/ContentType"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a4b",
                      "key": "trip",
                      "name": "Trip",
                      "description": "A trip with its departures.",
                      "icon": null,
                      "group": null,
                      "fields": [
                        {
                          "key": "title",
                          "name": "Title",
                          "type": "text",
                          "description": "Six days of paddling between the peaks of Lofoten.",
                          "required": true,
                          "default": null,
                          "validation": {
                            "min": 1,
                            "max": 1,
                            "minLength": 1,
                            "maxLength": 1,
                            "pattern": "…",
                            "message": "…"
                          },
                          "options": [
                            {
                              "label": "Kayaking",
                              "value": "…"
                            }
                          ],
                          "allowedComponents": [
                            "…"
                          ],
                          "allowedContentTypes": [
                            "…"
                          ],
                          "allowedMimeTypes": [
                            "…"
                          ],
                          "taxonomyKey": "…",
                          "localised": false,
                          "regional": false,
                          "protects": "none",
                          "group": "…",
                          "hidden": false,
                          "showWhen": {
                            "field": "…",
                            "equals": null
                          },
                          "step": 1,
                          "unit": "…",
                          "halfStars": false,
                          "languages": [
                            "text"
                          ],
                          "defaultLanguage": "text"
                        }
                      ],
                      "allowedComponents": [
                        "…"
                      ],
                      "template": [
                        "…"
                      ],
                      "seo": {
                        "enabled": true,
                        "fields": [
                          {
                            "key": "title",
                            "name": "Title",
                            "type": "text",
                            "description": "Six days of paddling between the peaks of Lofoten.",
                            "required": true,
                            "default": null,
                            "validation": {
                              "min": 1,
                              "max": 1,
                              "minLength": 1,
                              "maxLength": 1,
                              "pattern": "…",
                              "message": "…"
                            },
                            "options": [
                              {
                                "label": "Kayaking",
                                "value": "…"
                              }
                            ],
                            "allowedComponents": [
                              "…"
                            ],
                            "allowedContentTypes": [
                              "…"
                            ],
                            "allowedMimeTypes": [
                              "…"
                            ],
                            "taxonomyKey": "…",
                            "localised": false,
                            "regional": false,
                            "protects": "none",
                            "group": "…",
                            "hidden": false,
                            "showWhen": {
                              "field": "…",
                              "equals": null
                            },
                            "step": 1,
                            "unit": "…",
                            "halfStars": false,
                            "languages": [
                              "text"
                            ],
                            "defaultLanguage": "text"
                          }
                        ],
                        "titleTemplate": null,
                        "descriptionField": null,
                        "sitemapPriority": 1,
                        "sitemapChangeFrequency": null,
                        "noIndexByDefault": false
                      },
                      "slugBehaviour": {
                        "source": "name",
                        "editable": true,
                        "unique": true
                      },
                      "publishing": {
                        "requiresApproval": false,
                        "steps": [
                          {
                            "key": "lofoten",
                            "name": "Lofoten sea kayaking",
                            "role": null,
                            "permission": null
                          }
                        ],
                        "regionSteps": {},
                        "reviewMonths": 1
                      },
                      "isGlobal": false,
                      "singleton": false,
                      "urlPrefix": null,
                      "editor": "preview",
                      "mainHeading": null,
                      "schemaVersion": 12,
                      "updatedAt": "2026-11-02T09:30:00.000Z"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postContentTypesAndComponentsContentTypes",
        "tags": [
          "Content types and components"
        ],
        "summary": "Adds one",
        "description": "Adds one. Permission: schema:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 64,
                    "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$",
                    "description": "Such as trip. Never changes."
                  },
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "description": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 500
                  },
                  "icon": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 60
                  },
                  "group": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 60
                  },
                  "fields": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 64,
                          "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                        },
                        "name": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 200
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "text",
                            "textarea",
                            "richtext",
                            "number",
                            "boolean",
                            "select",
                            "multiselect",
                            "color",
                            "slider",
                            "rating",
                            "code",
                            "palette",
                            "date",
                            "time",
                            "datetime",
                            "asset",
                            "assets",
                            "link",
                            "targets",
                            "reference",
                            "references",
                            "taxonomy",
                            "taxonomyTerms",
                            "claims",
                            "component",
                            "components",
                            "trip",
                            "trips",
                            "destination",
                            "departure",
                            "product",
                            "products",
                            "collection",
                            "bookingService",
                            "bookingServices",
                            "bookingStaff",
                            "reviewLocation",
                            "job",
                            "jobFilter",
                            "shopifyProduct",
                            "shopifyProducts"
                          ]
                        },
                        "description": {
                          "type": "string",
                          "maxLength": 300
                        },
                        "required": {
                          "default": false,
                          "type": "boolean"
                        },
                        "default": {
                          "description": "Any JSON value."
                        },
                        "validation": {
                          "type": "object",
                          "properties": {
                            "min": {
                              "type": "number"
                            },
                            "max": {
                              "type": "number"
                            },
                            "minLength": {
                              "type": "integer",
                              "minimum": 0
                            },
                            "maxLength": {
                              "type": "integer",
                              "minimum": 1
                            },
                            "pattern": {
                              "type": "string",
                              "maxLength": 200
                            },
                            "message": {
                              "type": "string",
                              "maxLength": 200
                            }
                          }
                        },
                        "options": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "label": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 120
                              },
                              "value": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 120
                              }
                            },
                            "required": [
                              "label",
                              "value"
                            ]
                          }
                        },
                        "allowedComponents": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 64,
                            "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                          }
                        },
                        "allowedContentTypes": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 64,
                            "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                          }
                        },
                        "allowedMimeTypes": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "maxLength": 100
                          }
                        },
                        "taxonomyKey": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 64,
                          "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                        },
                        "localised": {
                          "type": "boolean"
                        },
                        "regional": {
                          "type": "boolean"
                        },
                        "protects": {
                          "type": "string",
                          "enum": [
                            "none",
                            "price",
                            "promotion"
                          ]
                        },
                        "group": {
                          "type": "string",
                          "maxLength": 60
                        },
                        "hidden": {
                          "type": "boolean"
                        },
                        "showWhen": {
                          "type": "object",
                          "properties": {
                            "field": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 64,
                              "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                            },
                            "equals": {
                              "anyOf": [
                                {
                                  "type": "boolean"
                                },
                                {
                                  "type": "string",
                                  "maxLength": 120
                                },
                                {
                                  "minItems": 1,
                                  "maxItems": 50,
                                  "type": "array",
                                  "items": {
                                    "type": "string",
                                    "maxLength": 120
                                  }
                                }
                              ]
                            }
                          },
                          "required": [
                            "field",
                            "equals"
                          ]
                        },
                        "step": {
                          "type": "number",
                          "exclusiveMinimum": 0
                        },
                        "unit": {
                          "type": "string",
                          "maxLength": 20
                        },
                        "halfStars": {
                          "type": "boolean"
                        },
                        "languages": {
                          "maxItems": 22,
                          "type": "array",
                          "items": {
                            "type": "string",
                            "enum": [
                              "text",
                              "ts",
                              "tsx",
                              "js",
                              "json",
                              "html",
                              "xml",
                              "yaml",
                              "graphql",
                              "bash",
                              "python",
                              "php",
                              "java",
                              "kotlin",
                              "swift",
                              "vue",
                              "svelte",
                              "astro",
                              "blade",
                              "twig",
                              "dockerfile",
                              "http"
                            ]
                          }
                        },
                        "defaultLanguage": {
                          "type": "string",
                          "enum": [
                            "text",
                            "ts",
                            "tsx",
                            "js",
                            "json",
                            "html",
                            "xml",
                            "yaml",
                            "graphql",
                            "bash",
                            "python",
                            "php",
                            "java",
                            "kotlin",
                            "swift",
                            "vue",
                            "svelte",
                            "astro",
                            "blade",
                            "twig",
                            "dockerfile",
                            "http"
                          ]
                        }
                      },
                      "required": [
                        "key",
                        "name",
                        "type"
                      ]
                    },
                    "description": "The fields. See the Field schema and the field types guide."
                  },
                  "allowedComponents": {
                    "default": "*",
                    "anyOf": [
                      {
                        "type": "string",
                        "const": "*"
                      },
                      {
                        "type": "array",
                        "items": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 64,
                          "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                        }
                      }
                    ],
                    "description": "* or the keys of blocks the body may hold."
                  },
                  "template": {
                    "default": [],
                    "type": "array",
                    "items": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 64,
                      "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                    },
                    "description": "Blocks a new item starts with."
                  },
                  "seo": {
                    "type": "object",
                    "properties": {
                      "enabled": {
                        "default": true,
                        "type": "boolean"
                      },
                      "fields": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "key": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 64,
                              "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                            },
                            "name": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 200
                            },
                            "type": {
                              "type": "string",
                              "enum": [
                                "text",
                                "textarea",
                                "richtext",
                                "number",
                                "boolean",
                                "select",
                                "multiselect",
                                "color",
                                "slider",
                                "rating",
                                "code",
                                "palette",
                                "date",
                                "time",
                                "datetime",
                                "asset",
                                "assets",
                                "link",
                                "targets",
                                "reference",
                                "references",
                                "taxonomy",
                                "taxonomyTerms",
                                "claims",
                                "component",
                                "components",
                                "trip",
                                "trips",
                                "destination",
                                "departure",
                                "product",
                                "products",
                                "collection",
                                "bookingService",
                                "bookingServices",
                                "bookingStaff",
                                "reviewLocation",
                                "job",
                                "jobFilter",
                                "shopifyProduct",
                                "shopifyProducts"
                              ]
                            },
                            "description": {
                              "type": "string",
                              "maxLength": 300
                            },
                            "required": {
                              "default": false,
                              "type": "boolean"
                            },
                            "default": {
                              "description": "Any JSON value."
                            },
                            "validation": {
                              "type": "object",
                              "properties": {
                                "min": {
                                  "type": "number"
                                },
                                "max": {
                                  "type": "number"
                                },
                                "minLength": {
                                  "type": "integer",
                                  "minimum": 0
                                },
                                "maxLength": {
                                  "type": "integer",
                                  "minimum": 1
                                },
                                "pattern": {
                                  "type": "string",
                                  "maxLength": 200
                                },
                                "message": {
                                  "type": "string",
                                  "maxLength": 200
                                }
                              }
                            },
                            "options": {
                              "type": "array",
                              "items": {
                                "type": "object",
                                "properties": {
                                  "label": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 120
                                  },
                                  "value": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 120
                                  }
                                },
                                "required": [
                                  "label",
                                  "value"
                                ]
                              }
                            },
                            "allowedComponents": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 64,
                                "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                              }
                            },
                            "allowedContentTypes": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 64,
                                "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                              }
                            },
                            "allowedMimeTypes": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "maxLength": 100
                              }
                            },
                            "taxonomyKey": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 64,
                              "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                            },
                            "localised": {
                              "type": "boolean"
                            },
                            "regional": {
                              "type": "boolean"
                            },
                            "protects": {
                              "type": "string",
                              "enum": [
                                "none",
                                "price",
                                "promotion"
                              ]
                            },
                            "group": {
                              "type": "string",
                              "maxLength": 60
                            },
                            "hidden": {
                              "type": "boolean"
                            },
                            "showWhen": {
                              "type": "object",
                              "properties": {
                                "field": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 64,
                                  "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                                },
                                "equals": {
                                  "anyOf": [
                                    {
                                      "type": "boolean"
                                    },
                                    {
                                      "type": "string",
                                      "maxLength": 120
                                    },
                                    {
                                      "minItems": 1,
                                      "maxItems": 50,
                                      "type": "array",
                                      "items": {
                                        "type": "string",
                                        "maxLength": 120
                                      }
                                    }
                                  ]
                                }
                              },
                              "required": [
                                "field",
                                "equals"
                              ]
                            },
                            "step": {
                              "type": "number",
                              "exclusiveMinimum": 0
                            },
                            "unit": {
                              "type": "string",
                              "maxLength": 20
                            },
                            "halfStars": {
                              "type": "boolean"
                            },
                            "languages": {
                              "maxItems": 22,
                              "type": "array",
                              "items": {
                                "type": "string",
                                "enum": [
                                  "text",
                                  "ts",
                                  "tsx",
                                  "js",
                                  "json",
                                  "html",
                                  "xml",
                                  "yaml",
                                  "graphql",
                                  "bash",
                                  "python",
                                  "php",
                                  "java",
                                  "kotlin",
                                  "swift",
                                  "vue",
                                  "svelte",
                                  "astro",
                                  "blade",
                                  "twig",
                                  "dockerfile",
                                  "http"
                                ]
                              }
                            },
                            "defaultLanguage": {
                              "type": "string",
                              "enum": [
                                "text",
                                "ts",
                                "tsx",
                                "js",
                                "json",
                                "html",
                                "xml",
                                "yaml",
                                "graphql",
                                "bash",
                                "python",
                                "php",
                                "java",
                                "kotlin",
                                "swift",
                                "vue",
                                "svelte",
                                "astro",
                                "blade",
                                "twig",
                                "dockerfile",
                                "http"
                              ]
                            }
                          },
                          "required": [
                            "key",
                            "name",
                            "type"
                          ]
                        }
                      },
                      "titleTemplate": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 200
                      },
                      "descriptionField": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 60
                      },
                      "sitemapPriority": {
                        "type": [
                          "number",
                          "null"
                        ],
                        "minimum": 0,
                        "maximum": 1
                      },
                      "sitemapChangeFrequency": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "enum": [
                          "always",
                          "hourly",
                          "daily",
                          "weekly",
                          "monthly",
                          "yearly",
                          "never",
                          null
                        ]
                      }
                    }
                  },
                  "slugBehaviour": {
                    "default": {
                      "source": "name",
                      "editable": true,
                      "unique": true
                    },
                    "type": "object",
                    "properties": {
                      "source": {
                        "default": "name",
                        "type": "string",
                        "enum": [
                          "name",
                          "manual"
                        ]
                      },
                      "editable": {
                        "default": true,
                        "type": "boolean"
                      },
                      "unique": {
                        "default": true,
                        "type": "boolean"
                      }
                    }
                  },
                  "publishing": {
                    "type": "object",
                    "properties": {
                      "requiresApproval": {
                        "default": false,
                        "type": "boolean"
                      },
                      "steps": {
                        "maxItems": 5,
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "key": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 64,
                              "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                            },
                            "name": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 200
                            },
                            "role": {
                              "type": [
                                "string",
                                "null"
                              ],
                              "maxLength": 64
                            }
                          },
                          "required": [
                            "key",
                            "name"
                          ]
                        }
                      },
                      "regionSteps": {
                        "type": "object",
                        "additionalProperties": {
                          "maxItems": 5,
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "key": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 64,
                                "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                              },
                              "name": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 200
                              },
                              "role": {
                                "type": [
                                  "string",
                                  "null"
                                ],
                                "maxLength": 64
                              }
                            },
                            "required": [
                              "key",
                              "name"
                            ]
                          }
                        }
                      },
                      "reviewMonths": {
                        "type": [
                          "integer",
                          "null"
                        ],
                        "minimum": 1,
                        "maximum": 36
                      }
                    }
                  },
                  "folderRestrictions": {
                    "default": [],
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "isGlobal": {
                    "default": false,
                    "type": "boolean",
                    "description": "Read by key, with no address, such as a footer."
                  },
                  "singleton": {
                    "default": false,
                    "type": "boolean",
                    "description": "Only one item of this type."
                  },
                  "editor": {
                    "type": "string",
                    "enum": [
                      "preview",
                      "panel"
                    ]
                  },
                  "mainHeading": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 64
                  }
                },
                "required": [
                  "key",
                  "name"
                ]
              },
              "example": {
                "key": "trip",
                "name": "Trip",
                "fields": [
                  {
                    "key": "title",
                    "name": "Title",
                    "type": "text",
                    "required": true
                  },
                  {
                    "key": "days",
                    "name": "Days",
                    "type": "number"
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The new item.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/ContentType"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a4b",
                    "key": "trip",
                    "name": "Trip",
                    "description": "A trip with its departures.",
                    "icon": null,
                    "group": null,
                    "fields": [
                      {
                        "key": "title",
                        "name": "Title",
                        "type": "text",
                        "description": "Six days of paddling between the peaks of Lofoten.",
                        "required": true,
                        "default": null,
                        "validation": {
                          "min": 1,
                          "max": 1,
                          "minLength": 1,
                          "maxLength": 1,
                          "pattern": "…",
                          "message": "…"
                        },
                        "options": [
                          {
                            "label": "Kayaking",
                            "value": "…"
                          }
                        ],
                        "allowedComponents": [
                          "…"
                        ],
                        "allowedContentTypes": [
                          "…"
                        ],
                        "allowedMimeTypes": [
                          "…"
                        ],
                        "taxonomyKey": "…",
                        "localised": false,
                        "regional": false,
                        "protects": "none",
                        "group": "…",
                        "hidden": false,
                        "showWhen": {
                          "field": "…",
                          "equals": null
                        },
                        "step": 1,
                        "unit": "…",
                        "halfStars": false,
                        "languages": [
                          "text"
                        ],
                        "defaultLanguage": "text"
                      }
                    ],
                    "allowedComponents": [
                      "…"
                    ],
                    "template": [
                      "…"
                    ],
                    "seo": {
                      "enabled": true,
                      "fields": [
                        {
                          "key": "title",
                          "name": "Title",
                          "type": "text",
                          "description": "Six days of paddling between the peaks of Lofoten.",
                          "required": true,
                          "default": null,
                          "validation": {
                            "min": 1,
                            "max": 1,
                            "minLength": 1,
                            "maxLength": 1,
                            "pattern": "…",
                            "message": "…"
                          },
                          "options": [
                            {
                              "label": "Kayaking",
                              "value": "…"
                            }
                          ],
                          "allowedComponents": [
                            "…"
                          ],
                          "allowedContentTypes": [
                            "…"
                          ],
                          "allowedMimeTypes": [
                            "…"
                          ],
                          "taxonomyKey": "…",
                          "localised": false,
                          "regional": false,
                          "protects": "none",
                          "group": "…",
                          "hidden": false,
                          "showWhen": {
                            "field": "…",
                            "equals": null
                          },
                          "step": 1,
                          "unit": "…",
                          "halfStars": false,
                          "languages": [
                            "text"
                          ],
                          "defaultLanguage": "text"
                        }
                      ],
                      "titleTemplate": null,
                      "descriptionField": null,
                      "sitemapPriority": 1,
                      "sitemapChangeFrequency": null,
                      "noIndexByDefault": false
                    },
                    "slugBehaviour": {
                      "source": "name",
                      "editable": true,
                      "unique": true
                    },
                    "publishing": {
                      "requiresApproval": false,
                      "steps": [
                        {
                          "key": "lofoten",
                          "name": "Lofoten sea kayaking",
                          "role": null,
                          "permission": null
                        }
                      ],
                      "regionSteps": {},
                      "reviewMonths": 1
                    },
                    "isGlobal": false,
                    "singleton": false,
                    "urlPrefix": null,
                    "editor": "preview",
                    "mainHeading": null,
                    "schemaVersion": 12,
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or an editor or main heading the type can't have.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:manage, or approval steps or review dates on a plan without them.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "A content type with the key exists.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/content-types/{key}": {
      "delete": {
        "operationId": "deleteContentTypesAndComponentsContentTypesByKey",
        "tags": [
          "Content types and components"
        ],
        "summary": "Deletes one no content uses",
        "description": "Deletes one no content uses. Permission: schema:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "key",
            "in": "path",
            "required": true,
            "description": "The key, such as trip, hero or activity.",
            "schema": {
              "type": "string"
            },
            "example": "trip"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such item with that key, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content type not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "Content still uses it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "get": {
        "operationId": "getContentTypesAndComponentsContentTypesByKey",
        "tags": [
          "Content types and components"
        ],
        "summary": "One content type",
        "description": "One content type. Permission: schema:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "key",
            "in": "path",
            "required": true,
            "description": "The key, such as trip, hero or activity.",
            "schema": {
              "type": "string"
            },
            "example": "trip"
          }
        ],
        "responses": {
          "200": {
            "description": "The content type.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/ContentType"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a4b",
                    "key": "trip",
                    "name": "Trip",
                    "description": "A trip with its departures.",
                    "icon": null,
                    "group": null,
                    "fields": [
                      {
                        "key": "title",
                        "name": "Title",
                        "type": "text",
                        "description": "Six days of paddling between the peaks of Lofoten.",
                        "required": true,
                        "default": null,
                        "validation": {
                          "min": 1,
                          "max": 1,
                          "minLength": 1,
                          "maxLength": 1,
                          "pattern": "…",
                          "message": "…"
                        },
                        "options": [
                          {
                            "label": "Kayaking",
                            "value": "…"
                          }
                        ],
                        "allowedComponents": [
                          "…"
                        ],
                        "allowedContentTypes": [
                          "…"
                        ],
                        "allowedMimeTypes": [
                          "…"
                        ],
                        "taxonomyKey": "…",
                        "localised": false,
                        "regional": false,
                        "protects": "none",
                        "group": "…",
                        "hidden": false,
                        "showWhen": {
                          "field": "…",
                          "equals": null
                        },
                        "step": 1,
                        "unit": "…",
                        "halfStars": false,
                        "languages": [
                          "text"
                        ],
                        "defaultLanguage": "text"
                      }
                    ],
                    "allowedComponents": [
                      "…"
                    ],
                    "template": [
                      "…"
                    ],
                    "seo": {
                      "enabled": true,
                      "fields": [
                        {
                          "key": "title",
                          "name": "Title",
                          "type": "text",
                          "description": "Six days of paddling between the peaks of Lofoten.",
                          "required": true,
                          "default": null,
                          "validation": {
                            "min": 1,
                            "max": 1,
                            "minLength": 1,
                            "maxLength": 1,
                            "pattern": "…",
                            "message": "…"
                          },
                          "options": [
                            {
                              "label": "Kayaking",
                              "value": "…"
                            }
                          ],
                          "allowedComponents": [
                            "…"
                          ],
                          "allowedContentTypes": [
                            "…"
                          ],
                          "allowedMimeTypes": [
                            "…"
                          ],
                          "taxonomyKey": "…",
                          "localised": false,
                          "regional": false,
                          "protects": "none",
                          "group": "…",
                          "hidden": false,
                          "showWhen": {
                            "field": "…",
                            "equals": null
                          },
                          "step": 1,
                          "unit": "…",
                          "halfStars": false,
                          "languages": [
                            "text"
                          ],
                          "defaultLanguage": "text"
                        }
                      ],
                      "titleTemplate": null,
                      "descriptionField": null,
                      "sitemapPriority": 1,
                      "sitemapChangeFrequency": null,
                      "noIndexByDefault": false
                    },
                    "slugBehaviour": {
                      "source": "name",
                      "editable": true,
                      "unique": true
                    },
                    "publishing": {
                      "requiresApproval": false,
                      "steps": [
                        {
                          "key": "lofoten",
                          "name": "Lofoten sea kayaking",
                          "role": null,
                          "permission": null
                        }
                      ],
                      "regionSteps": {},
                      "reviewMonths": 1
                    },
                    "isGlobal": false,
                    "singleton": false,
                    "urlPrefix": null,
                    "editor": "preview",
                    "mainHeading": null,
                    "schemaVersion": 12,
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such item with that key, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content type not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchContentTypesAndComponentsContentTypesByKey",
        "tags": [
          "Content types and components"
        ],
        "summary": "Changes one",
        "description": "Changes one. Permission: schema:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "key",
            "in": "path",
            "required": true,
            "description": "The key, such as trip, hero or activity.",
            "schema": {
              "type": "string"
            },
            "example": "trip"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "urlPrefix": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 100,
                    "description": "Where items of this type live, such as /trips."
                  },
                  "description": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 500
                  },
                  "icon": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 60
                  },
                  "group": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 60
                  },
                  "fields": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 64,
                          "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                        },
                        "name": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 200
                        },
                        "type": {
                          "type": "string",
                          "enum": [
                            "text",
                            "textarea",
                            "richtext",
                            "number",
                            "boolean",
                            "select",
                            "multiselect",
                            "color",
                            "slider",
                            "rating",
                            "code",
                            "palette",
                            "date",
                            "time",
                            "datetime",
                            "asset",
                            "assets",
                            "link",
                            "targets",
                            "reference",
                            "references",
                            "taxonomy",
                            "taxonomyTerms",
                            "claims",
                            "component",
                            "components",
                            "trip",
                            "trips",
                            "destination",
                            "departure",
                            "product",
                            "products",
                            "collection",
                            "bookingService",
                            "bookingServices",
                            "bookingStaff",
                            "reviewLocation",
                            "job",
                            "jobFilter",
                            "shopifyProduct",
                            "shopifyProducts"
                          ]
                        },
                        "description": {
                          "type": "string",
                          "maxLength": 300
                        },
                        "required": {
                          "default": false,
                          "type": "boolean"
                        },
                        "default": {
                          "description": "Any JSON value."
                        },
                        "validation": {
                          "type": "object",
                          "properties": {
                            "min": {
                              "type": "number"
                            },
                            "max": {
                              "type": "number"
                            },
                            "minLength": {
                              "type": "integer",
                              "minimum": 0
                            },
                            "maxLength": {
                              "type": "integer",
                              "minimum": 1
                            },
                            "pattern": {
                              "type": "string",
                              "maxLength": 200
                            },
                            "message": {
                              "type": "string",
                              "maxLength": 200
                            }
                          }
                        },
                        "options": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "label": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 120
                              },
                              "value": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 120
                              }
                            },
                            "required": [
                              "label",
                              "value"
                            ]
                          }
                        },
                        "allowedComponents": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 64,
                            "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                          }
                        },
                        "allowedContentTypes": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 64,
                            "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                          }
                        },
                        "allowedMimeTypes": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "maxLength": 100
                          }
                        },
                        "taxonomyKey": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 64,
                          "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                        },
                        "localised": {
                          "type": "boolean"
                        },
                        "regional": {
                          "type": "boolean"
                        },
                        "protects": {
                          "type": "string",
                          "enum": [
                            "none",
                            "price",
                            "promotion"
                          ]
                        },
                        "group": {
                          "type": "string",
                          "maxLength": 60
                        },
                        "hidden": {
                          "type": "boolean"
                        },
                        "showWhen": {
                          "type": "object",
                          "properties": {
                            "field": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 64,
                              "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                            },
                            "equals": {
                              "anyOf": [
                                {
                                  "type": "boolean"
                                },
                                {
                                  "type": "string",
                                  "maxLength": 120
                                },
                                {
                                  "minItems": 1,
                                  "maxItems": 50,
                                  "type": "array",
                                  "items": {
                                    "type": "string",
                                    "maxLength": 120
                                  }
                                }
                              ]
                            }
                          },
                          "required": [
                            "field",
                            "equals"
                          ]
                        },
                        "step": {
                          "type": "number",
                          "exclusiveMinimum": 0
                        },
                        "unit": {
                          "type": "string",
                          "maxLength": 20
                        },
                        "halfStars": {
                          "type": "boolean"
                        },
                        "languages": {
                          "maxItems": 22,
                          "type": "array",
                          "items": {
                            "type": "string",
                            "enum": [
                              "text",
                              "ts",
                              "tsx",
                              "js",
                              "json",
                              "html",
                              "xml",
                              "yaml",
                              "graphql",
                              "bash",
                              "python",
                              "php",
                              "java",
                              "kotlin",
                              "swift",
                              "vue",
                              "svelte",
                              "astro",
                              "blade",
                              "twig",
                              "dockerfile",
                              "http"
                            ]
                          }
                        },
                        "defaultLanguage": {
                          "type": "string",
                          "enum": [
                            "text",
                            "ts",
                            "tsx",
                            "js",
                            "json",
                            "html",
                            "xml",
                            "yaml",
                            "graphql",
                            "bash",
                            "python",
                            "php",
                            "java",
                            "kotlin",
                            "swift",
                            "vue",
                            "svelte",
                            "astro",
                            "blade",
                            "twig",
                            "dockerfile",
                            "http"
                          ]
                        }
                      },
                      "required": [
                        "key",
                        "name",
                        "type"
                      ]
                    }
                  },
                  "allowedComponents": {
                    "anyOf": [
                      {
                        "type": "string",
                        "const": "*"
                      },
                      {
                        "type": "array",
                        "items": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 64,
                          "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                        }
                      }
                    ]
                  },
                  "template": {
                    "type": "array",
                    "items": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 64,
                      "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                    }
                  },
                  "seo": {
                    "type": "object",
                    "properties": {
                      "enabled": {
                        "type": "boolean"
                      },
                      "fields": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "key": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 64,
                              "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                            },
                            "name": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 200
                            },
                            "type": {
                              "type": "string",
                              "enum": [
                                "text",
                                "textarea",
                                "richtext",
                                "number",
                                "boolean",
                                "select",
                                "multiselect",
                                "color",
                                "slider",
                                "rating",
                                "code",
                                "palette",
                                "date",
                                "time",
                                "datetime",
                                "asset",
                                "assets",
                                "link",
                                "targets",
                                "reference",
                                "references",
                                "taxonomy",
                                "taxonomyTerms",
                                "claims",
                                "component",
                                "components",
                                "trip",
                                "trips",
                                "destination",
                                "departure",
                                "product",
                                "products",
                                "collection",
                                "bookingService",
                                "bookingServices",
                                "bookingStaff",
                                "reviewLocation",
                                "job",
                                "jobFilter",
                                "shopifyProduct",
                                "shopifyProducts"
                              ]
                            },
                            "description": {
                              "type": "string",
                              "maxLength": 300
                            },
                            "required": {
                              "default": false,
                              "type": "boolean"
                            },
                            "default": {
                              "description": "Any JSON value."
                            },
                            "validation": {
                              "type": "object",
                              "properties": {
                                "min": {
                                  "type": "number"
                                },
                                "max": {
                                  "type": "number"
                                },
                                "minLength": {
                                  "type": "integer",
                                  "minimum": 0
                                },
                                "maxLength": {
                                  "type": "integer",
                                  "minimum": 1
                                },
                                "pattern": {
                                  "type": "string",
                                  "maxLength": 200
                                },
                                "message": {
                                  "type": "string",
                                  "maxLength": 200
                                }
                              }
                            },
                            "options": {
                              "type": "array",
                              "items": {
                                "type": "object",
                                "properties": {
                                  "label": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 120
                                  },
                                  "value": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 120
                                  }
                                },
                                "required": [
                                  "label",
                                  "value"
                                ]
                              }
                            },
                            "allowedComponents": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 64,
                                "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                              }
                            },
                            "allowedContentTypes": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 64,
                                "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                              }
                            },
                            "allowedMimeTypes": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "maxLength": 100
                              }
                            },
                            "taxonomyKey": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 64,
                              "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                            },
                            "localised": {
                              "type": "boolean"
                            },
                            "regional": {
                              "type": "boolean"
                            },
                            "protects": {
                              "type": "string",
                              "enum": [
                                "none",
                                "price",
                                "promotion"
                              ]
                            },
                            "group": {
                              "type": "string",
                              "maxLength": 60
                            },
                            "hidden": {
                              "type": "boolean"
                            },
                            "showWhen": {
                              "type": "object",
                              "properties": {
                                "field": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 64,
                                  "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                                },
                                "equals": {
                                  "anyOf": [
                                    {
                                      "type": "boolean"
                                    },
                                    {
                                      "type": "string",
                                      "maxLength": 120
                                    },
                                    {
                                      "minItems": 1,
                                      "maxItems": 50,
                                      "type": "array",
                                      "items": {
                                        "type": "string",
                                        "maxLength": 120
                                      }
                                    }
                                  ]
                                }
                              },
                              "required": [
                                "field",
                                "equals"
                              ]
                            },
                            "step": {
                              "type": "number",
                              "exclusiveMinimum": 0
                            },
                            "unit": {
                              "type": "string",
                              "maxLength": 20
                            },
                            "halfStars": {
                              "type": "boolean"
                            },
                            "languages": {
                              "maxItems": 22,
                              "type": "array",
                              "items": {
                                "type": "string",
                                "enum": [
                                  "text",
                                  "ts",
                                  "tsx",
                                  "js",
                                  "json",
                                  "html",
                                  "xml",
                                  "yaml",
                                  "graphql",
                                  "bash",
                                  "python",
                                  "php",
                                  "java",
                                  "kotlin",
                                  "swift",
                                  "vue",
                                  "svelte",
                                  "astro",
                                  "blade",
                                  "twig",
                                  "dockerfile",
                                  "http"
                                ]
                              }
                            },
                            "defaultLanguage": {
                              "type": "string",
                              "enum": [
                                "text",
                                "ts",
                                "tsx",
                                "js",
                                "json",
                                "html",
                                "xml",
                                "yaml",
                                "graphql",
                                "bash",
                                "python",
                                "php",
                                "java",
                                "kotlin",
                                "swift",
                                "vue",
                                "svelte",
                                "astro",
                                "blade",
                                "twig",
                                "dockerfile",
                                "http"
                              ]
                            }
                          },
                          "required": [
                            "key",
                            "name",
                            "type"
                          ]
                        }
                      },
                      "titleTemplate": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 200
                      },
                      "descriptionField": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 60
                      },
                      "sitemapPriority": {
                        "type": [
                          "number",
                          "null"
                        ],
                        "minimum": 0,
                        "maximum": 1
                      },
                      "sitemapChangeFrequency": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "enum": [
                          "always",
                          "hourly",
                          "daily",
                          "weekly",
                          "monthly",
                          "yearly",
                          "never",
                          null
                        ]
                      }
                    }
                  },
                  "slugBehaviour": {
                    "type": "object",
                    "properties": {
                      "source": {
                        "type": "string",
                        "enum": [
                          "name",
                          "manual"
                        ]
                      },
                      "editable": {
                        "type": "boolean"
                      },
                      "unique": {
                        "type": "boolean"
                      }
                    }
                  },
                  "publishing": {
                    "type": "object",
                    "properties": {
                      "requiresApproval": {
                        "default": false,
                        "type": "boolean"
                      },
                      "steps": {
                        "maxItems": 5,
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "key": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 64,
                              "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                            },
                            "name": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 200
                            },
                            "role": {
                              "type": [
                                "string",
                                "null"
                              ],
                              "maxLength": 64
                            }
                          },
                          "required": [
                            "key",
                            "name"
                          ]
                        }
                      },
                      "regionSteps": {
                        "type": "object",
                        "additionalProperties": {
                          "maxItems": 5,
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "key": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 64,
                                "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                              },
                              "name": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 200
                              },
                              "role": {
                                "type": [
                                  "string",
                                  "null"
                                ],
                                "maxLength": 64
                              }
                            },
                            "required": [
                              "key",
                              "name"
                            ]
                          }
                        }
                      },
                      "reviewMonths": {
                        "type": [
                          "integer",
                          "null"
                        ],
                        "minimum": 1,
                        "maximum": 36
                      }
                    }
                  },
                  "folderRestrictions": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  },
                  "isGlobal": {
                    "type": "boolean"
                  },
                  "singleton": {
                    "type": "boolean"
                  },
                  "editor": {
                    "type": "string",
                    "enum": [
                      "preview",
                      "panel"
                    ]
                  },
                  "mainHeading": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 64
                  }
                }
              },
              "example": {
                "name": "Trip",
                "urlPrefix": "/trips"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The content type.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/ContentType"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a4b",
                    "key": "trip",
                    "name": "Trip",
                    "description": "A trip with its departures.",
                    "icon": null,
                    "group": null,
                    "fields": [
                      {
                        "key": "title",
                        "name": "Title",
                        "type": "text",
                        "description": "Six days of paddling between the peaks of Lofoten.",
                        "required": true,
                        "default": null,
                        "validation": {
                          "min": 1,
                          "max": 1,
                          "minLength": 1,
                          "maxLength": 1,
                          "pattern": "…",
                          "message": "…"
                        },
                        "options": [
                          {
                            "label": "Kayaking",
                            "value": "…"
                          }
                        ],
                        "allowedComponents": [
                          "…"
                        ],
                        "allowedContentTypes": [
                          "…"
                        ],
                        "allowedMimeTypes": [
                          "…"
                        ],
                        "taxonomyKey": "…",
                        "localised": false,
                        "regional": false,
                        "protects": "none",
                        "group": "…",
                        "hidden": false,
                        "showWhen": {
                          "field": "…",
                          "equals": null
                        },
                        "step": 1,
                        "unit": "…",
                        "halfStars": false,
                        "languages": [
                          "text"
                        ],
                        "defaultLanguage": "text"
                      }
                    ],
                    "allowedComponents": [
                      "…"
                    ],
                    "template": [
                      "…"
                    ],
                    "seo": {
                      "enabled": true,
                      "fields": [
                        {
                          "key": "title",
                          "name": "Title",
                          "type": "text",
                          "description": "Six days of paddling between the peaks of Lofoten.",
                          "required": true,
                          "default": null,
                          "validation": {
                            "min": 1,
                            "max": 1,
                            "minLength": 1,
                            "maxLength": 1,
                            "pattern": "…",
                            "message": "…"
                          },
                          "options": [
                            {
                              "label": "Kayaking",
                              "value": "…"
                            }
                          ],
                          "allowedComponents": [
                            "…"
                          ],
                          "allowedContentTypes": [
                            "…"
                          ],
                          "allowedMimeTypes": [
                            "…"
                          ],
                          "taxonomyKey": "…",
                          "localised": false,
                          "regional": false,
                          "protects": "none",
                          "group": "…",
                          "hidden": false,
                          "showWhen": {
                            "field": "…",
                            "equals": null
                          },
                          "step": 1,
                          "unit": "…",
                          "halfStars": false,
                          "languages": [
                            "text"
                          ],
                          "defaultLanguage": "text"
                        }
                      ],
                      "titleTemplate": null,
                      "descriptionField": null,
                      "sitemapPriority": 1,
                      "sitemapChangeFrequency": null,
                      "noIndexByDefault": false
                    },
                    "slugBehaviour": {
                      "source": "name",
                      "editable": true,
                      "unique": true
                    },
                    "publishing": {
                      "requiresApproval": false,
                      "steps": [
                        {
                          "key": "lofoten",
                          "name": "Lofoten sea kayaking",
                          "role": null,
                          "permission": null
                        }
                      ],
                      "regionSteps": {},
                      "reviewMonths": 1
                    },
                    "isGlobal": false,
                    "singleton": false,
                    "urlPrefix": null,
                    "editor": "preview",
                    "mainHeading": null,
                    "schemaVersion": 12,
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or a urlPrefix that isn't valid, is used elsewhere or doesn't fit where items live, or an editor or main heading the type can't have.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such item with that key, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content type not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/schema": {
      "get": {
        "operationId": "getContentTypesAndComponentsSchema",
        "tags": [
          "Content types and components"
        ],
        "summary": "Every content type and component at once, the field types, and whether you may change them",
        "description": "Every content type and component at once, the field types, and whether you may change them. Permission: schema:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "{ contentTypes, components, fieldTypes, canManage }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "contentTypes": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/ContentType"
                          }
                        },
                        "components": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/Component"
                          }
                        },
                        "fieldTypes": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "type": {
                                "type": "string",
                                "description": "Such as text."
                              },
                              "label": {
                                "type": "string"
                              },
                              "group": {
                                "type": "string",
                                "description": "Such as text, choice, relation or structure."
                              },
                              "supportsOptions": {
                                "type": "boolean"
                              },
                              "supportsComponents": {
                                "type": "boolean"
                              },
                              "supportsContentTypes": {
                                "type": "boolean"
                              },
                              "supportsTaxonomy": {
                                "type": "boolean"
                              }
                            },
                            "required": [
                              "type",
                              "label",
                              "group",
                              "supportsOptions",
                              "supportsComponents",
                              "supportsContentTypes",
                              "supportsTaxonomy"
                            ]
                          },
                          "description": "Every field type this server knows."
                        },
                        "canManage": {
                          "type": "boolean",
                          "description": "You may change the schema (schema:manage)."
                        }
                      },
                      "required": [
                        "contentTypes",
                        "components",
                        "fieldTypes",
                        "canManage"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "contentTypes": [
                      {
                        "id": "6650f1c2a9e4b1d2c3f40a4b",
                        "key": "trip",
                        "name": "Trip",
                        "description": "A trip with its departures.",
                        "icon": null,
                        "group": null,
                        "fields": [
                          {
                            "key": "title",
                            "name": "Title",
                            "type": "text",
                            "description": "Six days of paddling between the peaks of Lofoten.",
                            "required": true,
                            "default": null,
                            "validation": {
                              "min": 1,
                              "max": 1,
                              "minLength": 1,
                              "maxLength": 1,
                              "pattern": "…",
                              "message": "…"
                            },
                            "options": [
                              {
                                "label": "Kayaking",
                                "value": "…"
                              }
                            ],
                            "allowedComponents": [
                              "…"
                            ],
                            "allowedContentTypes": [
                              "…"
                            ],
                            "allowedMimeTypes": [
                              "…"
                            ],
                            "taxonomyKey": "…",
                            "localised": false,
                            "regional": false,
                            "protects": "none",
                            "group": "…",
                            "hidden": false,
                            "showWhen": {
                              "field": "…",
                              "equals": null
                            },
                            "step": 1,
                            "unit": "…",
                            "halfStars": false,
                            "languages": [
                              "text"
                            ],
                            "defaultLanguage": "text"
                          }
                        ],
                        "allowedComponents": [
                          "…"
                        ],
                        "template": [
                          "…"
                        ],
                        "seo": {
                          "enabled": true,
                          "fields": [
                            {
                              "key": "title",
                              "name": "Title",
                              "type": "text",
                              "description": "Six days of paddling between the peaks of Lofoten.",
                              "required": true,
                              "default": null,
                              "validation": {
                                "min": 1,
                                "max": 1,
                                "minLength": 1,
                                "maxLength": 1,
                                "pattern": "…",
                                "message": "…"
                              },
                              "options": [
                                {
                                  "label": "Kayaking",
                                  "value": "…"
                                }
                              ],
                              "allowedComponents": [
                                "…"
                              ],
                              "allowedContentTypes": [
                                "…"
                              ],
                              "allowedMimeTypes": [
                                "…"
                              ],
                              "taxonomyKey": "…",
                              "localised": false,
                              "regional": false,
                              "protects": "none",
                              "group": "…",
                              "hidden": false,
                              "showWhen": {
                                "field": "…",
                                "equals": null
                              },
                              "step": 1,
                              "unit": "…",
                              "halfStars": false,
                              "languages": [
                                "text"
                              ],
                              "defaultLanguage": "text"
                            }
                          ],
                          "titleTemplate": null,
                          "descriptionField": null,
                          "sitemapPriority": 1,
                          "sitemapChangeFrequency": null,
                          "noIndexByDefault": false
                        },
                        "slugBehaviour": {
                          "source": "name",
                          "editable": true,
                          "unique": true
                        },
                        "publishing": {
                          "requiresApproval": false,
                          "steps": [
                            {
                              "key": "lofoten",
                              "name": "Lofoten sea kayaking",
                              "role": null,
                              "permission": null
                            }
                          ],
                          "regionSteps": {},
                          "reviewMonths": 1
                        },
                        "isGlobal": false,
                        "singleton": false,
                        "urlPrefix": null,
                        "editor": "preview",
                        "mainHeading": null,
                        "schemaVersion": 12,
                        "updatedAt": "2026-11-02T09:30:00.000Z"
                      }
                    ],
                    "components": [
                      {
                        "id": "6650f1c2a9e4b1d2c3f40a49",
                        "key": "hero",
                        "name": "Hero",
                        "description": "Six days of paddling between the peaks of Lofoten.",
                        "icon": null,
                        "group": "Page top",
                        "fields": [
                          {
                            "key": "title",
                            "name": "Title",
                            "type": "text",
                            "description": "Six days of paddling between the peaks of Lofoten.",
                            "required": true,
                            "default": null,
                            "validation": {
                              "min": 1,
                              "max": 1,
                              "minLength": 1,
                              "maxLength": 1,
                              "pattern": "…",
                              "message": "…"
                            },
                            "options": [
                              {
                                "label": "Kayaking",
                                "value": "…"
                              }
                            ],
                            "allowedComponents": [
                              "…"
                            ],
                            "allowedContentTypes": [
                              "…"
                            ],
                            "allowedMimeTypes": [
                              "…"
                            ],
                            "taxonomyKey": "…",
                            "localised": false,
                            "regional": false,
                            "protects": "none",
                            "group": "…",
                            "hidden": false,
                            "showWhen": {
                              "field": "…",
                              "equals": null
                            },
                            "step": 1,
                            "unit": "…",
                            "halfStars": false,
                            "languages": [
                              "text"
                            ],
                            "defaultLanguage": "text"
                          }
                        ],
                        "allowedChildren": [
                          "…"
                        ],
                        "isRoot": true,
                        "isNestable": true,
                        "previewImage": null,
                        "mainHeading": null,
                        "mainHeadingWhen": null,
                        "hiddenFromLibrary": false,
                        "schemaVersion": 12,
                        "deprecated": false,
                        "updatedAt": "2026-11-02T09:30:00.000Z"
                      }
                    ],
                    "fieldTypes": [
                      {
                        "type": "…",
                        "label": "Kayaking",
                        "group": "…",
                        "supportsOptions": false,
                        "supportsComponents": false,
                        "supportsContentTypes": false,
                        "supportsTaxonomy": false
                      }
                    ],
                    "canManage": true
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/schema/uses": {
      "get": {
        "operationId": "getContentTypesAndComponentsSchemaUses",
        "tags": [
          "Content types and components"
        ],
        "summary": "How many entries use each content type and component, and hold a value in each of their fields",
        "description": "How many entries use each content type and component, and hold a value in each of their fields. Permission: schema:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "{ contentTypes, components }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "contentTypes": {
                          "type": "object",
                          "additionalProperties": {
                            "type": "object",
                            "properties": {
                              "entries": {
                                "type": "integer",
                                "description": "Entries of the type, in every environment, region and language, the bin left out."
                              },
                              "fields": {
                                "type": "object",
                                "additionalProperties": {
                                  "type": "integer"
                                },
                                "description": "By field key: entries holding a value in it, drafted or published."
                              }
                            },
                            "required": [
                              "entries",
                              "fields"
                            ]
                          },
                          "description": "By content type key. Types no entry uses are left out."
                        },
                        "components": {
                          "type": "object",
                          "additionalProperties": {
                            "type": "object",
                            "properties": {
                              "entries": {
                                "type": "integer",
                                "description": "Entries with the block anywhere, drafted or published."
                              },
                              "fields": {
                                "type": "object",
                                "additionalProperties": {
                                  "type": "integer"
                                },
                                "description": "By field key: entries where the block holds a value in it."
                              }
                            },
                            "required": [
                              "entries",
                              "fields"
                            ]
                          },
                          "description": "By component key. Components no entry uses are left out."
                        }
                      },
                      "required": [
                        "contentTypes",
                        "components"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "contentTypes": {},
                    "components": {}
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/domains": {
      "get": {
        "operationId": "getDomainsDomains",
        "tags": [
          "Domains"
        ],
        "summary": "The space's domains",
        "description": "The space's domains. Permission: domain:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "List of domains.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Domain"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "_id": "6650f1c2a9e4b1d2c3f40a46",
                      "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                      "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "regionId": "6650f1c2a9e4b1d2c3f40a17",
                      "localeId": "6650f1c2a9e4b1d2c3f40a18",
                      "hostname": "northwilds.com",
                      "pathPrefix": null,
                      "primary": true,
                      "verified": true,
                      "verificationToken": "cms-orbit-verify=4b1d2c3f",
                      "createdAt": "2026-11-02T09:30:00.000Z",
                      "updatedAt": "2026-11-02T09:30:00.000Z"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks domain:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postDomainsDomains",
        "tags": [
          "Domains"
        ],
        "summary": "Adds a domain: hostname, environmentId (required), regionId, localeId, pathPrefix, primary",
        "description": "Adds a domain: hostname, environmentId (required), regionId, localeId, pathPrefix, primary. Permission: domain:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "hostname": {
                    "type": "string",
                    "description": "Such as northwilds.com."
                  },
                  "environmentId": {
                    "description": "The environment it serves. Required."
                  },
                  "regionId": {
                    "description": "The region it opens in."
                  },
                  "localeId": {
                    "description": "The language it opens in."
                  },
                  "pathPrefix": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "A folder, such as /no, for a domain shared between regions."
                  },
                  "primary": {
                    "type": "boolean",
                    "description": "Only a verified domain can be primary."
                  }
                },
                "required": [
                  "hostname",
                  "environmentId"
                ]
              },
              "example": {
                "hostname": "northwilds.com",
                "environmentId": "6650f1c2a9e4b1d2c3f40a13"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The domain and its verificationToken.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Domain"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "_id": "6650f1c2a9e4b1d2c3f40a46",
                    "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                    "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "regionId": "6650f1c2a9e4b1d2c3f40a17",
                    "localeId": "6650f1c2a9e4b1d2c3f40a18",
                    "hostname": "northwilds.com",
                    "pathPrefix": null,
                    "primary": true,
                    "verified": true,
                    "verificationToken": "cms-orbit-verify=4b1d2c3f",
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or not a hostname or a folder.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks domain:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "The environment, region or language isn't in this space.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "Another space uses the hostname.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/domains/{domainId}": {
      "delete": {
        "operationId": "deleteDomainsDomainsByDomainId",
        "tags": [
          "Domains"
        ],
        "summary": "Removes a domain",
        "description": "Removes a domain. Permission: domain:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "domainId",
            "in": "path",
            "required": true,
            "description": "The domain's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks domain:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such domain, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Domain not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchDomainsDomainsByDomainId",
        "tags": [
          "Domains"
        ],
        "summary": "Changes primary or pathPrefix",
        "description": "Changes primary or pathPrefix. Permission: domain:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "domainId",
            "in": "path",
            "required": true,
            "description": "The domain's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "primary": {
                    "type": "boolean",
                    "description": "Only a verified domain can be primary."
                  },
                  "pathPrefix": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "Such as /no, or null for none."
                  }
                },
                "required": []
              },
              "example": {
                "primary": true
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The domain.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Domain"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "_id": "6650f1c2a9e4b1d2c3f40a46",
                    "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                    "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "regionId": "6650f1c2a9e4b1d2c3f40a17",
                    "localeId": "6650f1c2a9e4b1d2c3f40a18",
                    "hostname": "northwilds.com",
                    "pathPrefix": null,
                    "primary": true,
                    "verified": true,
                    "verificationToken": "cms-orbit-verify=4b1d2c3f",
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or making an unverified domain primary, or a folder that isn't valid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks domain:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such domain, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Domain not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "A field of the wrong type.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/domains/{domainId}/verify": {
      "post": {
        "operationId": "postDomainsDomainsByDomainIdVerify",
        "tags": [
          "Domains"
        ],
        "summary": "Looks for the TXT record",
        "description": "Looks for the TXT record. Permission: domain:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "domainId",
            "in": "path",
            "required": true,
            "description": "The domain's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "responses": {
          "200": {
            "description": "{ verified, message }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "verified": {
                          "type": "boolean",
                          "description": "A failed check still answers 200, with false."
                        },
                        "message": {
                          "type": "string",
                          "description": "What was found."
                        }
                      },
                      "required": [
                        "verified",
                        "message"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "verified": true,
                    "message": "…"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks domain:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such domain, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Domain not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments": {
      "get": {
        "operationId": "getEnvironmentsRegionsAndLanguagesEnvironments",
        "tags": [
          "Environments, regions and languages"
        ],
        "summary": "The space's environments",
        "description": "The space's environments. Permission: environment:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "[{ id, spaceId, key, name, kind, isDefault, protected, sortOrder }].",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Environment"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a13",
                      "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                      "key": "production",
                      "name": "Production",
                      "kind": "production",
                      "isDefault": true,
                      "protected": false,
                      "sortOrder": 1
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks environment:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postEnvironmentsRegionsAndLanguagesEnvironments",
        "tags": [
          "Environments, regions and languages"
        ],
        "summary": "Adds an environment",
        "description": "Adds an environment. Permission: environment:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "description": "A slug, such as preview. Never changes."
                  },
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "kind": {
                    "default": "custom",
                    "type": "string",
                    "enum": [
                      "staging",
                      "production",
                      "custom"
                    ]
                  },
                  "protected": {
                    "default": false,
                    "type": "boolean",
                    "description": "A protected environment can't be deleted."
                  },
                  "hiddenFromSearch": {
                    "default": false,
                    "type": "boolean"
                  },
                  "dashboardNotifications": {
                    "default": true,
                    "type": "boolean"
                  },
                  "sortOrder": {
                    "default": 0,
                    "type": "integer"
                  },
                  "settings": {
                    "default": {},
                    "type": "object",
                    "additionalProperties": {
                      "description": "Any JSON value."
                    }
                  }
                },
                "required": [
                  "key",
                  "name"
                ]
              },
              "example": {
                "key": "preview",
                "name": "Preview",
                "kind": "custom"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The environment.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Environment"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a13",
                    "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                    "key": "production",
                    "name": "Production",
                    "kind": "production",
                    "isDefault": true,
                    "protected": false,
                    "sortOrder": 1
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks environment:manage, or the plan's environments are used up.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "An environment with the key exists.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}": {
      "delete": {
        "operationId": "deleteEnvironmentsRegionsAndLanguages",
        "tags": [
          "Environments, regions and languages"
        ],
        "summary": "Deletes an environment with no regions left, with its redirects",
        "description": "Deletes an environment with no regions left, with its redirects. Protected environments answer 400. Permission: environment:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "400": {
            "description": "The environment is protected.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks environment:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such environment, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Environment not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "It still has regions.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchEnvironmentsRegionsAndLanguages",
        "tags": [
          "Environments, regions and languages"
        ],
        "summary": "Changes name, kind, protected, sortOrder or settings",
        "description": "Changes name, kind, protected, sortOrder or settings. The key never changes. Permission: environment:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "kind": {
                    "type": "string",
                    "enum": [
                      "staging",
                      "production",
                      "custom"
                    ]
                  },
                  "protected": {
                    "type": "boolean"
                  },
                  "hiddenFromSearch": {
                    "type": "boolean"
                  },
                  "dashboardNotifications": {
                    "type": "boolean"
                  },
                  "sortOrder": {
                    "type": "integer"
                  },
                  "settings": {
                    "type": "object",
                    "additionalProperties": {
                      "description": "Any JSON value."
                    }
                  }
                }
              },
              "example": {
                "name": "Preview",
                "sortOrder": 2
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The environment.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Environment"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a13",
                    "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                    "key": "production",
                    "name": "Production",
                    "kind": "production",
                    "isDefault": true,
                    "protected": false,
                    "sortOrder": 1
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks environment:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such environment, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Environment not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/media-host": {
      "delete": {
        "operationId": "deleteDomainsMediaHost",
        "tags": [
          "Domains"
        ],
        "summary": "Removes it",
        "description": "Removes it. Permission: domain:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks domain:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such environment, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Environment not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "get": {
        "operationId": "getDomainsMediaHost",
        "tags": [
          "Domains"
        ],
        "summary": "The environment's own address for media, with its status",
        "description": "The environment's own address for media, with its status. Permission: domain:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          }
        ],
        "responses": {
          "200": {
            "description": "The media host, or null.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "anyOf": [
                        {
                          "$ref": "#/components/schemas/MediaHost"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "hostname": "media.northwilds.com",
                    "target": "media.bifrostorbit.com",
                    "status": "pending",
                    "message": null,
                    "checkedAt": "2026-11-02T09:30:00.000Z",
                    "cloudflareId": null,
                    "onWebsite": false
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks domain:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such environment, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Environment not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "put": {
        "operationId": "putDomainsMediaHost",
        "tags": [
          "Domains"
        ],
        "summary": "Sets it: { \"hostname\": \"media.northwilds.com\" }",
        "description": "Sets it: { \"hostname\": \"media.northwilds.com\" }. Permission: domain:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "hostname": {
                    "type": "string",
                    "description": "Such as media.northwilds.com. Empty removes it."
                  }
                },
                "required": [
                  "hostname"
                ]
              },
              "example": {
                "hostname": "media.northwilds.com"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The media host.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "anyOf": [
                        {
                          "$ref": "#/components/schemas/MediaHost"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "hostname": "media.northwilds.com",
                    "target": "media.bifrostorbit.com",
                    "status": "pending",
                    "message": null,
                    "checkedAt": "2026-11-02T09:30:00.000Z",
                    "cloudflareId": null,
                    "onWebsite": false
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or not a hostname on a domain the space uses, or Cloudflare refused it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks domain:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such environment, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Environment not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "Another space uses the hostname.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions": {
      "get": {
        "operationId": "getEnvironmentsRegionsAndLanguagesRegions",
        "tags": [
          "Environments, regions and languages"
        ],
        "summary": "The environment's regions",
        "description": "The environment's regions. Permission: region:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          }
        ],
        "responses": {
          "200": {
            "description": "[{ id, spaceId, environmentId, key, name, defaultLocaleId, currency, timezone, sortOrder }].",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Region"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a17",
                      "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "key": "norway",
                      "name": "Norway",
                      "defaultLocaleId": null,
                      "currency": "NOK",
                      "timezone": "Europe/Oslo",
                      "pathPrefix": null,
                      "sortOrder": 1
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks region:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such environment, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Environment not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postEnvironmentsRegionsAndLanguagesRegions",
        "tags": [
          "Environments, regions and languages"
        ],
        "summary": "Adds a region, with a first language in the organisation's default",
        "description": "Adds a region, with a first language in the organisation's default. Permission: region:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "description": "A slug, such as norway."
                  },
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "currency": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "minLength": 3,
                    "maxLength": 3,
                    "description": "Three letters, such as NOK."
                  },
                  "timezone": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "minLength": 1
                  },
                  "pathPrefix": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "pattern": "^(\\/[a-z0-9][a-z0-9-]*)*$",
                    "description": "Such as /no, or null for none."
                  },
                  "settings": {
                    "default": {},
                    "type": "object",
                    "additionalProperties": {
                      "description": "Any JSON value."
                    }
                  },
                  "metadata": {
                    "default": {},
                    "type": "object",
                    "additionalProperties": {
                      "description": "Any JSON value."
                    }
                  },
                  "sortOrder": {
                    "default": 0,
                    "type": "integer"
                  }
                },
                "required": [
                  "key",
                  "name"
                ]
              },
              "example": {
                "key": "norway",
                "name": "Norway",
                "currency": "NOK",
                "timezone": "Europe/Oslo",
                "pathPrefix": "/no"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The region.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Region"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a17",
                    "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "key": "norway",
                    "name": "Norway",
                    "defaultLocaleId": null,
                    "currency": "NOK",
                    "timezone": "Europe/Oslo",
                    "pathPrefix": null,
                    "sortOrder": 1
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks region:manage, or the plan's regions are used up.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such environment, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Environment not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "A region with the key exists in this environment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}": {
      "delete": {
        "operationId": "deleteEnvironmentsRegionsAndLanguagesRegionsByRegionId",
        "tags": [
          "Environments, regions and languages"
        ],
        "summary": "Deletes a region with no languages or redirects left",
        "description": "Deletes a region with no languages or redirects left. Permission: region:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks region:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such region, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Region not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "It still has languages, or redirects of its own.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchEnvironmentsRegionsAndLanguagesRegionsByRegionId",
        "tags": [
          "Environments, regions and languages"
        ],
        "summary": "Changes a region, including defaultLocaleId",
        "description": "Changes a region, including defaultLocaleId. Permission: region:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "currency": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "minLength": 3,
                    "maxLength": 3
                  },
                  "timezone": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "minLength": 1
                  },
                  "pathPrefix": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "pattern": "^(\\/[a-z0-9][a-z0-9-]*)*$"
                  },
                  "settings": {
                    "type": "object",
                    "additionalProperties": {
                      "description": "Any JSON value."
                    }
                  },
                  "metadata": {
                    "type": "object",
                    "additionalProperties": {
                      "description": "Any JSON value."
                    }
                  },
                  "sortOrder": {
                    "type": "integer"
                  },
                  "defaultLocaleId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "An id."
                  }
                }
              },
              "example": {
                "name": "Norway",
                "currency": "NOK"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The region.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Region"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a17",
                    "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "key": "norway",
                    "name": "Norway",
                    "defaultLocaleId": null,
                    "currency": "NOK",
                    "timezone": "Europe/Oslo",
                    "pathPrefix": null,
                    "sortOrder": 1
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks region:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such region, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Region not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales": {
      "get": {
        "operationId": "getEnvironmentsRegionsAndLanguagesRegionsByRegionIdLocales",
        "tags": [
          "Environments, regions and languages"
        ],
        "summary": "The region's languages",
        "description": "The region's languages. Permission: locale:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          }
        ],
        "responses": {
          "200": {
            "description": "[{ id, spaceId, environmentId, regionId, code, name, fallbackLocaleId, isDefault, enabled, sortOrder }].",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Locale"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a18",
                      "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "regionId": "6650f1c2a9e4b1d2c3f40a17",
                      "code": "nb-NO",
                      "name": "Norsk",
                      "fallbackLocaleId": null,
                      "isDefault": true,
                      "enabled": true,
                      "sortOrder": 1
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks locale:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such region, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Region not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postEnvironmentsRegionsAndLanguagesRegionsByRegionIdLocales",
        "tags": [
          "Environments, regions and languages"
        ],
        "summary": "Adds a language",
        "description": "Adds a language. Permission: locale:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "code": {
                    "type": "string",
                    "minLength": 2,
                    "maxLength": 35,
                    "description": "A language tag, such as nb-NO."
                  },
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "fallbackLocaleId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "An id."
                  },
                  "isDefault": {
                    "default": false,
                    "type": "boolean",
                    "description": "The first language in a region becomes its default."
                  },
                  "enabled": {
                    "default": true,
                    "type": "boolean"
                  },
                  "settings": {
                    "default": {},
                    "type": "object",
                    "additionalProperties": {
                      "description": "Any JSON value."
                    }
                  },
                  "sortOrder": {
                    "default": 0,
                    "type": "integer"
                  }
                },
                "required": [
                  "code",
                  "name"
                ]
              },
              "example": {
                "code": "nb-NO",
                "name": "Norsk"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The language.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Locale"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a18",
                    "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "regionId": "6650f1c2a9e4b1d2c3f40a17",
                    "code": "nb-NO",
                    "name": "Norsk",
                    "fallbackLocaleId": null,
                    "isDefault": true,
                    "enabled": true,
                    "sortOrder": 1
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or a fallback to itself or in a circle.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks locale:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such region, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Region not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "The region has the language.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}": {
      "delete": {
        "operationId": "deleteEnvironmentsRegionsAndLanguages2",
        "tags": [
          "Environments, regions and languages"
        ],
        "summary": "Deletes an empty language nothing falls back to",
        "description": "Deletes an empty language nothing falls back to. Permission: locale:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks locale:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such language, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Locale not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "It's the region's default, another language falls back to it, or it still holds entries, folders, menus or redirects, counting the bin.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchEnvironmentsRegionsAndLanguages2",
        "tags": [
          "Environments, regions and languages"
        ],
        "summary": "Changes a language",
        "description": "Changes a language. Permission: locale:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "fallbackLocaleId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "An id."
                  },
                  "isDefault": {
                    "type": "boolean"
                  },
                  "enabled": {
                    "type": "boolean"
                  },
                  "settings": {
                    "type": "object",
                    "additionalProperties": {
                      "description": "Any JSON value."
                    }
                  },
                  "sortOrder": {
                    "type": "integer"
                  }
                }
              },
              "example": {
                "name": "Norsk bokmål",
                "fallbackLocaleId": "6650f1c2a9e4b1d2c3f40a16"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The language.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Locale"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a18",
                    "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "regionId": "6650f1c2a9e4b1d2c3f40a17",
                    "code": "nb-NO",
                    "name": "Norsk",
                    "fallbackLocaleId": null,
                    "isDefault": true,
                    "enabled": true,
                    "sortOrder": 1
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or a fallback to itself or in a circle.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks locale:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such language, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Locale not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "Turning off or removing the default of the region.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/component-uses/{key}": {
      "get": {
        "operationId": "getContentTypesAndComponentsComponentUsesByKey",
        "tags": [
          "Content types and components"
        ],
        "summary": "Pages that use a component, up to 24",
        "description": "Pages that use a component, up to 24. Permission: content:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "key",
            "in": "path",
            "required": true,
            "description": "The key, such as trip, hero or activity.",
            "schema": {
              "type": "string"
            },
            "example": "trip"
          }
        ],
        "responses": {
          "200": {
            "description": "[{ contentId, page, url, summary, node }].",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "contentId": {
                            "type": "string",
                            "description": "An id."
                          },
                          "page": {
                            "type": "string",
                            "description": "The page's name."
                          },
                          "url": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "summary": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "description": "The block's main text."
                          },
                          "node": {
                            "$ref": "#/components/schemas/Block"
                          }
                        },
                        "required": [
                          "contentId",
                          "page",
                          "url",
                          "summary",
                          "node"
                        ]
                      },
                      "description": "Up to 24 pages."
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "contentId": "6650f1c2a9e4b1d2c3f40a21",
                      "page": "…",
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "summary": "Six days of paddling between the peaks of Lofoten.",
                      "node": {
                        "id": "6650f1c2a9e4b1d2c3f40a40",
                        "type": "…",
                        "schemaVersion": 12,
                        "fields": {},
                        "children": {},
                        "variant": null
                      }
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such item with that key, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Component use not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/content": {
      "get": {
        "operationId": "getContentContent",
        "tags": [
          "Content"
        ],
        "summary": "The content at the top level, or in folderId",
        "description": "The content at the top level, or in folderId. Permission: content:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "folderId",
            "in": "query",
            "required": false,
            "description": "A folder's id, or root for the top level. Leave it out for the top level.",
            "schema": {
              "type": "string"
            },
            "example": "root"
          },
          {
            "name": "url",
            "in": "query",
            "required": false,
            "description": "Find content by its address instead. Answers a list with one summary, or an empty list.",
            "schema": {
              "type": "string"
            },
            "example": "/trips/lofoten-sea-kayaking"
          },
          {
            "name": "externalId",
            "in": "query",
            "required": false,
            "description": "Find content by your own id instead, such as its id in the system you migrate from. Repeat it for up to 500 ids. Answers a summary for each one found.",
            "schema": {
              "type": "string"
            },
            "example": "drupal:node:412"
          }
        ],
        "responses": {
          "200": {
            "description": "List of summaries.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/ContentSummary"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a4e",
                      "name": "Lofoten sea kayaking",
                      "slug": "lofoten-sea-kayaking",
                      "url": "/trips/lofoten-sea-kayaking",
                      "status": "draft",
                      "contentTypeKey": "trip",
                      "folderId": "6650f1c2a9e4b1d2c3f40a20",
                      "externalId": null,
                      "isGlobal": false,
                      "isFolderIndex": false,
                      "updatedAt": "2026-11-02T09:30:00.000Z",
                      "publishedAt": "2026-11-02T09:30:00.000Z"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such language, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Locale not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postContentContent",
        "tags": [
          "Content"
        ],
        "summary": "Creates content as a draft",
        "description": "Creates content as a draft. Permission: content:create.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "description": "true checks everything a create checks and answers what it would make, with id null, without saving.",
            "schema": {
              "type": "string",
              "enum": [
                "true",
                "false"
              ]
            }
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200,
                    "description": "The name editors see, such as Lofoten sea kayaking."
                  },
                  "slug": {
                    "type": "string",
                    "description": "The last part of the address. From the name when left out."
                  },
                  "contentTypeKey": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 64,
                    "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$",
                    "description": "One of the space's content types."
                  },
                  "folderId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "The folder it lives in. The folder must accept the content type."
                  },
                  "urlOverride": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 500,
                    "description": "A whole address instead of folder and slug, such as /winter."
                  },
                  "fields": {
                    "default": {},
                    "type": "object",
                    "additionalProperties": {
                      "description": "Any JSON value."
                    },
                    "description": "Field values by key. See the field types guide."
                  },
                  "components": {
                    "default": [],
                    "type": "array",
                    "items": {
                      "description": "Any JSON value."
                    },
                    "description": "Blocks: each { id, type, fields, children, variant }, where children holds slots of further blocks. See the Block schema. Defaults to the content type's template."
                  },
                  "seo": {
                    "type": "object",
                    "properties": {
                      "title": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 200,
                        "default": null
                      },
                      "description": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 500,
                        "default": null
                      },
                      "canonical": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 500,
                        "default": null
                      },
                      "noIndex": {
                        "default": false,
                        "type": "boolean"
                      },
                      "ogTitle": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 200,
                        "default": null
                      },
                      "ogDescription": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 500,
                        "default": null
                      },
                      "ogImage": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 500,
                        "default": null
                      },
                      "twitterTitle": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 200,
                        "default": null
                      },
                      "twitterDescription": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 500,
                        "default": null
                      },
                      "twitterImage": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 500,
                        "default": null
                      },
                      "noFollow": {
                        "default": false,
                        "type": "boolean"
                      },
                      "breadcrumbLabel": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 120,
                        "default": null
                      },
                      "sitemapExclude": {
                        "default": false,
                        "type": "boolean"
                      },
                      "sitemapChangeFrequency": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "enum": [
                          "always",
                          "hourly",
                          "daily",
                          "weekly",
                          "monthly",
                          "yearly",
                          "never",
                          null
                        ],
                        "default": null
                      },
                      "sitemapPriority": {
                        "type": [
                          "number",
                          "null"
                        ],
                        "minimum": 0,
                        "maximum": 1,
                        "default": null
                      }
                    }
                  },
                  "globalKey": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "minLength": 1,
                    "maxLength": 64,
                    "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$",
                    "description": "The key a global entry is read by, such as footer."
                  },
                  "externalId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "minLength": 1,
                    "maxLength": 200,
                    "description": "Your own id for the entry, up to 200 characters, such as its id in the system you migrate from. Unique in this language: another entry with it answers 409."
                  },
                  "isFolderIndex": {
                    "default": false,
                    "type": "boolean",
                    "description": "The folder's own page, at the folder's address."
                  },
                  "sortOrder": {
                    "default": 0,
                    "type": "integer"
                  }
                },
                "required": [
                  "name",
                  "contentTypeKey"
                ]
              },
              "example": {
                "name": "Lofoten sea kayaking",
                "contentTypeKey": "trip",
                "folderId": "6650f1c2a9e4b1d2c3f40a20",
                "fields": {
                  "title": "Lofoten sea kayaking",
                  "days": 6
                },
                "seo": {
                  "description": "Six days of paddling between the peaks of Lofoten."
                }
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The summary.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/ContentSummary"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a4e",
                    "name": "Lofoten sea kayaking",
                    "slug": "lofoten-sea-kayaking",
                    "url": "/trips/lofoten-sea-kayaking",
                    "status": "draft",
                    "contentTypeKey": "trip",
                    "folderId": "6650f1c2a9e4b1d2c3f40a20",
                    "externalId": null,
                    "isGlobal": false,
                    "isFolderIndex": false,
                    "updatedAt": "2026-11-02T09:30:00.000Z",
                    "publishedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or a field value breaks the content type's rules (each in details as { path, message }), the folder doesn't accept the content type, or a link points to a page in the bin or another space.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:create, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such language, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Locale not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "The address or externalId is taken, or the content type allows one item and it exists.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/content/trash": {
      "delete": {
        "operationId": "deleteContentContentTrash",
        "tags": [
          "Content"
        ],
        "summary": "Erases every item of one content type in the bin",
        "description": "Erases every item of one content type in the bin. Permission: content:purge.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "type",
            "in": "query",
            "required": true,
            "description": "The content type key to erase, such as trip. Required.",
            "schema": {
              "type": "string"
            },
            "example": "trip"
          }
        ],
        "responses": {
          "200": {
            "description": "{ erased }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "erased": {
                          "type": "integer",
                          "description": "How many items were erased."
                        }
                      },
                      "required": [
                        "erased"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "erased": 1
                  }
                }
              }
            }
          },
          "400": {
            "description": "No type.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:purge, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such language, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Locale not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "get": {
        "operationId": "getContentContentTrash",
        "tags": [
          "Content"
        ],
        "summary": "What is in the bin in this language",
        "description": "What is in the bin in this language. Permission: content:delete.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          }
        ],
        "responses": {
          "200": {
            "description": "[{ id, name, url, contentTypeKey, deletedAt, folderName, urlTaken, wasPublished }].",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string",
                            "description": "An id."
                          },
                          "name": {
                            "type": "string"
                          },
                          "url": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "description": "The address it had."
                          },
                          "contentTypeKey": {
                            "type": "string"
                          },
                          "deletedAt": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "folderName": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "urlTaken": {
                            "type": "boolean",
                            "description": "Another item now uses the address, so restoring gives it a new one."
                          },
                          "wasPublished": {
                            "type": "boolean"
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "url",
                          "contentTypeKey",
                          "deletedAt",
                          "folderName",
                          "urlTaken",
                          "wasPublished"
                        ]
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "name": "Lofoten sea kayaking",
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "contentTypeKey": "…",
                      "deletedAt": "2026-11-02T09:30:00.000Z",
                      "folderName": null,
                      "urlTaken": false,
                      "wasPublished": false
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:delete.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such language, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Locale not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/content/{contentId}": {
      "delete": {
        "operationId": "deleteContentContentByContentId",
        "tags": [
          "Content"
        ],
        "summary": "Moves it to the bin",
        "description": "Moves it to the bin. redirectTo=/gear also adds a redirect from its live address. Permission: content:delete.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          },
          {
            "name": "redirectTo",
            "in": "query",
            "required": false,
            "description": "Also add a redirect from its live address to this one, such as /trips.",
            "schema": {
              "type": "string"
            },
            "example": "/trips"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "400": {
            "description": "A shared section that pages still use, or a redirect address that isn't valid.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:delete, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "get": {
        "operationId": "getContentContentByContentId",
        "tags": [
          "Content"
        ],
        "summary": "One item with its draft",
        "description": "One item with its draft. Permission: content:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          }
        ],
        "responses": {
          "200": {
            "description": "The item.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Content"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a21",
                    "name": "Lofoten sea kayaking",
                    "slug": "lofoten-sea-kayaking",
                    "url": "/trips/lofoten-sea-kayaking",
                    "status": "draft",
                    "contentTypeKey": "trip",
                    "folderId": "6650f1c2a9e4b1d2c3f40a20",
                    "externalId": null,
                    "isGlobal": false,
                    "isFolderIndex": false,
                    "updatedAt": "2026-11-02T09:30:00.000Z",
                    "publishedAt": "2026-11-02T09:30:00.000Z",
                    "urlOverride": null,
                    "draft": {
                      "fields": {},
                      "components": [
                        {
                          "id": "hero-1",
                          "type": "hero",
                          "schemaVersion": 12,
                          "fields": {
                            "heading": "Paddle the Lofoten fjords"
                          },
                          "children": {},
                          "variant": null
                        }
                      ],
                      "seo": {
                        "title": "Lofoten sea kayaking",
                        "description": "Six days of paddling between the peaks of Lofoten.",
                        "canonical": null,
                        "noIndex": false,
                        "ogTitle": null,
                        "ogDescription": null,
                        "ogImage": null,
                        "twitterTitle": null,
                        "twitterDescription": null,
                        "twitterImage": null,
                        "noFollow": false,
                        "breadcrumbLabel": null,
                        "sitemapExclude": false,
                        "sitemapChangeFrequency": "always",
                        "sitemapPriority": 0
                      },
                      "updatedAt": "2026-11-02T09:30:00.000Z",
                      "updatedBy": "6650f1c2a9e4b1d2c3f40a30"
                    },
                    "draftVersion": 12,
                    "publishedVersion": 12,
                    "docVersion": 12
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchContentContentByContentId",
        "tags": [
          "Content"
        ],
        "summary": "Saves the draft",
        "description": "Saves the draft. Permission: content:update.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "description": "true checks everything a save checks and answers the entry as it would be, without saving.",
            "schema": {
              "type": "string",
              "enum": [
                "true",
                "false"
              ]
            }
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "slug": {
                    "type": "string"
                  },
                  "urlOverride": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 500
                  },
                  "folderId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "An id."
                  },
                  "fields": {
                    "type": "object",
                    "additionalProperties": {
                      "description": "Any JSON value."
                    },
                    "description": "Field values by key. Fields you leave out keep their value."
                  },
                  "components": {
                    "type": "array",
                    "items": {
                      "description": "Any JSON value."
                    },
                    "description": "Blocks: each { id, type, fields, children, variant }, where children holds slots of further blocks. See the Block schema."
                  },
                  "seo": {
                    "type": "object",
                    "properties": {
                      "title": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 200
                      },
                      "description": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 500
                      },
                      "canonical": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 500
                      },
                      "noIndex": {
                        "type": "boolean"
                      },
                      "ogTitle": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 200
                      },
                      "ogDescription": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 500
                      },
                      "ogImage": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 500
                      },
                      "twitterTitle": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 200
                      },
                      "twitterDescription": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 500
                      },
                      "twitterImage": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 500
                      },
                      "noFollow": {
                        "type": "boolean"
                      },
                      "breadcrumbLabel": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 120
                      },
                      "sitemapExclude": {
                        "type": "boolean"
                      },
                      "sitemapChangeFrequency": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "enum": [
                          "always",
                          "hourly",
                          "daily",
                          "weekly",
                          "monthly",
                          "yearly",
                          "never",
                          null
                        ]
                      },
                      "sitemapPriority": {
                        "type": [
                          "number",
                          "null"
                        ],
                        "minimum": 0,
                        "maximum": 1
                      }
                    }
                  },
                  "externalId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "minLength": 1,
                    "maxLength": 200,
                    "description": "Your own id for the entry, or null to remove it. Unique in this language."
                  },
                  "isFolderIndex": {
                    "type": "boolean"
                  },
                  "sortOrder": {
                    "type": "integer"
                  },
                  "docVersion": {
                    "type": "integer",
                    "description": "The version you read. A save answers 409 when the page has changed since."
                  }
                }
              },
              "example": {
                "docVersion": 12,
                "fields": {
                  "title": "Lofoten sea kayaking",
                  "days": 6,
                  "priceFrom": 18900
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The item.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Content"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a21",
                    "name": "Lofoten sea kayaking",
                    "slug": "lofoten-sea-kayaking",
                    "url": "/trips/lofoten-sea-kayaking",
                    "status": "draft",
                    "contentTypeKey": "trip",
                    "folderId": "6650f1c2a9e4b1d2c3f40a20",
                    "externalId": null,
                    "isGlobal": false,
                    "isFolderIndex": false,
                    "updatedAt": "2026-11-02T09:30:00.000Z",
                    "publishedAt": "2026-11-02T09:30:00.000Z",
                    "urlOverride": null,
                    "draft": {
                      "fields": {},
                      "components": [
                        {
                          "id": "hero-1",
                          "type": "hero",
                          "schemaVersion": 12,
                          "fields": {
                            "heading": "Paddle the Lofoten fjords"
                          },
                          "children": {},
                          "variant": null
                        }
                      ],
                      "seo": {
                        "title": "Lofoten sea kayaking",
                        "description": "Six days of paddling between the peaks of Lofoten.",
                        "canonical": null,
                        "noIndex": false,
                        "ogTitle": null,
                        "ogDescription": null,
                        "ogImage": null,
                        "twitterTitle": null,
                        "twitterDescription": null,
                        "twitterImage": null,
                        "noFollow": false,
                        "breadcrumbLabel": null,
                        "sitemapExclude": false,
                        "sitemapChangeFrequency": "always",
                        "sitemapPriority": 0
                      },
                      "updatedAt": "2026-11-02T09:30:00.000Z",
                      "updatedBy": "6650f1c2a9e4b1d2c3f40a30"
                    },
                    "draftVersion": 12,
                    "publishedVersion": 12,
                    "docVersion": 12
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or a field value breaks the content type's rules (each in details as { path, message }), the folder doesn't accept the content type, or a link points to a page in the bin or another space.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:update, or changes price, promotion or brand-locked fields without pricing:manage, promotions:manage or brand:manage.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "The page changed since the docVersion you sent (details has currentVersion, expected and received), someone has it open, the address is taken, or the content type allows one item.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/content/{contentId}/delivery": {
      "get": {
        "operationId": "getContentContentByContentIdDelivery",
        "tags": [
          "Content"
        ],
        "summary": "What the Delivery API answers for it",
        "description": "What the Delivery API answers for it. draft=true for the draft. Permission: content:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          },
          {
            "name": "draft",
            "in": "query",
            "required": false,
            "description": "true for what the draft would deliver.",
            "schema": {
              "type": "string",
              "enum": [
                "true",
                "false"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "{ request, body }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "request": {
                          "type": "string",
                          "description": "The Delivery API address that answers this, such as /cms/v1/content?url=/trips/lofoten-sea-kayaking."
                        },
                        "body": {
                          "description": "What it answers: a Page or, for a global entry, a Global. See https://docs.bifrostorbit.com/reference/cms-delivery/."
                        }
                      },
                      "required": [
                        "request",
                        "body"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "request": "/cms/v1/content?url=/trips/lofoten-sea-kayaking",
                    "body": null
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postContentContentByContentIdDelivery",
        "tags": [
          "Content"
        ],
        "summary": "What the Delivery API would answer for a draft you send in the body, before saving it",
        "description": "What the Delivery API would answer for a draft you send in the body, before saving it. as=banner or as=popup previews a banner or popup; include=references adds referenced entries. Permission: content:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          },
          {
            "name": "as",
            "in": "query",
            "required": false,
            "description": "banner or popup previews the draft as a banner or popup.",
            "schema": {
              "type": "string",
              "enum": [
                "banner",
                "popup"
              ]
            }
          },
          {
            "name": "include",
            "in": "query",
            "required": false,
            "description": "references adds the entries the draft refers to.",
            "schema": {
              "type": "string"
            },
            "example": "references"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "description": "A draft, as you would save it.",
                "properties": {
                  "fields": {
                    "type": "object",
                    "additionalProperties": {},
                    "description": "The draft's field values."
                  },
                  "components": {
                    "type": "array",
                    "items": {
                      "$ref": "#/components/schemas/Block"
                    }
                  }
                },
                "required": [
                  "fields"
                ]
              },
              "example": {
                "fields": {
                  "title": "Lofoten sea kayaking"
                },
                "components": []
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "{ request, body }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "description": "What the Delivery API would answer: { fields, components } for a page, or a banner or popup as the Delivery API delivers them. See https://docs.bifrostorbit.com/reference/cms-delivery/."
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": null
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or the draft breaks the content type's rules, or as=banner on content that isn't a banner.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:read, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/content/{contentId}/duplicate": {
      "post": {
        "operationId": "postContentContentByContentIdDuplicate",
        "tags": [
          "Content"
        ],
        "summary": "Copies it in the same folder, with a new name and address",
        "description": "Copies it in the same folder, with a new name and address. includeMedia (default true). Permission: content:copy.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "includeContent": {
                    "default": true,
                    "type": "boolean",
                    "description": "Copy the fields and blocks."
                  },
                  "includeSeo": {
                    "default": true,
                    "type": "boolean",
                    "description": "Copy the search settings."
                  },
                  "includeMedia": {
                    "default": true,
                    "type": "boolean",
                    "description": "Keep the images and files."
                  }
                }
              },
              "example": {
                "includeMedia": true
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The summary.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/ContentSummary"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a4e",
                    "name": "Lofoten sea kayaking",
                    "slug": "lofoten-sea-kayaking",
                    "url": "/trips/lofoten-sea-kayaking",
                    "status": "draft",
                    "contentTypeKey": "trip",
                    "folderId": "6650f1c2a9e4b1d2c3f40a20",
                    "externalId": null,
                    "isGlobal": false,
                    "isFolderIndex": false,
                    "updatedAt": "2026-11-02T09:30:00.000Z",
                    "publishedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:copy, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/content/{contentId}/emergency-publish": {
      "post": {
        "operationId": "postPublishingContentByContentIdEmergencyPublish",
        "tags": [
          "Publishing"
        ],
        "summary": "Publishes a banner at once on every page, past approval",
        "description": "Publishes a banner at once on every page, past approval. Permission: emergency:publish.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "reason": {
                    "type": "string",
                    "description": "Why it can't wait, 5 to 300 characters. Recorded in the audit log."
                  }
                },
                "required": [
                  "reason"
                ]
              },
              "example": {
                "reason": "The Tromsø ferry is cancelled today because of the storm."
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The item.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Content"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a21",
                    "name": "Lofoten sea kayaking",
                    "slug": "lofoten-sea-kayaking",
                    "url": "/trips/lofoten-sea-kayaking",
                    "status": "draft",
                    "contentTypeKey": "trip",
                    "folderId": "6650f1c2a9e4b1d2c3f40a20",
                    "externalId": null,
                    "isGlobal": false,
                    "isFolderIndex": false,
                    "updatedAt": "2026-11-02T09:30:00.000Z",
                    "publishedAt": "2026-11-02T09:30:00.000Z",
                    "urlOverride": null,
                    "draft": {
                      "fields": {},
                      "components": [
                        {
                          "id": "hero-1",
                          "type": "hero",
                          "schemaVersion": 12,
                          "fields": {
                            "heading": "Paddle the Lofoten fjords"
                          },
                          "children": {},
                          "variant": null
                        }
                      ],
                      "seo": {
                        "title": "Lofoten sea kayaking",
                        "description": "Six days of paddling between the peaks of Lofoten.",
                        "canonical": null,
                        "noIndex": false,
                        "ogTitle": null,
                        "ogDescription": null,
                        "ogImage": null,
                        "twitterTitle": null,
                        "twitterDescription": null,
                        "twitterImage": null,
                        "noFollow": false,
                        "breadcrumbLabel": null,
                        "sitemapExclude": false,
                        "sitemapChangeFrequency": "always",
                        "sitemapPriority": 0
                      },
                      "updatedAt": "2026-11-02T09:30:00.000Z",
                      "updatedBy": "6650f1c2a9e4b1d2c3f40a30"
                    },
                    "draftVersion": 12,
                    "publishedVersion": 12,
                    "docVersion": 12
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or no reason, a reason over 300 characters, or content that isn't a banner.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks emergency:publish, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/content/{contentId}/preview": {
      "post": {
        "operationId": "postContentContentByContentIdPreview",
        "tags": [
          "Content"
        ],
        "summary": "A preview link for the draft, valid for an hour",
        "description": "A preview link for the draft, valid for an hour. Permission: content:read_draft.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "responses": {
          "201": {
            "description": "{ token, expiresAt, url }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "token": {
                          "type": "string"
                        },
                        "expiresAt": {
                          "type": "string",
                          "description": "In an hour.",
                          "format": "date-time"
                        },
                        "url": {
                          "type": "string",
                          "description": "The space's preview address with the token, ready to open."
                        }
                      },
                      "required": [
                        "token",
                        "expiresAt",
                        "url"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "token": "cms_pk_…",
                    "expiresAt": "2026-11-02T09:30:00.000Z",
                    "url": "https://northwilds.com/trips/lofoten-sea-kayaking"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:read_draft, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/content/{contentId}/promote": {
      "post": {
        "operationId": "postPublishingContentByContentIdPromote",
        "tags": [
          "Publishing"
        ],
        "summary": "Copies the published version to another environment and publishes it there",
        "description": "Copies the published version to another environment and publishes it there. Permission: content:publish in both.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "targetEnvironmentId": {
                    "type": "string",
                    "description": "The environment to publish it in, such as production."
                  }
                },
                "required": [
                  "targetEnvironmentId"
                ]
              },
              "example": {
                "targetEnvironmentId": "6650f1c2a9e4b1d2c3f40a14"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "{ contentId, targetContentId, targetEnvironment, created }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "contentId": {
                          "type": "string",
                          "description": "An id."
                        },
                        "targetContentId": {
                          "type": "string",
                          "description": "Its id in the other environment."
                        },
                        "targetEnvironment": {
                          "type": "string",
                          "description": "The other environment's name."
                        },
                        "created": {
                          "type": "boolean",
                          "description": "It didn't exist there before."
                        }
                      },
                      "required": [
                        "contentId",
                        "targetContentId",
                        "targetEnvironment",
                        "created"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "contentId": "6650f1c2a9e4b1d2c3f40a21",
                    "targetContentId": "6650f1c2a9e4b1d2c3f40a5f",
                    "targetEnvironment": "…",
                    "created": true
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or the same environment, or the other environment lacks the region or language.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:publish here or there.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "It isn't published here, or another page uses the address there.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/promote": {
      "post": {
        "operationId": "postPublishingPromote",
        "tags": [
          "Publishing"
        ],
        "summary": "Promotes every published entry in a folder or language to another environment, with their redirects",
        "description": "Promotes every published entry in a folder or language to another environment, with their redirects. Permission: content:publish in both, redirect:manage for redirects.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "targetEnvironmentId": {
                    "type": "string",
                    "description": "The environment to publish in, such as production."
                  },
                  "folderId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "Promote this folder and every folder in it. Leave it out, or send null, for every entry in this language."
                  },
                  "redirects": {
                    "default": true,
                    "type": "boolean",
                    "description": "Also copy the redirects to the pages promoted, or for a whole language every redirect in it. Needs redirect:manage; without it they are left out and redirectsSkipped is true."
                  },
                  "dryRun": {
                    "default": false,
                    "type": "boolean",
                    "description": "Answer what would happen without changing anything."
                  },
                  "after": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "The next value of the previous answer. Each call handles up to 100 entries, fewer when they take more than 30 seconds."
                  }
                },
                "required": [
                  "targetEnvironmentId"
                ]
              },
              "example": {
                "targetEnvironmentId": "6650f1c2a9e4b1d2c3f40a14",
                "folderId": "6650f1c2a9e4b1d2c3f40a20",
                "dryRun": true
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "{ dryRun, target, total, items, next, redirects, redirectsSkipped }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "dryRun": {
                          "type": "boolean"
                        },
                        "target": {
                          "type": "string",
                          "description": "The other environment's name."
                        },
                        "total": {
                          "type": "integer",
                          "description": "Entries in the folder or language, across every call."
                        },
                        "items": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "contentId": {
                                "type": "string",
                                "description": "An id."
                              },
                              "name": {
                                "type": "string"
                              },
                              "url": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              },
                              "outcome": {
                                "type": "string",
                                "description": "unchanged when the other environment already has what is published here; notPublished entries are left out.",
                                "enum": [
                                  "create",
                                  "update",
                                  "unchanged",
                                  "notPublished",
                                  "error"
                                ]
                              },
                              "message": {
                                "type": [
                                  "string",
                                  "null"
                                ],
                                "description": "Why it failed."
                              }
                            },
                            "required": [
                              "contentId",
                              "name",
                              "url",
                              "outcome",
                              "message"
                            ]
                          },
                          "description": "The entries handled by this call."
                        },
                        "next": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "description": "Send it as after to handle the next 100. null on the last call."
                        },
                        "redirects": {
                          "type": [
                            "object",
                            "null"
                          ],
                          "description": "On the last call, when redirects is true.",
                          "properties": {
                            "create": {
                              "type": "integer"
                            },
                            "update": {
                              "type": "integer"
                            },
                            "unchanged": {
                              "type": "integer"
                            },
                            "error": {
                              "type": "integer"
                            }
                          },
                          "required": [
                            "create",
                            "update",
                            "unchanged",
                            "error"
                          ]
                        },
                        "redirectsSkipped": {
                          "type": "boolean",
                          "description": "Redirects were asked for without redirect:manage."
                        }
                      },
                      "required": [
                        "dryRun",
                        "target",
                        "total",
                        "items",
                        "next",
                        "redirects",
                        "redirectsSkipped"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "dryRun": false,
                    "target": "…",
                    "total": 4,
                    "items": [
                      {
                        "contentId": "6650f1c2a9e4b1d2c3f40a21",
                        "name": "Lofoten sea kayaking",
                        "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                        "outcome": "create",
                        "message": null
                      }
                    ],
                    "next": null,
                    "redirects": {
                      "create": 1,
                      "update": 1,
                      "unchanged": 1,
                      "error": 1
                    },
                    "redirectsSkipped": false
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or the same environment, or the other environment lacks the region or language.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:publish here or there.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such environment or folder.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Locale not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/content/{contentId}/publish": {
      "post": {
        "operationId": "postPublishingContentByContentIdPublish",
        "tags": [
          "Publishing"
        ],
        "summary": "Publishes the draft",
        "description": "Publishes the draft. Permission: content:publish.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "changeSummary": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 300,
                    "description": "What changed, shown in the history."
                  },
                  "summaryKind": {
                    "type": "string",
                    "enum": [
                      "siteSettings",
                      "allSiteSettings"
                    ],
                    "description": "Used by the CMS screens."
                  },
                  "accessibilityOverride": {
                    "type": "object",
                    "properties": {
                      "reason": {
                        "type": "string",
                        "minLength": 5,
                        "maxLength": 500
                      }
                    },
                    "required": [
                      "reason"
                    ],
                    "description": "Publish despite accessibility problems that would block it. Needs space:update."
                  },
                  "expectedDraftVersion": {
                    "type": "integer",
                    "minimum": 0,
                    "description": "The draftVersion you last read. If the page changed since, the answer is 409 draft_changed and nothing is published."
                  }
                }
              },
              "example": {
                "changeSummary": "New departures for 2027."
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The item, with redirect.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "description": "The item, with the redirect publishing added.",
                      "properties": {
                        "id": {
                          "type": "string",
                          "description": "An id."
                        },
                        "name": {
                          "type": "string"
                        },
                        "slug": {
                          "type": "string"
                        },
                        "url": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "draft",
                            "in_review",
                            "published",
                            "scheduled",
                            "archived"
                          ]
                        },
                        "contentTypeKey": {
                          "type": "string"
                        },
                        "folderId": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "description": "An id."
                        },
                        "externalId": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "isGlobal": {
                          "type": "boolean"
                        },
                        "isFolderIndex": {
                          "type": "boolean"
                        },
                        "updatedAt": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "publishedAt": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "format": "date-time"
                        },
                        "urlOverride": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "draft": {
                          "type": "object",
                          "description": "The draft. No seo for content without an address.",
                          "properties": {
                            "fields": {
                              "type": "object",
                              "additionalProperties": {},
                              "description": "Field values by key. See https://docs.bifrostorbit.com/cms/developers/field-types/."
                            },
                            "components": {
                              "type": "array",
                              "items": {
                                "$ref": "#/components/schemas/Block"
                              }
                            },
                            "seo": {
                              "type": "object",
                              "properties": {
                                "title": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "description": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "canonical": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "noIndex": {
                                  "type": "boolean"
                                },
                                "ogTitle": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "ogDescription": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "ogImage": {
                                  "type": [
                                    "string",
                                    "null"
                                  ],
                                  "description": "A media id or address."
                                },
                                "twitterTitle": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "twitterDescription": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "twitterImage": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "noFollow": {
                                  "type": "boolean"
                                },
                                "breadcrumbLabel": {
                                  "type": [
                                    "string",
                                    "null"
                                  ]
                                },
                                "sitemapExclude": {
                                  "type": "boolean"
                                },
                                "sitemapChangeFrequency": {
                                  "type": [
                                    "string",
                                    "null"
                                  ],
                                  "enum": [
                                    "always",
                                    "hourly",
                                    "daily",
                                    "weekly",
                                    "monthly",
                                    "yearly",
                                    "never",
                                    null
                                  ]
                                },
                                "sitemapPriority": {
                                  "type": [
                                    "number",
                                    "null"
                                  ],
                                  "minimum": 0,
                                  "maximum": 1
                                }
                              },
                              "required": [
                                "title",
                                "description",
                                "canonical",
                                "noIndex",
                                "ogTitle",
                                "ogDescription",
                                "ogImage",
                                "twitterTitle",
                                "twitterDescription",
                                "twitterImage",
                                "noFollow",
                                "breadcrumbLabel",
                                "sitemapExclude",
                                "sitemapChangeFrequency",
                                "sitemapPriority"
                              ]
                            },
                            "updatedAt": {
                              "type": "string",
                              "format": "date-time"
                            },
                            "updatedBy": {
                              "type": "string",
                              "description": "An id."
                            }
                          },
                          "required": [
                            "fields",
                            "components",
                            "updatedAt",
                            "updatedBy"
                          ]
                        },
                        "draftVersion": {
                          "type": "integer"
                        },
                        "publishedVersion": {
                          "type": "integer",
                          "description": "Compare with draftVersion to see whether the draft has unpublished changes."
                        },
                        "docVersion": {
                          "type": "integer",
                          "description": "Send it back with each save, so a save never overwrites changes you haven't seen."
                        },
                        "redirect": {
                          "type": [
                            "object",
                            "null"
                          ],
                          "description": "The redirect added because the address changed, when the space adds them.",
                          "properties": {
                            "id": {
                              "type": "string",
                              "description": "An id."
                            },
                            "source": {
                              "type": "string"
                            },
                            "destination": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "id",
                            "source",
                            "destination"
                          ]
                        }
                      },
                      "required": [
                        "id",
                        "name",
                        "slug",
                        "url",
                        "status",
                        "contentTypeKey",
                        "folderId",
                        "externalId",
                        "isGlobal",
                        "isFolderIndex",
                        "updatedAt",
                        "publishedAt",
                        "urlOverride",
                        "draft",
                        "draftVersion",
                        "publishedVersion",
                        "docVersion",
                        "redirect"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a40",
                    "name": "Lofoten sea kayaking",
                    "slug": "lofoten-sea-kayaking",
                    "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                    "status": "draft",
                    "contentTypeKey": "…",
                    "folderId": "6650f1c2a9e4b1d2c3f40a20",
                    "externalId": null,
                    "isGlobal": false,
                    "isFolderIndex": false,
                    "updatedAt": "2026-11-02T09:30:00.000Z",
                    "publishedAt": "2026-11-02T09:30:00.000Z",
                    "urlOverride": null,
                    "draft": {
                      "fields": {},
                      "components": [
                        {
                          "id": "hero-1",
                          "type": "hero",
                          "schemaVersion": 12,
                          "fields": {
                            "heading": "Paddle the Lofoten fjords"
                          },
                          "children": {},
                          "variant": null
                        }
                      ],
                      "seo": {
                        "title": "Lofoten sea kayaking",
                        "description": "Six days of paddling between the peaks of Lofoten.",
                        "canonical": null,
                        "noIndex": false,
                        "ogTitle": null,
                        "ogDescription": null,
                        "ogImage": null,
                        "twitterTitle": null,
                        "twitterDescription": null,
                        "twitterImage": null,
                        "noFollow": false,
                        "breadcrumbLabel": null,
                        "sitemapExclude": false,
                        "sitemapChangeFrequency": "always",
                        "sitemapPriority": 0
                      },
                      "updatedAt": "2026-11-02T09:30:00.000Z",
                      "updatedBy": "6650f1c2a9e4b1d2c3f40a30"
                    },
                    "draftVersion": 12,
                    "publishedVersion": 12,
                    "docVersion": 12,
                    "redirect": {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "source": "…",
                      "destination": "…"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:publish, or the plan's limits.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "Nothing new to publish, it needs approval or sign-off, a check blocks it (details.blockers), or accessibility problems block it (details.accessibility and details.canOverride).",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/content/{contentId}/purge": {
      "delete": {
        "operationId": "deleteContentContentByContentIdPurge",
        "tags": [
          "Content"
        ],
        "summary": "Erases an item in the bin, with its history, for good",
        "description": "Erases an item in the bin, with its history, for good. Permission: content:purge.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "400": {
            "description": "It isn't in the bin.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:purge, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/content/{contentId}/restore": {
      "post": {
        "operationId": "postContentContentByContentIdRestore",
        "tags": [
          "Content"
        ],
        "summary": "Takes it out of the bin, as an unpublished draft",
        "description": "Takes it out of the bin, as an unpublished draft. Permission: content:create.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "responses": {
          "200": {
            "description": "The item.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Content"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a21",
                    "name": "Lofoten sea kayaking",
                    "slug": "lofoten-sea-kayaking",
                    "url": "/trips/lofoten-sea-kayaking",
                    "status": "draft",
                    "contentTypeKey": "trip",
                    "folderId": "6650f1c2a9e4b1d2c3f40a20",
                    "externalId": null,
                    "isGlobal": false,
                    "isFolderIndex": false,
                    "updatedAt": "2026-11-02T09:30:00.000Z",
                    "publishedAt": "2026-11-02T09:30:00.000Z",
                    "urlOverride": null,
                    "draft": {
                      "fields": {},
                      "components": [
                        {
                          "id": "hero-1",
                          "type": "hero",
                          "schemaVersion": 12,
                          "fields": {
                            "heading": "Paddle the Lofoten fjords"
                          },
                          "children": {},
                          "variant": null
                        }
                      ],
                      "seo": {
                        "title": "Lofoten sea kayaking",
                        "description": "Six days of paddling between the peaks of Lofoten.",
                        "canonical": null,
                        "noIndex": false,
                        "ogTitle": null,
                        "ogDescription": null,
                        "ogImage": null,
                        "twitterTitle": null,
                        "twitterDescription": null,
                        "twitterImage": null,
                        "noFollow": false,
                        "breadcrumbLabel": null,
                        "sitemapExclude": false,
                        "sitemapChangeFrequency": "always",
                        "sitemapPriority": 0
                      },
                      "updatedAt": "2026-11-02T09:30:00.000Z",
                      "updatedBy": "6650f1c2a9e4b1d2c3f40a30"
                    },
                    "draftVersion": 12,
                    "publishedVersion": 12,
                    "docVersion": 12
                  }
                }
              }
            }
          },
          "400": {
            "description": "It isn't in the bin, or its folder is gone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:create, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/content/{contentId}/review": {
      "get": {
        "operationId": "getReviewsContentByContentIdReview",
        "tags": [
          "Reviews"
        ],
        "summary": "Its latest review, or null",
        "description": "Its latest review, or null. Permission: content:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          }
        ],
        "responses": {
          "200": {
            "description": "The review.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "anyOf": [
                        {
                          "$ref": "#/components/schemas/Review"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a46",
                    "contentId": "6650f1c2a9e4b1d2c3f40a21",
                    "contentName": "Lofoten sea kayaking",
                    "contentUrl": "/trips/lofoten-sea-kayaking",
                    "contentType": "trip",
                    "region": "Norway",
                    "locale": "Norsk",
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "regionId": "6650f1c2a9e4b1d2c3f40a17",
                    "localeId": "6650f1c2a9e4b1d2c3f40a18",
                    "version": 12,
                    "status": "pending",
                    "steps": [
                      {
                        "key": "lofoten",
                        "name": "Lofoten sea kayaking",
                        "status": "pending",
                        "decidedBy": "6650f1c2a9e4b1d2c3f40a30",
                        "decidedRole": null,
                        "decidedAt": "2026-11-02T09:30:00.000Z",
                        "comment": null,
                        "who": null
                      }
                    ],
                    "message": null,
                    "reviewers": [
                      "…"
                    ],
                    "publishOnApproval": true,
                    "submittedBy": "Ingrid Berg",
                    "sentByAgent": null,
                    "draftedByAi": null,
                    "submittedAt": "2026-11-02T09:30:00.000Z",
                    "decidedAt": "2026-11-02T09:30:00.000Z",
                    "publishedAt": "2026-11-02T09:30:00.000Z",
                    "stale": false
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postReviewsContentByContentIdReview",
        "tags": [
          "Reviews"
        ],
        "summary": "Sends the draft for review",
        "description": "Sends the draft for review. Permission: content:update.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "message": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 2000,
                    "default": null,
                    "description": "What to look at, up to 2,000 characters."
                  },
                  "reviewerIds": {
                    "default": [],
                    "maxItems": 20,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^[0-9a-f]{24}$"
                    },
                    "description": "Up to 20 people to ask, from GET {space}/reviewers."
                  },
                  "publishOnApproval": {
                    "default": true,
                    "type": "boolean",
                    "description": "Publish as soon as it's approved."
                  }
                }
              },
              "example": {
                "message": "New 2027 departures and prices.",
                "reviewerIds": [
                  "6650f1c2a9e4b1d2c3f40a30"
                ]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The review.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Review"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a46",
                    "contentId": "6650f1c2a9e4b1d2c3f40a21",
                    "contentName": "Lofoten sea kayaking",
                    "contentUrl": "/trips/lofoten-sea-kayaking",
                    "contentType": "trip",
                    "region": "Norway",
                    "locale": "Norsk",
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "regionId": "6650f1c2a9e4b1d2c3f40a17",
                    "localeId": "6650f1c2a9e4b1d2c3f40a18",
                    "version": 12,
                    "status": "pending",
                    "steps": [
                      {
                        "key": "lofoten",
                        "name": "Lofoten sea kayaking",
                        "status": "pending",
                        "decidedBy": "6650f1c2a9e4b1d2c3f40a30",
                        "decidedRole": null,
                        "decidedAt": "2026-11-02T09:30:00.000Z",
                        "comment": null,
                        "who": null
                      }
                    ],
                    "message": null,
                    "reviewers": [
                      "…"
                    ],
                    "publishOnApproval": true,
                    "submittedBy": "Ingrid Berg",
                    "sentByAgent": null,
                    "draftedByAi": null,
                    "submittedAt": "2026-11-02T09:30:00.000Z",
                    "decidedAt": "2026-11-02T09:30:00.000Z",
                    "publishedAt": "2026-11-02T09:30:00.000Z",
                    "stale": false
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:update, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "Nothing new to review.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/content/{contentId}/revisions": {
      "get": {
        "operationId": "getContentContentByContentIdRevisions",
        "tags": [
          "Content"
        ],
        "summary": "Its saved and published versions, newest first, within the plan's history",
        "description": "Its saved and published versions, newest first, within the plan's history. Permission: content:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          }
        ],
        "responses": {
          "200": {
            "description": "[{ id, version, kind, changeSummary, rollbackOfVersion, userId, by, createdAt }].",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string",
                            "description": "An id."
                          },
                          "version": {
                            "type": "integer"
                          },
                          "kind": {
                            "type": "string",
                            "enum": [
                              "save",
                              "publish",
                              "unpublish",
                              "rollback",
                              "release",
                              "promotion"
                            ]
                          },
                          "changeSummary": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "rollbackOfVersion": {
                            "type": [
                              "integer",
                              "null"
                            ]
                          },
                          "userId": {
                            "type": "string",
                            "description": "An id."
                          },
                          "by": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "description": "Who, by name."
                          },
                          "createdAt": {
                            "type": "string",
                            "format": "date-time"
                          }
                        },
                        "required": [
                          "id",
                          "version",
                          "kind",
                          "changeSummary",
                          "rollbackOfVersion",
                          "userId",
                          "by",
                          "createdAt"
                        ]
                      },
                      "description": "Newest first, within the plan's history."
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "version": 12,
                      "kind": "save",
                      "changeSummary": null,
                      "rollbackOfVersion": 12,
                      "userId": "6650f1c2a9e4b1d2c3f40a30",
                      "by": "Ingrid Berg",
                      "createdAt": "2026-11-02T09:30:00.000Z"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/content/{contentId}/revisions/{revisionId}/compare": {
      "get": {
        "operationId": "getContentContentByContentIdRevisionsByRevisionIdCompare",
        "tags": [
          "Content"
        ],
        "summary": "What changed between a revision and the draft",
        "description": "What changed between a revision and the draft. Permission: content:read_draft.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          },
          {
            "name": "revisionId",
            "in": "path",
            "required": true,
            "description": "The revision's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "200": {
            "description": "{ version, createdAt, changes, before }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "version": {
                          "type": "integer"
                        },
                        "createdAt": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "changes": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "area": {
                                "type": "string",
                                "enum": [
                                  "field",
                                  "seo",
                                  "component"
                                ]
                              },
                              "key": {
                                "type": "string"
                              },
                              "type": {
                                "type": "string"
                              },
                              "change": {
                                "type": "string",
                                "enum": [
                                  "added",
                                  "removed",
                                  "changed"
                                ]
                              },
                              "fields": {
                                "type": "array",
                                "items": {
                                  "type": "string"
                                }
                              },
                              "label": {
                                "type": "string",
                                "description": "Such as Title, or Hero › Heading."
                              }
                            },
                            "required": [
                              "area",
                              "key",
                              "change",
                              "label"
                            ]
                          },
                          "description": "What differs between the revision and the draft."
                        },
                        "before": {
                          "type": "object",
                          "description": "The revision's fields and blocks.",
                          "properties": {
                            "fields": {
                              "type": "object",
                              "additionalProperties": {}
                            },
                            "components": {
                              "type": "array",
                              "items": {
                                "$ref": "#/components/schemas/Block"
                              }
                            }
                          },
                          "required": [
                            "fields",
                            "components"
                          ]
                        }
                      },
                      "required": [
                        "version",
                        "createdAt",
                        "changes",
                        "before"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "version": 12,
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "changes": [
                      {
                        "area": "field",
                        "key": "lofoten",
                        "type": "…",
                        "change": "added",
                        "fields": [
                          "…"
                        ],
                        "label": "Kayaking"
                      }
                    ],
                    "before": {
                      "fields": {},
                      "components": [
                        {
                          "id": "hero-1",
                          "type": "hero",
                          "schemaVersion": 12,
                          "fields": {
                            "heading": "Paddle the Lofoten fjords"
                          },
                          "children": {},
                          "variant": null
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:read_draft.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such revision, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Revision not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/content/{contentId}/rollback": {
      "post": {
        "operationId": "postPublishingContentByContentIdRollback",
        "tags": [
          "Publishing"
        ],
        "summary": "Puts an earlier revision back",
        "description": "Puts an earlier revision back. Permission: content:rollback.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "revisionId": {
                    "type": "string",
                    "description": "The revision to put back. When the page is live, it's published straight away."
                  },
                  "changeSummary": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 300
                  }
                },
                "required": [
                  "revisionId"
                ]
              },
              "example": {
                "revisionId": "6650f1c2a9e4b1d2c3f40a30",
                "changeSummary": "Back to the summer prices."
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The item.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Content"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a21",
                    "name": "Lofoten sea kayaking",
                    "slug": "lofoten-sea-kayaking",
                    "url": "/trips/lofoten-sea-kayaking",
                    "status": "draft",
                    "contentTypeKey": "trip",
                    "folderId": "6650f1c2a9e4b1d2c3f40a20",
                    "externalId": null,
                    "isGlobal": false,
                    "isFolderIndex": false,
                    "updatedAt": "2026-11-02T09:30:00.000Z",
                    "publishedAt": "2026-11-02T09:30:00.000Z",
                    "urlOverride": null,
                    "draft": {
                      "fields": {},
                      "components": [
                        {
                          "id": "hero-1",
                          "type": "hero",
                          "schemaVersion": 12,
                          "fields": {
                            "heading": "Paddle the Lofoten fjords"
                          },
                          "children": {},
                          "variant": null
                        }
                      ],
                      "seo": {
                        "title": "Lofoten sea kayaking",
                        "description": "Six days of paddling between the peaks of Lofoten.",
                        "canonical": null,
                        "noIndex": false,
                        "ogTitle": null,
                        "ogDescription": null,
                        "ogImage": null,
                        "twitterTitle": null,
                        "twitterDescription": null,
                        "twitterImage": null,
                        "noFollow": false,
                        "breadcrumbLabel": null,
                        "sitemapExclude": false,
                        "sitemapChangeFrequency": "always",
                        "sitemapPriority": 0
                      },
                      "updatedAt": "2026-11-02T09:30:00.000Z",
                      "updatedBy": "6650f1c2a9e4b1d2c3f40a30"
                    },
                    "draftVersion": 12,
                    "publishedVersion": 12,
                    "docVersion": 12
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:rollback, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/content/{contentId}/schedule": {
      "get": {
        "operationId": "getPublishingContentByContentIdSchedule",
        "tags": [
          "Publishing"
        ],
        "summary": "Its scheduled publishing and unpublishing",
        "description": "Its scheduled publishing and unpublishing. Permission: release:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          }
        ],
        "responses": {
          "200": {
            "description": "[{ releaseId, action, at, sharedWith }].",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Schedule"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "releaseId": "6650f1c2a9e4b1d2c3f40a59",
                      "action": "publish",
                      "at": "2026-11-02T09:30:00.000Z",
                      "sharedWith": 1
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Not a content id.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks release:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postPublishingContentByContentIdSchedule",
        "tags": [
          "Publishing"
        ],
        "summary": "Publishes or unpublishes it at a time",
        "description": "Publishes or unpublishes it at a time. Permission: content:publish or content:unpublish, and release:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "at": {
                    "type": "string",
                    "description": "When, in the future, ISO 8601 with a time zone. Required.",
                    "format": "date-time"
                  },
                  "action": {
                    "type": "string",
                    "description": "Default publish.",
                    "enum": [
                      "publish",
                      "unpublish"
                    ]
                  }
                },
                "required": [
                  "at"
                ]
              },
              "example": {
                "at": "2026-12-01T08:00:00Z",
                "action": "publish"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "{ releaseId, action, at, sharedWith }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Schedule"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "releaseId": "6650f1c2a9e4b1d2c3f40a59",
                    "action": "publish",
                    "at": "2026-11-02T09:30:00.000Z",
                    "sharedWith": 1
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or no date and time, or one in the past.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:publish or content:unpublish, release:manage, or the plan has no releases.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/content/{contentId}/unpublish": {
      "post": {
        "operationId": "postPublishingContentByContentIdUnpublish",
        "tags": [
          "Publishing"
        ],
        "summary": "Takes it off the website",
        "description": "Takes it off the website. redirectTo adds a redirect. Permission: content:unpublish.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "redirectTo": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "Also add a redirect from its address to this one, such as /trips."
                  }
                },
                "required": []
              },
              "example": {
                "redirectTo": "/trips"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The item.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Content"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a21",
                    "name": "Lofoten sea kayaking",
                    "slug": "lofoten-sea-kayaking",
                    "url": "/trips/lofoten-sea-kayaking",
                    "status": "draft",
                    "contentTypeKey": "trip",
                    "folderId": "6650f1c2a9e4b1d2c3f40a20",
                    "externalId": null,
                    "isGlobal": false,
                    "isFolderIndex": false,
                    "updatedAt": "2026-11-02T09:30:00.000Z",
                    "publishedAt": "2026-11-02T09:30:00.000Z",
                    "urlOverride": null,
                    "draft": {
                      "fields": {},
                      "components": [
                        {
                          "id": "hero-1",
                          "type": "hero",
                          "schemaVersion": 12,
                          "fields": {
                            "heading": "Paddle the Lofoten fjords"
                          },
                          "children": {},
                          "variant": null
                        }
                      ],
                      "seo": {
                        "title": "Lofoten sea kayaking",
                        "description": "Six days of paddling between the peaks of Lofoten.",
                        "canonical": null,
                        "noIndex": false,
                        "ogTitle": null,
                        "ogDescription": null,
                        "ogImage": null,
                        "twitterTitle": null,
                        "twitterDescription": null,
                        "twitterImage": null,
                        "noFollow": false,
                        "breadcrumbLabel": null,
                        "sitemapExclude": false,
                        "sitemapChangeFrequency": "always",
                        "sitemapPriority": 0
                      },
                      "updatedAt": "2026-11-02T09:30:00.000Z",
                      "updatedBy": "6650f1c2a9e4b1d2c3f40a30"
                    },
                    "draftVersion": 12,
                    "publishedVersion": 12,
                    "docVersion": 12
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:unpublish, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "It isn't published, is scheduled, or is in a release.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/content/{contentId}/update-from-source": {
      "post": {
        "operationId": "postCopyingAndTranslatingContentByContentIdUpdateFromSource",
        "tags": [
          "Copying and translating"
        ],
        "summary": "Brings a regional copy up to date with its source",
        "description": "Brings a regional copy up to date with its source. Permission: content:update.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "responses": {
          "200": {
            "description": "{ kept }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "kept": {
                          "type": "integer",
                          "description": "Fields kept because they were changed here."
                        }
                      },
                      "required": [
                        "kept"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "kept": 1
                  }
                }
              }
            }
          },
          "400": {
            "description": "It isn't a regional copy, or its source is gone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:update, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/copy": {
      "post": {
        "operationId": "postCopyingAndTranslatingCopy",
        "tags": [
          "Copying and translating"
        ],
        "summary": "Copies pages or folders to another region or language",
        "description": "Copies pages or folders to another region or language. Permission: content:copy here, content:create there.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "environmentId": {
                    "type": "string",
                    "description": "The target environment."
                  },
                  "regionId": {
                    "type": "string",
                    "description": "The target region."
                  },
                  "localeId": {
                    "type": "string",
                    "description": "The target language."
                  },
                  "folderId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "A folder to copy, with what it holds."
                  },
                  "contentIds": {
                    "type": "array",
                    "items": {
                      "type": "string",
                      "description": "An id."
                    },
                    "description": "Pages to copy. Without these and folderId, the whole language is copied."
                  },
                  "includeContent": {
                    "default": true,
                    "type": "boolean"
                  },
                  "includeSeo": {
                    "default": true,
                    "type": "boolean"
                  },
                  "includeMedia": {
                    "default": true,
                    "type": "boolean"
                  }
                },
                "required": [
                  "environmentId",
                  "regionId",
                  "localeId"
                ]
              },
              "example": {
                "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                "regionId": "6650f1c2a9e4b1d2c3f40a17",
                "localeId": "6650f1c2a9e4b1d2c3f40a18",
                "contentIds": [
                  "6650f1c2a9e4b1d2c3f40a21"
                ]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "{ folders, content, target }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "folders": {
                          "type": "integer"
                        },
                        "content": {
                          "type": "integer"
                        },
                        "target": {
                          "type": "object",
                          "properties": {
                            "environmentId": {
                              "type": "string",
                              "description": "An id."
                            },
                            "regionId": {
                              "type": "string",
                              "description": "An id."
                            },
                            "localeId": {
                              "type": "string",
                              "description": "An id."
                            }
                          },
                          "required": [
                            "environmentId",
                            "regionId",
                            "localeId"
                          ]
                        },
                        "pages": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "sourceId": {
                                "type": "string",
                                "description": "An id."
                              },
                              "id": {
                                "type": "string",
                                "description": "An id."
                              },
                              "name": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "sourceId",
                              "id",
                              "name"
                            ]
                          },
                          "description": "When you copied chosen pages: each copy's new id with the id it was copied from."
                        }
                      },
                      "required": [
                        "folders",
                        "content",
                        "target"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "folders": 1,
                    "content": 1,
                    "target": {
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "regionId": "6650f1c2a9e4b1d2c3f40a17",
                      "localeId": "6650f1c2a9e4b1d2c3f40a18"
                    },
                    "pages": [
                      {
                        "sourceId": "6650f1c2a9e4b1d2c3f40a58",
                        "id": "6650f1c2a9e4b1d2c3f40a40",
                        "name": "Lofoten sea kayaking"
                      }
                    ]
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or the target is where it is now.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:copy here or content:create there.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such language, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Locale not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/folders": {
      "get": {
        "operationId": "getFoldersFolders",
        "tags": [
          "Folders"
        ],
        "summary": "Every folder in the language, as a flat list",
        "description": "Every folder in the language, as a flat list. Permission: content:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          }
        ],
        "responses": {
          "200": {
            "description": "[{ id, parentId, name, slug, urlSegment, depth, path, url, childCount, contentCount, contentTypes }].",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/FolderNode"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a4a",
                      "parentId": null,
                      "name": "Trips",
                      "slug": "trips",
                      "urlSegment": null,
                      "depth": 1,
                      "path": [
                        "…"
                      ],
                      "url": "/trips",
                      "childCount": 4,
                      "contentCount": 4,
                      "contentTypes": [
                        "…"
                      ]
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such language, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Locale not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postFoldersFolders",
        "tags": [
          "Folders"
        ],
        "summary": "Creates a folder",
        "description": "Creates a folder. Permission: content:create.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "slug": {
                    "type": "string"
                  },
                  "parentId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "An id."
                  },
                  "urlSegment": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "The folder's part of the address, when it differs from the slug."
                  },
                  "sortOrder": {
                    "default": 0,
                    "type": "integer"
                  },
                  "contentTypeRestrictions": {
                    "default": [],
                    "maxItems": 100,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "minLength": 1
                    },
                    "description": "Content type keys it accepts. Empty for any."
                  }
                },
                "required": [
                  "name"
                ]
              },
              "example": {
                "name": "Norway",
                "parentId": "6650f1c2a9e4b1d2c3f40a20",
                "contentTypeRestrictions": [
                  "trip"
                ]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The folder.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Folder"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a20",
                    "parentId": null,
                    "name": "Trips",
                    "slug": "trips",
                    "urlSegment": null,
                    "depth": 1,
                    "path": [
                      "…"
                    ],
                    "sortOrder": 1
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or an unknown content type.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:create, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such language, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Locale not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "A sibling uses the slug.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/folders/{folderId}": {
      "delete": {
        "operationId": "deleteFoldersFoldersByFolderId",
        "tags": [
          "Folders"
        ],
        "summary": "Deletes an empty folder and its empty subfolders",
        "description": "Deletes an empty folder and its empty subfolders. Permission: content:delete.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "folderId",
            "in": "path",
            "required": true,
            "description": "The folder's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:delete, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such folder, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Folder not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "It, or a folder in it, still holds content.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchFoldersFoldersByFolderId",
        "tags": [
          "Folders"
        ],
        "summary": "Renames it or changes its rules",
        "description": "Renames it or changes its rules. Permission: content:update.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "folderId",
            "in": "path",
            "required": true,
            "description": "The folder's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "slug": {
                    "type": "string"
                  },
                  "urlSegment": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "sortOrder": {
                    "type": "integer"
                  },
                  "contentTypeRestrictions": {
                    "maxItems": 100,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "minLength": 1
                    }
                  }
                }
              },
              "example": {
                "name": "Norway trips"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The folder.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Folder"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a20",
                    "parentId": null,
                    "name": "Trips",
                    "slug": "trips",
                    "urlSegment": null,
                    "depth": 1,
                    "path": [
                      "…"
                    ],
                    "sortOrder": 1
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or an unknown content type, or a restriction its content doesn't meet.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:update, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such folder, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Folder not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "A sibling uses the slug.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/folders/{folderId}/duplicate": {
      "post": {
        "operationId": "postFoldersFoldersByFolderIdDuplicate",
        "tags": [
          "Folders"
        ],
        "summary": "Copies it with its content",
        "description": "Copies it with its content. Permission: content:copy.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "folderId",
            "in": "path",
            "required": true,
            "description": "The folder's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "includeContent": {
                    "default": true,
                    "type": "boolean"
                  },
                  "includeSeo": {
                    "default": true,
                    "type": "boolean"
                  },
                  "includeMedia": {
                    "default": true,
                    "type": "boolean"
                  }
                }
              },
              "example": {
                "includeContent": true
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "What was copied.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "folders": {
                          "type": "integer"
                        },
                        "content": {
                          "type": "integer"
                        },
                        "target": {
                          "type": "object",
                          "properties": {
                            "environmentId": {
                              "type": "string",
                              "description": "An id."
                            },
                            "regionId": {
                              "type": "string",
                              "description": "An id."
                            },
                            "localeId": {
                              "type": "string",
                              "description": "An id."
                            }
                          },
                          "required": [
                            "environmentId",
                            "regionId",
                            "localeId"
                          ]
                        },
                        "pages": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "sourceId": {
                                "type": "string",
                                "description": "An id."
                              },
                              "id": {
                                "type": "string",
                                "description": "An id."
                              },
                              "name": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "sourceId",
                              "id",
                              "name"
                            ]
                          },
                          "description": "When you copied chosen pages: each copy's new id with the id it was copied from."
                        }
                      },
                      "required": [
                        "folders",
                        "content",
                        "target"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "folders": 1,
                    "content": 1,
                    "target": {
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "regionId": "6650f1c2a9e4b1d2c3f40a17",
                      "localeId": "6650f1c2a9e4b1d2c3f40a18"
                    },
                    "pages": [
                      {
                        "sourceId": "6650f1c2a9e4b1d2c3f40a58",
                        "id": "6650f1c2a9e4b1d2c3f40a40",
                        "name": "Lofoten sea kayaking"
                      }
                    ]
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:copy, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such folder, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Folder not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/folders/{folderId}/move": {
      "post": {
        "operationId": "postFoldersFoldersByFolderIdMove",
        "tags": [
          "Folders"
        ],
        "summary": "Moves it: { \"parentId\": \"…\" }, or null for the top",
        "description": "Moves it: { \"parentId\": \"…\" }, or null for the top. Permission: content:update.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "folderId",
            "in": "path",
            "required": true,
            "description": "The folder's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "parentId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "The new parent folder, or null for the top."
                  }
                },
                "required": [
                  "parentId"
                ]
              },
              "example": {
                "parentId": null
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The folder.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Folder"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a20",
                    "parentId": null,
                    "name": "Trips",
                    "slug": "trips",
                    "urlSegment": null,
                    "depth": 1,
                    "path": [
                      "…"
                    ],
                    "sortOrder": 1
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or into itself or one of its own folders.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:update, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such folder, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Folder not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "A folder with its slug is already there.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/metadata/export": {
      "get": {
        "operationId": "getSEOAndAccessibilitySettingsMetadataExport",
        "tags": [
          "SEO and accessibility settings"
        ],
        "summary": "Every page's title, description and search visibility as CSV",
        "description": "Every page's title, description and search visibility as CSV. Permission: content:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          }
        ],
        "responses": {
          "200": {
            "description": "One row per page: id, name, address, title, description and whether search engines index it.",
            "content": {
              "text/csv": {
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such language, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Locale not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/metadata/import": {
      "post": {
        "operationId": "postSEOAndAccessibilitySettingsMetadataImport",
        "tags": [
          "SEO and accessibility settings"
        ],
        "summary": "Updates them from CSV: { csv, apply }, up to 5,000 rows",
        "description": "Updates them from CSV: { csv, apply }, up to 5,000 rows. Permission: content:update.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "csv": {
                    "type": "string",
                    "description": "The file's text, in the export's columns. Up to 5,000 rows."
                  },
                  "apply": {
                    "type": "boolean",
                    "description": "false (the default) only reports what would happen. true does it."
                  }
                },
                "required": [
                  "csv"
                ]
              },
              "example": {
                "csv": "id,name,url,title,description,index\n6650f1c2a9e4b1d2c3f40a21,Lofoten sea kayaking,/trips/lofoten-sea-kayaking,Sea kayaking in Lofoten,Six days of paddling.,yes",
                "apply": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "What was or would be done.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "applied": {
                          "type": "boolean"
                        },
                        "rows": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "line": {
                                "type": "integer"
                              },
                              "id": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              },
                              "name": {
                                "type": "string"
                              },
                              "url": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              },
                              "outcome": {
                                "type": "string",
                                "enum": [
                                  "change",
                                  "unchanged",
                                  "error"
                                ]
                              },
                              "changes": {
                                "type": "array",
                                "items": {
                                  "type": "object",
                                  "properties": {
                                    "field": {
                                      "type": "string",
                                      "enum": [
                                        "title",
                                        "description",
                                        "index"
                                      ]
                                    },
                                    "from": {
                                      "type": "string"
                                    },
                                    "to": {
                                      "type": "string"
                                    }
                                  },
                                  "required": [
                                    "field",
                                    "from",
                                    "to"
                                  ]
                                }
                              },
                              "message": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              }
                            },
                            "required": [
                              "line",
                              "id",
                              "name",
                              "url",
                              "outcome",
                              "changes",
                              "message"
                            ]
                          }
                        },
                        "counts": {
                          "type": "object",
                          "properties": {
                            "change": {
                              "type": "integer"
                            },
                            "unchanged": {
                              "type": "integer"
                            },
                            "error": {
                              "type": "integer"
                            }
                          },
                          "required": [
                            "change",
                            "unchanged",
                            "error"
                          ]
                        },
                        "failed": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "string"
                              },
                              "message": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "id",
                              "message"
                            ]
                          },
                          "description": "Rows that failed while applying."
                        }
                      },
                      "required": [
                        "applied",
                        "rows",
                        "counts",
                        "failed"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "applied": false,
                    "rows": [
                      {
                        "line": 1,
                        "id": "6650f1c2a9e4b1d2c3f40a40",
                        "name": "Lofoten sea kayaking",
                        "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                        "outcome": "change",
                        "changes": [
                          {
                            "field": "title",
                            "from": "…",
                            "to": "…"
                          }
                        ],
                        "message": null
                      }
                    ],
                    "counts": {
                      "change": 1,
                      "unchanged": 1,
                      "error": 1
                    },
                    "failed": [
                      {
                        "id": "6650f1c2a9e4b1d2c3f40a40",
                        "message": "…"
                      }
                    ]
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or no csv, more than 5,000 rows, or columns it doesn't know.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:update, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such language, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Locale not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/translate": {
      "post": {
        "operationId": "postCopyingAndTranslatingTranslate",
        "tags": [
          "Copying and translating"
        ],
        "summary": "Machine-translates text into this language",
        "description": "Machine-translates text into this language. Permission: content:update.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "text": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 20000,
                    "description": "What to translate into this language, up to 20,000 characters."
                  },
                  "html": {
                    "default": false,
                    "type": "boolean",
                    "description": "The text is rich text, so tags are kept."
                  }
                },
                "required": [
                  "text"
                ]
              },
              "example": {
                "text": "Six days of paddling between the peaks of Lofoten."
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "{ text, to, usage }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "text": {
                          "type": "string",
                          "description": "The translation."
                        },
                        "to": {
                          "type": "string",
                          "description": "The language code, such as nb-NO."
                        },
                        "usage": {
                          "type": "object",
                          "properties": {
                            "used": {
                              "type": "integer",
                              "description": "Characters used this month."
                            },
                            "allowed": {
                              "type": [
                                "integer",
                                "null"
                              ],
                              "description": "The plan's monthly allowance, or null for no limit."
                            }
                          },
                          "required": [
                            "used",
                            "allowed"
                          ]
                        }
                      },
                      "required": [
                        "text",
                        "to",
                        "usage"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "text": "…",
                    "to": "…",
                    "usage": {
                      "used": 1,
                      "allowed": 1
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or machine translation is not set up.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:update, or the plan's monthly characters are used up.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such language, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Locale not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/environments/{environmentId}/regions/{regionId}/locales/{localeId}/xliff": {
      "get": {
        "operationId": "getCopyingAndTranslatingXliff",
        "tags": [
          "Copying and translating"
        ],
        "summary": "A page or a folder's pages as an XLIFF 2.0 file for translation into another language of the region",
        "description": "A page or a folder's pages as an XLIFF 2.0 file for translation into another language of the region. Growth and up. Permission: content:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "contentId",
            "in": "query",
            "required": false,
            "description": "The page to translate. Send this or folderId.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          },
          {
            "name": "folderId",
            "in": "query",
            "required": false,
            "description": "A folder whose pages, with those of its subfolders, to translate. Up to 200 pages.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a22"
          },
          {
            "name": "targetLocaleId",
            "in": "query",
            "required": true,
            "description": "The language to translate into: another language of the same region.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a19"
          }
        ],
        "responses": {
          "200": {
            "description": "XLIFF 2.0 with one file per page (its id) and one unit per text, long text, rich text and SEO title or description, including those inside blocks. Rich text keeps its tags as text.",
            "content": {
              "application/xliff+xml": {
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "400": {
            "description": "No page or folder, more than 200 pages, or a language outside the region.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "The plan is below Growth.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such language, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Locale not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postCopyingAndTranslatingXliff",
        "tags": [
          "Copying and translating"
        ],
        "summary": "Imports a translated XLIFF file as drafts in the other language, making the pages there when they are missing",
        "description": "Imports a translated XLIFF file as drafts in the other language, making the pages there when they are missing. Never publishes. Growth and up. Permission: content:update there.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "regionId",
            "in": "path",
            "required": true,
            "description": "The region's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a17"
          },
          {
            "name": "localeId",
            "in": "path",
            "required": true,
            "description": "The language's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a18"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "xliff": {
                    "type": "string",
                    "description": "The translated file's text, XLIFF 2.0 or 1.2, up to 10 MB."
                  },
                  "targetLocaleId": {
                    "type": "string",
                    "description": "The language the file is translated into."
                  }
                },
                "required": [
                  "xliff",
                  "targetLocaleId"
                ]
              },
              "example": {
                "xliff": "<?xml version=\"1.0\"?><xliff xmlns=\"urn:oasis:names:tc:xliff:document:2.0\" version=\"2.0\" srcLang=\"en-GB\" trgLang=\"nb-NO\">…</xliff>",
                "targetLocaleId": "6650f1c2a9e4b1d2c3f40a19"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "{ pages, created, units, skipped }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "pages": {
                          "type": "integer",
                          "description": "Pages whose draft now holds the translation."
                        },
                        "created": {
                          "type": "integer",
                          "description": "Pages made in the other language because they were missing."
                        },
                        "units": {
                          "type": "integer",
                          "description": "Texts filled in."
                        },
                        "skipped": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "name": {
                                "type": "string"
                              },
                              "reason": {
                                "type": "string",
                                "enum": [
                                  "locked",
                                  "invalid",
                                  "noChanges"
                                ]
                              }
                            },
                            "required": [
                              "name",
                              "reason"
                            ]
                          }
                        }
                      },
                      "required": [
                        "pages",
                        "created",
                        "units",
                        "skipped"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "pages": 1,
                    "created": 1,
                    "units": 1,
                    "skipped": [
                      {
                        "name": "Lofoten sea kayaking",
                        "reason": "locked"
                      }
                    ]
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or not XLIFF, or translated from or into another language.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "The plan is below Growth, or content:update is missing in the other language.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such language, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Locale not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/experiments": {
      "get": {
        "operationId": "getExperimentsExperiments",
        "tags": [
          "Experiments"
        ],
        "summary": "Experiments, up to 200",
        "description": "Experiments, up to 200. contentId, status (active or a status). Permission: experiments:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "contentId",
            "in": "query",
            "required": false,
            "description": "Only experiments on this page.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "status",
            "in": "query",
            "required": false,
            "description": "active (draft, scheduled, running or paused), or one status.",
            "schema": {
              "type": "string",
              "enum": [
                "active",
                "draft",
                "scheduled",
                "running",
                "paused",
                "completed"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List of experiments.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Experiment"
                      },
                      "description": "Up to 200, most recently changed first."
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a4a",
                      "key": "lofoten-hero",
                      "name": "Lofoten hero headline",
                      "hypothesis": null,
                      "status": "running",
                      "scope": "blocks",
                      "targetBlockIds": [
                        "6650f1c2a9e4b1d2c3f40a5d"
                      ],
                      "page": {
                        "id": "6650f1c2a9e4b1d2c3f40a40",
                        "name": "Lofoten sea kayaking",
                        "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                        "published": true
                      },
                      "scopeIds": {
                        "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                        "regionId": "6650f1c2a9e4b1d2c3f40a17",
                        "localeId": "6650f1c2a9e4b1d2c3f40a18"
                      },
                      "variants": [
                        {
                          "key": "lofoten-hero",
                          "name": "Lofoten hero headline",
                          "control": true,
                          "weight": 1,
                          "changed": [
                            "…"
                          ],
                          "edited": false
                        }
                      ],
                      "traffic": 1,
                      "audience": {
                        "devices": [
                          "desktop"
                        ],
                        "visitors": "all",
                        "utm": {
                          "source": null,
                          "medium": null,
                          "campaign": null
                        },
                        "countries": [
                          "…"
                        ]
                      },
                      "goal": {
                        "key": "lofoten",
                        "label": "Kayaking",
                        "goal": {
                          "kind": "click"
                        }
                      },
                      "guardrails": [
                        {
                          "key": "lofoten-hero",
                          "label": "Kayaking",
                          "goal": {
                            "kind": "click"
                          }
                        }
                      ],
                      "mode": "split",
                      "startAt": "2026-11-02T09:30:00.000Z",
                      "endAt": "2026-11-02T09:30:00.000Z",
                      "minDays": 1,
                      "startedAt": "2026-11-02T09:30:00.000Z",
                      "endedAt": "2026-11-02T09:30:00.000Z",
                      "winner": null,
                      "holdWinner": false,
                      "promotedAt": "2026-11-02T09:30:00.000Z",
                      "createdAt": "2026-11-02T09:30:00.000Z",
                      "updatedAt": "2026-11-02T09:30:00.000Z"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks experiments:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postExperimentsExperiments",
        "tags": [
          "Experiments"
        ],
        "summary": "Creates one on a page",
        "description": "Creates one on a page. Permission: experiments:manage and content:update.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "contentId": {
                    "type": "string",
                    "description": "The page to test."
                  },
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 120
                  },
                  "hypothesis": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 500,
                    "default": null
                  },
                  "scope": {
                    "default": "blocks",
                    "type": "string",
                    "enum": [
                      "blocks",
                      "page"
                    ],
                    "description": "blocks tests chosen blocks, page the whole page."
                  },
                  "targetBlockIds": {
                    "default": [],
                    "maxItems": 20,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 40
                    },
                    "description": "The blocks to test, with scope blocks."
                  },
                  "variants": {
                    "default": 1,
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 3,
                    "description": "How many variants besides the original, 1 to 3."
                  },
                  "goal": {
                    "type": "object",
                    "properties": {
                      "label": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 80
                      },
                      "goal": {
                        "oneOf": [
                          {
                            "type": "object",
                            "properties": {
                              "kind": {
                                "type": "string",
                                "const": "click"
                              }
                            },
                            "required": [
                              "kind"
                            ]
                          },
                          {
                            "type": "object",
                            "properties": {
                              "kind": {
                                "type": "string",
                                "const": "form"
                              }
                            },
                            "required": [
                              "kind"
                            ]
                          },
                          {
                            "type": "object",
                            "properties": {
                              "kind": {
                                "type": "string",
                                "const": "engaged"
                              }
                            },
                            "required": [
                              "kind"
                            ]
                          },
                          {
                            "type": "object",
                            "properties": {
                              "kind": {
                                "type": "string",
                                "const": "page"
                              },
                              "path": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 300
                              },
                              "match": {
                                "default": "exact",
                                "type": "string",
                                "enum": [
                                  "exact",
                                  "prefix"
                                ]
                              }
                            },
                            "required": [
                              "kind",
                              "path"
                            ]
                          },
                          {
                            "type": "object",
                            "properties": {
                              "kind": {
                                "type": "string",
                                "const": "event"
                              },
                              "name": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 120
                              }
                            },
                            "required": [
                              "kind",
                              "name"
                            ]
                          },
                          {
                            "type": "object",
                            "properties": {
                              "kind": {
                                "type": "string",
                                "const": "insights"
                              },
                              "goalId": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 64
                              },
                              "name": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 120
                              },
                              "rule": {
                                "oneOf": [
                                  {
                                    "type": "object",
                                    "properties": {
                                      "kind": {
                                        "type": "string",
                                        "const": "page"
                                      },
                                      "path": {
                                        "type": "string",
                                        "minLength": 1,
                                        "maxLength": 300
                                      },
                                      "match": {
                                        "type": "string",
                                        "enum": [
                                          "exact",
                                          "prefix"
                                        ]
                                      }
                                    },
                                    "required": [
                                      "kind",
                                      "path",
                                      "match"
                                    ]
                                  },
                                  {
                                    "type": "object",
                                    "properties": {
                                      "kind": {
                                        "type": "string",
                                        "const": "event"
                                      },
                                      "name": {
                                        "type": "string",
                                        "minLength": 1,
                                        "maxLength": 120
                                      }
                                    },
                                    "required": [
                                      "kind",
                                      "name"
                                    ]
                                  }
                                ]
                              }
                            },
                            "required": [
                              "kind",
                              "goalId",
                              "name",
                              "rule"
                            ]
                          }
                        ]
                      }
                    },
                    "required": [
                      "label",
                      "goal"
                    ],
                    "description": "{ label, goal: { kind } }, with kind click, form, engaged, page (with path and match), event (with name) or insights."
                  },
                  "guardrails": {
                    "default": [],
                    "maxItems": 3,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "label": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 80
                        },
                        "goal": {
                          "oneOf": [
                            {
                              "type": "object",
                              "properties": {
                                "kind": {
                                  "type": "string",
                                  "const": "click"
                                }
                              },
                              "required": [
                                "kind"
                              ]
                            },
                            {
                              "type": "object",
                              "properties": {
                                "kind": {
                                  "type": "string",
                                  "const": "form"
                                }
                              },
                              "required": [
                                "kind"
                              ]
                            },
                            {
                              "type": "object",
                              "properties": {
                                "kind": {
                                  "type": "string",
                                  "const": "engaged"
                                }
                              },
                              "required": [
                                "kind"
                              ]
                            },
                            {
                              "type": "object",
                              "properties": {
                                "kind": {
                                  "type": "string",
                                  "const": "page"
                                },
                                "path": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 300
                                },
                                "match": {
                                  "default": "exact",
                                  "type": "string",
                                  "enum": [
                                    "exact",
                                    "prefix"
                                  ]
                                }
                              },
                              "required": [
                                "kind",
                                "path"
                              ]
                            },
                            {
                              "type": "object",
                              "properties": {
                                "kind": {
                                  "type": "string",
                                  "const": "event"
                                },
                                "name": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 120
                                }
                              },
                              "required": [
                                "kind",
                                "name"
                              ]
                            },
                            {
                              "type": "object",
                              "properties": {
                                "kind": {
                                  "type": "string",
                                  "const": "insights"
                                },
                                "goalId": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 64
                                },
                                "name": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 120
                                },
                                "rule": {
                                  "oneOf": [
                                    {
                                      "type": "object",
                                      "properties": {
                                        "kind": {
                                          "type": "string",
                                          "const": "page"
                                        },
                                        "path": {
                                          "type": "string",
                                          "minLength": 1,
                                          "maxLength": 300
                                        },
                                        "match": {
                                          "type": "string",
                                          "enum": [
                                            "exact",
                                            "prefix"
                                          ]
                                        }
                                      },
                                      "required": [
                                        "kind",
                                        "path",
                                        "match"
                                      ]
                                    },
                                    {
                                      "type": "object",
                                      "properties": {
                                        "kind": {
                                          "type": "string",
                                          "const": "event"
                                        },
                                        "name": {
                                          "type": "string",
                                          "minLength": 1,
                                          "maxLength": 120
                                        }
                                      },
                                      "required": [
                                        "kind",
                                        "name"
                                      ]
                                    }
                                  ]
                                }
                              },
                              "required": [
                                "kind",
                                "goalId",
                                "name",
                                "rule"
                              ]
                            }
                          ]
                        }
                      },
                      "required": [
                        "label",
                        "goal"
                      ]
                    },
                    "description": "Up to 3 more goals that must not get worse."
                  },
                  "audience": {
                    "default": {
                      "devices": [],
                      "visitors": "all",
                      "utm": {
                        "source": null,
                        "medium": null,
                        "campaign": null
                      },
                      "countries": []
                    },
                    "type": "object",
                    "properties": {
                      "devices": {
                        "default": [],
                        "maxItems": 3,
                        "type": "array",
                        "items": {
                          "type": "string",
                          "enum": [
                            "desktop",
                            "mobile",
                            "tablet"
                          ]
                        }
                      },
                      "visitors": {
                        "default": "all",
                        "type": "string",
                        "enum": [
                          "all",
                          "new",
                          "returning"
                        ]
                      },
                      "utm": {
                        "default": {
                          "source": null,
                          "medium": null,
                          "campaign": null
                        },
                        "type": "object",
                        "properties": {
                          "source": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "maxLength": 100,
                            "default": null
                          },
                          "medium": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "maxLength": 100,
                            "default": null
                          },
                          "campaign": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "maxLength": 100,
                            "default": null
                          }
                        }
                      },
                      "countries": {
                        "default": [],
                        "maxItems": 50,
                        "type": "array",
                        "items": {
                          "type": "string",
                          "pattern": "^[A-Z]{2}$"
                        }
                      }
                    }
                  },
                  "traffic": {
                    "default": 100,
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 100,
                    "description": "Per cent of visitors in the experiment."
                  },
                  "mode": {
                    "default": "split",
                    "type": "string",
                    "enum": [
                      "split",
                      "bandit"
                    ],
                    "description": "split shares visitors evenly. bandit sends more to the variant that does best."
                  },
                  "startAt": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "format": "date-time",
                    "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
                    "default": null
                  },
                  "endAt": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "format": "date-time",
                    "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$",
                    "default": null
                  },
                  "minDays": {
                    "default": 7,
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 60
                  }
                },
                "required": [
                  "contentId",
                  "name",
                  "goal"
                ]
              },
              "example": {
                "contentId": "6650f1c2a9e4b1d2c3f40a21",
                "name": "Lofoten hero headline",
                "hypothesis": "Naming the fjords gets more bookings.",
                "targetBlockIds": [
                  "hero-1"
                ],
                "goal": {
                  "label": "Booked a trip",
                  "goal": {
                    "kind": "page",
                    "path": "/booking/thanks"
                  }
                }
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The new item.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Experiment"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a4a",
                    "key": "lofoten-hero",
                    "name": "Lofoten hero headline",
                    "hypothesis": null,
                    "status": "running",
                    "scope": "blocks",
                    "targetBlockIds": [
                      "6650f1c2a9e4b1d2c3f40a5d"
                    ],
                    "page": {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "name": "Lofoten sea kayaking",
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "published": true
                    },
                    "scopeIds": {
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "regionId": "6650f1c2a9e4b1d2c3f40a17",
                      "localeId": "6650f1c2a9e4b1d2c3f40a18"
                    },
                    "variants": [
                      {
                        "key": "lofoten-hero",
                        "name": "Lofoten hero headline",
                        "control": true,
                        "weight": 1,
                        "changed": [
                          "…"
                        ],
                        "edited": false
                      }
                    ],
                    "traffic": 1,
                    "audience": {
                      "devices": [
                        "desktop"
                      ],
                      "visitors": "all",
                      "utm": {
                        "source": null,
                        "medium": null,
                        "campaign": null
                      },
                      "countries": [
                        "…"
                      ]
                    },
                    "goal": {
                      "key": "lofoten",
                      "label": "Kayaking",
                      "goal": {
                        "kind": "click"
                      }
                    },
                    "guardrails": [
                      {
                        "key": "lofoten-hero",
                        "label": "Kayaking",
                        "goal": {
                          "kind": "click"
                        }
                      }
                    ],
                    "mode": "split",
                    "startAt": "2026-11-02T09:30:00.000Z",
                    "endAt": "2026-11-02T09:30:00.000Z",
                    "minDays": 1,
                    "startedAt": "2026-11-02T09:30:00.000Z",
                    "endedAt": "2026-11-02T09:30:00.000Z",
                    "winner": null,
                    "holdWinner": false,
                    "promotedAt": "2026-11-02T09:30:00.000Z",
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or a page without an address, or no blocks chosen with scope blocks.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks experiments:manage or content:update, or the plan has no experiments.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "The page has an experiment running.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/experiments/settings": {
      "put": {
        "operationId": "putExperimentsExperimentsSettings",
        "tags": [
          "Experiments"
        ],
        "summary": "How visitors are assigned: { \"assignment\": \"cookieless\" }, consent or cookie",
        "description": "How visitors are assigned: { \"assignment\": \"cookieless\" }, consent or cookie. Permission: experiments:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "assignment": {
                    "type": "string",
                    "enum": [
                      "cookieless",
                      "consent",
                      "cookie"
                    ],
                    "description": "cookieless (the default) needs no cookie, consent uses a cookie after the visitor agrees, cookie always uses one."
                  }
                },
                "required": [
                  "assignment"
                ]
              },
              "example": {
                "assignment": "consent"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "{ assignment }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "assignment": {
                          "type": "string",
                          "enum": [
                            "cookieless",
                            "consent",
                            "cookie"
                          ]
                        }
                      },
                      "required": [
                        "assignment"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "assignment": "cookieless"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks experiments:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/experiments/{experimentId}": {
      "delete": {
        "operationId": "deleteExperimentsExperimentsByExperimentId",
        "tags": [
          "Experiments"
        ],
        "summary": "Deletes one that is not running",
        "description": "Deletes one that is not running. Permission: experiments:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "experimentId",
            "in": "path",
            "required": true,
            "description": "The experiment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "400": {
            "description": "It's running. Stop it first.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks experiments:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such experiment, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Experiment not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "get": {
        "operationId": "getExperimentsExperimentsByExperimentId",
        "tags": [
          "Experiments"
        ],
        "summary": "One experiment",
        "description": "One experiment. Permission: experiments:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "experimentId",
            "in": "path",
            "required": true,
            "description": "The experiment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "200": {
            "description": "The experiment.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Experiment"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a4a",
                    "key": "lofoten-hero",
                    "name": "Lofoten hero headline",
                    "hypothesis": null,
                    "status": "running",
                    "scope": "blocks",
                    "targetBlockIds": [
                      "6650f1c2a9e4b1d2c3f40a5d"
                    ],
                    "page": {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "name": "Lofoten sea kayaking",
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "published": true
                    },
                    "scopeIds": {
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "regionId": "6650f1c2a9e4b1d2c3f40a17",
                      "localeId": "6650f1c2a9e4b1d2c3f40a18"
                    },
                    "variants": [
                      {
                        "key": "lofoten-hero",
                        "name": "Lofoten hero headline",
                        "control": true,
                        "weight": 1,
                        "changed": [
                          "…"
                        ],
                        "edited": false
                      }
                    ],
                    "traffic": 1,
                    "audience": {
                      "devices": [
                        "desktop"
                      ],
                      "visitors": "all",
                      "utm": {
                        "source": null,
                        "medium": null,
                        "campaign": null
                      },
                      "countries": [
                        "…"
                      ]
                    },
                    "goal": {
                      "key": "lofoten",
                      "label": "Kayaking",
                      "goal": {
                        "kind": "click"
                      }
                    },
                    "guardrails": [
                      {
                        "key": "lofoten-hero",
                        "label": "Kayaking",
                        "goal": {
                          "kind": "click"
                        }
                      }
                    ],
                    "mode": "split",
                    "startAt": "2026-11-02T09:30:00.000Z",
                    "endAt": "2026-11-02T09:30:00.000Z",
                    "minDays": 1,
                    "startedAt": "2026-11-02T09:30:00.000Z",
                    "endedAt": "2026-11-02T09:30:00.000Z",
                    "winner": null,
                    "holdWinner": false,
                    "promotedAt": "2026-11-02T09:30:00.000Z",
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks experiments:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such experiment, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Experiment not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchExperimentsExperimentsByExperimentId",
        "tags": [
          "Experiments"
        ],
        "summary": "Changes it",
        "description": "Changes it. Permission: experiments:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "experimentId",
            "in": "path",
            "required": true,
            "description": "The experiment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 120
                  },
                  "hypothesis": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 500
                  },
                  "variants": {
                    "minItems": 2,
                    "maxItems": 4,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "key": {
                          "type": "string",
                          "pattern": "^[a-d]$"
                        },
                        "name": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 60
                        },
                        "weight": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 100
                        }
                      },
                      "required": [
                        "name",
                        "weight"
                      ]
                    },
                    "description": "Every variant, with the original: { key, name, weight }. Weights add up to 100. Fixed once it has started."
                  },
                  "goal": {
                    "type": "object",
                    "properties": {
                      "label": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 80
                      },
                      "goal": {
                        "oneOf": [
                          {
                            "type": "object",
                            "properties": {
                              "kind": {
                                "type": "string",
                                "const": "click"
                              }
                            },
                            "required": [
                              "kind"
                            ]
                          },
                          {
                            "type": "object",
                            "properties": {
                              "kind": {
                                "type": "string",
                                "const": "form"
                              }
                            },
                            "required": [
                              "kind"
                            ]
                          },
                          {
                            "type": "object",
                            "properties": {
                              "kind": {
                                "type": "string",
                                "const": "engaged"
                              }
                            },
                            "required": [
                              "kind"
                            ]
                          },
                          {
                            "type": "object",
                            "properties": {
                              "kind": {
                                "type": "string",
                                "const": "page"
                              },
                              "path": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 300
                              },
                              "match": {
                                "default": "exact",
                                "type": "string",
                                "enum": [
                                  "exact",
                                  "prefix"
                                ]
                              }
                            },
                            "required": [
                              "kind",
                              "path"
                            ]
                          },
                          {
                            "type": "object",
                            "properties": {
                              "kind": {
                                "type": "string",
                                "const": "event"
                              },
                              "name": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 120
                              }
                            },
                            "required": [
                              "kind",
                              "name"
                            ]
                          },
                          {
                            "type": "object",
                            "properties": {
                              "kind": {
                                "type": "string",
                                "const": "insights"
                              },
                              "goalId": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 64
                              },
                              "name": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 120
                              },
                              "rule": {
                                "oneOf": [
                                  {
                                    "type": "object",
                                    "properties": {
                                      "kind": {
                                        "type": "string",
                                        "const": "page"
                                      },
                                      "path": {
                                        "type": "string",
                                        "minLength": 1,
                                        "maxLength": 300
                                      },
                                      "match": {
                                        "type": "string",
                                        "enum": [
                                          "exact",
                                          "prefix"
                                        ]
                                      }
                                    },
                                    "required": [
                                      "kind",
                                      "path",
                                      "match"
                                    ]
                                  },
                                  {
                                    "type": "object",
                                    "properties": {
                                      "kind": {
                                        "type": "string",
                                        "const": "event"
                                      },
                                      "name": {
                                        "type": "string",
                                        "minLength": 1,
                                        "maxLength": 120
                                      }
                                    },
                                    "required": [
                                      "kind",
                                      "name"
                                    ]
                                  }
                                ]
                              }
                            },
                            "required": [
                              "kind",
                              "goalId",
                              "name",
                              "rule"
                            ]
                          }
                        ]
                      }
                    },
                    "required": [
                      "label",
                      "goal"
                    ]
                  },
                  "guardrails": {
                    "maxItems": 3,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "label": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 80
                        },
                        "goal": {
                          "oneOf": [
                            {
                              "type": "object",
                              "properties": {
                                "kind": {
                                  "type": "string",
                                  "const": "click"
                                }
                              },
                              "required": [
                                "kind"
                              ]
                            },
                            {
                              "type": "object",
                              "properties": {
                                "kind": {
                                  "type": "string",
                                  "const": "form"
                                }
                              },
                              "required": [
                                "kind"
                              ]
                            },
                            {
                              "type": "object",
                              "properties": {
                                "kind": {
                                  "type": "string",
                                  "const": "engaged"
                                }
                              },
                              "required": [
                                "kind"
                              ]
                            },
                            {
                              "type": "object",
                              "properties": {
                                "kind": {
                                  "type": "string",
                                  "const": "page"
                                },
                                "path": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 300
                                },
                                "match": {
                                  "default": "exact",
                                  "type": "string",
                                  "enum": [
                                    "exact",
                                    "prefix"
                                  ]
                                }
                              },
                              "required": [
                                "kind",
                                "path"
                              ]
                            },
                            {
                              "type": "object",
                              "properties": {
                                "kind": {
                                  "type": "string",
                                  "const": "event"
                                },
                                "name": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 120
                                }
                              },
                              "required": [
                                "kind",
                                "name"
                              ]
                            },
                            {
                              "type": "object",
                              "properties": {
                                "kind": {
                                  "type": "string",
                                  "const": "insights"
                                },
                                "goalId": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 64
                                },
                                "name": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 120
                                },
                                "rule": {
                                  "oneOf": [
                                    {
                                      "type": "object",
                                      "properties": {
                                        "kind": {
                                          "type": "string",
                                          "const": "page"
                                        },
                                        "path": {
                                          "type": "string",
                                          "minLength": 1,
                                          "maxLength": 300
                                        },
                                        "match": {
                                          "type": "string",
                                          "enum": [
                                            "exact",
                                            "prefix"
                                          ]
                                        }
                                      },
                                      "required": [
                                        "kind",
                                        "path",
                                        "match"
                                      ]
                                    },
                                    {
                                      "type": "object",
                                      "properties": {
                                        "kind": {
                                          "type": "string",
                                          "const": "event"
                                        },
                                        "name": {
                                          "type": "string",
                                          "minLength": 1,
                                          "maxLength": 120
                                        }
                                      },
                                      "required": [
                                        "kind",
                                        "name"
                                      ]
                                    }
                                  ]
                                }
                              },
                              "required": [
                                "kind",
                                "goalId",
                                "name",
                                "rule"
                              ]
                            }
                          ]
                        }
                      },
                      "required": [
                        "label",
                        "goal"
                      ]
                    }
                  },
                  "audience": {
                    "type": "object",
                    "properties": {
                      "devices": {
                        "default": [],
                        "maxItems": 3,
                        "type": "array",
                        "items": {
                          "type": "string",
                          "enum": [
                            "desktop",
                            "mobile",
                            "tablet"
                          ]
                        }
                      },
                      "visitors": {
                        "default": "all",
                        "type": "string",
                        "enum": [
                          "all",
                          "new",
                          "returning"
                        ]
                      },
                      "utm": {
                        "default": {
                          "source": null,
                          "medium": null,
                          "campaign": null
                        },
                        "type": "object",
                        "properties": {
                          "source": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "maxLength": 100,
                            "default": null
                          },
                          "medium": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "maxLength": 100,
                            "default": null
                          },
                          "campaign": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "maxLength": 100,
                            "default": null
                          }
                        }
                      },
                      "countries": {
                        "default": [],
                        "maxItems": 50,
                        "type": "array",
                        "items": {
                          "type": "string",
                          "pattern": "^[A-Z]{2}$"
                        }
                      }
                    }
                  },
                  "traffic": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 100
                  },
                  "mode": {
                    "type": "string",
                    "enum": [
                      "split",
                      "bandit"
                    ]
                  },
                  "startAt": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "format": "date-time",
                    "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
                  },
                  "endAt": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "format": "date-time",
                    "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"
                  },
                  "minDays": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 60
                  }
                }
              },
              "example": {
                "name": "Lofoten hero headline",
                "traffic": 50
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The experiment.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Experiment"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a4a",
                    "key": "lofoten-hero",
                    "name": "Lofoten hero headline",
                    "hypothesis": null,
                    "status": "running",
                    "scope": "blocks",
                    "targetBlockIds": [
                      "6650f1c2a9e4b1d2c3f40a5d"
                    ],
                    "page": {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "name": "Lofoten sea kayaking",
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "published": true
                    },
                    "scopeIds": {
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "regionId": "6650f1c2a9e4b1d2c3f40a17",
                      "localeId": "6650f1c2a9e4b1d2c3f40a18"
                    },
                    "variants": [
                      {
                        "key": "lofoten-hero",
                        "name": "Lofoten hero headline",
                        "control": true,
                        "weight": 1,
                        "changed": [
                          "…"
                        ],
                        "edited": false
                      }
                    ],
                    "traffic": 1,
                    "audience": {
                      "devices": [
                        "desktop"
                      ],
                      "visitors": "all",
                      "utm": {
                        "source": null,
                        "medium": null,
                        "campaign": null
                      },
                      "countries": [
                        "…"
                      ]
                    },
                    "goal": {
                      "key": "lofoten",
                      "label": "Kayaking",
                      "goal": {
                        "kind": "click"
                      }
                    },
                    "guardrails": [
                      {
                        "key": "lofoten-hero",
                        "label": "Kayaking",
                        "goal": {
                          "kind": "click"
                        }
                      }
                    ],
                    "mode": "split",
                    "startAt": "2026-11-02T09:30:00.000Z",
                    "endAt": "2026-11-02T09:30:00.000Z",
                    "minDays": 1,
                    "startedAt": "2026-11-02T09:30:00.000Z",
                    "endedAt": "2026-11-02T09:30:00.000Z",
                    "winner": null,
                    "holdWinner": false,
                    "promotedAt": "2026-11-02T09:30:00.000Z",
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or it has ended, variants, goals or audience change after it started, or weights that don't add up to 100.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks experiments:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such experiment, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Experiment not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/experiments/{experimentId}/links": {
      "get": {
        "operationId": "getExperimentsExperimentsByExperimentIdLinks",
        "tags": [
          "Experiments"
        ],
        "summary": "Preview links for each variant",
        "description": "Preview links for each variant. Permission: experiments:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "experimentId",
            "in": "path",
            "required": true,
            "description": "The experiment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "200": {
            "description": "[{ key, name, url, frame }].",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "key": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "url": {
                            "type": "string",
                            "description": "A preview link showing the variant."
                          },
                          "frame": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "description": "The same, to show in a frame."
                          }
                        },
                        "required": [
                          "key",
                          "name",
                          "url",
                          "frame"
                        ]
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "key": "lofoten",
                      "name": "Lofoten sea kayaking",
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "frame": null
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks experiments:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such experiment, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Experiment not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/experiments/{experimentId}/pause": {
      "post": {
        "operationId": "postExperimentsExperimentsByExperimentIdPause",
        "tags": [
          "Experiments"
        ],
        "summary": "Pauses it",
        "description": "Pauses it. Permission: experiments:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "experimentId",
            "in": "path",
            "required": true,
            "description": "The experiment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "responses": {
          "200": {
            "description": "The experiment.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Experiment"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a4a",
                    "key": "lofoten-hero",
                    "name": "Lofoten hero headline",
                    "hypothesis": null,
                    "status": "running",
                    "scope": "blocks",
                    "targetBlockIds": [
                      "6650f1c2a9e4b1d2c3f40a5d"
                    ],
                    "page": {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "name": "Lofoten sea kayaking",
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "published": true
                    },
                    "scopeIds": {
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "regionId": "6650f1c2a9e4b1d2c3f40a17",
                      "localeId": "6650f1c2a9e4b1d2c3f40a18"
                    },
                    "variants": [
                      {
                        "key": "lofoten-hero",
                        "name": "Lofoten hero headline",
                        "control": true,
                        "weight": 1,
                        "changed": [
                          "…"
                        ],
                        "edited": false
                      }
                    ],
                    "traffic": 1,
                    "audience": {
                      "devices": [
                        "desktop"
                      ],
                      "visitors": "all",
                      "utm": {
                        "source": null,
                        "medium": null,
                        "campaign": null
                      },
                      "countries": [
                        "…"
                      ]
                    },
                    "goal": {
                      "key": "lofoten",
                      "label": "Kayaking",
                      "goal": {
                        "kind": "click"
                      }
                    },
                    "guardrails": [
                      {
                        "key": "lofoten-hero",
                        "label": "Kayaking",
                        "goal": {
                          "kind": "click"
                        }
                      }
                    ],
                    "mode": "split",
                    "startAt": "2026-11-02T09:30:00.000Z",
                    "endAt": "2026-11-02T09:30:00.000Z",
                    "minDays": 1,
                    "startedAt": "2026-11-02T09:30:00.000Z",
                    "endedAt": "2026-11-02T09:30:00.000Z",
                    "winner": null,
                    "holdWinner": false,
                    "promotedAt": "2026-11-02T09:30:00.000Z",
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The experiment's state doesn't allow this, such as starting one that has ended.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks experiments:manage, or called by an AI agent: a person starts, pauses, resumes and stops experiments.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such experiment, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Experiment not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/experiments/{experimentId}/promote": {
      "post": {
        "operationId": "postExperimentsExperimentsByExperimentIdPromote",
        "tags": [
          "Experiments"
        ],
        "summary": "Puts the winning variant in the page's draft: { \"variant\": \"b\" }",
        "description": "Puts the winning variant in the page's draft: { \"variant\": \"b\" }. Permission: experiments:promote.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "experimentId",
            "in": "path",
            "required": true,
            "description": "The experiment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "variant": {
                    "type": "string",
                    "pattern": "^[a-d]$",
                    "description": "The winning variant's key, a to d. a is the original."
                  }
                },
                "required": [
                  "variant"
                ]
              },
              "example": {
                "variant": "b"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "{ experiment, contentId, requiresApproval, canPublish }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "description": "Promoting doesn't publish: publish the page or send it for review afterwards.",
                      "properties": {
                        "experiment": {
                          "$ref": "#/components/schemas/Experiment"
                        },
                        "contentId": {
                          "type": "string",
                          "description": "An id."
                        },
                        "requiresApproval": {
                          "type": "boolean",
                          "description": "The page needs review before publishing."
                        },
                        "canPublish": {
                          "type": "boolean",
                          "description": "The token's person may publish it now."
                        }
                      },
                      "required": [
                        "experiment",
                        "contentId",
                        "requiresApproval",
                        "canPublish"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "experiment": {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "key": "lofoten",
                      "name": "Lofoten sea kayaking",
                      "hypothesis": null,
                      "status": "draft",
                      "scope": "blocks",
                      "targetBlockIds": [
                        "6650f1c2a9e4b1d2c3f40a5d"
                      ],
                      "page": {
                        "id": "6650f1c2a9e4b1d2c3f40a40",
                        "name": "Lofoten sea kayaking",
                        "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                        "published": true
                      },
                      "scopeIds": {
                        "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                        "regionId": "6650f1c2a9e4b1d2c3f40a17",
                        "localeId": "6650f1c2a9e4b1d2c3f40a18"
                      },
                      "variants": [
                        {
                          "key": "lofoten",
                          "name": "Lofoten sea kayaking",
                          "control": true,
                          "weight": 1,
                          "changed": [
                            "…"
                          ],
                          "edited": false
                        }
                      ],
                      "traffic": 1,
                      "audience": {
                        "devices": [
                          "desktop"
                        ],
                        "visitors": "all",
                        "utm": {
                          "source": null,
                          "medium": null,
                          "campaign": null
                        },
                        "countries": [
                          "…"
                        ]
                      },
                      "goal": {
                        "key": "lofoten",
                        "label": "Kayaking",
                        "goal": {
                          "kind": "click"
                        }
                      },
                      "guardrails": [
                        {
                          "key": "lofoten",
                          "label": "Kayaking",
                          "goal": {
                            "kind": "click"
                          }
                        }
                      ],
                      "mode": "split",
                      "startAt": "2026-11-02T09:30:00.000Z",
                      "endAt": "2026-11-02T09:30:00.000Z",
                      "minDays": 1,
                      "startedAt": "2026-11-02T09:30:00.000Z",
                      "endedAt": "2026-11-02T09:30:00.000Z",
                      "winner": null,
                      "holdWinner": false,
                      "promotedAt": "2026-11-02T09:30:00.000Z",
                      "createdAt": "2026-11-02T09:30:00.000Z",
                      "updatedAt": "2026-11-02T09:30:00.000Z"
                    },
                    "contentId": "6650f1c2a9e4b1d2c3f40a21",
                    "requiresApproval": false,
                    "canPublish": false
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or it hasn't started, or its winner was already promoted.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks experiments:promote, or called by an AI agent.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such experiment, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Experiment not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/experiments/{experimentId}/results": {
      "get": {
        "operationId": "getExperimentsExperimentsByExperimentIdResults",
        "tags": [
          "Experiments"
        ],
        "summary": "Results, with the verdict and each variant",
        "description": "Results, with the verdict and each variant. Permission: experiments:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "experimentId",
            "in": "path",
            "required": true,
            "description": "The experiment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "200": {
            "description": "The results.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "experiment": {
                          "$ref": "#/components/schemas/Experiment"
                        },
                        "days": {
                          "type": "integer"
                        },
                        "visitorsPerDay": {
                          "type": "number"
                        },
                        "verdict": {
                          "type": "string",
                          "enum": [
                            "collecting",
                            "keepGoing",
                            "winner",
                            "noDifference",
                            "controlWins",
                            "mismatch"
                          ]
                        },
                        "leader": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "description": "The variant ahead."
                        },
                        "daysLeft": {
                          "type": [
                            "integer",
                            "null"
                          ]
                        },
                        "slow": {
                          "type": "boolean",
                          "description": "Too few visitors to finish in good time."
                        },
                        "guidance": {
                          "type": "string",
                          "description": "What to do next, in English."
                        },
                        "guidanceWording": {
                          "type": "object",
                          "description": "The guidance as a translation key.",
                          "properties": {
                            "key": {
                              "type": "string"
                            },
                            "values": {
                              "type": "object",
                              "additionalProperties": {}
                            }
                          },
                          "required": [
                            "key",
                            "values"
                          ]
                        },
                        "srm": {
                          "type": [
                            "object",
                            "null"
                          ],
                          "properties": {
                            "pValue": {
                              "type": "number"
                            },
                            "mismatch": {
                              "type": "boolean",
                              "description": "Visitors are not split as set, so the results can't be trusted."
                            }
                          },
                          "required": [
                            "pValue",
                            "mismatch"
                          ]
                        },
                        "arms": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "key": {
                                "type": "string"
                              },
                              "name": {
                                "type": "string"
                              },
                              "control": {
                                "type": "boolean"
                              },
                              "visitors": {
                                "type": "integer"
                              },
                              "conversions": {
                                "type": "integer"
                              },
                              "rate": {
                                "type": "number"
                              },
                              "beatControl": {
                                "type": [
                                  "number",
                                  "null"
                                ],
                                "description": "The chance it beats the original, 0 to 1."
                              },
                              "best": {
                                "type": "number",
                                "description": "The chance it's the best, 0 to 1."
                              },
                              "uplift": {
                                "type": [
                                  "number",
                                  "null"
                                ]
                              },
                              "upliftLow": {
                                "type": [
                                  "number",
                                  "null"
                                ]
                              },
                              "upliftHigh": {
                                "type": [
                                  "number",
                                  "null"
                                ]
                              },
                              "expectedLoss": {
                                "type": "number"
                              }
                            },
                            "required": [
                              "key",
                              "name",
                              "control",
                              "visitors",
                              "conversions",
                              "rate",
                              "beatControl",
                              "best",
                              "uplift",
                              "upliftLow",
                              "upliftHigh",
                              "expectedLoss"
                            ]
                          }
                        },
                        "guardrails": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "key": {
                                "type": "string"
                              },
                              "label": {
                                "type": "string"
                              },
                              "arms": {
                                "type": "array",
                                "items": {
                                  "type": "object",
                                  "properties": {
                                    "key": {
                                      "type": "string"
                                    },
                                    "name": {
                                      "type": "string"
                                    },
                                    "rate": {
                                      "type": "number"
                                    },
                                    "worse": {
                                      "type": "number"
                                    }
                                  },
                                  "required": [
                                    "key",
                                    "name",
                                    "rate",
                                    "worse"
                                  ]
                                }
                              },
                              "harmed": {
                                "type": "array",
                                "items": {
                                  "type": "string"
                                }
                              }
                            },
                            "required": [
                              "key",
                              "label",
                              "arms",
                              "harmed"
                            ]
                          }
                        },
                        "series": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "day": {
                                "type": "string"
                              },
                              "arms": {
                                "type": "object",
                                "additionalProperties": {
                                  "type": "object",
                                  "properties": {
                                    "visitors": {
                                      "type": "integer"
                                    },
                                    "conversions": {
                                      "type": "integer"
                                    },
                                    "rate": {
                                      "type": "number"
                                    }
                                  },
                                  "required": [
                                    "visitors",
                                    "conversions",
                                    "rate"
                                  ]
                                }
                              }
                            },
                            "required": [
                              "day",
                              "arms"
                            ]
                          },
                          "description": "Running totals by day."
                        },
                        "daily": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "day": {
                                "type": "string"
                              },
                              "arms": {
                                "type": "object",
                                "additionalProperties": {
                                  "type": "object",
                                  "properties": {
                                    "visitors": {
                                      "type": "integer"
                                    },
                                    "conversions": {
                                      "type": "integer"
                                    }
                                  },
                                  "required": [
                                    "visitors",
                                    "conversions"
                                  ]
                                }
                              }
                            },
                            "required": [
                              "day",
                              "arms"
                            ]
                          },
                          "description": "Each day's numbers."
                        },
                        "neededPerArm": {
                          "type": [
                            "integer",
                            "null"
                          ],
                          "description": "Visitors each variant needs."
                        },
                        "changes": {
                          "type": "object",
                          "additionalProperties": {
                            "type": "array",
                            "items": {}
                          },
                          "description": "What each variant changes, by variant key."
                        },
                        "assignment": {
                          "type": "string",
                          "enum": [
                            "cookieless",
                            "consent",
                            "cookie"
                          ]
                        },
                        "insights": {
                          "description": "With Insights Orbit: reportUrl and a traffic estimate.",
                          "anyOf": [
                            {},
                            {
                              "type": "null"
                            }
                          ]
                        }
                      },
                      "required": [
                        "experiment",
                        "days",
                        "visitorsPerDay",
                        "verdict",
                        "leader",
                        "daysLeft",
                        "slow",
                        "guidance",
                        "guidanceWording",
                        "srm",
                        "arms",
                        "guardrails",
                        "series",
                        "daily",
                        "neededPerArm",
                        "changes",
                        "assignment"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "experiment": {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "key": "lofoten",
                      "name": "Lofoten sea kayaking",
                      "hypothesis": null,
                      "status": "draft",
                      "scope": "blocks",
                      "targetBlockIds": [
                        "6650f1c2a9e4b1d2c3f40a5d"
                      ],
                      "page": {
                        "id": "6650f1c2a9e4b1d2c3f40a40",
                        "name": "Lofoten sea kayaking",
                        "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                        "published": true
                      },
                      "scopeIds": {
                        "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                        "regionId": "6650f1c2a9e4b1d2c3f40a17",
                        "localeId": "6650f1c2a9e4b1d2c3f40a18"
                      },
                      "variants": [
                        {
                          "key": "lofoten",
                          "name": "Lofoten sea kayaking",
                          "control": true,
                          "weight": 1,
                          "changed": [
                            "…"
                          ],
                          "edited": false
                        }
                      ],
                      "traffic": 1,
                      "audience": {
                        "devices": [
                          "desktop"
                        ],
                        "visitors": "all",
                        "utm": {
                          "source": null,
                          "medium": null,
                          "campaign": null
                        },
                        "countries": [
                          "…"
                        ]
                      },
                      "goal": {
                        "key": "lofoten",
                        "label": "Kayaking",
                        "goal": {
                          "kind": "click"
                        }
                      },
                      "guardrails": [
                        {
                          "key": "lofoten",
                          "label": "Kayaking",
                          "goal": {
                            "kind": "click"
                          }
                        }
                      ],
                      "mode": "split",
                      "startAt": "2026-11-02T09:30:00.000Z",
                      "endAt": "2026-11-02T09:30:00.000Z",
                      "minDays": 1,
                      "startedAt": "2026-11-02T09:30:00.000Z",
                      "endedAt": "2026-11-02T09:30:00.000Z",
                      "winner": null,
                      "holdWinner": false,
                      "promotedAt": "2026-11-02T09:30:00.000Z",
                      "createdAt": "2026-11-02T09:30:00.000Z",
                      "updatedAt": "2026-11-02T09:30:00.000Z"
                    },
                    "days": 1,
                    "visitorsPerDay": 1,
                    "verdict": "collecting",
                    "leader": null,
                    "daysLeft": 1,
                    "slow": false,
                    "guidance": "…",
                    "guidanceWording": {
                      "key": "lofoten",
                      "values": {}
                    },
                    "srm": {
                      "pValue": 1,
                      "mismatch": false
                    },
                    "arms": [
                      {
                        "key": "lofoten",
                        "name": "Lofoten sea kayaking",
                        "control": true,
                        "visitors": 1,
                        "conversions": 12,
                        "rate": 1,
                        "beatControl": 1,
                        "best": 1,
                        "uplift": 1,
                        "upliftLow": 1,
                        "upliftHigh": 1,
                        "expectedLoss": 1
                      }
                    ],
                    "guardrails": [
                      {
                        "key": "lofoten",
                        "label": "Kayaking",
                        "arms": [
                          {
                            "key": "lofoten",
                            "name": "Lofoten sea kayaking",
                            "rate": 1,
                            "worse": 1
                          }
                        ],
                        "harmed": [
                          "…"
                        ]
                      }
                    ],
                    "series": [
                      {
                        "day": "…",
                        "arms": {}
                      }
                    ],
                    "daily": [
                      {
                        "day": "…",
                        "arms": {}
                      }
                    ],
                    "neededPerArm": 1,
                    "changes": {},
                    "assignment": "cookieless",
                    "insights": null
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks experiments:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such experiment, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Experiment not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/experiments/{experimentId}/resume": {
      "post": {
        "operationId": "postExperimentsExperimentsByExperimentIdResume",
        "tags": [
          "Experiments"
        ],
        "summary": "Resumes it",
        "description": "Resumes it. Permission: experiments:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "experimentId",
            "in": "path",
            "required": true,
            "description": "The experiment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "responses": {
          "200": {
            "description": "The experiment.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Experiment"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a4a",
                    "key": "lofoten-hero",
                    "name": "Lofoten hero headline",
                    "hypothesis": null,
                    "status": "running",
                    "scope": "blocks",
                    "targetBlockIds": [
                      "6650f1c2a9e4b1d2c3f40a5d"
                    ],
                    "page": {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "name": "Lofoten sea kayaking",
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "published": true
                    },
                    "scopeIds": {
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "regionId": "6650f1c2a9e4b1d2c3f40a17",
                      "localeId": "6650f1c2a9e4b1d2c3f40a18"
                    },
                    "variants": [
                      {
                        "key": "lofoten-hero",
                        "name": "Lofoten hero headline",
                        "control": true,
                        "weight": 1,
                        "changed": [
                          "…"
                        ],
                        "edited": false
                      }
                    ],
                    "traffic": 1,
                    "audience": {
                      "devices": [
                        "desktop"
                      ],
                      "visitors": "all",
                      "utm": {
                        "source": null,
                        "medium": null,
                        "campaign": null
                      },
                      "countries": [
                        "…"
                      ]
                    },
                    "goal": {
                      "key": "lofoten",
                      "label": "Kayaking",
                      "goal": {
                        "kind": "click"
                      }
                    },
                    "guardrails": [
                      {
                        "key": "lofoten-hero",
                        "label": "Kayaking",
                        "goal": {
                          "kind": "click"
                        }
                      }
                    ],
                    "mode": "split",
                    "startAt": "2026-11-02T09:30:00.000Z",
                    "endAt": "2026-11-02T09:30:00.000Z",
                    "minDays": 1,
                    "startedAt": "2026-11-02T09:30:00.000Z",
                    "endedAt": "2026-11-02T09:30:00.000Z",
                    "winner": null,
                    "holdWinner": false,
                    "promotedAt": "2026-11-02T09:30:00.000Z",
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The experiment's state doesn't allow this, such as starting one that has ended.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks experiments:manage, or called by an AI agent: a person starts, pauses, resumes and stops experiments.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such experiment, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Experiment not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/experiments/{experimentId}/start": {
      "post": {
        "operationId": "postExperimentsExperimentsByExperimentIdStart",
        "tags": [
          "Experiments"
        ],
        "summary": "Starts it, or schedules it when startAt is later",
        "description": "Starts it, or schedules it when startAt is later. Permission: experiments:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "experimentId",
            "in": "path",
            "required": true,
            "description": "The experiment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "responses": {
          "200": {
            "description": "The experiment.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Experiment"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a4a",
                    "key": "lofoten-hero",
                    "name": "Lofoten hero headline",
                    "hypothesis": null,
                    "status": "running",
                    "scope": "blocks",
                    "targetBlockIds": [
                      "6650f1c2a9e4b1d2c3f40a5d"
                    ],
                    "page": {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "name": "Lofoten sea kayaking",
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "published": true
                    },
                    "scopeIds": {
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "regionId": "6650f1c2a9e4b1d2c3f40a17",
                      "localeId": "6650f1c2a9e4b1d2c3f40a18"
                    },
                    "variants": [
                      {
                        "key": "lofoten-hero",
                        "name": "Lofoten hero headline",
                        "control": true,
                        "weight": 1,
                        "changed": [
                          "…"
                        ],
                        "edited": false
                      }
                    ],
                    "traffic": 1,
                    "audience": {
                      "devices": [
                        "desktop"
                      ],
                      "visitors": "all",
                      "utm": {
                        "source": null,
                        "medium": null,
                        "campaign": null
                      },
                      "countries": [
                        "…"
                      ]
                    },
                    "goal": {
                      "key": "lofoten",
                      "label": "Kayaking",
                      "goal": {
                        "kind": "click"
                      }
                    },
                    "guardrails": [
                      {
                        "key": "lofoten-hero",
                        "label": "Kayaking",
                        "goal": {
                          "kind": "click"
                        }
                      }
                    ],
                    "mode": "split",
                    "startAt": "2026-11-02T09:30:00.000Z",
                    "endAt": "2026-11-02T09:30:00.000Z",
                    "minDays": 1,
                    "startedAt": "2026-11-02T09:30:00.000Z",
                    "endedAt": "2026-11-02T09:30:00.000Z",
                    "winner": null,
                    "holdWinner": false,
                    "promotedAt": "2026-11-02T09:30:00.000Z",
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "It isn't a draft or scheduled, or isn't ready, such as a variant with no changes.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks experiments:manage, or called by an AI agent: a person starts, pauses, resumes and stops experiments.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such experiment, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Experiment not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/experiments/{experimentId}/stop": {
      "post": {
        "operationId": "postExperimentsExperimentsByExperimentIdStop",
        "tags": [
          "Experiments"
        ],
        "summary": "Ends it",
        "description": "Ends it. Permission: experiments:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "experimentId",
            "in": "path",
            "required": true,
            "description": "The experiment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "responses": {
          "200": {
            "description": "The experiment.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Experiment"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a4a",
                    "key": "lofoten-hero",
                    "name": "Lofoten hero headline",
                    "hypothesis": null,
                    "status": "running",
                    "scope": "blocks",
                    "targetBlockIds": [
                      "6650f1c2a9e4b1d2c3f40a5d"
                    ],
                    "page": {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "name": "Lofoten sea kayaking",
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "published": true
                    },
                    "scopeIds": {
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "regionId": "6650f1c2a9e4b1d2c3f40a17",
                      "localeId": "6650f1c2a9e4b1d2c3f40a18"
                    },
                    "variants": [
                      {
                        "key": "lofoten-hero",
                        "name": "Lofoten hero headline",
                        "control": true,
                        "weight": 1,
                        "changed": [
                          "…"
                        ],
                        "edited": false
                      }
                    ],
                    "traffic": 1,
                    "audience": {
                      "devices": [
                        "desktop"
                      ],
                      "visitors": "all",
                      "utm": {
                        "source": null,
                        "medium": null,
                        "campaign": null
                      },
                      "countries": [
                        "…"
                      ]
                    },
                    "goal": {
                      "key": "lofoten",
                      "label": "Kayaking",
                      "goal": {
                        "kind": "click"
                      }
                    },
                    "guardrails": [
                      {
                        "key": "lofoten-hero",
                        "label": "Kayaking",
                        "goal": {
                          "kind": "click"
                        }
                      }
                    ],
                    "mode": "split",
                    "startAt": "2026-11-02T09:30:00.000Z",
                    "endAt": "2026-11-02T09:30:00.000Z",
                    "minDays": 1,
                    "startedAt": "2026-11-02T09:30:00.000Z",
                    "endedAt": "2026-11-02T09:30:00.000Z",
                    "winner": null,
                    "holdWinner": false,
                    "promotedAt": "2026-11-02T09:30:00.000Z",
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The experiment's state doesn't allow this, such as starting one that has ended.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks experiments:manage, or called by an AI agent: a person starts, pauses, resumes and stops experiments.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such experiment, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Experiment not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/experiments/{experimentId}/variants/{variantKey}": {
      "get": {
        "operationId": "getExperimentsExperimentsByExperimentIdVariantsByVariantKey",
        "tags": [
          "Experiments"
        ],
        "summary": "A variant's content",
        "description": "A variant's content. Permission: experiments:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "experimentId",
            "in": "path",
            "required": true,
            "description": "The experiment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "variantKey",
            "in": "path",
            "required": true,
            "description": "The variant's key, a to d. a is the original.",
            "schema": {
              "type": "string"
            },
            "example": "b"
          }
        ],
        "responses": {
          "200": {
            "description": "{ experiment, variant, fields, components, locked }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "experiment": {
                          "$ref": "#/components/schemas/Experiment"
                        },
                        "variant": {
                          "type": "object",
                          "properties": {
                            "key": {
                              "type": "string"
                            },
                            "name": {
                              "type": "string"
                            },
                            "control": {
                              "type": "boolean"
                            }
                          },
                          "required": [
                            "key",
                            "name",
                            "control"
                          ]
                        },
                        "fields": {
                          "type": "object",
                          "additionalProperties": {}
                        },
                        "components": {
                          "type": "array",
                          "items": {
                            "$ref": "#/components/schemas/Block"
                          }
                        },
                        "locked": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "description": "Why it can't be changed now, such as a running experiment."
                        }
                      },
                      "required": [
                        "experiment",
                        "variant",
                        "fields",
                        "components",
                        "locked"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "experiment": {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "key": "lofoten",
                      "name": "Lofoten sea kayaking",
                      "hypothesis": null,
                      "status": "draft",
                      "scope": "blocks",
                      "targetBlockIds": [
                        "6650f1c2a9e4b1d2c3f40a5d"
                      ],
                      "page": {
                        "id": "6650f1c2a9e4b1d2c3f40a40",
                        "name": "Lofoten sea kayaking",
                        "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                        "published": true
                      },
                      "scopeIds": {
                        "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                        "regionId": "6650f1c2a9e4b1d2c3f40a17",
                        "localeId": "6650f1c2a9e4b1d2c3f40a18"
                      },
                      "variants": [
                        {
                          "key": "lofoten",
                          "name": "Lofoten sea kayaking",
                          "control": true,
                          "weight": 1,
                          "changed": [
                            "…"
                          ],
                          "edited": false
                        }
                      ],
                      "traffic": 1,
                      "audience": {
                        "devices": [
                          "desktop"
                        ],
                        "visitors": "all",
                        "utm": {
                          "source": null,
                          "medium": null,
                          "campaign": null
                        },
                        "countries": [
                          "…"
                        ]
                      },
                      "goal": {
                        "key": "lofoten",
                        "label": "Kayaking",
                        "goal": {
                          "kind": "click"
                        }
                      },
                      "guardrails": [
                        {
                          "key": "lofoten",
                          "label": "Kayaking",
                          "goal": {
                            "kind": "click"
                          }
                        }
                      ],
                      "mode": "split",
                      "startAt": "2026-11-02T09:30:00.000Z",
                      "endAt": "2026-11-02T09:30:00.000Z",
                      "minDays": 1,
                      "startedAt": "2026-11-02T09:30:00.000Z",
                      "endedAt": "2026-11-02T09:30:00.000Z",
                      "winner": null,
                      "holdWinner": false,
                      "promotedAt": "2026-11-02T09:30:00.000Z",
                      "createdAt": "2026-11-02T09:30:00.000Z",
                      "updatedAt": "2026-11-02T09:30:00.000Z"
                    },
                    "variant": {
                      "key": "lofoten",
                      "name": "Lofoten sea kayaking",
                      "control": true
                    },
                    "fields": {},
                    "components": [
                      {
                        "id": "hero-1",
                        "type": "hero",
                        "schemaVersion": 12,
                        "fields": {
                          "heading": "Paddle the Lofoten fjords"
                        },
                        "children": {},
                        "variant": null
                      }
                    ],
                    "locked": null
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks experiments:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such variant, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Variant not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "put": {
        "operationId": "putExperimentsExperimentsByExperimentIdVariantsByVariantKey",
        "tags": [
          "Experiments"
        ],
        "summary": "Saves a variant's content: { fields, components }",
        "description": "Saves a variant's content: { fields, components }. Permission: experiments:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "experimentId",
            "in": "path",
            "required": true,
            "description": "The experiment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "variantKey",
            "in": "path",
            "required": true,
            "description": "The variant's key, a to d. a is the original.",
            "schema": {
              "type": "string"
            },
            "example": "b"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "fields": {
                    "type": "object",
                    "additionalProperties": {},
                    "description": "The variant's field values."
                  },
                  "components": {
                    "type": "array",
                    "items": {
                      "$ref": "#/components/schemas/Block"
                    },
                    "description": "The variant's blocks."
                  }
                },
                "required": []
              },
              "example": {
                "fields": {
                  "title": "Paddle between Reine and Hamnøy"
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "{ savedAt, changed }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "savedAt": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "changed": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "Blocks or fields that now differ from the original."
                        }
                      },
                      "required": [
                        "savedAt",
                        "changed"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "savedAt": "2026-11-02T09:30:00.000Z",
                    "changed": [
                      "…"
                    ]
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or the variant is locked, is the original, changes blocks outside the experiment, or breaks the content type's rules.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks experiments:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such variant, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Variant not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/experiments/{experimentId}/variants/{variantKey}/reset": {
      "post": {
        "operationId": "postExperimentsExperimentsByExperimentIdVariantsByVariantKeyReset",
        "tags": [
          "Experiments"
        ],
        "summary": "Sets a variant back to the page's draft",
        "description": "Sets a variant back to the page's draft. Permission: experiments:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "experimentId",
            "in": "path",
            "required": true,
            "description": "The experiment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "variantKey",
            "in": "path",
            "required": true,
            "description": "The variant's key, a to d. a is the original.",
            "schema": {
              "type": "string"
            },
            "example": "b"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "responses": {
          "200": {
            "description": "The experiment.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Experiment"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a4a",
                    "key": "lofoten-hero",
                    "name": "Lofoten hero headline",
                    "hypothesis": null,
                    "status": "running",
                    "scope": "blocks",
                    "targetBlockIds": [
                      "6650f1c2a9e4b1d2c3f40a5d"
                    ],
                    "page": {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "name": "Lofoten sea kayaking",
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "published": true
                    },
                    "scopeIds": {
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "regionId": "6650f1c2a9e4b1d2c3f40a17",
                      "localeId": "6650f1c2a9e4b1d2c3f40a18"
                    },
                    "variants": [
                      {
                        "key": "lofoten-hero",
                        "name": "Lofoten hero headline",
                        "control": true,
                        "weight": 1,
                        "changed": [
                          "…"
                        ],
                        "edited": false
                      }
                    ],
                    "traffic": 1,
                    "audience": {
                      "devices": [
                        "desktop"
                      ],
                      "visitors": "all",
                      "utm": {
                        "source": null,
                        "medium": null,
                        "campaign": null
                      },
                      "countries": [
                        "…"
                      ]
                    },
                    "goal": {
                      "key": "lofoten",
                      "label": "Kayaking",
                      "goal": {
                        "kind": "click"
                      }
                    },
                    "guardrails": [
                      {
                        "key": "lofoten-hero",
                        "label": "Kayaking",
                        "goal": {
                          "kind": "click"
                        }
                      }
                    ],
                    "mode": "split",
                    "startAt": "2026-11-02T09:30:00.000Z",
                    "endAt": "2026-11-02T09:30:00.000Z",
                    "minDays": 1,
                    "startedAt": "2026-11-02T09:30:00.000Z",
                    "endedAt": "2026-11-02T09:30:00.000Z",
                    "winner": null,
                    "holdWinner": false,
                    "promotedAt": "2026-11-02T09:30:00.000Z",
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The variant is locked or is the original.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks experiments:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such variant, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Variant not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/export": {
      "get": {
        "operationId": "getSpacesExport",
        "tags": [
          "Spaces"
        ],
        "summary": "Downloads the space as JSON",
        "description": "Downloads the space as JSON. Permission: space:clone.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "An attachment, named after the space and the day.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "format": {
                      "const": "cms-orbit-export"
                    },
                    "version": {
                      "const": 1
                    },
                    "exportedAt": {
                      "type": "string",
                      "format": "date-time"
                    },
                    "space": {
                      "type": "object",
                      "additionalProperties": {},
                      "description": "The space's name, slug and settings."
                    },
                    "collections": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "array",
                        "items": {}
                      },
                      "description": "Every environment, region, language, content type, component, taxonomy, term, folder, page, menu, redirect, domain, media folder and file."
                    }
                  },
                  "required": [
                    "format",
                    "version",
                    "exportedAt",
                    "space",
                    "collections"
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:clone.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/flags": {
      "get": {
        "operationId": "getFeatureFlagsFlags",
        "tags": [
          "Feature flags"
        ],
        "summary": "Every flag in every environment",
        "description": "Every flag in every environment. Permission: environment:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "{ names, environments: [{ id, name, flags }] }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "names": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "Every flag's name."
                        },
                        "environments": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "string",
                                "description": "An id."
                              },
                              "name": {
                                "type": "string"
                              },
                              "flags": {
                                "type": "object",
                                "additionalProperties": {
                                  "type": "boolean"
                                },
                                "description": "Whether each flag is on here."
                              }
                            },
                            "required": [
                              "id",
                              "name",
                              "flags"
                            ]
                          }
                        }
                      },
                      "required": [
                        "names",
                        "environments"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "names": [
                      "Lofoten sea kayaking"
                    ],
                    "environments": [
                      {
                        "id": "6650f1c2a9e4b1d2c3f40a40",
                        "name": "Lofoten sea kayaking",
                        "flags": {}
                      }
                    ]
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks environment:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postFeatureFlagsFlags",
        "tags": [
          "Feature flags"
        ],
        "summary": "Adds a flag, off everywhere: { \"name\": \"winter-sale\" }",
        "description": "Adds a flag, off everywhere: { \"name\": \"winter-sale\" }. Permission: environment:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "description": "Lowercase letters, digits and hyphens, up to 48 characters, such as winter-sale."
                  }
                },
                "required": [
                  "name"
                ]
              },
              "example": {
                "name": "winter-sale"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The table.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "names": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "Every flag's name."
                        },
                        "environments": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "string",
                                "description": "An id."
                              },
                              "name": {
                                "type": "string"
                              },
                              "flags": {
                                "type": "object",
                                "additionalProperties": {
                                  "type": "boolean"
                                },
                                "description": "Whether each flag is on here."
                              }
                            },
                            "required": [
                              "id",
                              "name",
                              "flags"
                            ]
                          }
                        }
                      },
                      "required": [
                        "names",
                        "environments"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "names": [
                      "Lofoten sea kayaking"
                    ],
                    "environments": [
                      {
                        "id": "6650f1c2a9e4b1d2c3f40a40",
                        "name": "Lofoten sea kayaking",
                        "flags": {}
                      }
                    ]
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or not a valid name, or the name is used.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks environment:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/flags/{name}": {
      "delete": {
        "operationId": "deleteFeatureFlagsFlagsByName",
        "tags": [
          "Feature flags"
        ],
        "summary": "Removes it",
        "description": "Removes it. Permission: environment:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "name",
            "in": "path",
            "required": true,
            "description": "The flag's name, such as winter-sale.",
            "schema": {
              "type": "string"
            },
            "example": "winter-sale"
          }
        ],
        "responses": {
          "200": {
            "description": "The table.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "names": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "Every flag's name."
                        },
                        "environments": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "string",
                                "description": "An id."
                              },
                              "name": {
                                "type": "string"
                              },
                              "flags": {
                                "type": "object",
                                "additionalProperties": {
                                  "type": "boolean"
                                },
                                "description": "Whether each flag is on here."
                              }
                            },
                            "required": [
                              "id",
                              "name",
                              "flags"
                            ]
                          }
                        }
                      },
                      "required": [
                        "names",
                        "environments"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "names": [
                      "Lofoten sea kayaking"
                    ],
                    "environments": [
                      {
                        "id": "6650f1c2a9e4b1d2c3f40a40",
                        "name": "Lofoten sea kayaking",
                        "flags": {}
                      }
                    ]
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks environment:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such flag, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Flag not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/flags/{name}/environments/{environmentId}": {
      "put": {
        "operationId": "putFeatureFlagsFlagsByNameEnvironmentsByEnvironmentId",
        "tags": [
          "Feature flags"
        ],
        "summary": "Turns it on or off: { \"on\": true }",
        "description": "Turns it on or off: { \"on\": true }. Permission: environment:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "name",
            "in": "path",
            "required": true,
            "description": "The flag's name, such as winter-sale.",
            "schema": {
              "type": "string"
            },
            "example": "winter-sale"
          },
          {
            "name": "environmentId",
            "in": "path",
            "required": true,
            "description": "The environment's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "on": {
                    "type": "boolean",
                    "description": "Anything but true turns it off."
                  }
                },
                "required": [
                  "on"
                ]
              },
              "example": {
                "on": true
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The table.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "names": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "Every flag's name."
                        },
                        "environments": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "string",
                                "description": "An id."
                              },
                              "name": {
                                "type": "string"
                              },
                              "flags": {
                                "type": "object",
                                "additionalProperties": {
                                  "type": "boolean"
                                },
                                "description": "Whether each flag is on here."
                              }
                            },
                            "required": [
                              "id",
                              "name",
                              "flags"
                            ]
                          }
                        }
                      },
                      "required": [
                        "names",
                        "environments"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "names": [
                      "Lofoten sea kayaking"
                    ],
                    "environments": [
                      {
                        "id": "6650f1c2a9e4b1d2c3f40a40",
                        "name": "Lofoten sea kayaking",
                        "flags": {}
                      }
                    ]
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks environment:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such environment, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Environment not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/import": {
      "post": {
        "operationId": "postSpacesImport",
        "tags": [
          "Spaces"
        ],
        "summary": "Adds content types, components and taxonomies from an export",
        "description": "Adds content types, components and taxonomies from an export. Permission: schema:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "file": {
                    "description": "The export, as GET {space}/export answers it."
                  },
                  "apply": {
                    "type": "boolean",
                    "description": "false (the default) only reports what would happen. true does it."
                  }
                },
                "required": [
                  "file"
                ]
              },
              "example": {
                "file": {
                  "format": "cms-orbit-export",
                  "version": 1
                },
                "apply": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "What was or would be added.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "applied": {
                          "type": "boolean"
                        },
                        "items": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "kind": {
                                "type": "string",
                                "enum": [
                                  "contentType",
                                  "component",
                                  "taxonomy"
                                ]
                              },
                              "key": {
                                "type": "string"
                              },
                              "name": {
                                "type": "string"
                              },
                              "outcome": {
                                "type": "string",
                                "enum": [
                                  "add",
                                  "exists",
                                  "error"
                                ]
                              },
                              "message": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              }
                            },
                            "required": [
                              "kind",
                              "key",
                              "name",
                              "outcome",
                              "message"
                            ]
                          },
                          "description": "Items that exist are skipped, never overwritten."
                        }
                      },
                      "required": [
                        "applied",
                        "items"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "applied": false,
                    "items": [
                      {
                        "kind": "contentType",
                        "key": "lofoten",
                        "name": "Lofoten sea kayaking",
                        "outcome": "add",
                        "message": null
                      }
                    ]
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or file isn't a CMS Orbit export.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/import/content": {
      "post": {
        "operationId": "postSpacesImportContent",
        "tags": [
          "Spaces"
        ],
        "summary": "Adds pages from an export",
        "description": "Adds pages from an export. Permission: space:clone.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "file": {
                    "description": "The export, as GET {space}/export answers it."
                  },
                  "apply": {
                    "type": "boolean",
                    "description": "false (the default) only reports what would happen. true does it."
                  }
                },
                "required": [
                  "file"
                ]
              },
              "example": {
                "file": {
                  "format": "cms-orbit-export",
                  "version": 1
                },
                "apply": true
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "What was or would be added.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "applied": {
                          "type": "boolean"
                        },
                        "items": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "name": {
                                "type": "string"
                              },
                              "url": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              },
                              "where": {
                                "type": "string",
                                "description": "The environment, region and language it goes to."
                              },
                              "outcome": {
                                "type": "string",
                                "enum": [
                                  "add",
                                  "exists",
                                  "error"
                                ]
                              },
                              "message": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              }
                            },
                            "required": [
                              "name",
                              "url",
                              "where",
                              "outcome",
                              "message"
                            ]
                          },
                          "description": "Pages are matched by environment key, region key and language code."
                        }
                      },
                      "required": [
                        "applied",
                        "items"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "applied": false,
                    "items": [
                      {
                        "name": "Lofoten sea kayaking",
                        "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                        "where": "…",
                        "outcome": "add",
                        "message": null
                      }
                    ]
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or file isn't a CMS Orbit export.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:clone, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/insights": {
      "delete": {
        "operationId": "deleteConnectedSatellitesInsights",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Removes the insights Orbit site: { site } to link one, or { create: { name, domains } }",
        "description": "Removes the insights Orbit site: { site } to link one, or { create: { name, domains } }. Permission: space:read; space:update to change.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "The connection.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "null",
                      "description": "Always null."
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": null
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:read; space:update to change, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "get": {
        "operationId": "getConnectedSatellitesInsights",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Reads the insights Orbit site: { site } to link one, or { create: { name, domains } }",
        "description": "Reads the insights Orbit site: { site } to link one, or { create: { name, domains } }. Permission: space:read; space:update to change.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "The connection.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "anyOf": [
                        {
                          "$ref": "#/components/schemas/InsightsConnection"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "linked": {
                      "site": "…",
                      "name": "Lofoten sea kayaking"
                    },
                    "sites": [
                      {
                        "site": "…",
                        "name": "Lofoten sea kayaking",
                        "domains": [
                          "…"
                        ],
                        "spaces": [
                          {
                            "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                            "name": "Lofoten sea kayaking"
                          }
                        ]
                      }
                    ],
                    "canManage": true,
                    "canEdit": true,
                    "suggestion": {
                      "name": "Lofoten sea kayaking",
                      "domains": [
                        "…"
                      ]
                    },
                    "reportUrl": null,
                    "error": null
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:read; space:update to change.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "put": {
        "operationId": "putConnectedSatellitesInsights",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Changes the insights Orbit site: { site } to link one, or { create: { name, domains } }",
        "description": "Changes the insights Orbit site: { site } to link one, or { create: { name, domains } }. Permission: space:read; space:update to change.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "oneOf": [
                  {
                    "type": "object",
                    "properties": {
                      "site": {
                        "type": "string",
                        "description": "An Insights Orbit site key to link."
                      }
                    },
                    "required": [
                      "site"
                    ]
                  },
                  {
                    "type": "object",
                    "description": "Creates a site and links it.",
                    "properties": {
                      "create": {
                        "type": "object",
                        "properties": {
                          "name": {
                            "type": "string"
                          },
                          "domains": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            },
                            "description": "1 to 20 domains, such as northwilds.com."
                          }
                        },
                        "required": [
                          "name",
                          "domains"
                        ]
                      }
                    },
                    "required": [
                      "create"
                    ]
                  }
                ]
              },
              "example": {
                "create": {
                  "name": "Northwilds",
                  "domains": [
                    "northwilds.com"
                  ]
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The connection.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "anyOf": [
                        {
                          "$ref": "#/components/schemas/InsightsConnection"
                        },
                        {
                          "type": "null"
                        }
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "linked": {
                      "site": "…",
                      "name": "Lofoten sea kayaking"
                    },
                    "sites": [
                      {
                        "site": "…",
                        "name": "Lofoten sea kayaking",
                        "domains": [
                          "…"
                        ],
                        "spaces": [
                          {
                            "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                            "name": "Lofoten sea kayaking"
                          }
                        ]
                      }
                    ],
                    "canManage": true,
                    "canEdit": true,
                    "suggestion": {
                      "name": "Lofoten sea kayaking",
                      "domains": [
                        "…"
                      ]
                    },
                    "reportUrl": null,
                    "error": null
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or insights Orbit is not available to the organisation, or the body is neither { site } nor { create }.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:read; space:update to change, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/logo": {
      "delete": {
        "operationId": "deleteSpacesLogo",
        "tags": [
          "Spaces"
        ],
        "summary": "Removes the logo",
        "description": "Removes the logo. Permission: space:update.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "The space.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Space"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a02",
                    "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                    "name": "Northwilds website",
                    "slug": "northwilds-website",
                    "description": "Trips and gear for the far north.",
                    "logoUrl": null,
                    "defaultEnvironmentId": null,
                    "settings": {
                      "autoRedirectOnUrlChange": true,
                      "localeFallbackEnabled": true,
                      "machineTranslation": true,
                      "previewUrl": null,
                      "previewUrls": [
                        {
                          "name": "Lofoten sea kayaking",
                          "url": "https://northwilds.com/trips/lofoten-sea-kayaking"
                        }
                      ],
                      "previewDevices": [
                        {
                          "name": "Lofoten sea kayaking",
                          "width": 1
                        }
                      ],
                      "timezone": "Europe/Oslo",
                      "regionFallback": null,
                      "trashRetentionDays": 30,
                      "seo": {
                        "xDefaultRegion": null,
                        "organisationName": null,
                        "socialProfiles": [
                          "…"
                        ],
                        "robotsTxt": null,
                        "titleTemplate": null,
                        "defaultDescription": null,
                        "defaultImage": null,
                        "twitterHandle": null,
                        "verification": {
                          "google": null,
                          "bing": null
                        },
                        "websitePaths": [
                          "…"
                        ],
                        "indexNow": false
                      },
                      "indexNowKey": "…",
                      "accessibility": {
                        "publish": "off",
                        "tags": [
                          "…"
                        ]
                      },
                      "insights": {
                        "site": "…",
                        "name": "Lofoten sea kayaking"
                      },
                      "workflowStages": [
                        {
                          "id": "6650f1c2a9e4b1d2c3f40a40",
                          "name": "Lofoten sea kayaking",
                          "colour": "…"
                        }
                      ],
                      "travel": {
                        "brandId": "6650f1c2a9e4b1d2c3f40a57",
                        "bookingSlug": "…",
                        "brandName": "Northwilds",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "commerce": {
                        "storeSlug": "…",
                        "brandName": "Northwilds",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "booking": {
                        "locationId": "6650f1c2a9e4b1d2c3f40a5a",
                        "slug": "lofoten-sea-kayaking",
                        "locationName": "…",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "presenceOrbit": {
                        "siteSlug": "…",
                        "brandName": "Northwilds",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "careers": {
                        "siteSlug": "…",
                        "name": "Lofoten sea kayaking",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "experiments": {
                        "assignment": "cookieless"
                      }
                    },
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:update, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postSpacesLogo",
        "tags": [
          "Spaces"
        ],
        "summary": "Uploads the logo: multipart/form-data with file, PNG, JPEG or WebP, up to 2 MB",
        "description": "Uploads the logo: multipart/form-data with file, PNG, JPEG or WebP, up to 2 MB. SVG is refused. Permission: space:update.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "multipart/form-data": {
              "schema": {
                "type": "object",
                "properties": {
                  "file": {
                    "type": "string",
                    "description": "A PNG, JPEG or WebP image, up to 2 MB. SVG is refused.",
                    "format": "binary"
                  }
                },
                "required": [
                  "file"
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The space.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Space"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a02",
                    "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                    "name": "Northwilds website",
                    "slug": "northwilds-website",
                    "description": "Trips and gear for the far north.",
                    "logoUrl": null,
                    "defaultEnvironmentId": null,
                    "settings": {
                      "autoRedirectOnUrlChange": true,
                      "localeFallbackEnabled": true,
                      "machineTranslation": true,
                      "previewUrl": null,
                      "previewUrls": [
                        {
                          "name": "Lofoten sea kayaking",
                          "url": "https://northwilds.com/trips/lofoten-sea-kayaking"
                        }
                      ],
                      "previewDevices": [
                        {
                          "name": "Lofoten sea kayaking",
                          "width": 1
                        }
                      ],
                      "timezone": "Europe/Oslo",
                      "regionFallback": null,
                      "trashRetentionDays": 30,
                      "seo": {
                        "xDefaultRegion": null,
                        "organisationName": null,
                        "socialProfiles": [
                          "…"
                        ],
                        "robotsTxt": null,
                        "titleTemplate": null,
                        "defaultDescription": null,
                        "defaultImage": null,
                        "twitterHandle": null,
                        "verification": {
                          "google": null,
                          "bing": null
                        },
                        "websitePaths": [
                          "…"
                        ],
                        "indexNow": false
                      },
                      "indexNowKey": "…",
                      "accessibility": {
                        "publish": "off",
                        "tags": [
                          "…"
                        ]
                      },
                      "insights": {
                        "site": "…",
                        "name": "Lofoten sea kayaking"
                      },
                      "workflowStages": [
                        {
                          "id": "6650f1c2a9e4b1d2c3f40a40",
                          "name": "Lofoten sea kayaking",
                          "colour": "…"
                        }
                      ],
                      "travel": {
                        "brandId": "6650f1c2a9e4b1d2c3f40a57",
                        "bookingSlug": "…",
                        "brandName": "Northwilds",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "commerce": {
                        "storeSlug": "…",
                        "brandName": "Northwilds",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "booking": {
                        "locationId": "6650f1c2a9e4b1d2c3f40a5a",
                        "slug": "lofoten-sea-kayaking",
                        "locationName": "…",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "presenceOrbit": {
                        "siteSlug": "…",
                        "brandName": "Northwilds",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "careers": {
                        "siteSlug": "…",
                        "name": "Lofoten sea kayaking",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "experiments": {
                        "assignment": "cookieless"
                      }
                    },
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Not multipart/form-data, no file, a type other than PNG, JPEG or WebP, or over 2 MB.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Send the request as multipart/form-data"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:update, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/media": {
      "get": {
        "operationId": "getMediaMedia",
        "tags": [
          "Media"
        ],
        "summary": "The whole library, newest first",
        "description": "The whole library, newest first. Permission: media:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "List of files.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Media"
                      },
                      "description": "Newest first."
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a45",
                      "filename": "lofoten-kayaks.webp",
                      "url": "https://media.northwilds.com/lofoten-kayaks.webp",
                      "mimeType": "image/webp",
                      "category": "image",
                      "size": 4,
                      "checksum": null,
                      "width": 1,
                      "height": 1,
                      "folderId": "6650f1c2a9e4b1d2c3f40a20",
                      "title": {},
                      "alt": {
                        "en-GB": "Kayaks on a calm fjord"
                      },
                      "caption": {},
                      "tags": [
                        "…"
                      ],
                      "createdAt": "2026-11-02T09:30:00.000Z",
                      "original": {
                        "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                        "width": 1,
                        "height": 1
                      },
                      "crop": {
                        "x": 1,
                        "y": 1,
                        "width": 1,
                        "height": 1,
                        "rotate": 0,
                        "aspect": null
                      },
                      "edit": {
                        "version": 1,
                        "steps": [
                          null
                        ]
                      },
                      "focalPoint": {
                        "x": 1,
                        "y": 1
                      },
                      "consent": {
                        "reference": null,
                        "status": "pending",
                        "restrictions": null
                      },
                      "subtitles": {},
                      "source": {
                        "provider": "cloudinary",
                        "externalId": "6650f1c2a9e4b1d2c3f40a5a"
                      }
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks media:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postMediaMedia",
        "tags": [
          "Media"
        ],
        "summary": "Uploads a file",
        "description": "Uploads a file. Permission: media:upload.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "multipart/form-data": {
              "schema": {
                "type": "object",
                "properties": {
                  "file": {
                    "type": "string",
                    "description": "JPEG, PNG, WebP, AVIF, GIF, SVG, PDF, MP4 or WebM, up to 25 MB. JPEG and PNG are stored as WebP.",
                    "format": "binary"
                  },
                  "folderId": {
                    "type": "string",
                    "description": "A media folder's id."
                  },
                  "crop": {
                    "type": "string",
                    "description": "A crop to apply at once, as JSON text: { \"area\": { \"x\", \"y\", \"width\", \"height\", \"rotate\" }, \"aspect\": \"16:9\" }."
                  },
                  "keepOriginal": {
                    "type": "string",
                    "description": "true keeps the uncropped file as well.",
                    "enum": [
                      "true",
                      "false"
                    ]
                  }
                },
                "required": [
                  "file"
                ]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The file.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Media",
                      "description": "The file. A file the library already has answers with the existing one."
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a45",
                    "filename": "lofoten-kayaks.webp",
                    "url": "https://media.northwilds.com/lofoten-kayaks.webp",
                    "mimeType": "image/webp",
                    "category": "image",
                    "size": 4,
                    "checksum": null,
                    "width": 1,
                    "height": 1,
                    "folderId": "6650f1c2a9e4b1d2c3f40a20",
                    "title": {},
                    "alt": {
                      "en-GB": "Kayaks on a calm fjord"
                    },
                    "caption": {},
                    "tags": [
                      "…"
                    ],
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "original": {
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "width": 1,
                      "height": 1
                    },
                    "crop": {
                      "x": 1,
                      "y": 1,
                      "width": 1,
                      "height": 1,
                      "rotate": 0,
                      "aspect": null
                    },
                    "edit": {
                      "version": 1,
                      "steps": [
                        null
                      ]
                    },
                    "focalPoint": {
                      "x": 1,
                      "y": 1
                    },
                    "consent": {
                      "reference": null,
                      "status": "pending",
                      "restrictions": null
                    },
                    "subtitles": {},
                    "source": {
                      "provider": "cloudinary",
                      "externalId": "6650f1c2a9e4b1d2c3f40a5a"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Not multipart/form-data, no file, a type it doesn't take, over 25 MB, or crop that isn't JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Send the request as multipart/form-data"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks media:upload, or the plan's storage is full.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "crop doesn't match its schema.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/media/folders": {
      "get": {
        "operationId": "getMediaMediaFolders",
        "tags": [
          "Media"
        ],
        "summary": "Media folders",
        "description": "Media folders. Permission: media:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "[{ id, name, parentId }].",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/MediaFolder"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a4b",
                      "name": "Lofoten 2026",
                      "parentId": null
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks media:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postMediaMediaFolders",
        "tags": [
          "Media"
        ],
        "summary": "Adds one: name, parentId",
        "description": "Adds one: name, parentId. Permission: media:upload.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "parentId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "An id."
                  }
                },
                "required": [
                  "name"
                ]
              },
              "example": {
                "name": "Lofoten 2026"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The new item.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/MediaFolder"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a4b",
                    "name": "Lofoten 2026",
                    "parentId": null
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body is empty or isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks media:upload, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/media/folders/{folderId}": {
      "delete": {
        "operationId": "deleteMediaMediaFoldersByFolderId",
        "tags": [
          "Media"
        ],
        "summary": "Deletes an empty one",
        "description": "Deletes an empty one. Permission: media:delete.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "folderId",
            "in": "path",
            "required": true,
            "description": "The folder's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks media:delete, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such folder, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Folder not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "It still holds files or folders.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchMediaMediaFoldersByFolderId",
        "tags": [
          "Media"
        ],
        "summary": "Renames one",
        "description": "Renames one. Permission: media:upload.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "folderId",
            "in": "path",
            "required": true,
            "description": "The folder's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  }
                }
              },
              "example": {
                "name": "Lofoten summer 2026"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The folder.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/MediaFolder"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a4b",
                    "name": "Lofoten 2026",
                    "parentId": null
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body is empty or isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks media:upload, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such folder, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Folder not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/media/trash": {
      "delete": {
        "operationId": "deleteMediaMediaTrash",
        "tags": [
          "Media"
        ],
        "summary": "Empties the bin",
        "description": "Empties the bin. Permission: content:purge.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "{ erased }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "erased": {
                          "type": "integer",
                          "description": "How many files were erased."
                        }
                      },
                      "required": [
                        "erased"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "erased": 1
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:purge, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "get": {
        "operationId": "getMediaMediaTrash",
        "tags": [
          "Media"
        ],
        "summary": "Files in the bin",
        "description": "Files in the bin. Permission: media:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "List.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string",
                            "description": "An id."
                          },
                          "filename": {
                            "type": "string"
                          },
                          "url": {
                            "type": "string"
                          },
                          "mimeType": {
                            "type": "string"
                          },
                          "size": {
                            "type": "integer"
                          },
                          "deletedAt": {
                            "type": "string",
                            "format": "date-time"
                          }
                        },
                        "required": [
                          "id",
                          "filename",
                          "url",
                          "mimeType",
                          "size",
                          "deletedAt"
                        ]
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "filename": "…",
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "mimeType": "…",
                      "size": 4,
                      "deletedAt": "2026-11-02T09:30:00.000Z"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks media:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/media/trash/{mediaId}": {
      "delete": {
        "operationId": "deleteMediaMediaTrashByMediaId",
        "tags": [
          "Media"
        ],
        "summary": "Erases one file for good",
        "description": "Erases one file for good. Permission: content:purge.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "mediaId",
            "in": "path",
            "required": true,
            "description": "The media's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:purge, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such media, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Trash not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postMediaMediaTrashByMediaId",
        "tags": [
          "Media"
        ],
        "summary": "Takes a file out of the bin",
        "description": "Takes a file out of the bin. Permission: media:delete.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "mediaId",
            "in": "path",
            "required": true,
            "description": "The media's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks media:delete, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such media, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Trash not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/media/{mediaId}": {
      "delete": {
        "operationId": "deleteMediaMediaByMediaId",
        "tags": [
          "Media"
        ],
        "summary": "Moves it to the bin",
        "description": "Moves it to the bin. Permission: media:delete.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "mediaId",
            "in": "path",
            "required": true,
            "description": "The media's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks media:delete, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such media, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Media not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchMediaMediaByMediaId",
        "tags": [
          "Media"
        ],
        "summary": "Changes its name, folder, texts, tags, focal point or consent",
        "description": "Changes its name, folder, texts, tags, focal point or consent. Permission: media:upload.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "mediaId",
            "in": "path",
            "required": true,
            "description": "The media's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "filename": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "folderId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "An id."
                  },
                  "title": {
                    "type": "object",
                    "additionalProperties": {
                      "type": "string",
                      "maxLength": 500
                    },
                    "description": "By language code."
                  },
                  "alt": {
                    "type": "object",
                    "additionalProperties": {
                      "type": "string",
                      "maxLength": 500
                    },
                    "description": "By language code, such as { \"en-GB\": \"Kayaks on a calm fjord\" }. Up to 500 characters each."
                  },
                  "caption": {
                    "type": "object",
                    "additionalProperties": {
                      "type": "string",
                      "maxLength": 500
                    },
                    "description": "By language code."
                  },
                  "tags": {
                    "maxItems": 50,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "maxLength": 40
                    }
                  },
                  "focalPoint": {
                    "type": [
                      "object",
                      "null"
                    ],
                    "properties": {
                      "x": {
                        "type": "number",
                        "minimum": 0,
                        "maximum": 1
                      },
                      "y": {
                        "type": "number",
                        "minimum": 0,
                        "maximum": 1
                      }
                    },
                    "required": [
                      "x",
                      "y"
                    ],
                    "description": "From 0 to 1, x from the left and y from the top."
                  },
                  "consent": {
                    "type": [
                      "object",
                      "null"
                    ],
                    "properties": {
                      "reference": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 120,
                        "default": null
                      },
                      "status": {
                        "default": "pending",
                        "type": "string",
                        "enum": [
                          "pending",
                          "approved",
                          "withdrawn"
                        ]
                      },
                      "restrictions": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 500,
                        "default": null
                      }
                    },
                    "description": "For photos of people."
                  }
                }
              },
              "example": {
                "alt": {
                  "en-GB": "Kayaks on a calm fjord below Reinebringen"
                },
                "tags": [
                  "lofoten",
                  "kayak"
                ],
                "focalPoint": {
                  "x": 0.4,
                  "y": 0.6
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The file.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Media"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a45",
                    "filename": "lofoten-kayaks.webp",
                    "url": "https://media.northwilds.com/lofoten-kayaks.webp",
                    "mimeType": "image/webp",
                    "category": "image",
                    "size": 4,
                    "checksum": null,
                    "width": 1,
                    "height": 1,
                    "folderId": "6650f1c2a9e4b1d2c3f40a20",
                    "title": {},
                    "alt": {
                      "en-GB": "Kayaks on a calm fjord"
                    },
                    "caption": {},
                    "tags": [
                      "…"
                    ],
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "original": {
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "width": 1,
                      "height": 1
                    },
                    "crop": {
                      "x": 1,
                      "y": 1,
                      "width": 1,
                      "height": 1,
                      "rotate": 0,
                      "aspect": null
                    },
                    "edit": {
                      "version": 1,
                      "steps": [
                        null
                      ]
                    },
                    "focalPoint": {
                      "x": 1,
                      "y": 1
                    },
                    "consent": {
                      "reference": null,
                      "status": "pending",
                      "restrictions": null
                    },
                    "subtitles": {},
                    "source": {
                      "provider": "cloudinary",
                      "externalId": "6650f1c2a9e4b1d2c3f40a5a"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body is empty or isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks media:upload, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such media, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Media not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/media/{mediaId}/crop": {
      "post": {
        "operationId": "postMediaMediaByMediaIdCrop",
        "tags": [
          "Media"
        ],
        "summary": "Crops or edits an image, or takes the crop and edits off again",
        "description": "Crops or edits an image, or takes the crop and edits off again. Permission: media:upload.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "mediaId",
            "in": "path",
            "required": true,
            "description": "The media's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "area": {
                    "type": [
                      "object",
                      "null"
                    ],
                    "properties": {
                      "x": {
                        "type": "number",
                        "minimum": 0
                      },
                      "y": {
                        "type": "number",
                        "minimum": 0
                      },
                      "width": {
                        "type": "number",
                        "minimum": 1
                      },
                      "height": {
                        "type": "number",
                        "minimum": 1
                      },
                      "rotate": {
                        "type": "number",
                        "enum": [
                          0,
                          90,
                          180,
                          270
                        ]
                      }
                    },
                    "required": [
                      "x",
                      "y",
                      "width",
                      "height",
                      "rotate"
                    ],
                    "description": "In pixels of the original after the quarter turn, flips and straightening. null removes the crop."
                  },
                  "aspect": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 20,
                    "description": "Such as 16:9."
                  },
                  "edit": {
                    "type": [
                      "object",
                      "null"
                    ],
                    "properties": {
                      "version": {
                        "default": 1,
                        "type": "number",
                        "const": 1
                      },
                      "steps": {
                        "maxItems": 12,
                        "type": "array",
                        "items": {
                          "oneOf": [
                            {
                              "type": "object",
                              "properties": {
                                "type": {
                                  "type": "string",
                                  "const": "flip"
                                },
                                "horizontal": {
                                  "type": "boolean"
                                },
                                "vertical": {
                                  "type": "boolean"
                                }
                              },
                              "required": [
                                "type",
                                "horizontal",
                                "vertical"
                              ]
                            },
                            {
                              "type": "object",
                              "properties": {
                                "type": {
                                  "type": "string",
                                  "const": "straighten"
                                },
                                "angle": {
                                  "type": "number",
                                  "minimum": -45,
                                  "maximum": 45
                                }
                              },
                              "required": [
                                "type",
                                "angle"
                              ]
                            },
                            {
                              "type": "object",
                              "properties": {
                                "type": {
                                  "type": "string",
                                  "const": "redact"
                                },
                                "areas": {
                                  "maxItems": 30,
                                  "type": "array",
                                  "items": {
                                    "type": "object",
                                    "properties": {
                                      "x": {
                                        "type": "number",
                                        "minimum": 0,
                                        "maximum": 1
                                      },
                                      "y": {
                                        "type": "number",
                                        "minimum": 0,
                                        "maximum": 1
                                      },
                                      "width": {
                                        "type": "number",
                                        "minimum": 0,
                                        "maximum": 1
                                      },
                                      "height": {
                                        "type": "number",
                                        "minimum": 0,
                                        "maximum": 1
                                      },
                                      "style": {
                                        "type": "string",
                                        "enum": [
                                          "blur",
                                          "pixelate"
                                        ]
                                      }
                                    },
                                    "required": [
                                      "x",
                                      "y",
                                      "width",
                                      "height",
                                      "style"
                                    ]
                                  }
                                }
                              },
                              "required": [
                                "type",
                                "areas"
                              ]
                            },
                            {
                              "type": "object",
                              "properties": {
                                "type": {
                                  "type": "string",
                                  "const": "adjust"
                                },
                                "brightness": {
                                  "type": "number",
                                  "minimum": -100,
                                  "maximum": 100
                                },
                                "contrast": {
                                  "type": "number",
                                  "minimum": -100,
                                  "maximum": 100
                                },
                                "saturation": {
                                  "type": "number",
                                  "minimum": -100,
                                  "maximum": 100
                                },
                                "warmth": {
                                  "type": "number",
                                  "minimum": -100,
                                  "maximum": 100
                                },
                                "shadows": {
                                  "type": "number",
                                  "minimum": -100,
                                  "maximum": 100
                                },
                                "highlights": {
                                  "type": "number",
                                  "minimum": -100,
                                  "maximum": 100
                                }
                              },
                              "required": [
                                "type"
                              ]
                            },
                            {
                              "type": "object",
                              "properties": {
                                "type": {
                                  "type": "string",
                                  "const": "look"
                                },
                                "name": {
                                  "type": "string",
                                  "enum": [
                                    "warm",
                                    "cool",
                                    "mono",
                                    "noir",
                                    "faded",
                                    "vivid"
                                  ]
                                },
                                "strength": {
                                  "type": "number",
                                  "minimum": 0,
                                  "maximum": 100
                                }
                              },
                              "required": [
                                "type",
                                "name",
                                "strength"
                              ]
                            },
                            {
                              "type": "object",
                              "properties": {
                                "type": {
                                  "type": "string",
                                  "const": "sharpen"
                                },
                                "amount": {
                                  "type": "number",
                                  "minimum": 0,
                                  "maximum": 100
                                }
                              },
                              "required": [
                                "type",
                                "amount"
                              ]
                            }
                          ]
                        }
                      }
                    },
                    "required": [
                      "steps"
                    ],
                    "description": "The image editor's changes: flip, straighten (-45 to 45 degrees), redact (areas as fractions of the straightened image, blurred or pixelated), adjust (-100 to 100 each), look (warm, cool, mono, noir, faded or vivid, strength 0 to 100) and sharpen (0 to 100). null removes them; leave it out to keep them. The original is kept either way."
                  },
                  "asCopy": {
                    "default": false,
                    "type": "boolean",
                    "description": "Keep this file and add the result as a new one, answered with 201."
                  }
                },
                "required": [
                  "area"
                ]
              },
              "example": {
                "area": {
                  "x": 0,
                  "y": 120,
                  "width": 1600,
                  "height": 900,
                  "rotate": 0
                },
                "aspect": "16:9",
                "edit": {
                  "version": 1,
                  "steps": [
                    {
                      "type": "straighten",
                      "angle": 1.5
                    },
                    {
                      "type": "redact",
                      "areas": [
                        {
                          "x": 0.62,
                          "y": 0.71,
                          "width": 0.12,
                          "height": 0.05,
                          "style": "pixelate"
                        }
                      ]
                    },
                    {
                      "type": "adjust",
                      "brightness": 8,
                      "contrast": 0,
                      "saturation": 0,
                      "warmth": 12,
                      "shadows": 15,
                      "highlights": -10
                    },
                    {
                      "type": "look",
                      "name": "warm",
                      "strength": 40
                    }
                  ]
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The file, or 201 with a copy.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Media"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a45",
                    "filename": "lofoten-kayaks.webp",
                    "url": "https://media.northwilds.com/lofoten-kayaks.webp",
                    "mimeType": "image/webp",
                    "category": "image",
                    "size": 4,
                    "checksum": null,
                    "width": 1,
                    "height": 1,
                    "folderId": "6650f1c2a9e4b1d2c3f40a20",
                    "title": {},
                    "alt": {
                      "en-GB": "Kayaks on a calm fjord"
                    },
                    "caption": {},
                    "tags": [
                      "…"
                    ],
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "original": {
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "width": 1,
                      "height": 1
                    },
                    "crop": {
                      "x": 1,
                      "y": 1,
                      "width": 1,
                      "height": 1,
                      "rotate": 0,
                      "aspect": null
                    },
                    "edit": {
                      "version": 1,
                      "steps": [
                        null
                      ]
                    },
                    "focalPoint": {
                      "x": 1,
                      "y": 1
                    },
                    "consent": {
                      "reference": null,
                      "status": "pending",
                      "restrictions": null
                    },
                    "subtitles": {},
                    "source": {
                      "provider": "cloudinary",
                      "externalId": "6650f1c2a9e4b1d2c3f40a5a"
                    }
                  }
                }
              }
            }
          },
          "201": {
            "description": "With asCopy: the new file.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Media"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a45",
                    "filename": "lofoten-kayaks.webp",
                    "url": "https://media.northwilds.com/lofoten-kayaks.webp",
                    "mimeType": "image/webp",
                    "category": "image",
                    "size": 4,
                    "checksum": null,
                    "width": 1,
                    "height": 1,
                    "folderId": "6650f1c2a9e4b1d2c3f40a20",
                    "title": {},
                    "alt": {
                      "en-GB": "Kayaks on a calm fjord"
                    },
                    "caption": {},
                    "tags": [
                      "…"
                    ],
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "original": {
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "width": 1,
                      "height": 1
                    },
                    "crop": {
                      "x": 1,
                      "y": 1,
                      "width": 1,
                      "height": 1,
                      "rotate": 0,
                      "aspect": null
                    },
                    "edit": {
                      "version": 1,
                      "steps": [
                        null
                      ]
                    },
                    "focalPoint": {
                      "x": 1,
                      "y": 1
                    },
                    "consent": {
                      "reference": null,
                      "status": "pending",
                      "restrictions": null
                    },
                    "subtitles": {},
                    "source": {
                      "provider": "cloudinary",
                      "externalId": "6650f1c2a9e4b1d2c3f40a5a"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body is empty or isn't valid JSON. Or the file isn't a JPEG, PNG, WebP or AVIF image, or the area is outside it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks media:upload, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such media, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Media not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/media/{mediaId}/edit": {
      "post": {
        "operationId": "postMediaMediaByMediaIdEdit",
        "tags": [
          "Media"
        ],
        "summary": "The same as crop, under a name that fits edits",
        "description": "The same as crop, under a name that fits edits. Permission: media:upload.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "mediaId",
            "in": "path",
            "required": true,
            "description": "The media's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "area": {
                    "type": [
                      "object",
                      "null"
                    ],
                    "properties": {
                      "x": {
                        "type": "number",
                        "minimum": 0
                      },
                      "y": {
                        "type": "number",
                        "minimum": 0
                      },
                      "width": {
                        "type": "number",
                        "minimum": 1
                      },
                      "height": {
                        "type": "number",
                        "minimum": 1
                      },
                      "rotate": {
                        "type": "number",
                        "enum": [
                          0,
                          90,
                          180,
                          270
                        ]
                      }
                    },
                    "required": [
                      "x",
                      "y",
                      "width",
                      "height",
                      "rotate"
                    ],
                    "description": "In pixels of the original after the quarter turn, flips and straightening. null removes the crop."
                  },
                  "aspect": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 20,
                    "description": "Such as 16:9."
                  },
                  "edit": {
                    "type": [
                      "object",
                      "null"
                    ],
                    "properties": {
                      "version": {
                        "default": 1,
                        "type": "number",
                        "const": 1
                      },
                      "steps": {
                        "maxItems": 12,
                        "type": "array",
                        "items": {
                          "oneOf": [
                            {
                              "type": "object",
                              "properties": {
                                "type": {
                                  "type": "string",
                                  "const": "flip"
                                },
                                "horizontal": {
                                  "type": "boolean"
                                },
                                "vertical": {
                                  "type": "boolean"
                                }
                              },
                              "required": [
                                "type",
                                "horizontal",
                                "vertical"
                              ]
                            },
                            {
                              "type": "object",
                              "properties": {
                                "type": {
                                  "type": "string",
                                  "const": "straighten"
                                },
                                "angle": {
                                  "type": "number",
                                  "minimum": -45,
                                  "maximum": 45
                                }
                              },
                              "required": [
                                "type",
                                "angle"
                              ]
                            },
                            {
                              "type": "object",
                              "properties": {
                                "type": {
                                  "type": "string",
                                  "const": "redact"
                                },
                                "areas": {
                                  "maxItems": 30,
                                  "type": "array",
                                  "items": {
                                    "type": "object",
                                    "properties": {
                                      "x": {
                                        "type": "number",
                                        "minimum": 0,
                                        "maximum": 1
                                      },
                                      "y": {
                                        "type": "number",
                                        "minimum": 0,
                                        "maximum": 1
                                      },
                                      "width": {
                                        "type": "number",
                                        "minimum": 0,
                                        "maximum": 1
                                      },
                                      "height": {
                                        "type": "number",
                                        "minimum": 0,
                                        "maximum": 1
                                      },
                                      "style": {
                                        "type": "string",
                                        "enum": [
                                          "blur",
                                          "pixelate"
                                        ]
                                      }
                                    },
                                    "required": [
                                      "x",
                                      "y",
                                      "width",
                                      "height",
                                      "style"
                                    ]
                                  }
                                }
                              },
                              "required": [
                                "type",
                                "areas"
                              ]
                            },
                            {
                              "type": "object",
                              "properties": {
                                "type": {
                                  "type": "string",
                                  "const": "adjust"
                                },
                                "brightness": {
                                  "type": "number",
                                  "minimum": -100,
                                  "maximum": 100
                                },
                                "contrast": {
                                  "type": "number",
                                  "minimum": -100,
                                  "maximum": 100
                                },
                                "saturation": {
                                  "type": "number",
                                  "minimum": -100,
                                  "maximum": 100
                                },
                                "warmth": {
                                  "type": "number",
                                  "minimum": -100,
                                  "maximum": 100
                                },
                                "shadows": {
                                  "type": "number",
                                  "minimum": -100,
                                  "maximum": 100
                                },
                                "highlights": {
                                  "type": "number",
                                  "minimum": -100,
                                  "maximum": 100
                                }
                              },
                              "required": [
                                "type"
                              ]
                            },
                            {
                              "type": "object",
                              "properties": {
                                "type": {
                                  "type": "string",
                                  "const": "look"
                                },
                                "name": {
                                  "type": "string",
                                  "enum": [
                                    "warm",
                                    "cool",
                                    "mono",
                                    "noir",
                                    "faded",
                                    "vivid"
                                  ]
                                },
                                "strength": {
                                  "type": "number",
                                  "minimum": 0,
                                  "maximum": 100
                                }
                              },
                              "required": [
                                "type",
                                "name",
                                "strength"
                              ]
                            },
                            {
                              "type": "object",
                              "properties": {
                                "type": {
                                  "type": "string",
                                  "const": "sharpen"
                                },
                                "amount": {
                                  "type": "number",
                                  "minimum": 0,
                                  "maximum": 100
                                }
                              },
                              "required": [
                                "type",
                                "amount"
                              ]
                            }
                          ]
                        }
                      }
                    },
                    "required": [
                      "steps"
                    ],
                    "description": "The image editor's changes: flip, straighten (-45 to 45 degrees), redact (areas as fractions of the straightened image, blurred or pixelated), adjust (-100 to 100 each), look (warm, cool, mono, noir, faded or vivid, strength 0 to 100) and sharpen (0 to 100). null removes them; leave it out to keep them. The original is kept either way."
                  },
                  "asCopy": {
                    "default": false,
                    "type": "boolean",
                    "description": "Keep this file and add the result as a new one, answered with 201."
                  }
                },
                "required": [
                  "area"
                ]
              },
              "example": {
                "area": {
                  "x": 0,
                  "y": 120,
                  "width": 1600,
                  "height": 900,
                  "rotate": 0
                },
                "aspect": "16:9",
                "edit": {
                  "version": 1,
                  "steps": [
                    {
                      "type": "straighten",
                      "angle": 1.5
                    },
                    {
                      "type": "redact",
                      "areas": [
                        {
                          "x": 0.62,
                          "y": 0.71,
                          "width": 0.12,
                          "height": 0.05,
                          "style": "pixelate"
                        }
                      ]
                    },
                    {
                      "type": "adjust",
                      "brightness": 8,
                      "contrast": 0,
                      "saturation": 0,
                      "warmth": 12,
                      "shadows": 15,
                      "highlights": -10
                    },
                    {
                      "type": "look",
                      "name": "warm",
                      "strength": 40
                    }
                  ]
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The file, or 201 with a copy.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Media"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a45",
                    "filename": "lofoten-kayaks.webp",
                    "url": "https://media.northwilds.com/lofoten-kayaks.webp",
                    "mimeType": "image/webp",
                    "category": "image",
                    "size": 4,
                    "checksum": null,
                    "width": 1,
                    "height": 1,
                    "folderId": "6650f1c2a9e4b1d2c3f40a20",
                    "title": {},
                    "alt": {
                      "en-GB": "Kayaks on a calm fjord"
                    },
                    "caption": {},
                    "tags": [
                      "…"
                    ],
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "original": {
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "width": 1,
                      "height": 1
                    },
                    "crop": {
                      "x": 1,
                      "y": 1,
                      "width": 1,
                      "height": 1,
                      "rotate": 0,
                      "aspect": null
                    },
                    "edit": {
                      "version": 1,
                      "steps": [
                        null
                      ]
                    },
                    "focalPoint": {
                      "x": 1,
                      "y": 1
                    },
                    "consent": {
                      "reference": null,
                      "status": "pending",
                      "restrictions": null
                    },
                    "subtitles": {},
                    "source": {
                      "provider": "cloudinary",
                      "externalId": "6650f1c2a9e4b1d2c3f40a5a"
                    }
                  }
                }
              }
            }
          },
          "201": {
            "description": "With asCopy: the new file.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Media"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a45",
                    "filename": "lofoten-kayaks.webp",
                    "url": "https://media.northwilds.com/lofoten-kayaks.webp",
                    "mimeType": "image/webp",
                    "category": "image",
                    "size": 4,
                    "checksum": null,
                    "width": 1,
                    "height": 1,
                    "folderId": "6650f1c2a9e4b1d2c3f40a20",
                    "title": {},
                    "alt": {
                      "en-GB": "Kayaks on a calm fjord"
                    },
                    "caption": {},
                    "tags": [
                      "…"
                    ],
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "original": {
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "width": 1,
                      "height": 1
                    },
                    "crop": {
                      "x": 1,
                      "y": 1,
                      "width": 1,
                      "height": 1,
                      "rotate": 0,
                      "aspect": null
                    },
                    "edit": {
                      "version": 1,
                      "steps": [
                        null
                      ]
                    },
                    "focalPoint": {
                      "x": 1,
                      "y": 1
                    },
                    "consent": {
                      "reference": null,
                      "status": "pending",
                      "restrictions": null
                    },
                    "subtitles": {},
                    "source": {
                      "provider": "cloudinary",
                      "externalId": "6650f1c2a9e4b1d2c3f40a5a"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body is empty or isn't valid JSON. Or the file isn't a JPEG, PNG, WebP or AVIF image, or the area is outside it.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks media:upload, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such media, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Media not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/media/{mediaId}/original": {
      "get": {
        "operationId": "getMediaMediaByMediaIdOriginal",
        "tags": [
          "Media"
        ],
        "summary": "The kept original, for editors only, never cached",
        "description": "The kept original, for editors only, never cached. Permission: media:upload.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "mediaId",
            "in": "path",
            "required": true,
            "description": "The media's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "200": {
            "description": "The file the image is made from, answered with Cache-Control: private, no-store. An image with blurred areas keeps its original privately, and this is the only address that serves it.",
            "content": {
              "image/*": {
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks media:upload.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such file, or it has no kept original.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Media not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "delete": {
        "operationId": "deleteMediaMediaByMediaIdOriginal",
        "tags": [
          "Media"
        ],
        "summary": "Replaces the original with the blurred image for good",
        "description": "Replaces the original with the blurred image for good. Permission: content:purge.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "mediaId",
            "in": "path",
            "required": true,
            "description": "The media's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "200": {
            "description": "The file.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Media"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a45",
                    "filename": "lofoten-kayaks.webp",
                    "url": "https://media.northwilds.com/lofoten-kayaks.webp",
                    "mimeType": "image/webp",
                    "category": "image",
                    "size": 4,
                    "checksum": null,
                    "width": 1,
                    "height": 1,
                    "folderId": "6650f1c2a9e4b1d2c3f40a20",
                    "title": {},
                    "alt": {
                      "en-GB": "Kayaks on a calm fjord"
                    },
                    "caption": {},
                    "tags": [
                      "…"
                    ],
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "original": {
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "width": 1,
                      "height": 1
                    },
                    "crop": {
                      "x": 1,
                      "y": 1,
                      "width": 1,
                      "height": 1,
                      "rotate": 0,
                      "aspect": null
                    },
                    "edit": {
                      "version": 1,
                      "steps": [
                        null
                      ]
                    },
                    "focalPoint": {
                      "x": 1,
                      "y": 1
                    },
                    "consent": {
                      "reference": null,
                      "status": "pending",
                      "restrictions": null
                    },
                    "subtitles": {},
                    "source": {
                      "provider": "cloudinary",
                      "externalId": "6650f1c2a9e4b1d2c3f40a5a"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The image has no blurred areas, so there is no original to remove.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:purge, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such media, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Media not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/media/{mediaId}/subtitles": {
      "delete": {
        "operationId": "deleteMediaMediaByMediaIdSubtitles",
        "tags": [
          "Media"
        ],
        "summary": "Removes one language's subtitles",
        "description": "Removes one language's subtitles. Permission: media:upload.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "mediaId",
            "in": "path",
            "required": true,
            "description": "The media's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "locale",
            "in": "query",
            "required": true,
            "description": "The language whose subtitles to remove, such as nb-NO. Required.",
            "schema": {
              "type": "string"
            },
            "example": "nb-NO"
          }
        ],
        "responses": {
          "200": {
            "description": "The file.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Media"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a45",
                    "filename": "lofoten-kayaks.webp",
                    "url": "https://media.northwilds.com/lofoten-kayaks.webp",
                    "mimeType": "image/webp",
                    "category": "image",
                    "size": 4,
                    "checksum": null,
                    "width": 1,
                    "height": 1,
                    "folderId": "6650f1c2a9e4b1d2c3f40a20",
                    "title": {},
                    "alt": {
                      "en-GB": "Kayaks on a calm fjord"
                    },
                    "caption": {},
                    "tags": [
                      "…"
                    ],
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "original": {
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "width": 1,
                      "height": 1
                    },
                    "crop": {
                      "x": 1,
                      "y": 1,
                      "width": 1,
                      "height": 1,
                      "rotate": 0,
                      "aspect": null
                    },
                    "edit": {
                      "version": 1,
                      "steps": [
                        null
                      ]
                    },
                    "focalPoint": {
                      "x": 1,
                      "y": 1
                    },
                    "consent": {
                      "reference": null,
                      "status": "pending",
                      "restrictions": null
                    },
                    "subtitles": {},
                    "source": {
                      "provider": "cloudinary",
                      "externalId": "6650f1c2a9e4b1d2c3f40a5a"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "No locale.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks media:upload, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such media, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Media not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postMediaMediaByMediaIdSubtitles",
        "tags": [
          "Media"
        ],
        "summary": "Adds WebVTT subtitles to a video",
        "description": "Adds WebVTT subtitles to a video. Permission: media:upload.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "mediaId",
            "in": "path",
            "required": true,
            "description": "The media's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "multipart/form-data": {
              "schema": {
                "type": "object",
                "properties": {
                  "file": {
                    "type": "string",
                    "description": "A WebVTT file, up to 1 MB.",
                    "format": "binary"
                  },
                  "locale": {
                    "type": "string",
                    "description": "The language, such as nb-NO."
                  }
                },
                "required": [
                  "file",
                  "locale"
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The file.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Media"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a45",
                    "filename": "lofoten-kayaks.webp",
                    "url": "https://media.northwilds.com/lofoten-kayaks.webp",
                    "mimeType": "image/webp",
                    "category": "image",
                    "size": 4,
                    "checksum": null,
                    "width": 1,
                    "height": 1,
                    "folderId": "6650f1c2a9e4b1d2c3f40a20",
                    "title": {},
                    "alt": {
                      "en-GB": "Kayaks on a calm fjord"
                    },
                    "caption": {},
                    "tags": [
                      "…"
                    ],
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "original": {
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "width": 1,
                      "height": 1
                    },
                    "crop": {
                      "x": 1,
                      "y": 1,
                      "width": 1,
                      "height": 1,
                      "rotate": 0,
                      "aspect": null
                    },
                    "edit": {
                      "version": 1,
                      "steps": [
                        null
                      ]
                    },
                    "focalPoint": {
                      "x": 1,
                      "y": 1
                    },
                    "consent": {
                      "reference": null,
                      "status": "pending",
                      "restrictions": null
                    },
                    "subtitles": {},
                    "source": {
                      "provider": "cloudinary",
                      "externalId": "6650f1c2a9e4b1d2c3f40a5a"
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "No file or locale, a file that isn't a video, or a subtitle file over 1 MB.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Send the request as multipart/form-data"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks media:upload, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such media, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Media not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/media/{mediaId}/usage": {
      "get": {
        "operationId": "getMediaMediaByMediaIdUsage",
        "tags": [
          "Media"
        ],
        "summary": "Pages that use it",
        "description": "Pages that use it. Permission: media:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "mediaId",
            "in": "path",
            "required": true,
            "description": "The media's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "200": {
            "description": "[{ id, name, url, contentType, live }].",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string",
                            "description": "An id."
                          },
                          "name": {
                            "type": "string"
                          },
                          "url": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "contentType": {
                            "type": "string"
                          },
                          "live": {
                            "type": "boolean",
                            "description": "The published page uses it, not only the draft."
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "url",
                          "contentType",
                          "live"
                        ]
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "name": "Lofoten sea kayaking",
                      "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                      "contentType": "…",
                      "live": true
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks media:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such media, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Media not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/navigation": {
      "get": {
        "operationId": "getMenusNavigation",
        "tags": [
          "Menus"
        ],
        "summary": "The environment's menus",
        "description": "The environment's menus. environmentId is required. Permission: navigation:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "query",
            "required": true,
            "description": "The environment's id. Required.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          }
        ],
        "responses": {
          "200": {
            "description": "List of menus.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Menu"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "_id": "6650f1c2a9e4b1d2c3f40a44",
                      "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                      "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "regionId": "6650f1c2a9e4b1d2c3f40a17",
                      "localeId": "6650f1c2a9e4b1d2c3f40a18",
                      "key": "main",
                      "name": "Main menu",
                      "kind": "header",
                      "items": [
                        {
                          "id": "6650f1c2a9e4b1d2c3f40a48",
                          "label": "Trips",
                          "kind": "folder",
                          "contentId": "6650f1c2a9e4b1d2c3f40a21",
                          "folderId": "6650f1c2a9e4b1d2c3f40a20",
                          "href": null,
                          "target": "_self",
                          "icon": null,
                          "badge": null,
                          "description": "Six days of paddling between the peaks of Lofoten.",
                          "visible": true,
                          "travel": {
                            "id": "6650f1c2a9e4b1d2c3f40a40",
                            "name": "Lofoten sea kayaking",
                            "kind": "country"
                          },
                          "children": []
                        }
                      ],
                      "createdBy": "6650f1c2a9e4b1d2c3f40a30",
                      "updatedBy": "6650f1c2a9e4b1d2c3f40a30",
                      "createdAt": "2026-11-02T09:30:00.000Z",
                      "updatedAt": "2026-11-02T09:30:00.000Z"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks navigation:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postMenusNavigation",
        "tags": [
          "Menus"
        ],
        "summary": "Adds a menu",
        "description": "Adds a menu. Permission: navigation:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "environmentId": {
                    "type": "string",
                    "description": "An id."
                  },
                  "key": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 64,
                    "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$",
                    "description": "Such as main."
                  },
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "kind": {
                    "default": "custom",
                    "type": "string",
                    "enum": [
                      "header",
                      "footer",
                      "mobile",
                      "custom"
                    ]
                  },
                  "regionId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "Only in this region, or null for all."
                  },
                  "localeId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "Only in this language, or null for all."
                  },
                  "items": {
                    "type": "array",
                    "items": {
                      "description": "Any JSON value."
                    },
                    "description": "Menu items: each { label, kind, contentId or folderId or href, target, icon, badge, description, visible, children }. At most 4 levels."
                  }
                },
                "required": [
                  "environmentId",
                  "key",
                  "name"
                ]
              },
              "example": {
                "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                "key": "main",
                "name": "Main menu",
                "kind": "header",
                "items": [
                  {
                    "label": "Trips",
                    "kind": "folder",
                    "folderId": "6650f1c2a9e4b1d2c3f40a20"
                  },
                  {
                    "label": "Gear",
                    "kind": "external",
                    "href": "https://northwilds.com/gear"
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The menu.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Menu"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "_id": "6650f1c2a9e4b1d2c3f40a44",
                    "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                    "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "regionId": "6650f1c2a9e4b1d2c3f40a17",
                    "localeId": "6650f1c2a9e4b1d2c3f40a18",
                    "key": "main",
                    "name": "Main menu",
                    "kind": "header",
                    "items": [
                      {
                        "id": "6650f1c2a9e4b1d2c3f40a48",
                        "label": "Trips",
                        "kind": "folder",
                        "contentId": "6650f1c2a9e4b1d2c3f40a21",
                        "folderId": "6650f1c2a9e4b1d2c3f40a20",
                        "href": null,
                        "target": "_self",
                        "icon": null,
                        "badge": null,
                        "description": "Six days of paddling between the peaks of Lofoten.",
                        "visible": true,
                        "travel": {
                          "id": "6650f1c2a9e4b1d2c3f40a40",
                          "name": "Lofoten sea kayaking",
                          "kind": "country"
                        },
                        "children": []
                      }
                    ],
                    "createdBy": "6650f1c2a9e4b1d2c3f40a30",
                    "updatedBy": "6650f1c2a9e4b1d2c3f40a30",
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or items nest more than 4 levels.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks navigation:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "A menu with the key exists in the environment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/navigation/{navigationId}": {
      "delete": {
        "operationId": "deleteMenusNavigationByNavigationId",
        "tags": [
          "Menus"
        ],
        "summary": "Deletes it",
        "description": "Deletes it. Permission: navigation:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "navigationId",
            "in": "path",
            "required": true,
            "description": "The navigation's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks navigation:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such navigation, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Navigation not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchMenusNavigationByNavigationId",
        "tags": [
          "Menus"
        ],
        "summary": "Changes its name, kind or items",
        "description": "Changes its name, kind or items. Permission: navigation:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "navigationId",
            "in": "path",
            "required": true,
            "description": "The navigation's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "kind": {
                    "type": "string",
                    "enum": [
                      "header",
                      "footer",
                      "mobile",
                      "custom"
                    ]
                  },
                  "items": {
                    "type": "array",
                    "items": {
                      "description": "Any JSON value."
                    },
                    "description": "Replaces every item."
                  }
                }
              },
              "example": {
                "name": "Main menu",
                "items": [
                  {
                    "label": "Trips",
                    "kind": "folder",
                    "folderId": "6650f1c2a9e4b1d2c3f40a20"
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The menu.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Menu"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "_id": "6650f1c2a9e4b1d2c3f40a44",
                    "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                    "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "regionId": "6650f1c2a9e4b1d2c3f40a17",
                    "localeId": "6650f1c2a9e4b1d2c3f40a18",
                    "key": "main",
                    "name": "Main menu",
                    "kind": "header",
                    "items": [
                      {
                        "id": "6650f1c2a9e4b1d2c3f40a48",
                        "label": "Trips",
                        "kind": "folder",
                        "contentId": "6650f1c2a9e4b1d2c3f40a21",
                        "folderId": "6650f1c2a9e4b1d2c3f40a20",
                        "href": null,
                        "target": "_self",
                        "icon": null,
                        "badge": null,
                        "description": "Six days of paddling between the peaks of Lofoten.",
                        "visible": true,
                        "travel": {
                          "id": "6650f1c2a9e4b1d2c3f40a40",
                          "name": "Lofoten sea kayaking",
                          "kind": "country"
                        },
                        "children": []
                      }
                    ],
                    "createdBy": "6650f1c2a9e4b1d2c3f40a30",
                    "updatedBy": "6650f1c2a9e4b1d2c3f40a30",
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or items nest more than 4 levels.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks navigation:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such navigation, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Navigation not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/presence-orbit": {
      "get": {
        "operationId": "getConnectedSatellitesPresenceOrbit",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Reads the presence Orbit connection: { connected }",
        "description": "Reads the presence Orbit connection: { connected }. Permission: space:update to change.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "The connection.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/PresenceConnection"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "reachable": true,
                    "brandName": "Northwilds",
                    "locations": [
                      {
                        "id": "6650f1c2a9e4b1d2c3f40a50",
                        "name": "Lofoten sea kayaking",
                        "slug": "lofoten-sea-kayaking",
                        "city": "Tromsø",
                        "average": 1,
                        "total": 4
                      }
                    ],
                    "connection": {
                      "siteSlug": "…",
                      "brandName": "Northwilds",
                      "connectedAt": "2026-11-02T09:30:00.000Z",
                      "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                    },
                    "canManage": true
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:update to change.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "put": {
        "operationId": "putConnectedSatellitesPresenceOrbit",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Changes the presence Orbit connection: { connected }",
        "description": "Changes the presence Orbit connection: { connected }. Permission: space:update to change.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "connected": {
                    "type": "boolean"
                  }
                },
                "required": [
                  "connected"
                ]
              },
              "example": {
                "connected": true
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The connection.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/PresenceConnection"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "reachable": true,
                    "brandName": "Northwilds",
                    "locations": [
                      {
                        "id": "6650f1c2a9e4b1d2c3f40a50",
                        "name": "Lofoten sea kayaking",
                        "slug": "lofoten-sea-kayaking",
                        "city": "Tromsø",
                        "average": 1,
                        "total": 4
                      }
                    ],
                    "connection": {
                      "siteSlug": "…",
                      "brandName": "Northwilds",
                      "connectedAt": "2026-11-02T09:30:00.000Z",
                      "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                    },
                    "canManage": true
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or presence Orbit could not be reached, or the organisation has none.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:update to change, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/presence-orbit/locations": {
      "get": {
        "operationId": "getConnectedSatellitesPresenceOrbitLocations",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Presence Orbit locations with their ratings",
        "description": "Presence Orbit locations with their ratings. A satellite that is not connected answers 400. Permission: Space access.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "List.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/PresenceLocation"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a50",
                      "name": "Lofoten sea kayaking",
                      "slug": "lofoten-sea-kayaking",
                      "city": "Tromsø",
                      "average": 1,
                      "total": 4
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The satellite is not connected to this space, or could not be reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks Space access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/redirects": {
      "get": {
        "operationId": "getRedirectsRedirects",
        "tags": [
          "Redirects"
        ],
        "summary": "The environment's redirects",
        "description": "The environment's redirects. environmentId is required. Permission: redirect:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "query",
            "required": true,
            "description": "The environment's id. Required.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          }
        ],
        "responses": {
          "200": {
            "description": "List of redirects.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Redirect"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "_id": "6650f1c2a9e4b1d2c3f40a48",
                      "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                      "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "regionId": "6650f1c2a9e4b1d2c3f40a17",
                      "localeId": "6650f1c2a9e4b1d2c3f40a18",
                      "source": "/trips/lofoten",
                      "destinationType": "url",
                      "destinationUrl": "/trips/lofoten-sea-kayaking",
                      "destinationContentId": null,
                      "statusCode": 301,
                      "enabled": true,
                      "origin": "manual",
                      "note": null,
                      "noteWording": null,
                      "hits": 1,
                      "lastHitAt": "2026-11-02T09:30:00.000Z",
                      "status": "draft",
                      "createdBy": "6650f1c2a9e4b1d2c3f40a30",
                      "updatedBy": "6650f1c2a9e4b1d2c3f40a30",
                      "createdAt": "2026-11-02T09:30:00.000Z",
                      "updatedAt": "2026-11-02T09:30:00.000Z"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks redirect:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postRedirectsRedirects",
        "tags": [
          "Redirects"
        ],
        "summary": "Adds a redirect",
        "description": "Adds a redirect. Permission: redirect:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "environmentId": {
                    "type": "string",
                    "description": "An id."
                  },
                  "source": {
                    "type": "string",
                    "minLength": 1,
                    "description": "The old address, such as /trips/lofoten."
                  },
                  "destinationUrl": {
                    "type": "string",
                    "minLength": 1,
                    "description": "A path such as /trips/lofoten-sea-kayaking, or a full https:// address."
                  },
                  "regionId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "An id."
                  },
                  "localeId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "An id."
                  },
                  "statusCode": {
                    "default": 301,
                    "type": "number",
                    "enum": [
                      301,
                      302,
                      307,
                      308
                    ]
                  },
                  "enabled": {
                    "default": true,
                    "type": "boolean"
                  },
                  "note": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 500,
                    "default": null,
                    "description": "Up to 500 characters."
                  }
                },
                "required": [
                  "environmentId",
                  "source",
                  "destinationUrl"
                ]
              },
              "example": {
                "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                "source": "/trips/lofoten",
                "destinationUrl": "/trips/lofoten-sea-kayaking",
                "statusCode": 301
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The new item.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Redirect"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "_id": "6650f1c2a9e4b1d2c3f40a48",
                    "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                    "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "regionId": "6650f1c2a9e4b1d2c3f40a17",
                    "localeId": "6650f1c2a9e4b1d2c3f40a18",
                    "source": "/trips/lofoten",
                    "destinationType": "url",
                    "destinationUrl": "/trips/lofoten-sea-kayaking",
                    "destinationContentId": null,
                    "statusCode": 301,
                    "enabled": true,
                    "origin": "manual",
                    "note": null,
                    "noteWording": null,
                    "hits": 1,
                    "lastHitAt": "2026-11-02T09:30:00.000Z",
                    "status": "draft",
                    "createdBy": "6650f1c2a9e4b1d2c3f40a30",
                    "updatedBy": "6650f1c2a9e4b1d2c3f40a30",
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or a redirect to itself, in a loop, or in a chain of more than 10.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks redirect:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "A redirect from the source exists.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/redirects/export": {
      "get": {
        "operationId": "getRedirectsRedirectsExport",
        "tags": [
          "Redirects"
        ],
        "summary": "Downloads them as CSV",
        "description": "Downloads them as CSV. Permission: redirect:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "query",
            "required": true,
            "description": "The environment's id. Required.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          }
        ],
        "responses": {
          "200": {
            "description": "The columns source, destination, status, region, locale, enabled and note.",
            "content": {
              "text/csv": {
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks redirect:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/redirects/import": {
      "post": {
        "operationId": "postRedirectsRedirectsImport",
        "tags": [
          "Redirects"
        ],
        "summary": "Adds or updates them from CSV",
        "description": "Adds or updates them from CSV. Permission: redirect:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "environmentId": {
                    "type": "string",
                    "description": "The environment's id."
                  },
                  "csv": {
                    "type": "string",
                    "description": "The file's text. The first row names the columns: source (or from, old url), destination (or to, new url), and optionally status, region, locale, enabled and note. Up to 5,000 rows."
                  },
                  "apply": {
                    "type": "boolean",
                    "description": "false (the default) only reports what would happen. true does it."
                  }
                },
                "required": [
                  "environmentId",
                  "csv"
                ]
              },
              "example": {
                "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                "csv": "source,destination,status\n/trips/lofoten,/trips/lofoten-sea-kayaking,301",
                "apply": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "What was or would be done.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "applied": {
                          "type": "boolean"
                        },
                        "rows": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "line": {
                                "type": "integer"
                              },
                              "source": {
                                "type": "string"
                              },
                              "destination": {
                                "type": "string"
                              },
                              "statusCode": {
                                "type": [
                                  "integer",
                                  "null"
                                ]
                              },
                              "region": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              },
                              "outcome": {
                                "type": "string",
                                "enum": [
                                  "create",
                                  "update",
                                  "unchanged",
                                  "error"
                                ]
                              },
                              "message": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              }
                            },
                            "required": [
                              "line",
                              "source",
                              "destination",
                              "statusCode",
                              "region",
                              "outcome",
                              "message"
                            ]
                          }
                        },
                        "counts": {
                          "type": "object",
                          "properties": {
                            "create": {
                              "type": "integer"
                            },
                            "update": {
                              "type": "integer"
                            },
                            "unchanged": {
                              "type": "integer"
                            },
                            "error": {
                              "type": "integer"
                            }
                          },
                          "required": [
                            "create",
                            "update",
                            "unchanged",
                            "error"
                          ]
                        }
                      },
                      "required": [
                        "applied",
                        "rows",
                        "counts"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "applied": false,
                    "rows": [
                      {
                        "line": 1,
                        "source": "…",
                        "destination": "…",
                        "statusCode": 1,
                        "region": null,
                        "outcome": "create",
                        "message": null
                      }
                    ],
                    "counts": {
                      "create": 1,
                      "update": 1,
                      "unchanged": 1,
                      "error": 1
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or no rows, more than 5,000, or no source and destination columns.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks redirect:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/redirects/{redirectId}": {
      "delete": {
        "operationId": "deleteRedirectsRedirectsByRedirectId",
        "tags": [
          "Redirects"
        ],
        "summary": "Deletes one",
        "description": "Deletes one. Permission: redirect:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "redirectId",
            "in": "path",
            "required": true,
            "description": "The redirect's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks redirect:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such redirect, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Redirect not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchRedirectsRedirectsByRedirectId",
        "tags": [
          "Redirects"
        ],
        "summary": "Changes one",
        "description": "Changes one. Permission: redirect:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "redirectId",
            "in": "path",
            "required": true,
            "description": "The redirect's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "source": {
                    "type": "string",
                    "minLength": 1
                  },
                  "destinationUrl": {
                    "type": "string",
                    "minLength": 1
                  },
                  "regionId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "An id."
                  },
                  "localeId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "An id."
                  },
                  "statusCode": {
                    "type": "number",
                    "enum": [
                      301,
                      302,
                      307,
                      308
                    ]
                  },
                  "enabled": {
                    "type": "boolean"
                  },
                  "note": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 500
                  }
                }
              },
              "example": {
                "destinationUrl": "/trips/norway/lofoten-sea-kayaking",
                "enabled": true
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The redirect.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Redirect"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "_id": "6650f1c2a9e4b1d2c3f40a48",
                    "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                    "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "regionId": "6650f1c2a9e4b1d2c3f40a17",
                    "localeId": "6650f1c2a9e4b1d2c3f40a18",
                    "source": "/trips/lofoten",
                    "destinationType": "url",
                    "destinationUrl": "/trips/lofoten-sea-kayaking",
                    "destinationContentId": null,
                    "statusCode": 301,
                    "enabled": true,
                    "origin": "manual",
                    "note": null,
                    "noteWording": null,
                    "hits": 1,
                    "lastHitAt": "2026-11-02T09:30:00.000Z",
                    "status": "draft",
                    "createdBy": "6650f1c2a9e4b1d2c3f40a30",
                    "updatedBy": "6650f1c2a9e4b1d2c3f40a30",
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or a redirect to itself, in a loop, or in a chain of more than 10.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks redirect:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such redirect, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Redirect not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "A redirect from the source exists.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/releases": {
      "get": {
        "operationId": "getReleasesReleases",
        "tags": [
          "Releases"
        ],
        "summary": "The environment's releases, newest first",
        "description": "The environment's releases, newest first. environmentId is required. Permission: release:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "environmentId",
            "in": "query",
            "required": true,
            "description": "The environment's id. Required.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a13"
          }
        ],
        "responses": {
          "200": {
            "description": "List of releases.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Release"
                      },
                      "description": "Newest first."
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "_id": "6650f1c2a9e4b1d2c3f40a47",
                      "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                      "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "targetEnvironmentId": "6650f1c2a9e4b1d2c3f40a63",
                      "name": "Winter 2026 trips",
                      "description": "Six days of paddling between the peaks of Lofoten.",
                      "status": "scheduled",
                      "items": [
                        {
                          "contentId": "6650f1c2a9e4b1d2c3f40a21",
                          "action": "publish",
                          "regionId": "6650f1c2a9e4b1d2c3f40a17",
                          "localeId": "6650f1c2a9e4b1d2c3f40a18",
                          "includeChildren": false,
                          "addedAt": "2026-11-02T09:30:00.000Z",
                          "addedBy": "6650f1c2a9e4b1d2c3f40a30",
                          "outcome": {
                            "status": "published",
                            "reason": null
                          }
                        }
                      ],
                      "scheduledAt": "2026-11-02T09:30:00.000Z",
                      "publishedAt": "2026-11-02T09:30:00.000Z",
                      "publishedBy": "6650f1c2a9e4b1d2c3f40a30",
                      "createdBy": "6650f1c2a9e4b1d2c3f40a30",
                      "heldByPause": false,
                      "createdAt": "2026-11-02T09:30:00.000Z",
                      "updatedAt": "2026-11-02T09:30:00.000Z"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks release:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postReleasesReleases",
        "tags": [
          "Releases"
        ],
        "summary": "Creates a release",
        "description": "Creates a release. Permission: release:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "environmentId": {
                    "type": "string",
                    "description": "The environment's id, as text."
                  },
                  "name": {
                    "type": "string"
                  },
                  "description": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 2000
                  },
                  "scheduledAt": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "When to publish it, ISO 8601 in the future. Leave it out to publish by hand."
                  }
                },
                "required": [
                  "environmentId",
                  "name"
                ]
              },
              "example": {
                "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                "name": "Winter 2026 trips",
                "scheduledAt": "2026-12-01T08:00:00Z"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The release.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Release"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "_id": "6650f1c2a9e4b1d2c3f40a47",
                    "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                    "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "targetEnvironmentId": "6650f1c2a9e4b1d2c3f40a63",
                    "name": "Winter 2026 trips",
                    "description": "Six days of paddling between the peaks of Lofoten.",
                    "status": "scheduled",
                    "items": [
                      {
                        "contentId": "6650f1c2a9e4b1d2c3f40a21",
                        "action": "publish",
                        "regionId": "6650f1c2a9e4b1d2c3f40a17",
                        "localeId": "6650f1c2a9e4b1d2c3f40a18",
                        "includeChildren": false,
                        "addedAt": "2026-11-02T09:30:00.000Z",
                        "addedBy": "6650f1c2a9e4b1d2c3f40a30",
                        "outcome": {
                          "status": "published",
                          "reason": null
                        }
                      }
                    ],
                    "scheduledAt": "2026-11-02T09:30:00.000Z",
                    "publishedAt": "2026-11-02T09:30:00.000Z",
                    "publishedBy": "6650f1c2a9e4b1d2c3f40a30",
                    "createdBy": "6650f1c2a9e4b1d2c3f40a30",
                    "heldByPause": false,
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or an empty name, or a scheduledAt that isn't a date or is in the past.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks release:manage, or the plan has no releases.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/releases/{releaseId}": {
      "delete": {
        "operationId": "deleteReleasesReleasesByReleaseId",
        "tags": [
          "Releases"
        ],
        "summary": "Deletes it",
        "description": "Deletes it. Permission: release:delete.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "releaseId",
            "in": "path",
            "required": true,
            "description": "The release's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks release:delete, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such release, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Release not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "Only open or scheduled releases can change.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchReleasesReleasesByReleaseId",
        "tags": [
          "Releases"
        ],
        "summary": "Renames or reschedules it",
        "description": "Renames or reschedules it. scheduledAt: null unschedules it. Permission: release:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "releaseId",
            "in": "path",
            "required": true,
            "description": "The release's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string"
                  },
                  "scheduledAt": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "A new time, or null to unschedule it."
                  }
                }
              },
              "example": {
                "scheduledAt": "2026-12-02T08:00:00Z"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The release.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Release"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "_id": "6650f1c2a9e4b1d2c3f40a47",
                    "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                    "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "targetEnvironmentId": "6650f1c2a9e4b1d2c3f40a63",
                    "name": "Winter 2026 trips",
                    "description": "Six days of paddling between the peaks of Lofoten.",
                    "status": "scheduled",
                    "items": [
                      {
                        "contentId": "6650f1c2a9e4b1d2c3f40a21",
                        "action": "publish",
                        "regionId": "6650f1c2a9e4b1d2c3f40a17",
                        "localeId": "6650f1c2a9e4b1d2c3f40a18",
                        "includeChildren": false,
                        "addedAt": "2026-11-02T09:30:00.000Z",
                        "addedBy": "6650f1c2a9e4b1d2c3f40a30",
                        "outcome": {
                          "status": "published",
                          "reason": null
                        }
                      }
                    ],
                    "scheduledAt": "2026-11-02T09:30:00.000Z",
                    "publishedAt": "2026-11-02T09:30:00.000Z",
                    "publishedBy": "6650f1c2a9e4b1d2c3f40a30",
                    "createdBy": "6650f1c2a9e4b1d2c3f40a30",
                    "heldByPause": false,
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or an empty name, or a scheduledAt that isn't a date or is in the past.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks release:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such release, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Release not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "Only open or scheduled releases can change.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/releases/{releaseId}/cancel": {
      "post": {
        "operationId": "postReleasesReleasesByReleaseIdCancel",
        "tags": [
          "Releases"
        ],
        "summary": "Cancels it",
        "description": "Cancels it. Permission: release:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "releaseId",
            "in": "path",
            "required": true,
            "description": "The release's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks release:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such release, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Release not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "Only open or scheduled releases can change.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/releases/{releaseId}/items/{contentId}": {
      "delete": {
        "operationId": "deleteReleasesReleasesByReleaseIdItemsByContentId",
        "tags": [
          "Releases"
        ],
        "summary": "Takes a page out",
        "description": "Takes a page out. Permission: release:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "releaseId",
            "in": "path",
            "required": true,
            "description": "The release's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks release:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "Only open or scheduled releases can change.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "put": {
        "operationId": "putReleasesReleasesByReleaseIdItemsByContentId",
        "tags": [
          "Releases"
        ],
        "summary": "Adds a page, or changes what happens to it: { \"action\": \"publish\" } or \"unpublish\"",
        "description": "Adds a page, or changes what happens to it: { \"action\": \"publish\" } or \"unpublish\". Permission: release:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "releaseId",
            "in": "path",
            "required": true,
            "description": "The release's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "contentId",
            "in": "path",
            "required": true,
            "description": "The content item's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a21"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "action": {
                    "type": "string",
                    "description": "Anything but unpublish counts as publish.",
                    "enum": [
                      "publish",
                      "unpublish"
                    ]
                  }
                },
                "required": []
              },
              "example": {
                "action": "publish"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The release.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Release"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "_id": "6650f1c2a9e4b1d2c3f40a47",
                    "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                    "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "targetEnvironmentId": "6650f1c2a9e4b1d2c3f40a63",
                    "name": "Winter 2026 trips",
                    "description": "Six days of paddling between the peaks of Lofoten.",
                    "status": "scheduled",
                    "items": [
                      {
                        "contentId": "6650f1c2a9e4b1d2c3f40a21",
                        "action": "publish",
                        "regionId": "6650f1c2a9e4b1d2c3f40a17",
                        "localeId": "6650f1c2a9e4b1d2c3f40a18",
                        "includeChildren": false,
                        "addedAt": "2026-11-02T09:30:00.000Z",
                        "addedBy": "6650f1c2a9e4b1d2c3f40a30",
                        "outcome": {
                          "status": "published",
                          "reason": null
                        }
                      }
                    ],
                    "scheduledAt": "2026-11-02T09:30:00.000Z",
                    "publishedAt": "2026-11-02T09:30:00.000Z",
                    "publishedBy": "6650f1c2a9e4b1d2c3f40a30",
                    "createdBy": "6650f1c2a9e4b1d2c3f40a30",
                    "heldByPause": false,
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or unpublishing a page that isn't published.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks release:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such content item, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Content not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "Only open or scheduled releases can change.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/releases/{releaseId}/publish": {
      "post": {
        "operationId": "postReleasesReleasesByReleaseIdPublish",
        "tags": [
          "Releases"
        ],
        "summary": "Publishes it now",
        "description": "Publishes it now. Permission: release:publish.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "releaseId",
            "in": "path",
            "required": true,
            "description": "The release's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "responses": {
          "200": {
            "description": "{ release, outcome: { published, unpublished, failed } }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "release": {
                          "$ref": "#/components/schemas/Release"
                        },
                        "outcome": {
                          "type": "object",
                          "properties": {
                            "published": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "description": "An id."
                              },
                              "description": "Pages published."
                            },
                            "unpublished": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "description": "An id."
                              },
                              "description": "Pages taken off the website."
                            },
                            "failed": {
                              "type": "array",
                              "items": {
                                "type": "object",
                                "properties": {
                                  "contentId": {
                                    "type": "string",
                                    "description": "An id."
                                  },
                                  "reason": {
                                    "type": "string"
                                  }
                                },
                                "required": [
                                  "contentId",
                                  "reason"
                                ]
                              }
                            }
                          },
                          "required": [
                            "published",
                            "unpublished",
                            "failed"
                          ]
                        }
                      },
                      "required": [
                        "release",
                        "outcome"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "release": {
                      "_id": "6650f1c2a9e4b1d2c3f40a40",
                      "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                      "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "targetEnvironmentId": "6650f1c2a9e4b1d2c3f40a63",
                      "name": "Lofoten sea kayaking",
                      "description": "Six days of paddling between the peaks of Lofoten.",
                      "status": "open",
                      "items": [
                        {
                          "contentId": "6650f1c2a9e4b1d2c3f40a21",
                          "action": "publish",
                          "regionId": "6650f1c2a9e4b1d2c3f40a17",
                          "localeId": "6650f1c2a9e4b1d2c3f40a18",
                          "includeChildren": false,
                          "addedAt": "2026-11-02T09:30:00.000Z",
                          "addedBy": "6650f1c2a9e4b1d2c3f40a30",
                          "outcome": {
                            "status": "published",
                            "reason": null
                          }
                        }
                      ],
                      "scheduledAt": "2026-11-02T09:30:00.000Z",
                      "publishedAt": "2026-11-02T09:30:00.000Z",
                      "publishedBy": "6650f1c2a9e4b1d2c3f40a30",
                      "createdBy": "6650f1c2a9e4b1d2c3f40a30",
                      "heldByPause": false,
                      "createdAt": "2026-11-02T09:30:00.000Z",
                      "updatedAt": "2026-11-02T09:30:00.000Z"
                    },
                    "outcome": {
                      "published": [
                        "…"
                      ],
                      "unpublished": [
                        "…"
                      ],
                      "failed": [
                        {
                          "contentId": "6650f1c2a9e4b1d2c3f40a21",
                          "reason": "…"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The release is empty.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks release:publish, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such release, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Release not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "It isn't open or scheduled, or it's being published already.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/reviewers": {
      "get": {
        "operationId": "getReviewsReviewers",
        "tags": [
          "Reviews"
        ],
        "summary": "Who can be asked to review",
        "description": "Who can be asked to review. Permission: content:update.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "[{ userId, name, email, roleName, role, canApprove, invited }].",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "userId": {
                            "type": "string",
                            "description": "An id."
                          },
                          "name": {
                            "type": "string"
                          },
                          "email": {
                            "type": "string"
                          },
                          "roleName": {
                            "type": "string"
                          },
                          "role": {
                            "type": "string"
                          },
                          "canApprove": {
                            "type": "boolean"
                          },
                          "invited": {
                            "type": "boolean",
                            "description": "Hasn't accepted the invitation yet."
                          }
                        },
                        "required": [
                          "userId",
                          "name",
                          "email",
                          "roleName",
                          "role",
                          "canApprove",
                          "invited"
                        ]
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "userId": "6650f1c2a9e4b1d2c3f40a30",
                      "name": "Lofoten sea kayaking",
                      "email": "ingrid.berg@northwilds.com",
                      "roleName": "…",
                      "role": "…",
                      "canApprove": false,
                      "invited": false
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:update.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/reviews": {
      "get": {
        "operationId": "getReviewsReviews",
        "tags": [
          "Reviews"
        ],
        "summary": "Reviews",
        "description": "Reviews. status is open (default) or decided; mine=true. Up to 100. Permission: content:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "status",
            "in": "query",
            "required": false,
            "description": "open (the default) or decided.",
            "schema": {
              "type": "string",
              "enum": [
                "open",
                "decided"
              ]
            }
          },
          {
            "name": "mine",
            "in": "query",
            "required": false,
            "description": "true for reviews you sent or were asked to do.",
            "schema": {
              "type": "string",
              "enum": [
                "true",
                "false"
              ]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List of reviews.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Review"
                      },
                      "description": "Up to 100."
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a46",
                      "contentId": "6650f1c2a9e4b1d2c3f40a21",
                      "contentName": "Lofoten sea kayaking",
                      "contentUrl": "/trips/lofoten-sea-kayaking",
                      "contentType": "trip",
                      "region": "Norway",
                      "locale": "Norsk",
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "regionId": "6650f1c2a9e4b1d2c3f40a17",
                      "localeId": "6650f1c2a9e4b1d2c3f40a18",
                      "version": 12,
                      "status": "pending",
                      "steps": [
                        {
                          "key": "lofoten",
                          "name": "Lofoten sea kayaking",
                          "status": "pending",
                          "decidedBy": "6650f1c2a9e4b1d2c3f40a30",
                          "decidedRole": null,
                          "decidedAt": "2026-11-02T09:30:00.000Z",
                          "comment": null,
                          "who": null
                        }
                      ],
                      "message": null,
                      "reviewers": [
                        "…"
                      ],
                      "publishOnApproval": true,
                      "submittedBy": "Ingrid Berg",
                      "sentByAgent": null,
                      "draftedByAi": null,
                      "submittedAt": "2026-11-02T09:30:00.000Z",
                      "decidedAt": "2026-11-02T09:30:00.000Z",
                      "publishedAt": "2026-11-02T09:30:00.000Z",
                      "stale": false
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/reviews/{reviewId}": {
      "get": {
        "operationId": "getReviewsReviewsByReviewId",
        "tags": [
          "Reviews"
        ],
        "summary": "One review, with its changes and comments",
        "description": "One review, with its changes and comments. Permission: content:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "reviewId",
            "in": "path",
            "required": true,
            "description": "The review's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "200": {
            "description": "The review.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string",
                          "description": "An id."
                        },
                        "contentId": {
                          "type": "string",
                          "description": "An id."
                        },
                        "contentName": {
                          "type": "string"
                        },
                        "contentUrl": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "contentType": {
                          "type": "string"
                        },
                        "region": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "locale": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "environmentId": {
                          "type": "string",
                          "description": "An id."
                        },
                        "regionId": {
                          "type": "string",
                          "description": "An id."
                        },
                        "localeId": {
                          "type": "string",
                          "description": "An id."
                        },
                        "version": {
                          "type": "integer",
                          "description": "The draft version sent."
                        },
                        "status": {
                          "type": "string",
                          "enum": [
                            "pending",
                            "approved",
                            "rejected",
                            "withdrawn",
                            "superseded"
                          ]
                        },
                        "steps": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "key": {
                                "type": "string"
                              },
                              "name": {
                                "type": "string"
                              },
                              "status": {
                                "type": "string",
                                "enum": [
                                  "pending",
                                  "approved",
                                  "rejected"
                                ]
                              },
                              "decidedBy": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              },
                              "decidedRole": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              },
                              "decidedAt": {
                                "type": [
                                  "string",
                                  "null"
                                ],
                                "format": "date-time"
                              },
                              "comment": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              },
                              "who": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              }
                            },
                            "required": [
                              "key",
                              "name",
                              "status",
                              "decidedBy",
                              "decidedRole",
                              "decidedAt",
                              "comment",
                              "who"
                            ]
                          }
                        },
                        "message": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "reviewers": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "description": "An id."
                          }
                        },
                        "publishOnApproval": {
                          "type": "boolean"
                        },
                        "submittedBy": {
                          "type": "string"
                        },
                        "sentByAgent": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "draftedByAi": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "submittedAt": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "decidedAt": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "format": "date-time"
                        },
                        "publishedAt": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "format": "date-time"
                        },
                        "stale": {
                          "type": "boolean",
                          "description": "The page changed after it was sent."
                        },
                        "changes": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "area": {
                                "type": "string",
                                "enum": [
                                  "field",
                                  "seo",
                                  "component"
                                ]
                              },
                              "key": {
                                "type": "string"
                              },
                              "type": {
                                "type": "string"
                              },
                              "change": {
                                "type": "string",
                                "enum": [
                                  "added",
                                  "removed",
                                  "changed"
                                ]
                              },
                              "fields": {
                                "type": "array",
                                "items": {
                                  "type": "string"
                                }
                              }
                            },
                            "required": [
                              "area",
                              "key",
                              "change"
                            ]
                          },
                          "description": "What the draft changes."
                        },
                        "isNew": {
                          "type": "boolean",
                          "description": "The page has never been published."
                        },
                        "comments": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "string",
                                "description": "An id."
                              },
                              "author": {
                                "type": "string"
                              },
                              "body": {
                                "type": "string"
                              },
                              "componentId": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              },
                              "createdAt": {
                                "type": "string",
                                "format": "date-time"
                              }
                            },
                            "required": [
                              "id",
                              "author",
                              "body",
                              "componentId",
                              "createdAt"
                            ]
                          }
                        },
                        "canDecide": {
                          "type": "boolean"
                        },
                        "decideBlocked": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "description": "Why the token's person can't decide, such as their own changes."
                        },
                        "decideBlockedWording": {
                          "description": "The same as a translation key.",
                          "anyOf": [
                            {},
                            {
                              "type": "null"
                            }
                          ]
                        },
                        "canWithdraw": {
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "id",
                        "contentId",
                        "contentName",
                        "contentUrl",
                        "contentType",
                        "region",
                        "locale",
                        "environmentId",
                        "regionId",
                        "localeId",
                        "version",
                        "status",
                        "steps",
                        "message",
                        "reviewers",
                        "publishOnApproval",
                        "submittedBy",
                        "sentByAgent",
                        "draftedByAi",
                        "submittedAt",
                        "decidedAt",
                        "publishedAt",
                        "stale",
                        "changes",
                        "isNew",
                        "comments",
                        "canDecide",
                        "decideBlocked",
                        "decideBlockedWording",
                        "canWithdraw"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a40",
                    "contentId": "6650f1c2a9e4b1d2c3f40a21",
                    "contentName": "…",
                    "contentUrl": null,
                    "contentType": "…",
                    "region": null,
                    "locale": "nb-NO",
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "regionId": "6650f1c2a9e4b1d2c3f40a17",
                    "localeId": "6650f1c2a9e4b1d2c3f40a18",
                    "version": 12,
                    "status": "pending",
                    "steps": [
                      {
                        "key": "lofoten",
                        "name": "Lofoten sea kayaking",
                        "status": "pending",
                        "decidedBy": "6650f1c2a9e4b1d2c3f40a30",
                        "decidedRole": null,
                        "decidedAt": "2026-11-02T09:30:00.000Z",
                        "comment": null,
                        "who": null
                      }
                    ],
                    "message": null,
                    "reviewers": [
                      "…"
                    ],
                    "publishOnApproval": true,
                    "submittedBy": "6650f1c2a9e4b1d2c3f40a30",
                    "sentByAgent": null,
                    "draftedByAi": null,
                    "submittedAt": "2026-11-02T09:30:00.000Z",
                    "decidedAt": "2026-11-02T09:30:00.000Z",
                    "publishedAt": "2026-11-02T09:30:00.000Z",
                    "stale": false,
                    "changes": [
                      {
                        "area": "field",
                        "key": "lofoten",
                        "type": "…",
                        "change": "added",
                        "fields": [
                          "…"
                        ]
                      }
                    ],
                    "isNew": false,
                    "comments": [
                      {
                        "id": "6650f1c2a9e4b1d2c3f40a40",
                        "author": "Ingrid Berg",
                        "body": "…",
                        "componentId": null,
                        "createdAt": "2026-11-02T09:30:00.000Z"
                      }
                    ],
                    "canDecide": true,
                    "decideBlocked": null,
                    "decideBlockedWording": null,
                    "canWithdraw": false
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "The review is in a region or language the token's person can't read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such review, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Review not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/reviews/{reviewId}/comments": {
      "post": {
        "operationId": "postReviewsReviewsByReviewIdComments",
        "tags": [
          "Reviews"
        ],
        "summary": "Comments on a review",
        "description": "Comments on a review. Permission: content:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "reviewId",
            "in": "path",
            "required": true,
            "description": "The review's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "body": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 4000
                  },
                  "componentId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 100,
                    "default": null,
                    "description": "A block the comment is about."
                  }
                },
                "required": [
                  "body"
                ]
              },
              "example": {
                "body": "Could the second paragraph name the fjords?"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The comment.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string",
                          "description": "An id."
                        },
                        "body": {
                          "type": "string"
                        },
                        "componentId": {
                          "type": [
                            "string",
                            "null"
                          ]
                        },
                        "createdAt": {
                          "type": "string",
                          "format": "date-time"
                        }
                      },
                      "required": [
                        "id",
                        "body",
                        "componentId",
                        "createdAt"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a40",
                    "body": "…",
                    "componentId": null,
                    "createdAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:read, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such review, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Review not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/reviews/{reviewId}/decision": {
      "post": {
        "operationId": "postReviewsReviewsByReviewIdDecision",
        "tags": [
          "Reviews"
        ],
        "summary": "Approves or rejects",
        "description": "Approves or rejects. Permission: content:approve.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "reviewId",
            "in": "path",
            "required": true,
            "description": "The review's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "decision": {
                    "type": "string",
                    "enum": [
                      "approve",
                      "reject"
                    ]
                  },
                  "comment": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 2000,
                    "default": null,
                    "description": "Required to reject: what needs to change."
                  }
                },
                "required": [
                  "decision"
                ]
              },
              "example": {
                "decision": "approve",
                "comment": "Looks good."
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The review.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Review"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a46",
                    "contentId": "6650f1c2a9e4b1d2c3f40a21",
                    "contentName": "Lofoten sea kayaking",
                    "contentUrl": "/trips/lofoten-sea-kayaking",
                    "contentType": "trip",
                    "region": "Norway",
                    "locale": "Norsk",
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "regionId": "6650f1c2a9e4b1d2c3f40a17",
                    "localeId": "6650f1c2a9e4b1d2c3f40a18",
                    "version": 12,
                    "status": "pending",
                    "steps": [
                      {
                        "key": "lofoten",
                        "name": "Lofoten sea kayaking",
                        "status": "pending",
                        "decidedBy": "6650f1c2a9e4b1d2c3f40a30",
                        "decidedRole": null,
                        "decidedAt": "2026-11-02T09:30:00.000Z",
                        "comment": null,
                        "who": null
                      }
                    ],
                    "message": null,
                    "reviewers": [
                      "…"
                    ],
                    "publishOnApproval": true,
                    "submittedBy": "Ingrid Berg",
                    "sentByAgent": null,
                    "draftedByAi": null,
                    "submittedAt": "2026-11-02T09:30:00.000Z",
                    "decidedAt": "2026-11-02T09:30:00.000Z",
                    "publishedAt": "2026-11-02T09:30:00.000Z",
                    "stale": false
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:approve, or your own changes.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such review, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Review not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "It isn't open, the page changed after it was sent, or someone else decided first.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/reviews/{reviewId}/withdraw": {
      "post": {
        "operationId": "postReviewsReviewsByReviewIdWithdraw",
        "tags": [
          "Reviews"
        ],
        "summary": "Withdraws a review",
        "description": "Withdraws a review. Permission: Its sender, or content:approve.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "reviewId",
            "in": "path",
            "required": true,
            "description": "The review's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "responses": {
          "200": {
            "description": "The review.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Review"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a46",
                    "contentId": "6650f1c2a9e4b1d2c3f40a21",
                    "contentName": "Lofoten sea kayaking",
                    "contentUrl": "/trips/lofoten-sea-kayaking",
                    "contentType": "trip",
                    "region": "Norway",
                    "locale": "Norsk",
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "regionId": "6650f1c2a9e4b1d2c3f40a17",
                    "localeId": "6650f1c2a9e4b1d2c3f40a18",
                    "version": 12,
                    "status": "pending",
                    "steps": [
                      {
                        "key": "lofoten",
                        "name": "Lofoten sea kayaking",
                        "status": "pending",
                        "decidedBy": "6650f1c2a9e4b1d2c3f40a30",
                        "decidedRole": null,
                        "decidedAt": "2026-11-02T09:30:00.000Z",
                        "comment": null,
                        "who": null
                      }
                    ],
                    "message": null,
                    "reviewers": [
                      "…"
                    ],
                    "publishOnApproval": true,
                    "submittedBy": "Ingrid Berg",
                    "sentByAgent": null,
                    "draftedByAi": null,
                    "submittedAt": "2026-11-02T09:30:00.000Z",
                    "decidedAt": "2026-11-02T09:30:00.000Z",
                    "publishedAt": "2026-11-02T09:30:00.000Z",
                    "stale": false
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks Its sender, or content:approve, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such review, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Review not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "It isn't open.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/seo": {
      "get": {
        "operationId": "getSEOAndAccessibilitySettingsSeo",
        "tags": [
          "SEO and accessibility settings"
        ],
        "summary": "The space's search settings",
        "description": "The space's search settings. Permission: space:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "The settings.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/SiteSeo"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "xDefaultRegion": null,
                    "organisationName": null,
                    "socialProfiles": [
                      "…"
                    ],
                    "robotsTxt": null,
                    "titleTemplate": null,
                    "defaultDescription": null,
                    "defaultImage": null,
                    "twitterHandle": null,
                    "verification": {
                      "google": null,
                      "bing": null
                    },
                    "websitePaths": [
                      "…"
                    ],
                    "indexNow": false
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "put": {
        "operationId": "putSEOAndAccessibilitySettingsSeo",
        "tags": [
          "SEO and accessibility settings"
        ],
        "summary": "Replaces them",
        "description": "Replaces them. Permission: seo:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": false,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "xDefaultRegion": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 60,
                    "default": null
                  },
                  "organisationName": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 120,
                    "default": null
                  },
                  "socialProfiles": {
                    "default": [],
                    "maxItems": 20,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "format": "uri"
                    }
                  },
                  "robotsTxt": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 20000,
                    "default": null
                  },
                  "titleTemplate": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 200,
                    "default": null
                  },
                  "defaultDescription": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 300,
                    "default": null
                  },
                  "defaultImage": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "pattern": "^[0-9a-f]{24}$",
                    "default": null,
                    "description": "A media id."
                  },
                  "twitterHandle": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "pattern": "^@?[A-Za-z0-9_]{1,15}$",
                    "default": null
                  },
                  "verification": {
                    "default": {
                      "google": null,
                      "bing": null
                    },
                    "type": "object",
                    "properties": {
                      "google": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 200,
                        "default": null
                      },
                      "bing": {
                        "type": [
                          "string",
                          "null"
                        ],
                        "maxLength": 200,
                        "default": null
                      }
                    }
                  },
                  "indexNow": {
                    "default": true,
                    "type": "boolean"
                  },
                  "websitePaths": {
                    "maxItems": 100,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^\\/[^\\s?#]*$"
                    },
                    "description": "Kept when left out. Everything else left out is cleared."
                  }
                }
              },
              "example": {
                "organisationName": "Northwilds",
                "titleTemplate": "%s | Northwilds",
                "defaultDescription": "Small-group trips and tested gear for the far north.",
                "socialProfiles": [
                  "https://www.instagram.com/northwilds"
                ],
                "xDefaultRegion": "norway"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The settings.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/SiteSeo"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "xDefaultRegion": null,
                    "organisationName": null,
                    "socialProfiles": [
                      "…"
                    ],
                    "robotsTxt": null,
                    "titleTemplate": null,
                    "defaultDescription": null,
                    "defaultImage": null,
                    "twitterHandle": null,
                    "verification": {
                      "google": null,
                      "bing": null
                    },
                    "websitePaths": [
                      "…"
                    ],
                    "indexNow": false
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks seo:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "The default image isn't in the space's media.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/taxonomies": {
      "get": {
        "operationId": "getTaxonomiesTaxonomies",
        "tags": [
          "Taxonomies"
        ],
        "summary": "Every taxonomy",
        "description": "Every taxonomy. Permission: content:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "[{ id, key, name, description, termCount }].",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Taxonomy"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a48",
                      "key": "activity",
                      "name": "Activity",
                      "description": "What you do on the trip.",
                      "termCount": 4
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postTaxonomiesTaxonomies",
        "tags": [
          "Taxonomies"
        ],
        "summary": "Adds one: key, name, description",
        "description": "Adds one: key, name, description. Permission: schema:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "key": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 64,
                    "pattern": "^[a-zA-Z][a-zA-Z0-9_-]*$"
                  },
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "description": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 500
                  }
                },
                "required": [
                  "key",
                  "name"
                ]
              },
              "example": {
                "key": "activity",
                "name": "Activity",
                "description": "What you do on the trip."
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The new item.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Taxonomy"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a48",
                    "key": "activity",
                    "name": "Activity",
                    "description": "What you do on the trip.",
                    "termCount": 4
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body is empty or isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "A taxonomy with the key exists.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/taxonomies/{key}": {
      "delete": {
        "operationId": "deleteTaxonomiesTaxonomiesByKey",
        "tags": [
          "Taxonomies"
        ],
        "summary": "Deletes one with its terms",
        "description": "Deletes one with its terms. Permission: schema:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "key",
            "in": "path",
            "required": true,
            "description": "The key, such as trip, hero or activity.",
            "schema": {
              "type": "string"
            },
            "example": "trip"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such item with that key, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Taxonomy not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchTaxonomiesTaxonomiesByKey",
        "tags": [
          "Taxonomies"
        ],
        "summary": "Renames one",
        "description": "Renames one. Permission: schema:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "key",
            "in": "path",
            "required": true,
            "description": "The key, such as trip, hero or activity.",
            "schema": {
              "type": "string"
            },
            "example": "trip"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "description": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 500
                  }
                }
              },
              "example": {
                "name": "Activities"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The taxonomy.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Taxonomy"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a48",
                    "key": "activity",
                    "name": "Activity",
                    "description": "What you do on the trip.",
                    "termCount": 4
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body is empty or isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such item with that key, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Taxonomy not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/taxonomies/{key}/reorder": {
      "post": {
        "operationId": "postTaxonomiesTaxonomiesByKeyReorder",
        "tags": [
          "Taxonomies"
        ],
        "summary": "Puts terms in order: { \"order\": [ids] }",
        "description": "Puts terms in order: { \"order\": [ids] }. Permission: schema:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "key",
            "in": "path",
            "required": true,
            "description": "The key, such as trip, hero or activity.",
            "schema": {
              "type": "string"
            },
            "example": "trip"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "order": {
                    "type": "array",
                    "items": {
                      "type": "string",
                      "description": "An id."
                    },
                    "description": "Every term's id, in the new order."
                  }
                },
                "required": [
                  "order"
                ]
              },
              "example": {
                "order": [
                  "6650f1c2a9e4b1d2c3f40a41",
                  "6650f1c2a9e4b1d2c3f40a40"
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The terms.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Term"
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a44",
                      "value": "kayaking",
                      "label": "Kayaking",
                      "labels": {
                        "nb-NO": "Padling"
                      },
                      "regions": {},
                      "sortOrder": 1
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The body is empty or isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such item with that key, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Taxonomy not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/taxonomies/{key}/terms": {
      "get": {
        "operationId": "getTaxonomiesTaxonomiesByKeyTerms",
        "tags": [
          "Taxonomies"
        ],
        "summary": "Its terms, in order",
        "description": "Its terms, in order. Permission: content:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "key",
            "in": "path",
            "required": true,
            "description": "The key, such as trip, hero or activity.",
            "schema": {
              "type": "string"
            },
            "example": "trip"
          }
        ],
        "responses": {
          "200": {
            "description": "[{ id, value, label, labels, regions, sortOrder }].",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Term"
                      },
                      "description": "In order."
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a44",
                      "value": "kayaking",
                      "label": "Kayaking",
                      "labels": {
                        "nb-NO": "Padling"
                      },
                      "regions": {},
                      "sortOrder": 1
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such item with that key, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Taxonomy not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postTaxonomiesTaxonomiesByKeyTerms",
        "tags": [
          "Taxonomies"
        ],
        "summary": "Adds a term",
        "description": "Adds a term. Permission: schema:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "key",
            "in": "path",
            "required": true,
            "description": "The key, such as trip, hero or activity.",
            "schema": {
              "type": "string"
            },
            "example": "trip"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "value": {
                    "type": "string",
                    "description": "A slug, such as kayaking."
                  },
                  "label": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "labels": {
                    "default": {},
                    "type": "object",
                    "additionalProperties": {
                      "type": "string",
                      "maxLength": 200
                    },
                    "description": "By language code, such as { \"nb-NO\": \"Padling\" }."
                  },
                  "regions": {
                    "default": {},
                    "type": "object",
                    "additionalProperties": {
                      "type": "object",
                      "properties": {
                        "hidden": {
                          "type": "boolean"
                        },
                        "labels": {
                          "type": "object",
                          "additionalProperties": {
                            "type": "string",
                            "maxLength": 200
                          }
                        }
                      }
                    },
                    "description": "Overrides by region key, each { hidden, labels }: hidden leaves the term out for that region, and labels by language code replace the term's labels there, such as { \"germany\": { \"hidden\": true } }."
                  },
                  "sortOrder": {
                    "default": 0,
                    "type": "integer"
                  }
                },
                "required": [
                  "value",
                  "label"
                ]
              },
              "example": {
                "value": "kayaking",
                "label": "Kayaking",
                "labels": {
                  "nb-NO": "Padling"
                },
                "regions": {
                  "germany": {
                    "hidden": true
                  }
                }
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The new item.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Term"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a44",
                    "value": "kayaking",
                    "label": "Kayaking",
                    "labels": {
                      "nb-NO": "Padling"
                    },
                    "regions": {},
                    "sortOrder": 1
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body is empty or isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such item with that key, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Taxonomy not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "The taxonomy has a term with the value.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/taxonomies/{key}/terms/{termId}": {
      "delete": {
        "operationId": "deleteTaxonomiesTaxonomiesByKeyTermsByTermId",
        "tags": [
          "Taxonomies"
        ],
        "summary": "Deletes a term",
        "description": "Deletes a term. Permission: schema:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "key",
            "in": "path",
            "required": true,
            "description": "The key, such as trip, hero or activity.",
            "schema": {
              "type": "string"
            },
            "example": "trip"
          },
          {
            "name": "termId",
            "in": "path",
            "required": true,
            "description": "The term's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such term, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Term not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchTaxonomiesTaxonomiesByKeyTermsByTermId",
        "tags": [
          "Taxonomies"
        ],
        "summary": "Changes a term",
        "description": "Changes a term. Permission: schema:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "key",
            "in": "path",
            "required": true,
            "description": "The key, such as trip, hero or activity.",
            "schema": {
              "type": "string"
            },
            "example": "trip"
          },
          {
            "name": "termId",
            "in": "path",
            "required": true,
            "description": "The term's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "value": {
                    "type": "string"
                  },
                  "label": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200
                  },
                  "labels": {
                    "type": "object",
                    "additionalProperties": {
                      "type": "string",
                      "maxLength": 200
                    }
                  },
                  "regions": {
                    "type": "object",
                    "additionalProperties": {
                      "type": "object",
                      "properties": {
                        "hidden": {
                          "type": "boolean"
                        },
                        "labels": {
                          "type": "object",
                          "additionalProperties": {
                            "type": "string",
                            "maxLength": 200
                          }
                        }
                      }
                    },
                    "description": "Overrides by region key, each { hidden, labels }: hidden leaves the term out for that region, and labels by language code replace the term's labels there, such as { \"germany\": { \"hidden\": true } }. Replaces every region's overrides at once."
                  },
                  "sortOrder": {
                    "type": "integer"
                  }
                }
              },
              "example": {
                "label": "Sea kayaking",
                "regions": {
                  "norway": {
                    "labels": {
                      "nb-NO": "Havpadling"
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The term.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Term"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a44",
                    "value": "kayaking",
                    "label": "Kayaking",
                    "labels": {
                      "nb-NO": "Padling"
                    },
                    "regions": {},
                    "sortOrder": 1
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body is empty or isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such term, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Term not found"
                  }
                }
              }
            }
          },
          "409": {
            "description": "The taxonomy has a term with the value.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "conflict",
                    "message": "That value is already taken"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/taxonomies/{key}/export": {
      "get": {
        "operationId": "getTaxonomiesTaxonomiesByKeyExport",
        "tags": [
          "Taxonomies"
        ],
        "summary": "Downloads its terms as CSV",
        "description": "Downloads its terms as CSV. Permission: content:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "key",
            "in": "path",
            "required": true,
            "description": "The key, such as trip, hero or activity.",
            "schema": {
              "type": "string"
            },
            "example": "trip"
          }
        ],
        "responses": {
          "200": {
            "description": "UTF-8 with a byte order mark. The columns value, label, label:<language> for every language, then region:<region>:hidden and region:<region>:label:<language> for every region and its languages, one row per term in order.",
            "content": {
              "text/csv": {
                "schema": {
                  "type": "string"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks content:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such item with that key, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Taxonomy not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/taxonomies/{key}/import": {
      "post": {
        "operationId": "postTaxonomiesTaxonomiesByKeyImport",
        "tags": [
          "Taxonomies"
        ],
        "summary": "Adds or changes terms from CSV, or Storyblok's datasource CSV",
        "description": "Adds or changes terms from CSV, or Storyblok's datasource CSV. Permission: schema:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "key",
            "in": "path",
            "required": true,
            "description": "The key, such as trip, hero or activity.",
            "schema": {
              "type": "string"
            },
            "example": "trip"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "csv": {
                    "type": "string",
                    "maxLength": 5000000,
                    "description": "The file's text, comma or semicolon separated. The first row names the columns, as in the export; columns left out are left alone. Storyblok's datasource export (name, value, dimension_value) works too. Up to 5,000 rows."
                  },
                  "apply": {
                    "default": false,
                    "type": "boolean",
                    "description": "false (the default) only reports what would happen. true does it."
                  },
                  "removeMissing": {
                    "default": false,
                    "type": "boolean",
                    "description": "true deletes the terms the file doesn't list."
                  },
                  "dimension": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "maxLength": 200,
                    "description": "The column Storyblok's dimension_value fills, such as label:de-DE or region:germany:label:de-DE."
                  }
                },
                "required": [
                  "csv"
                ]
              },
              "example": {
                "csv": "value,label,label:nb-NO,region:germany:hidden\nhiking,Hiking,Fotturer,\nski-touring,Ski touring,Topptur,yes",
                "apply": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "What was or would be done.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "applied": {
                          "type": "boolean"
                        },
                        "format": {
                          "type": "string",
                          "enum": [
                            "orbit",
                            "storyblok"
                          ]
                        },
                        "columns": {
                          "type": "array",
                          "items": {
                            "type": "string"
                          },
                          "description": "The columns read, by their canonical names."
                        },
                        "problems": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "key": {
                                "type": "string"
                              },
                              "values": {
                                "type": "object",
                                "additionalProperties": {}
                              },
                              "message": {
                                "type": "string"
                              }
                            },
                            "required": [
                              "key",
                              "message"
                            ]
                          },
                          "description": "Problems with the file as a whole, such as an unknown language. Nothing is imported while there are any."
                        },
                        "rows": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "line": {
                                "type": [
                                  "integer",
                                  "null"
                                ],
                                "description": "The file's line, or null for a term the file leaves out."
                              },
                              "value": {
                                "type": "string"
                              },
                              "label": {
                                "type": "string"
                              },
                              "outcome": {
                                "type": "string",
                                "enum": [
                                  "add",
                                  "change",
                                  "same",
                                  "remove",
                                  "error"
                                ]
                              },
                              "changes": {
                                "type": "array",
                                "items": {
                                  "type": "string"
                                },
                                "description": "The columns that change."
                              },
                              "problem": {
                                "type": [
                                  "object",
                                  "null"
                                ],
                                "properties": {
                                  "key": {
                                    "type": "string"
                                  },
                                  "values": {
                                    "type": "object",
                                    "additionalProperties": {}
                                  }
                                },
                                "required": [
                                  "key"
                                ]
                              },
                              "message": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              }
                            },
                            "required": [
                              "line",
                              "value",
                              "label",
                              "outcome",
                              "changes",
                              "problem",
                              "message"
                            ]
                          }
                        },
                        "counts": {
                          "type": "object",
                          "properties": {
                            "add": {
                              "type": "integer"
                            },
                            "change": {
                              "type": "integer"
                            },
                            "same": {
                              "type": "integer"
                            },
                            "remove": {
                              "type": "integer"
                            },
                            "error": {
                              "type": "integer"
                            }
                          },
                          "required": [
                            "add",
                            "change",
                            "same",
                            "remove",
                            "error"
                          ]
                        }
                      },
                      "required": [
                        "applied",
                        "format",
                        "columns",
                        "problems",
                        "rows",
                        "counts"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "applied": false,
                    "format": "orbit",
                    "columns": [
                      "…"
                    ],
                    "problems": [
                      {
                        "key": "lofoten",
                        "values": {},
                        "message": "…"
                      }
                    ],
                    "rows": [
                      {
                        "line": 1,
                        "value": "…",
                        "label": "Kayaking",
                        "outcome": "add",
                        "changes": [
                          "…"
                        ],
                        "problem": {
                          "key": "lofoten",
                          "values": {}
                        },
                        "message": null
                      }
                    ],
                    "counts": {
                      "add": 1,
                      "change": 1,
                      "same": 1,
                      "remove": 1,
                      "error": 1
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks schema:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such item with that key, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Taxonomy not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "apply is true and the file has a problem as a whole.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/travel": {
      "get": {
        "operationId": "getConnectedSatellitesTravel",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Reads the travel Orbit connection: { connected, brandId }",
        "description": "Reads the travel Orbit connection: { connected, brandId }. Permission: space:update to change.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "The connection.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/TravelConnection"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "reachable": true,
                    "brands": [
                      {
                        "brandId": "6650f1c2a9e4b1d2c3f40a57",
                        "bookingSlug": "…",
                        "brandName": "Northwilds",
                        "logoUrl": null,
                        "siteUrl": "https://northwilds.com",
                        "locales": [
                          "nb-NO"
                        ],
                        "defaultLocale": "…"
                      }
                    ],
                    "site": {
                      "brandId": "6650f1c2a9e4b1d2c3f40a57",
                      "bookingSlug": "…",
                      "brandName": "Northwilds",
                      "logoUrl": null,
                      "siteUrl": "https://northwilds.com",
                      "locales": [
                        "nb-NO"
                      ],
                      "defaultLocale": "…"
                    },
                    "connection": {
                      "brandId": "6650f1c2a9e4b1d2c3f40a57",
                      "bookingSlug": "…",
                      "brandName": "Northwilds",
                      "siteUrl": "https://northwilds.com",
                      "connectedAt": "2026-11-02T09:30:00.000Z",
                      "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                    },
                    "canManage": true
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:update to change.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "put": {
        "operationId": "putConnectedSatellitesTravel",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Changes the travel Orbit connection: { connected, brandId }",
        "description": "Changes the travel Orbit connection: { connected, brandId }. Permission: space:update to change.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "connected": {
                    "type": "boolean"
                  },
                  "brandId": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "Which Travel Orbit brand the space shows."
                  }
                },
                "required": [
                  "connected"
                ]
              },
              "example": {
                "connected": true,
                "brandId": "northwilds"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "The connection.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/TravelConnection"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "reachable": true,
                    "brands": [
                      {
                        "brandId": "6650f1c2a9e4b1d2c3f40a57",
                        "bookingSlug": "…",
                        "brandName": "Northwilds",
                        "logoUrl": null,
                        "siteUrl": "https://northwilds.com",
                        "locales": [
                          "nb-NO"
                        ],
                        "defaultLocale": "…"
                      }
                    ],
                    "site": {
                      "brandId": "6650f1c2a9e4b1d2c3f40a57",
                      "bookingSlug": "…",
                      "brandName": "Northwilds",
                      "logoUrl": null,
                      "siteUrl": "https://northwilds.com",
                      "locales": [
                        "nb-NO"
                      ],
                      "defaultLocale": "…"
                    },
                    "connection": {
                      "brandId": "6650f1c2a9e4b1d2c3f40a57",
                      "bookingSlug": "…",
                      "brandName": "Northwilds",
                      "siteUrl": "https://northwilds.com",
                      "connectedAt": "2026-11-02T09:30:00.000Z",
                      "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                    },
                    "canManage": true
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or travel Orbit could not be reached, or no brand to connect.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:update to change, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/travel/destinations": {
      "get": {
        "operationId": "getConnectedSatellitesTravelDestinations",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Travel Orbit destinations",
        "description": "Travel Orbit destinations. A satellite that is not connected answers 400. Permission: Space access.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "locale",
            "in": "query",
            "required": false,
            "description": "The language to list in, such as nb-NO. Leave it out for the satellite's default.",
            "schema": {
              "type": "string"
            },
            "example": "nb-NO"
          }
        ],
        "responses": {
          "200": {
            "description": "List.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "code": {
                            "type": "string",
                            "description": "Such as NO."
                          },
                          "name": {
                            "type": "string"
                          },
                          "kind": {
                            "type": "string",
                            "enum": [
                              "country",
                              "continent"
                            ]
                          },
                          "continent": {
                            "type": "string"
                          },
                          "tripCount": {
                            "type": "integer"
                          }
                        },
                        "required": [
                          "code",
                          "name",
                          "kind",
                          "continent",
                          "tripCount"
                        ]
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "code": "nb-NO",
                      "name": "Lofoten sea kayaking",
                      "kind": "country",
                      "continent": "…",
                      "tripCount": 4
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The satellite is not connected to this space, or could not be reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks Space access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/travel/guides": {
      "get": {
        "operationId": "getConnectedSatellitesTravelGuides",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Travel Orbit guides",
        "description": "Travel Orbit guides. A satellite that is not connected answers 400. Permission: Space access.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "locale",
            "in": "query",
            "required": false,
            "description": "The language to list in, such as nb-NO. Leave it out for the satellite's default.",
            "schema": {
              "type": "string"
            },
            "example": "nb-NO"
          }
        ],
        "responses": {
          "200": {
            "description": "List.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "slug": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "role": {
                            "type": "string"
                          },
                          "image": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "tripCount": {
                            "type": "integer"
                          }
                        },
                        "required": [
                          "slug",
                          "name",
                          "role",
                          "image",
                          "tripCount"
                        ]
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "slug": "lofoten-sea-kayaking",
                      "name": "Lofoten sea kayaking",
                      "role": "…",
                      "image": null,
                      "tripCount": 4
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The satellite is not connected to this space, or could not be reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks Space access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/travel/trips": {
      "get": {
        "operationId": "getConnectedSatellitesTravelTrips",
        "tags": [
          "Connected satellites"
        ],
        "summary": "Travel Orbit trips",
        "description": "Travel Orbit trips. A satellite that is not connected answers 400. Permission: Space access.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "locale",
            "in": "query",
            "required": false,
            "description": "The language to list in, such as nb-NO. Leave it out for the satellite's default.",
            "schema": {
              "type": "string"
            },
            "example": "nb-NO"
          }
        ],
        "responses": {
          "200": {
            "description": "List.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string"
                          },
                          "name": {
                            "type": "string"
                          },
                          "summary": {
                            "type": "string"
                          },
                          "image": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "days": {
                            "type": [
                              "integer",
                              "null"
                            ]
                          },
                          "priceFrom": {
                            "type": [
                              "number",
                              "null"
                            ]
                          },
                          "currency": {
                            "type": "string"
                          },
                          "nextDeparture": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "description": "A date, YYYY-MM-DD."
                          },
                          "countries": {
                            "type": "array",
                            "items": {
                              "type": "string"
                            }
                          },
                          "departures": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "id": {
                                  "type": "string"
                                },
                                "startDate": {
                                  "type": "string"
                                },
                                "status": {
                                  "type": "string"
                                },
                                "seatsLeft": {
                                  "type": [
                                    "integer",
                                    "null"
                                  ]
                                }
                              },
                              "required": [
                                "id",
                                "startDate",
                                "status",
                                "seatsLeft"
                              ]
                            }
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "summary",
                          "image",
                          "days",
                          "priceFrom",
                          "currency",
                          "nextDeparture",
                          "countries",
                          "departures"
                        ]
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "name": "Lofoten sea kayaking",
                      "summary": "Six days of paddling between the peaks of Lofoten.",
                      "image": null,
                      "days": 1,
                      "priceFrom": 1,
                      "currency": "NOK",
                      "nextDeparture": null,
                      "countries": [
                        "…"
                      ],
                      "departures": [
                        {
                          "id": "6650f1c2a9e4b1d2c3f40a40",
                          "startDate": "…",
                          "status": "…",
                          "seatsLeft": 1
                        }
                      ]
                    }
                  ]
                }
              }
            }
          },
          "400": {
            "description": "The satellite is not connected to this space, or could not be reached.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks Space access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/webhooks": {
      "get": {
        "operationId": "getWebhooksWebhooks",
        "tags": [
          "Webhooks"
        ],
        "summary": "The space's webhooks, newest first",
        "description": "The space's webhooks, newest first. Permission: webhook:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "List of webhooks, without their secrets.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Webhook"
                      },
                      "description": "Newest first, without their secrets."
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "_id": "6650f1c2a9e4b1d2c3f40a47",
                      "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                      "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                      "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                      "name": "Rebuild northwilds.com",
                      "url": "https://northwilds.com/api/revalidate",
                      "events": [
                        "content.published"
                      ],
                      "enabled": true,
                      "headers": {},
                      "lastDeliveryAt": "2026-11-02T09:30:00.000Z",
                      "failureCount": 4,
                      "createdAt": "2026-11-02T09:30:00.000Z",
                      "updatedAt": "2026-11-02T09:30:00.000Z"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks webhook:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postWebhooksWebhooks",
        "tags": [
          "Webhooks"
        ],
        "summary": "Adds one",
        "description": "Adds one. Permission: webhook:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string"
                  },
                  "url": {
                    "type": "string",
                    "description": "HTTPS. Plain HTTP only for localhost. Redirects are not followed."
                  },
                  "events": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "At least one event name, such as content.published."
                  },
                  "environmentId": {
                    "description": "One environment, or null for every environment."
                  }
                },
                "required": [
                  "name",
                  "url",
                  "events"
                ]
              },
              "example": {
                "name": "Rebuild northwilds.com",
                "url": "https://northwilds.com/api/revalidate",
                "events": [
                  "content.published",
                  "content.unpublished"
                ],
                "environmentId": null
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "The new item and its secret.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "_id": {
                          "type": "string",
                          "description": "An id."
                        },
                        "organisationId": {
                          "type": "string",
                          "description": "An id."
                        },
                        "spaceId": {
                          "type": "string",
                          "description": "An id."
                        },
                        "environmentId": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "description": "null for every environment."
                        },
                        "name": {
                          "type": "string"
                        },
                        "url": {
                          "type": "string"
                        },
                        "events": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "description": "Such as content.published."
                          }
                        },
                        "enabled": {
                          "type": "boolean"
                        },
                        "headers": {
                          "type": "object",
                          "additionalProperties": {
                            "type": "string"
                          },
                          "description": "Headers sent with each delivery."
                        },
                        "lastDeliveryAt": {
                          "type": [
                            "string",
                            "null"
                          ],
                          "format": "date-time"
                        },
                        "failureCount": {
                          "type": "integer",
                          "description": "Failures in a row. At 20 the webhook is turned off."
                        },
                        "createdAt": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "updatedAt": {
                          "type": "string",
                          "format": "date-time"
                        },
                        "secret": {
                          "type": "string",
                          "description": "Signs each delivery, starting with whsec_. Shown only in this answer."
                        }
                      },
                      "required": [
                        "_id",
                        "organisationId",
                        "spaceId",
                        "environmentId",
                        "name",
                        "url",
                        "events",
                        "enabled",
                        "headers",
                        "lastDeliveryAt",
                        "failureCount",
                        "createdAt",
                        "updatedAt",
                        "secret"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "_id": "6650f1c2a9e4b1d2c3f40a40",
                    "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                    "spaceId": "6650f1c2a9e4b1d2c3f40a02",
                    "environmentId": "6650f1c2a9e4b1d2c3f40a13",
                    "name": "Lofoten sea kayaking",
                    "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                    "events": [
                      "…"
                    ],
                    "enabled": true,
                    "headers": {},
                    "lastDeliveryAt": "2026-11-02T09:30:00.000Z",
                    "failureCount": 4,
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z",
                    "secret": "whsec_…"
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or no name, a URL that isn't HTTPS, no events, or an event name it doesn't know.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks webhook:manage, or the plan's webhooks are used up.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "The environment isn't in this space.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "422": {
            "description": "The body doesn't match the schema. Each problem is in error.details.issues.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "validation_failed",
                    "message": "The request payload is invalid",
                    "details": {
                      "issues": [
                        {
                          "path": "name",
                          "message": "Required",
                          "code": "invalid_type"
                        }
                      ]
                    }
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/webhooks/{webhookId}": {
      "delete": {
        "operationId": "deleteWebhooksWebhooksByWebhookId",
        "tags": [
          "Webhooks"
        ],
        "summary": "Deletes it",
        "description": "Deletes it. Permission: webhook:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "webhookId",
            "in": "path",
            "required": true,
            "description": "The webhook's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "204": {
            "description": "Done, nothing to return."
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks webhook:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such webhook, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Webhook not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "get": {
        "operationId": "getWebhooksWebhooksByWebhookId",
        "tags": [
          "Webhooks"
        ],
        "summary": "Its last 50 deliveries",
        "description": "Its last 50 deliveries. Permission: webhook:read.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "webhookId",
            "in": "path",
            "required": true,
            "description": "The webhook's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          }
        ],
        "responses": {
          "200": {
            "description": "[{ id, event, statusCode, error, at }].",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string",
                            "description": "An id."
                          },
                          "event": {
                            "type": "string"
                          },
                          "statusCode": {
                            "type": [
                              "integer",
                              "null"
                            ],
                            "description": "The status your server answered, or null when it couldn't be reached."
                          },
                          "error": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "at": {
                            "type": "string",
                            "format": "date-time"
                          }
                        },
                        "required": [
                          "id",
                          "event",
                          "statusCode",
                          "error",
                          "at"
                        ]
                      },
                      "description": "The last 50 deliveries."
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "event": "…",
                      "statusCode": 1,
                      "error": null,
                      "at": "2026-11-02T09:30:00.000Z"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks webhook:read.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such webhook, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Webhook not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "patch": {
        "operationId": "patchWebhooksWebhooksByWebhookId",
        "tags": [
          "Webhooks"
        ],
        "summary": "Turns it on or off: { \"enabled\": true }",
        "description": "Turns it on or off: { \"enabled\": true }. Permission: webhook:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "webhookId",
            "in": "path",
            "required": true,
            "description": "The webhook's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "enabled": {
                    "type": "boolean",
                    "description": "Turning it on again starts the failure count afresh."
                  }
                },
                "required": [
                  "enabled"
                ]
              },
              "example": {
                "enabled": true
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "{ id, enabled }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string",
                          "description": "An id."
                        },
                        "enabled": {
                          "type": "boolean"
                        }
                      },
                      "required": [
                        "id",
                        "enabled"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a40",
                    "enabled": true
                  }
                }
              }
            }
          },
          "400": {
            "description": "The body isn't valid JSON. Or enabled isn't true or false.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "bad_request",
                    "message": "Request body must be valid JSON"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks webhook:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such webhook, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Webhook not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/spaces/{spaceId}/webhooks/{webhookId}/test": {
      "post": {
        "operationId": "postWebhooksWebhooksByWebhookIdTest",
        "tags": [
          "Webhooks"
        ],
        "summary": "Sends a webhook.test event now",
        "description": "Sends a webhook.test event now. Permission: webhook:manage.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "spaceId",
            "in": "path",
            "required": true,
            "description": "The space's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "webhookId",
            "in": "path",
            "required": true,
            "description": "The webhook's id.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a30"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "responses": {
          "200": {
            "description": "{ webhookId, url, statusCode, error }.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "webhookId": {
                          "type": "string",
                          "description": "An id."
                        },
                        "url": {
                          "type": "string"
                        },
                        "statusCode": {
                          "type": [
                            "integer",
                            "null"
                          ]
                        },
                        "error": {
                          "type": [
                            "string",
                            "null"
                          ]
                        }
                      },
                      "required": [
                        "webhookId",
                        "url",
                        "statusCode",
                        "error"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "webhookId": "6650f1c2a9e4b1d2c3f40a59",
                    "url": "https://northwilds.com/trips/lofoten-sea-kayaking",
                    "statusCode": 1,
                    "error": null
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks webhook:manage, or the token is read only.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such webhook, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Webhook not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/trash/spaces": {
      "get": {
        "operationId": "getSpacesTrashSpaces",
        "tags": [
          "Spaces"
        ],
        "summary": "Spaces in the bin",
        "description": "Spaces in the bin. Permission: space:delete.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          }
        ],
        "responses": {
          "200": {
            "description": "List.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "id": {
                            "type": "string",
                            "description": "An id."
                          },
                          "name": {
                            "type": "string"
                          },
                          "slug": {
                            "type": "string"
                          },
                          "logoUrl": {
                            "type": [
                              "string",
                              "null"
                            ]
                          },
                          "deletedAt": {
                            "type": "string",
                            "format": "date-time"
                          },
                          "deletedBy": {
                            "type": [
                              "string",
                              "null"
                            ],
                            "description": "Who moved it to the bin."
                          }
                        },
                        "required": [
                          "id",
                          "name",
                          "slug",
                          "logoUrl",
                          "deletedAt",
                          "deletedBy"
                        ]
                      }
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": [
                    {
                      "id": "6650f1c2a9e4b1d2c3f40a40",
                      "name": "Lofoten sea kayaking",
                      "slug": "lofoten-sea-kayaking",
                      "logoUrl": null,
                      "deletedAt": "2026-11-02T09:30:00.000Z",
                      "deletedBy": "6650f1c2a9e4b1d2c3f40a30"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:delete.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such organisation, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Organisation not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    },
    "/organisations/{organisationId}/trash/spaces/{trashedSpaceId}": {
      "delete": {
        "operationId": "deleteSpacesTrashSpacesByTrashedSpaceId",
        "tags": [
          "Spaces"
        ],
        "summary": "Erases a space in the bin, with its content and media, for good",
        "description": "Erases a space in the bin, with its content and media, for good. Permission: space:purge (owners).",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "trashedSpaceId",
            "in": "path",
            "required": true,
            "description": "The id of the space in the bin.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          }
        ],
        "responses": {
          "200": {
            "description": "What was erased.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object",
                      "properties": {
                        "name": {
                          "type": "string"
                        },
                        "slug": {
                          "type": "string"
                        },
                        "documents": {
                          "type": "object",
                          "additionalProperties": {
                            "type": "integer"
                          },
                          "description": "How many of each were erased."
                        },
                        "objectsRemoved": {
                          "type": "integer",
                          "description": "Files removed from storage."
                        }
                      },
                      "required": [
                        "name",
                        "slug",
                        "documents",
                        "objectsRemoved"
                      ]
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "name": "Lofoten sea kayaking",
                    "slug": "lofoten-sea-kayaking",
                    "documents": {},
                    "objectsRemoved": 1
                  }
                }
              }
            }
          },
          "400": {
            "description": "The space isn't in the bin.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:purge, which only owners have.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space in the bin, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      },
      "post": {
        "operationId": "postSpacesTrashSpacesByTrashedSpaceId",
        "tags": [
          "Spaces"
        ],
        "summary": "Takes a space out of the bin",
        "description": "Takes a space out of the bin. Permission: space:delete.",
        "parameters": [
          {
            "name": "organisationId",
            "in": "path",
            "required": true,
            "description": "The organisation's id, from the Management tokens page.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a01"
          },
          {
            "name": "trashedSpaceId",
            "in": "path",
            "required": true,
            "description": "The id of the space in the bin.",
            "schema": {
              "type": "string"
            },
            "example": "6650f1c2a9e4b1d2c3f40a02"
          },
          {
            "name": "Idempotency-Key",
            "in": "header",
            "required": false,
            "description": "Optional. A unique value, such as a UUID, that makes a retry safe: the same key with the same request within 24 hours returns the first answer again, with Idempotent-Replayed: true, instead of making the change twice. The same key with a different request gets 422; while the first request is still running, 409. Only successful answers are kept.",
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 255
            },
            "example": "4f1c2a9e-7b3d-4e8a-9c21-5d6e7f8a9b0c"
          }
        ],
        "responses": {
          "200": {
            "description": "The space.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "$ref": "#/components/schemas/Space"
                    }
                  },
                  "required": [
                    "data"
                  ]
                },
                "example": {
                  "data": {
                    "id": "6650f1c2a9e4b1d2c3f40a02",
                    "organisationId": "6650f1c2a9e4b1d2c3f40a01",
                    "name": "Northwilds website",
                    "slug": "northwilds-website",
                    "description": "Trips and gear for the far north.",
                    "logoUrl": null,
                    "defaultEnvironmentId": null,
                    "settings": {
                      "autoRedirectOnUrlChange": true,
                      "localeFallbackEnabled": true,
                      "machineTranslation": true,
                      "previewUrl": null,
                      "previewUrls": [
                        {
                          "name": "Lofoten sea kayaking",
                          "url": "https://northwilds.com/trips/lofoten-sea-kayaking"
                        }
                      ],
                      "previewDevices": [
                        {
                          "name": "Lofoten sea kayaking",
                          "width": 1
                        }
                      ],
                      "timezone": "Europe/Oslo",
                      "regionFallback": null,
                      "trashRetentionDays": 30,
                      "seo": {
                        "xDefaultRegion": null,
                        "organisationName": null,
                        "socialProfiles": [
                          "…"
                        ],
                        "robotsTxt": null,
                        "titleTemplate": null,
                        "defaultDescription": null,
                        "defaultImage": null,
                        "twitterHandle": null,
                        "verification": {
                          "google": null,
                          "bing": null
                        },
                        "websitePaths": [
                          "…"
                        ],
                        "indexNow": false
                      },
                      "indexNowKey": "…",
                      "accessibility": {
                        "publish": "off",
                        "tags": [
                          "…"
                        ]
                      },
                      "insights": {
                        "site": "…",
                        "name": "Lofoten sea kayaking"
                      },
                      "workflowStages": [
                        {
                          "id": "6650f1c2a9e4b1d2c3f40a40",
                          "name": "Lofoten sea kayaking",
                          "colour": "…"
                        }
                      ],
                      "travel": {
                        "brandId": "6650f1c2a9e4b1d2c3f40a57",
                        "bookingSlug": "…",
                        "brandName": "Northwilds",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "commerce": {
                        "storeSlug": "…",
                        "brandName": "Northwilds",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "booking": {
                        "locationId": "6650f1c2a9e4b1d2c3f40a5a",
                        "slug": "lofoten-sea-kayaking",
                        "locationName": "…",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "presenceOrbit": {
                        "siteSlug": "…",
                        "brandName": "Northwilds",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "careers": {
                        "siteSlug": "…",
                        "name": "Lofoten sea kayaking",
                        "siteUrl": "https://northwilds.com",
                        "connectedAt": "2026-11-02T09:30:00.000Z",
                        "connectedBy": "6650f1c2a9e4b1d2c3f40a30"
                      },
                      "experiments": {
                        "assignment": "cookieless"
                      }
                    },
                    "createdAt": "2026-11-02T09:30:00.000Z",
                    "updatedAt": "2026-11-02T09:30:00.000Z"
                  }
                }
              }
            }
          },
          "401": {
            "description": "No token, or a token that is unknown, expired or revoked, or whose person no longer has access.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "unauthorized",
                    "message": "This token is not valid"
                  }
                }
              }
            }
          },
          "403": {
            "description": "Lacks space:delete, or the plan's websites are used up.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "forbidden",
                    "message": "You do not have permission to perform this action"
                  }
                }
              }
            }
          },
          "404": {
            "description": "No such space in the bin, or it's in another organisation.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "not_found",
                    "message": "Space not found"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Something went wrong on our side. Try again in a moment.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                },
                "example": {
                  "error": {
                    "code": "internal_error",
                    "message": "Something went wrong"
                  }
                }
              }
            }
          }
        },
        "security": [
          {
            "bearer": []
          }
        ],
        "x-try-it": {
          "run": false,
          "reason": "Management tokens are secret and act as a person, so nothing is sent from the docs."
        }
      }
    }
  },
  "components": {
    "schemas": {
      "Error": {
        "type": "object",
        "description": "Every error has this shape. Write code against code and the status, never the message.",
        "properties": {
          "error": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "enum": [
                  "bad_request",
                  "unauthorized",
                  "forbidden",
                  "not_found",
                  "created_in_orbit",
                  "conflict",
                  "validation_failed",
                  "internal_error",
                  "unavailable"
                ]
              },
              "message": {
                "type": "string",
                "description": "Follows Accept-Language when CMS Orbit has the language."
              },
              "details": {
                "description": "When there is more to read. On 422, issues: each field that failed, with path, message and code. On a field value that breaks the content type's rules, a list of { path, message }. On a version conflict, currentVersion, expected and received."
              }
            },
            "required": [
              "code",
              "message"
            ]
          }
        },
        "required": [
          "error"
        ]
      },
      "Organisation": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "settings": {
            "type": "object",
            "properties": {
              "defaultLocaleCode": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "The language new regions start with, such as en-GB."
              },
              "featureFlags": {
                "type": "object",
                "additionalProperties": {
                  "type": "boolean"
                }
              }
            },
            "required": [
              "defaultLocaleCode",
              "featureFlags"
            ]
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "name",
          "slug",
          "settings",
          "createdAt"
        ]
      },
      "SpaceSettings": {
        "type": "object",
        "properties": {
          "autoRedirectOnUrlChange": {
            "type": "boolean",
            "description": "Add a redirect when a published page's address changes."
          },
          "localeFallbackEnabled": {
            "type": "boolean"
          },
          "machineTranslation": {
            "type": "boolean"
          },
          "previewUrl": {
            "type": [
              "string",
              "null"
            ]
          },
          "previewUrls": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "name": {
                  "type": "string"
                },
                "url": {
                  "type": "string"
                }
              },
              "required": [
                "name",
                "url"
              ]
            }
          },
          "previewDevices": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "name": {
                  "type": "string"
                },
                "width": {
                  "type": "integer"
                }
              },
              "required": [
                "name",
                "width"
              ]
            }
          },
          "timezone": {
            "type": "string",
            "description": "An IANA zone, such as Europe/Oslo."
          },
          "regionFallback": {
            "type": [
              "string",
              "null"
            ],
            "description": "A region key."
          },
          "trashRetentionDays": {
            "type": [
              "integer",
              "null"
            ],
            "enum": [
              30,
              60,
              90,
              null
            ]
          },
          "seo": {
            "$ref": "#/components/schemas/SiteSeo"
          },
          "indexNowKey": {
            "type": "string",
            "description": "The key search engines check at /<key>.txt on the website before accepting IndexNow pings. Made the first time one is sent."
          },
          "accessibility": {
            "$ref": "#/components/schemas/AccessibilitySettings"
          },
          "insights": {
            "type": "object",
            "properties": {
              "site": {
                "type": "string"
              },
              "name": {
                "type": "string"
              }
            },
            "required": [
              "site",
              "name"
            ]
          },
          "workflowStages": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string"
                },
                "name": {
                  "type": "string"
                },
                "colour": {
                  "type": "string",
                  "description": "Such as #2f6f4f."
                }
              },
              "required": [
                "id",
                "name",
                "colour"
              ]
            }
          },
          "travel": {
            "type": "object",
            "properties": {
              "brandId": {
                "type": "string"
              },
              "bookingSlug": {
                "type": "string"
              },
              "brandName": {
                "type": "string"
              },
              "siteUrl": {
                "type": "string"
              },
              "connectedAt": {
                "type": "string",
                "format": "date-time"
              },
              "connectedBy": {
                "type": [
                  "string",
                  "null"
                ]
              }
            },
            "required": [
              "bookingSlug",
              "brandName",
              "siteUrl",
              "connectedAt",
              "connectedBy"
            ]
          },
          "commerce": {
            "type": "object",
            "properties": {
              "storeSlug": {
                "type": "string"
              },
              "brandName": {
                "type": "string"
              },
              "siteUrl": {
                "type": "string"
              },
              "connectedAt": {
                "type": "string",
                "format": "date-time"
              },
              "connectedBy": {
                "type": [
                  "string",
                  "null"
                ]
              }
            },
            "required": [
              "storeSlug",
              "brandName",
              "siteUrl",
              "connectedAt",
              "connectedBy"
            ]
          },
          "booking": {
            "type": "object",
            "properties": {
              "locationId": {
                "type": "string"
              },
              "slug": {
                "type": "string"
              },
              "locationName": {
                "type": "string"
              },
              "siteUrl": {
                "type": "string"
              },
              "connectedAt": {
                "type": "string",
                "format": "date-time"
              },
              "connectedBy": {
                "type": [
                  "string",
                  "null"
                ]
              }
            },
            "required": [
              "locationId",
              "slug",
              "locationName",
              "siteUrl",
              "connectedAt",
              "connectedBy"
            ]
          },
          "presenceOrbit": {
            "type": "object",
            "properties": {
              "siteSlug": {
                "type": "string"
              },
              "brandName": {
                "type": "string"
              },
              "connectedAt": {
                "type": "string",
                "format": "date-time"
              },
              "connectedBy": {
                "type": [
                  "string",
                  "null"
                ]
              }
            },
            "required": [
              "siteSlug",
              "brandName",
              "connectedAt",
              "connectedBy"
            ]
          },
          "careers": {
            "type": "object",
            "properties": {
              "siteSlug": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "siteUrl": {
                "type": "string"
              },
              "connectedAt": {
                "type": "string",
                "format": "date-time"
              },
              "connectedBy": {
                "type": [
                  "string",
                  "null"
                ]
              }
            },
            "required": [
              "siteSlug",
              "name",
              "siteUrl",
              "connectedAt",
              "connectedBy"
            ]
          },
          "experiments": {
            "type": "object",
            "properties": {
              "assignment": {
                "type": "string",
                "enum": [
                  "cookieless",
                  "consent",
                  "cookie"
                ]
              }
            },
            "required": [
              "assignment"
            ]
          }
        },
        "required": [
          "autoRedirectOnUrlChange",
          "localeFallbackEnabled",
          "previewUrl",
          "timezone"
        ]
      },
      "Space": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "organisationId": {
            "type": "string",
            "description": "An id."
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "logoUrl": {
            "type": [
              "string",
              "null"
            ]
          },
          "defaultEnvironmentId": {
            "type": [
              "string",
              "null"
            ],
            "description": "An id."
          },
          "settings": {
            "$ref": "#/components/schemas/SpaceSettings"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "organisationId",
          "name",
          "slug",
          "description",
          "logoUrl",
          "defaultEnvironmentId",
          "settings",
          "createdAt",
          "updatedAt"
        ]
      },
      "Environment": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "spaceId": {
            "type": "string",
            "description": "An id."
          },
          "key": {
            "type": "string",
            "description": "Such as production. Never changes."
          },
          "name": {
            "type": "string"
          },
          "kind": {
            "type": "string",
            "enum": [
              "staging",
              "production",
              "custom"
            ]
          },
          "isDefault": {
            "type": "boolean"
          },
          "protected": {
            "type": "boolean",
            "description": "A protected environment can't be deleted."
          },
          "sortOrder": {
            "type": "integer"
          }
        },
        "required": [
          "id",
          "spaceId",
          "key",
          "name",
          "kind",
          "isDefault",
          "protected",
          "sortOrder"
        ]
      },
      "Region": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "spaceId": {
            "type": "string",
            "description": "An id."
          },
          "environmentId": {
            "type": "string",
            "description": "An id."
          },
          "key": {
            "type": "string",
            "description": "Such as norway."
          },
          "name": {
            "type": "string"
          },
          "defaultLocaleId": {
            "type": [
              "string",
              "null"
            ],
            "description": "An id."
          },
          "currency": {
            "type": [
              "string",
              "null"
            ],
            "description": "Such as NOK."
          },
          "timezone": {
            "type": [
              "string",
              "null"
            ]
          },
          "pathPrefix": {
            "type": [
              "string",
              "null"
            ],
            "description": "Such as /no. Addresses in the region start with it."
          },
          "sortOrder": {
            "type": "integer"
          }
        },
        "required": [
          "id",
          "spaceId",
          "environmentId",
          "key",
          "name",
          "defaultLocaleId",
          "currency",
          "timezone",
          "pathPrefix",
          "sortOrder"
        ]
      },
      "Locale": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "spaceId": {
            "type": "string",
            "description": "An id."
          },
          "environmentId": {
            "type": "string",
            "description": "An id."
          },
          "regionId": {
            "type": "string",
            "description": "An id."
          },
          "code": {
            "type": "string",
            "description": "Such as nb-NO."
          },
          "name": {
            "type": "string"
          },
          "fallbackLocaleId": {
            "type": [
              "string",
              "null"
            ],
            "description": "An id."
          },
          "isDefault": {
            "type": "boolean"
          },
          "enabled": {
            "type": "boolean"
          },
          "sortOrder": {
            "type": "integer"
          }
        },
        "required": [
          "id",
          "spaceId",
          "environmentId",
          "regionId",
          "code",
          "name",
          "fallbackLocaleId",
          "isDefault",
          "enabled",
          "sortOrder"
        ]
      },
      "Role": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "key": {
            "type": "string",
            "description": "Such as editor."
          },
          "name": {
            "type": "string"
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "permissions": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Such as content:publish."
          },
          "isSystem": {
            "type": "boolean",
            "description": "A built-in role."
          },
          "rank": {
            "type": "integer",
            "description": "0 to 100. You can only manage roles ranked below your own."
          }
        },
        "required": [
          "id",
          "key",
          "name",
          "description",
          "permissions",
          "isSystem",
          "rank"
        ]
      },
      "Member": {
        "type": "object",
        "properties": {
          "membershipId": {
            "type": "string",
            "description": "An id."
          },
          "userId": {
            "type": "string",
            "description": "An id."
          },
          "email": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "role": {
            "type": "string",
            "description": "The role's key."
          },
          "roleName": {
            "type": "string"
          },
          "spaceId": {
            "type": [
              "string",
              "null"
            ],
            "description": "null for the whole organisation."
          },
          "spaceName": {
            "type": [
              "string",
              "null"
            ]
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "suspended",
              "invited"
            ]
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "membershipId",
          "userId",
          "email",
          "name",
          "role",
          "roleName",
          "spaceId",
          "spaceName",
          "status",
          "createdAt"
        ]
      },
      "SpaceMember": {
        "type": "object",
        "properties": {
          "membershipId": {
            "type": "string",
            "description": "An id."
          },
          "userId": {
            "type": "string",
            "description": "An id."
          },
          "email": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "role": {
            "type": "string"
          },
          "roleName": {
            "type": "string"
          },
          "spaceId": {
            "type": [
              "string",
              "null"
            ],
            "description": "An id."
          },
          "spaceName": {
            "type": [
              "string",
              "null"
            ]
          },
          "status": {
            "type": "string",
            "enum": [
              "active",
              "suspended",
              "invited"
            ]
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "viaOrganisation": {
            "type": "boolean",
            "description": "Reaches the space through an organisation role that sees every space."
          },
          "regionKeys": {
            "type": [
              "array",
              "null"
            ],
            "items": {
              "type": "string"
            },
            "description": "The regions the person may change, or null for all."
          }
        },
        "required": [
          "membershipId",
          "userId",
          "email",
          "name",
          "role",
          "roleName",
          "spaceId",
          "spaceName",
          "status",
          "createdAt",
          "viaOrganisation",
          "regionKeys"
        ]
      },
      "ManagementToken": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "name": {
            "type": "string"
          },
          "person": {
            "type": "string",
            "description": "Who it acts as."
          },
          "readOnly": {
            "type": "boolean"
          },
          "prefix": {
            "type": "string",
            "description": "The first characters, to tell tokens apart."
          },
          "expiresAt": {
            "type": "string",
            "format": "date-time"
          },
          "lastUsedAt": {
            "type": [
              "string",
              "null"
            ],
            "description": "Updated at most once a minute.",
            "format": "date-time"
          },
          "revokedAt": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "mine": {
            "type": "boolean"
          }
        },
        "required": [
          "id",
          "name",
          "person",
          "readOnly",
          "prefix",
          "expiresAt",
          "lastUsedAt",
          "revokedAt",
          "createdAt",
          "mine"
        ]
      },
      "CliSignIn": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "name": {
            "type": "string",
            "description": "The name cms-orbit registered with, or cms-orbit."
          },
          "personId": {
            "type": "string",
            "description": "An id."
          },
          "person": {
            "type": "string",
            "description": "Who it acts as."
          },
          "signedInAt": {
            "type": "string",
            "format": "date-time"
          },
          "lastUsedAt": {
            "type": [
              "string",
              "null"
            ],
            "description": "Updated at most once a minute.",
            "format": "date-time"
          },
          "endsAt": {
            "type": "string",
            "description": "When it expires without use. Each renewal moves it to 30 days later.",
            "format": "date-time"
          },
          "mine": {
            "type": "boolean"
          },
          "canSignOut": {
            "type": "boolean",
            "description": "Yours, or someone ranked below you."
          }
        },
        "required": [
          "id",
          "name",
          "personId",
          "person",
          "signedInAt",
          "lastUsedAt",
          "endsAt",
          "mine",
          "canSignOut"
        ]
      },
      "ApiKey": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "name": {
            "type": "string"
          },
          "prefix": {
            "type": "string",
            "description": "Such as cms_pk_3f9a."
          },
          "environmentId": {
            "type": "string",
            "description": "An id."
          },
          "environmentName": {
            "type": "string"
          },
          "scopes": {
            "type": "array",
            "items": {
              "type": "string",
              "enum": [
                "content:read",
                "content:read_draft"
              ]
            }
          },
          "allowDraft": {
            "type": "boolean",
            "description": "A secret key that reads drafts."
          },
          "regionIds": {
            "type": [
              "array",
              "null"
            ],
            "items": {
              "type": "string",
              "description": "An id."
            }
          },
          "localeIds": {
            "type": [
              "array",
              "null"
            ],
            "items": {
              "type": "string",
              "description": "An id."
            }
          },
          "expiresAt": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "lastUsedAt": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "revokedAt": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "name",
          "prefix",
          "environmentId",
          "environmentName",
          "scopes",
          "allowDraft",
          "regionIds",
          "localeIds",
          "expiresAt",
          "lastUsedAt",
          "revokedAt",
          "createdAt"
        ]
      },
      "Domain": {
        "type": "object",
        "properties": {
          "_id": {
            "type": "string",
            "description": "An id."
          },
          "organisationId": {
            "type": "string",
            "description": "An id."
          },
          "spaceId": {
            "type": "string",
            "description": "An id."
          },
          "environmentId": {
            "type": "string",
            "description": "An id."
          },
          "regionId": {
            "type": [
              "string",
              "null"
            ],
            "description": "An id."
          },
          "localeId": {
            "type": [
              "string",
              "null"
            ],
            "description": "An id."
          },
          "hostname": {
            "type": "string",
            "description": "Such as northwilds.com."
          },
          "pathPrefix": {
            "type": [
              "string",
              "null"
            ],
            "description": "Such as /no."
          },
          "primary": {
            "type": "boolean"
          },
          "verified": {
            "type": "boolean"
          },
          "verificationToken": {
            "type": [
              "string",
              "null"
            ],
            "description": "Add it as a TXT record on the hostname or on _cms-orbit.<hostname>, then verify."
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "_id",
          "organisationId",
          "spaceId",
          "environmentId",
          "regionId",
          "localeId",
          "hostname",
          "pathPrefix",
          "primary",
          "verified",
          "verificationToken",
          "createdAt",
          "updatedAt"
        ]
      },
      "MediaHost": {
        "type": "object",
        "properties": {
          "environmentId": {
            "type": "string",
            "description": "An id."
          },
          "hostname": {
            "type": "string",
            "description": "Such as media.northwilds.com."
          },
          "target": {
            "type": "string",
            "description": "Where the CNAME record points."
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "active",
              "failed"
            ]
          },
          "message": {
            "type": [
              "string",
              "null"
            ]
          },
          "checkedAt": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "cloudflareId": {
            "type": [
              "string",
              "null"
            ]
          },
          "onWebsite": {
            "type": "boolean",
            "description": "The website's own server answers on the hostname."
          }
        },
        "required": [
          "environmentId",
          "hostname",
          "target",
          "status",
          "message",
          "checkedAt",
          "cloudflareId"
        ]
      },
      "Field": {
        "type": "object",
        "properties": {
          "key": {
            "type": "string",
            "description": "Such as title."
          },
          "name": {
            "type": "string"
          },
          "type": {
            "type": "string",
            "description": "Such as text, richtext, asset or reference. See https://docs.bifrostorbit.com/cms/developers/field-types/."
          },
          "description": {
            "type": "string"
          },
          "required": {
            "type": "boolean"
          },
          "default": {},
          "validation": {
            "type": "object",
            "properties": {
              "min": {
                "type": "number"
              },
              "max": {
                "type": "number"
              },
              "minLength": {
                "type": "integer"
              },
              "maxLength": {
                "type": "integer"
              },
              "pattern": {
                "type": "string"
              },
              "message": {
                "type": "string"
              }
            },
            "required": []
          },
          "options": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "label": {
                  "type": "string"
                },
                "value": {
                  "type": "string"
                }
              },
              "required": [
                "label",
                "value"
              ]
            }
          },
          "allowedComponents": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "allowedContentTypes": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "allowedMimeTypes": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "taxonomyKey": {
            "type": "string"
          },
          "localised": {
            "type": "boolean"
          },
          "regional": {
            "type": "boolean"
          },
          "protects": {
            "type": "string",
            "enum": [
              "none",
              "price",
              "promotion"
            ]
          },
          "group": {
            "type": "string"
          },
          "hidden": {
            "type": "boolean"
          },
          "showWhen": {
            "type": "object",
            "description": "Show and check the field only while another field has this value.",
            "properties": {
              "field": {
                "type": "string"
              },
              "equals": {
                "description": "A value, true or false, or a list of values."
              }
            },
            "required": [
              "field",
              "equals"
            ]
          },
          "step": {
            "type": "number",
            "description": "Slider: how far one move goes, such as 0.5. 1 when left out."
          },
          "unit": {
            "type": "string",
            "description": "Slider: a unit shown after the value, such as km or %. Up to 20 characters."
          },
          "halfStars": {
            "type": "boolean",
            "description": "Star rating: allow half stars, such as 3.5."
          },
          "languages": {
            "type": "array",
            "items": {
              "type": "string",
              "enum": [
                "text",
                "ts",
                "tsx",
                "js",
                "json",
                "html",
                "xml",
                "yaml",
                "graphql",
                "bash",
                "python",
                "php",
                "java",
                "kotlin",
                "swift",
                "vue",
                "svelte",
                "astro",
                "blade",
                "twig",
                "dockerfile",
                "http"
              ]
            },
            "description": "Code block: the languages editors may choose. Every language when left out or empty."
          },
          "defaultLanguage": {
            "type": "string",
            "description": "Code block: the language a new block starts in. The first allowed language when left out.",
            "enum": [
              "text",
              "ts",
              "tsx",
              "js",
              "json",
              "html",
              "xml",
              "yaml",
              "graphql",
              "bash",
              "python",
              "php",
              "java",
              "kotlin",
              "swift",
              "vue",
              "svelte",
              "astro",
              "blade",
              "twig",
              "dockerfile",
              "http"
            ]
          }
        },
        "required": [
          "key",
          "name",
          "type",
          "required"
        ]
      },
      "ContentType": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "key": {
            "type": "string",
            "description": "Such as trip."
          },
          "name": {
            "type": "string"
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "icon": {
            "type": [
              "string",
              "null"
            ]
          },
          "group": {
            "type": [
              "string",
              "null"
            ]
          },
          "fields": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Field"
            }
          },
          "allowedComponents": {
            "anyOf": [
              {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              {
                "const": "*"
              }
            ],
            "description": "Blocks the body may hold, or * for any."
          },
          "template": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Blocks a new item starts with."
          },
          "seo": {
            "type": "object",
            "properties": {
              "enabled": {
                "type": "boolean"
              },
              "fields": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/Field"
                }
              },
              "titleTemplate": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "descriptionField": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "sitemapPriority": {
                "type": [
                  "number",
                  "null"
                ]
              },
              "sitemapChangeFrequency": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "noIndexByDefault": {
                "type": "boolean"
              }
            },
            "required": [
              "enabled",
              "fields"
            ]
          },
          "slugBehaviour": {
            "type": "object",
            "properties": {
              "source": {
                "type": "string",
                "enum": [
                  "name",
                  "manual"
                ]
              },
              "editable": {
                "type": "boolean"
              },
              "unique": {
                "type": "boolean"
              }
            },
            "required": [
              "source",
              "editable",
              "unique"
            ]
          },
          "publishing": {
            "type": "object",
            "properties": {
              "requiresApproval": {
                "type": "boolean"
              },
              "steps": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "key": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    },
                    "role": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "permission": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  },
                  "required": [
                    "key",
                    "name"
                  ]
                },
                "description": "Up to 5 approval steps."
              },
              "regionSteps": {
                "type": "object",
                "additionalProperties": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "key": {
                        "type": "string"
                      },
                      "name": {
                        "type": "string"
                      },
                      "role": {
                        "type": [
                          "string",
                          "null"
                        ]
                      },
                      "permission": {
                        "type": [
                          "string",
                          "null"
                        ]
                      }
                    },
                    "required": [
                      "key",
                      "name"
                    ]
                  }
                },
                "description": "Approval steps for one region, by region key."
              },
              "reviewMonths": {
                "type": [
                  "integer",
                  "null"
                ],
                "description": "Months until an item is due for review."
              }
            },
            "required": [
              "requiresApproval"
            ]
          },
          "isGlobal": {
            "type": "boolean",
            "description": "Read by key, with no address, such as a footer."
          },
          "singleton": {
            "type": "boolean",
            "description": "Only one item of this type."
          },
          "urlPrefix": {
            "type": [
              "string",
              "null"
            ],
            "description": "Where items of this type live, such as /trips."
          },
          "editor": {
            "type": [
              "string",
              "null"
            ],
            "enum": [
              "preview",
              "panel",
              null
            ]
          },
          "mainHeading": {
            "type": [
              "string",
              "null"
            ],
            "description": "The text field that is the item's main heading."
          },
          "schemaVersion": {
            "type": "integer",
            "description": "Goes up each time the fields change."
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "key",
          "name",
          "description",
          "icon",
          "group",
          "fields",
          "allowedComponents",
          "template",
          "seo",
          "slugBehaviour",
          "publishing",
          "isGlobal",
          "singleton",
          "urlPrefix",
          "editor",
          "mainHeading",
          "schemaVersion",
          "updatedAt"
        ]
      },
      "Component": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "key": {
            "type": "string",
            "description": "Such as hero."
          },
          "name": {
            "type": "string"
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "icon": {
            "type": [
              "string",
              "null"
            ]
          },
          "group": {
            "type": [
              "string",
              "null"
            ]
          },
          "fields": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/Field"
            }
          },
          "allowedChildren": {
            "anyOf": [
              {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              {
                "const": "*"
              }
            ],
            "description": "Blocks its slots may hold, or * for any."
          },
          "isRoot": {
            "type": "boolean",
            "description": "May sit at the top of a page."
          },
          "isNestable": {
            "type": "boolean",
            "description": "May sit inside another block."
          },
          "previewImage": {
            "type": [
              "string",
              "null"
            ]
          },
          "mainHeading": {
            "type": [
              "string",
              "null"
            ],
            "description": "The text field that is the page's main heading when the block is used."
          },
          "mainHeadingWhen": {
            "type": [
              "string",
              "null"
            ],
            "description": "A yes/no field that decides whether mainHeading counts."
          },
          "hiddenFromLibrary": {
            "type": "boolean",
            "description": "Left out of the block library editors pick from."
          },
          "schemaVersion": {
            "type": "integer"
          },
          "deprecated": {
            "type": "boolean"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "key",
          "name",
          "description",
          "icon",
          "group",
          "fields",
          "allowedChildren",
          "isRoot",
          "isNestable",
          "previewImage",
          "mainHeading",
          "mainHeadingWhen",
          "hiddenFromLibrary",
          "schemaVersion",
          "deprecated",
          "updatedAt"
        ]
      },
      "Block": {
        "type": "object",
        "description": "One block in a page body.",
        "properties": {
          "id": {
            "type": "string"
          },
          "type": {
            "type": "string",
            "description": "The component's key, such as hero."
          },
          "schemaVersion": {
            "type": "integer"
          },
          "fields": {
            "type": "object",
            "additionalProperties": {},
            "description": "The component's fields."
          },
          "children": {
            "type": "object",
            "additionalProperties": {
              "type": "array",
              "items": {
                "$ref": "#/components/schemas/Block"
              }
            },
            "description": "Further blocks by slot."
          },
          "variant": {
            "type": [
              "string",
              "null"
            ]
          }
        },
        "required": [
          "id",
          "type",
          "schemaVersion",
          "fields",
          "children",
          "variant"
        ]
      },
      "ContentSummary": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "url": {
            "type": [
              "string",
              "null"
            ],
            "description": "Such as /trips/lofoten-sea-kayaking. null for content without an address."
          },
          "status": {
            "type": "string",
            "description": "published once it has been published, even while the draft has changes.",
            "enum": [
              "draft",
              "in_review",
              "published",
              "scheduled",
              "archived"
            ]
          },
          "contentTypeKey": {
            "type": "string"
          },
          "folderId": {
            "type": [
              "string",
              "null"
            ],
            "description": "An id."
          },
          "externalId": {
            "type": [
              "string",
              "null"
            ],
            "description": "Your own id for the entry, such as its id in the system it was imported from. Unique in its language."
          },
          "isGlobal": {
            "type": "boolean"
          },
          "isFolderIndex": {
            "type": "boolean"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          },
          "publishedAt": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "name",
          "slug",
          "url",
          "status",
          "contentTypeKey",
          "folderId",
          "externalId",
          "isGlobal",
          "isFolderIndex",
          "updatedAt",
          "publishedAt"
        ]
      },
      "Content": {
        "type": "object",
        "description": "One piece of content with its draft.",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "url": {
            "type": [
              "string",
              "null"
            ]
          },
          "status": {
            "type": "string",
            "enum": [
              "draft",
              "in_review",
              "published",
              "scheduled",
              "archived"
            ]
          },
          "contentTypeKey": {
            "type": "string"
          },
          "folderId": {
            "type": [
              "string",
              "null"
            ],
            "description": "An id."
          },
          "externalId": {
            "type": [
              "string",
              "null"
            ]
          },
          "isGlobal": {
            "type": "boolean"
          },
          "isFolderIndex": {
            "type": "boolean"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          },
          "publishedAt": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "urlOverride": {
            "type": [
              "string",
              "null"
            ]
          },
          "draft": {
            "type": "object",
            "description": "The draft. No seo for content without an address.",
            "properties": {
              "fields": {
                "type": "object",
                "additionalProperties": {},
                "description": "Field values by key. See https://docs.bifrostorbit.com/cms/developers/field-types/."
              },
              "components": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/Block"
                }
              },
              "seo": {
                "type": "object",
                "properties": {
                  "title": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "description": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "canonical": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "noIndex": {
                    "type": "boolean"
                  },
                  "ogTitle": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "ogDescription": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "ogImage": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "description": "A media id or address."
                  },
                  "twitterTitle": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "twitterDescription": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "twitterImage": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "noFollow": {
                    "type": "boolean"
                  },
                  "breadcrumbLabel": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "sitemapExclude": {
                    "type": "boolean"
                  },
                  "sitemapChangeFrequency": {
                    "type": [
                      "string",
                      "null"
                    ],
                    "enum": [
                      "always",
                      "hourly",
                      "daily",
                      "weekly",
                      "monthly",
                      "yearly",
                      "never",
                      null
                    ]
                  },
                  "sitemapPriority": {
                    "type": [
                      "number",
                      "null"
                    ],
                    "minimum": 0,
                    "maximum": 1
                  }
                },
                "required": [
                  "title",
                  "description",
                  "canonical",
                  "noIndex",
                  "ogTitle",
                  "ogDescription",
                  "ogImage",
                  "twitterTitle",
                  "twitterDescription",
                  "twitterImage",
                  "noFollow",
                  "breadcrumbLabel",
                  "sitemapExclude",
                  "sitemapChangeFrequency",
                  "sitemapPriority"
                ]
              },
              "updatedAt": {
                "type": "string",
                "format": "date-time"
              },
              "updatedBy": {
                "type": "string",
                "description": "An id."
              }
            },
            "required": [
              "fields",
              "components",
              "updatedAt",
              "updatedBy"
            ]
          },
          "draftVersion": {
            "type": "integer"
          },
          "publishedVersion": {
            "type": "integer",
            "description": "Compare with draftVersion to see whether the draft has unpublished changes."
          },
          "docVersion": {
            "type": "integer",
            "description": "Send it back with each save, so a save never overwrites changes you haven't seen."
          }
        },
        "required": [
          "id",
          "name",
          "slug",
          "url",
          "status",
          "contentTypeKey",
          "folderId",
          "externalId",
          "isGlobal",
          "isFolderIndex",
          "updatedAt",
          "publishedAt",
          "urlOverride",
          "draft",
          "draftVersion",
          "publishedVersion",
          "docVersion"
        ]
      },
      "Folder": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "parentId": {
            "type": [
              "string",
              "null"
            ],
            "description": "An id."
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "urlSegment": {
            "type": [
              "string",
              "null"
            ],
            "description": "The folder's part of the address, when it differs from the slug."
          },
          "depth": {
            "type": "integer"
          },
          "path": {
            "type": "array",
            "items": {
              "type": "string",
              "description": "An id."
            },
            "description": "The ids of the folders above it, from the top."
          },
          "sortOrder": {
            "type": "integer"
          }
        },
        "required": [
          "id",
          "parentId",
          "name",
          "slug",
          "urlSegment",
          "depth",
          "path",
          "sortOrder"
        ]
      },
      "FolderNode": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "parentId": {
            "type": [
              "string",
              "null"
            ],
            "description": "An id."
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "urlSegment": {
            "type": [
              "string",
              "null"
            ]
          },
          "depth": {
            "type": "integer"
          },
          "path": {
            "type": "array",
            "items": {
              "type": "string",
              "description": "An id."
            }
          },
          "url": {
            "type": "string",
            "description": "Such as /trips/norway."
          },
          "childCount": {
            "type": "integer"
          },
          "contentCount": {
            "type": "integer"
          },
          "contentTypes": {
            "type": "array",
            "items": {
              "type": "string"
            },
            "description": "Content type keys it accepts. Empty for any."
          }
        },
        "required": [
          "id",
          "parentId",
          "name",
          "slug",
          "urlSegment",
          "depth",
          "path",
          "url",
          "childCount",
          "contentCount",
          "contentTypes"
        ]
      },
      "Review": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "contentId": {
            "type": "string",
            "description": "An id."
          },
          "contentName": {
            "type": "string"
          },
          "contentUrl": {
            "type": [
              "string",
              "null"
            ]
          },
          "contentType": {
            "type": "string"
          },
          "region": {
            "type": [
              "string",
              "null"
            ]
          },
          "locale": {
            "type": [
              "string",
              "null"
            ]
          },
          "environmentId": {
            "type": "string",
            "description": "An id."
          },
          "regionId": {
            "type": "string",
            "description": "An id."
          },
          "localeId": {
            "type": "string",
            "description": "An id."
          },
          "version": {
            "type": "integer",
            "description": "The draft version sent."
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "approved",
              "rejected",
              "withdrawn",
              "superseded"
            ]
          },
          "steps": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "key": {
                  "type": "string"
                },
                "name": {
                  "type": "string"
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "pending",
                    "approved",
                    "rejected"
                  ]
                },
                "decidedBy": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "decidedRole": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "decidedAt": {
                  "type": [
                    "string",
                    "null"
                  ],
                  "format": "date-time"
                },
                "comment": {
                  "type": [
                    "string",
                    "null"
                  ]
                },
                "who": {
                  "type": [
                    "string",
                    "null"
                  ]
                }
              },
              "required": [
                "key",
                "name",
                "status",
                "decidedBy",
                "decidedRole",
                "decidedAt",
                "comment",
                "who"
              ]
            }
          },
          "message": {
            "type": [
              "string",
              "null"
            ]
          },
          "reviewers": {
            "type": "array",
            "items": {
              "type": "string",
              "description": "An id."
            }
          },
          "publishOnApproval": {
            "type": "boolean"
          },
          "submittedBy": {
            "type": "string"
          },
          "sentByAgent": {
            "type": [
              "string",
              "null"
            ]
          },
          "draftedByAi": {
            "type": [
              "string",
              "null"
            ]
          },
          "submittedAt": {
            "type": "string",
            "format": "date-time"
          },
          "decidedAt": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "publishedAt": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "stale": {
            "type": "boolean",
            "description": "The page changed after it was sent."
          }
        },
        "required": [
          "id",
          "contentId",
          "contentName",
          "contentUrl",
          "contentType",
          "region",
          "locale",
          "environmentId",
          "regionId",
          "localeId",
          "version",
          "status",
          "steps",
          "message",
          "reviewers",
          "publishOnApproval",
          "submittedBy",
          "sentByAgent",
          "draftedByAi",
          "submittedAt",
          "decidedAt",
          "publishedAt",
          "stale"
        ]
      },
      "Media": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "filename": {
            "type": "string"
          },
          "url": {
            "type": "string"
          },
          "mimeType": {
            "type": "string"
          },
          "category": {
            "type": "string",
            "description": "image, video, document or other."
          },
          "size": {
            "type": "integer",
            "description": "In bytes."
          },
          "checksum": {
            "type": [
              "string",
              "null"
            ],
            "description": "The SHA-256 of the stored file, in hex. null for files stored before checksums were kept."
          },
          "width": {
            "type": [
              "integer",
              "null"
            ]
          },
          "height": {
            "type": [
              "integer",
              "null"
            ]
          },
          "folderId": {
            "type": [
              "string",
              "null"
            ],
            "description": "An id."
          },
          "title": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            },
            "description": "By language code."
          },
          "alt": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            },
            "description": "By language code, such as { \"en-GB\": \"Kayaks on a calm fjord\" }."
          },
          "caption": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            },
            "description": "By language code."
          },
          "tags": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "original": {
            "type": [
              "object",
              "null"
            ],
            "description": "The file before the crop and edits, when it was kept. For an image with blurred areas, url is the media item's /original address, which needs media:upload.",
            "properties": {
              "url": {
                "type": "string"
              },
              "width": {
                "type": "integer"
              },
              "height": {
                "type": "integer"
              }
            },
            "required": [
              "url",
              "width",
              "height"
            ]
          },
          "crop": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "x": {
                "type": "number"
              },
              "y": {
                "type": "number"
              },
              "width": {
                "type": "number"
              },
              "height": {
                "type": "number"
              },
              "rotate": {
                "type": "integer",
                "enum": [
                  0,
                  90,
                  180,
                  270
                ]
              },
              "aspect": {
                "type": [
                  "string",
                  "null"
                ],
                "description": "Such as 16:9."
              }
            },
            "required": [
              "x",
              "y",
              "width",
              "height",
              "rotate",
              "aspect"
            ]
          },
          "edit": {
            "type": [
              "object",
              "null"
            ],
            "description": "Changes made in the image editor, or null.",
            "properties": {
              "version": {
                "type": "integer",
                "enum": [
                  1
                ]
              },
              "steps": {
                "type": "array",
                "items": {
                  "description": "One edit, such as { \"type\": \"adjust\", \"brightness\": 10 }. See the crop endpoint."
                },
                "description": "Applied in this order: flip, straighten, redact, then the crop, then adjust, look and sharpen."
              }
            },
            "required": [
              "version",
              "steps"
            ]
          },
          "focalPoint": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "x": {
                "type": "number",
                "description": "0 to 1 from the left."
              },
              "y": {
                "type": "number",
                "description": "0 to 1 from the top."
              }
            },
            "required": [
              "x",
              "y"
            ]
          },
          "consent": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "reference": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "status": {
                "type": "string",
                "enum": [
                  "pending",
                  "approved",
                  "withdrawn"
                ]
              },
              "restrictions": {
                "type": [
                  "string",
                  "null"
                ]
              }
            },
            "required": [
              "reference",
              "status",
              "restrictions"
            ]
          },
          "subtitles": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            },
            "description": "Subtitle file addresses by language code."
          },
          "source": {
            "type": [
              "object",
              "null"
            ],
            "description": "Set when the file is linked from a media library connected in Orbit rather than stored in CMS Orbit. url is then the library's own address.",
            "properties": {
              "provider": {
                "type": "string",
                "enum": [
                  "cloudinary",
                  "bynder",
                  "frontify"
                ]
              },
              "externalId": {
                "type": "string",
                "description": "The file's id in that library."
              }
            },
            "required": [
              "provider",
              "externalId"
            ]
          }
        },
        "required": [
          "id",
          "filename",
          "url",
          "mimeType",
          "category",
          "size",
          "checksum",
          "width",
          "height",
          "folderId",
          "title",
          "alt",
          "caption",
          "tags",
          "createdAt",
          "original",
          "crop",
          "edit",
          "focalPoint",
          "consent",
          "subtitles",
          "source"
        ]
      },
      "MediaFolder": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "name": {
            "type": "string"
          },
          "parentId": {
            "type": [
              "string",
              "null"
            ],
            "description": "An id."
          }
        },
        "required": [
          "id",
          "name",
          "parentId"
        ]
      },
      "MenuItem": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "label": {
            "type": "string"
          },
          "kind": {
            "type": "string",
            "enum": [
              "content",
              "folder",
              "external",
              "custom",
              "trip",
              "destination",
              "guide"
            ]
          },
          "contentId": {
            "type": [
              "string",
              "null"
            ],
            "description": "An id."
          },
          "folderId": {
            "type": [
              "string",
              "null"
            ],
            "description": "An id."
          },
          "href": {
            "type": [
              "string",
              "null"
            ]
          },
          "target": {
            "type": [
              "string",
              "null"
            ],
            "enum": [
              "_self",
              "_blank",
              null
            ]
          },
          "icon": {
            "type": [
              "string",
              "null"
            ]
          },
          "badge": {
            "type": [
              "string",
              "null"
            ]
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "visible": {
            "type": "boolean"
          },
          "travel": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "id": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "kind": {
                "type": "string",
                "enum": [
                  "country",
                  "continent"
                ]
              }
            },
            "required": [
              "id",
              "name"
            ]
          },
          "children": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/MenuItem"
            }
          }
        },
        "required": [
          "id",
          "label",
          "kind",
          "contentId",
          "folderId",
          "href",
          "target",
          "icon",
          "badge",
          "visible",
          "children"
        ]
      },
      "Menu": {
        "type": "object",
        "properties": {
          "_id": {
            "type": "string",
            "description": "An id."
          },
          "organisationId": {
            "type": "string",
            "description": "An id."
          },
          "spaceId": {
            "type": "string",
            "description": "An id."
          },
          "environmentId": {
            "type": "string",
            "description": "An id."
          },
          "regionId": {
            "type": [
              "string",
              "null"
            ],
            "description": "An id."
          },
          "localeId": {
            "type": [
              "string",
              "null"
            ],
            "description": "An id."
          },
          "key": {
            "type": "string",
            "description": "Such as main."
          },
          "name": {
            "type": "string"
          },
          "kind": {
            "type": "string",
            "enum": [
              "header",
              "footer",
              "mobile",
              "custom"
            ]
          },
          "items": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/MenuItem"
            }
          },
          "createdBy": {
            "type": "string",
            "description": "An id."
          },
          "updatedBy": {
            "type": "string",
            "description": "An id."
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "_id",
          "organisationId",
          "spaceId",
          "environmentId",
          "regionId",
          "localeId",
          "key",
          "name",
          "kind",
          "items",
          "createdBy",
          "updatedBy",
          "createdAt",
          "updatedAt"
        ]
      },
      "Redirect": {
        "type": "object",
        "properties": {
          "_id": {
            "type": "string",
            "description": "An id."
          },
          "organisationId": {
            "type": "string",
            "description": "An id."
          },
          "spaceId": {
            "type": "string",
            "description": "An id."
          },
          "environmentId": {
            "type": "string",
            "description": "An id."
          },
          "regionId": {
            "type": [
              "string",
              "null"
            ],
            "description": "An id."
          },
          "localeId": {
            "type": [
              "string",
              "null"
            ],
            "description": "An id."
          },
          "source": {
            "type": "string",
            "description": "Such as /trips/lofoten."
          },
          "destinationType": {
            "type": "string",
            "enum": [
              "url",
              "content"
            ]
          },
          "destinationUrl": {
            "type": [
              "string",
              "null"
            ]
          },
          "destinationContentId": {
            "type": [
              "string",
              "null"
            ],
            "description": "An id."
          },
          "statusCode": {
            "type": "integer",
            "enum": [
              301,
              302,
              307,
              308
            ]
          },
          "enabled": {
            "type": "boolean"
          },
          "origin": {
            "type": "string",
            "enum": [
              "manual",
              "auto_url_change",
              "import"
            ]
          },
          "note": {
            "type": [
              "string",
              "null"
            ]
          },
          "noteWording": {
            "description": "The note as a translation key, for notes CMS Orbit wrote itself.",
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ]
          },
          "hits": {
            "type": "integer"
          },
          "lastHitAt": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "status": {
            "type": "string",
            "enum": [
              "draft",
              "published"
            ]
          },
          "createdBy": {
            "type": "string",
            "description": "An id."
          },
          "updatedBy": {
            "type": "string",
            "description": "An id."
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "_id",
          "organisationId",
          "spaceId",
          "environmentId",
          "regionId",
          "localeId",
          "source",
          "destinationType",
          "destinationUrl",
          "destinationContentId",
          "statusCode",
          "enabled",
          "origin",
          "note",
          "hits",
          "lastHitAt",
          "status",
          "createdBy",
          "updatedBy",
          "createdAt",
          "updatedAt"
        ]
      },
      "Release": {
        "type": "object",
        "properties": {
          "_id": {
            "type": "string",
            "description": "An id."
          },
          "organisationId": {
            "type": "string",
            "description": "An id."
          },
          "spaceId": {
            "type": "string",
            "description": "An id."
          },
          "environmentId": {
            "type": "string",
            "description": "An id."
          },
          "targetEnvironmentId": {
            "type": "string",
            "description": "An id."
          },
          "name": {
            "type": "string"
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "status": {
            "type": "string",
            "enum": [
              "open",
              "scheduled",
              "publishing",
              "published",
              "failed",
              "cancelled"
            ]
          },
          "items": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "contentId": {
                  "type": "string",
                  "description": "An id."
                },
                "action": {
                  "type": "string",
                  "enum": [
                    "publish",
                    "unpublish"
                  ]
                },
                "regionId": {
                  "type": "string",
                  "description": "An id."
                },
                "localeId": {
                  "type": "string",
                  "description": "An id."
                },
                "includeChildren": {
                  "type": "boolean"
                },
                "addedAt": {
                  "type": "string",
                  "format": "date-time"
                },
                "addedBy": {
                  "type": "string",
                  "description": "An id."
                },
                "outcome": {
                  "type": "object",
                  "properties": {
                    "status": {
                      "type": "string",
                      "enum": [
                        "published",
                        "unpublished",
                        "failed"
                      ]
                    },
                    "reason": {
                      "type": [
                        "string",
                        "null"
                      ]
                    }
                  },
                  "required": [
                    "status",
                    "reason"
                  ]
                }
              },
              "required": [
                "contentId",
                "regionId",
                "localeId",
                "includeChildren",
                "addedAt",
                "addedBy"
              ]
            }
          },
          "scheduledAt": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "publishedAt": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "publishedBy": {
            "type": [
              "string",
              "null"
            ],
            "description": "An id."
          },
          "createdBy": {
            "type": "string",
            "description": "An id."
          },
          "heldByPause": {
            "type": "boolean",
            "description": "Held because the organisation's plan is paused."
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "_id",
          "organisationId",
          "spaceId",
          "environmentId",
          "targetEnvironmentId",
          "name",
          "description",
          "status",
          "items",
          "scheduledAt",
          "publishedAt",
          "publishedBy",
          "createdBy",
          "createdAt",
          "updatedAt"
        ]
      },
      "Experiment": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "key": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "hypothesis": {
            "type": [
              "string",
              "null"
            ]
          },
          "status": {
            "type": "string",
            "enum": [
              "draft",
              "scheduled",
              "running",
              "paused",
              "completed"
            ]
          },
          "scope": {
            "type": "string",
            "enum": [
              "blocks",
              "page"
            ]
          },
          "targetBlockIds": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "page": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "description": "An id."
              },
              "name": {
                "type": "string"
              },
              "url": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "published": {
                "type": "boolean"
              }
            },
            "required": [
              "id",
              "name",
              "url",
              "published"
            ]
          },
          "scopeIds": {
            "type": "object",
            "properties": {
              "environmentId": {
                "type": "string",
                "description": "An id."
              },
              "regionId": {
                "type": "string",
                "description": "An id."
              },
              "localeId": {
                "type": "string",
                "description": "An id."
              }
            },
            "required": [
              "environmentId",
              "regionId",
              "localeId"
            ]
          },
          "variants": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "key": {
                  "type": "string",
                  "description": "a is the original, then b, c and d."
                },
                "name": {
                  "type": "string"
                },
                "control": {
                  "type": "boolean"
                },
                "weight": {
                  "type": "integer"
                },
                "changed": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  },
                  "description": "Blocks or fields that differ from the original."
                },
                "edited": {
                  "type": "boolean"
                }
              },
              "required": [
                "key",
                "name",
                "control",
                "weight",
                "changed",
                "edited"
              ]
            }
          },
          "traffic": {
            "type": "integer",
            "description": "Per cent of visitors in the experiment."
          },
          "audience": {
            "type": "object",
            "properties": {
              "devices": {
                "type": "array",
                "items": {
                  "type": "string",
                  "enum": [
                    "desktop",
                    "mobile",
                    "tablet"
                  ]
                }
              },
              "visitors": {
                "type": "string",
                "enum": [
                  "all",
                  "new",
                  "returning"
                ]
              },
              "utm": {
                "type": "object",
                "properties": {
                  "source": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "medium": {
                    "type": [
                      "string",
                      "null"
                    ]
                  },
                  "campaign": {
                    "type": [
                      "string",
                      "null"
                    ]
                  }
                },
                "required": [
                  "source",
                  "medium",
                  "campaign"
                ]
              },
              "countries": {
                "type": "array",
                "items": {
                  "type": "string",
                  "description": "Such as NO."
                }
              }
            },
            "required": [
              "devices",
              "visitors",
              "utm",
              "countries"
            ]
          },
          "goal": {
            "type": "object",
            "properties": {
              "key": {
                "type": "string"
              },
              "label": {
                "type": "string",
                "description": "Such as Booked a trip."
              },
              "goal": {
                "type": "object",
                "description": "What counts. page has path and match, event has name, insights has goalId, name and rule.",
                "properties": {
                  "kind": {
                    "type": "string",
                    "enum": [
                      "click",
                      "form",
                      "engaged",
                      "page",
                      "event",
                      "insights"
                    ]
                  }
                },
                "required": [
                  "kind"
                ]
              }
            },
            "required": [
              "key",
              "label",
              "goal"
            ]
          },
          "guardrails": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "key": {
                  "type": "string"
                },
                "label": {
                  "type": "string",
                  "description": "Such as Booked a trip."
                },
                "goal": {
                  "type": "object",
                  "description": "What counts. page has path and match, event has name, insights has goalId, name and rule.",
                  "properties": {
                    "kind": {
                      "type": "string",
                      "enum": [
                        "click",
                        "form",
                        "engaged",
                        "page",
                        "event",
                        "insights"
                      ]
                    }
                  },
                  "required": [
                    "kind"
                  ]
                }
              },
              "required": [
                "key",
                "label",
                "goal"
              ]
            }
          },
          "mode": {
            "type": "string",
            "enum": [
              "split",
              "bandit"
            ]
          },
          "startAt": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "endAt": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "minDays": {
            "type": "integer"
          },
          "startedAt": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "endedAt": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "winner": {
            "type": [
              "string",
              "null"
            ]
          },
          "holdWinner": {
            "type": "boolean"
          },
          "promotedAt": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "id",
          "key",
          "name",
          "hypothesis",
          "status",
          "scope",
          "targetBlockIds",
          "page",
          "scopeIds",
          "variants",
          "traffic",
          "audience",
          "goal",
          "guardrails",
          "mode",
          "startAt",
          "endAt",
          "minDays",
          "startedAt",
          "endedAt",
          "winner",
          "holdWinner",
          "promotedAt",
          "createdAt",
          "updatedAt"
        ]
      },
      "Webhook": {
        "type": "object",
        "properties": {
          "_id": {
            "type": "string",
            "description": "An id."
          },
          "organisationId": {
            "type": "string",
            "description": "An id."
          },
          "spaceId": {
            "type": "string",
            "description": "An id."
          },
          "environmentId": {
            "type": [
              "string",
              "null"
            ],
            "description": "null for every environment."
          },
          "name": {
            "type": "string"
          },
          "url": {
            "type": "string"
          },
          "events": {
            "type": "array",
            "items": {
              "type": "string",
              "description": "Such as content.published."
            }
          },
          "enabled": {
            "type": "boolean"
          },
          "headers": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            },
            "description": "Headers sent with each delivery."
          },
          "lastDeliveryAt": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "failureCount": {
            "type": "integer",
            "description": "Failures in a row. At 20 the webhook is turned off."
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          }
        },
        "required": [
          "_id",
          "organisationId",
          "spaceId",
          "environmentId",
          "name",
          "url",
          "events",
          "enabled",
          "headers",
          "lastDeliveryAt",
          "failureCount",
          "createdAt",
          "updatedAt"
        ]
      },
      "Taxonomy": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "key": {
            "type": "string",
            "description": "Such as activity."
          },
          "name": {
            "type": "string"
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "termCount": {
            "type": "integer"
          }
        },
        "required": [
          "id",
          "key",
          "name",
          "description",
          "termCount"
        ]
      },
      "Term": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "value": {
            "type": "string",
            "description": "Such as kayaking."
          },
          "label": {
            "type": "string"
          },
          "labels": {
            "type": "object",
            "additionalProperties": {
              "type": "string"
            },
            "description": "By language code, such as { \"nb-NO\": \"Padling\" }."
          },
          "regions": {
            "type": "object",
            "additionalProperties": {
              "type": "object",
              "properties": {
                "hidden": {
                  "type": "boolean",
                  "description": "Left out for this region."
                },
                "labels": {
                  "type": "object",
                  "additionalProperties": {
                    "type": "string"
                  },
                  "description": "By language code; they win over labels in this region."
                }
              },
              "required": []
            },
            "description": "Overrides by region key."
          },
          "sortOrder": {
            "type": "integer"
          }
        },
        "required": [
          "id",
          "value",
          "label",
          "labels",
          "regions",
          "sortOrder"
        ]
      },
      "AccessibilitySettings": {
        "type": "object",
        "properties": {
          "publish": {
            "type": "string",
            "description": "Whether accessibility problems warn or block publishing.",
            "enum": [
              "off",
              "warn",
              "block"
            ]
          },
          "tags": {
            "type": "array",
            "items": {
              "type": "string",
              "description": "Such as wcag2aa."
            },
            "description": "The rule sets that apply."
          }
        },
        "required": [
          "publish",
          "tags"
        ]
      },
      "SiteSeo": {
        "type": "object",
        "properties": {
          "xDefaultRegion": {
            "type": [
              "string",
              "null"
            ]
          },
          "organisationName": {
            "type": [
              "string",
              "null"
            ]
          },
          "socialProfiles": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "robotsTxt": {
            "type": [
              "string",
              "null"
            ]
          },
          "titleTemplate": {
            "type": [
              "string",
              "null"
            ],
            "description": "Such as %s | Northwilds."
          },
          "defaultDescription": {
            "type": [
              "string",
              "null"
            ]
          },
          "defaultImage": {
            "type": [
              "string",
              "null"
            ],
            "description": "A media id."
          },
          "twitterHandle": {
            "type": [
              "string",
              "null"
            ]
          },
          "verification": {
            "type": "object",
            "properties": {
              "google": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "bing": {
                "type": [
                  "string",
                  "null"
                ]
              }
            },
            "required": []
          },
          "websitePaths": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "indexNow": {
            "type": "boolean",
            "description": "Tells search engines through IndexNow when a page is published, unpublished, moved or deleted in an environment they may index. On unless switched off."
          }
        },
        "required": [
          "xDefaultRegion",
          "organisationName",
          "socialProfiles",
          "robotsTxt"
        ]
      },
      "BookingConnection": {
        "type": "object",
        "properties": {
          "reachable": {
            "type": "boolean",
            "description": "Booking Orbit answered."
          },
          "location": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/BookingLocation"
              },
              {
                "type": "null"
              }
            ]
          },
          "locations": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/BookingLocation"
            }
          },
          "connection": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "locationId": {
                "type": "string"
              },
              "slug": {
                "type": "string"
              },
              "locationName": {
                "type": "string"
              },
              "siteUrl": {
                "type": "string"
              },
              "connectedAt": {
                "type": "string",
                "format": "date-time"
              },
              "connectedBy": {
                "type": [
                  "string",
                  "null"
                ]
              }
            },
            "required": [
              "locationId",
              "slug",
              "locationName",
              "siteUrl",
              "connectedAt",
              "connectedBy"
            ]
          },
          "canManage": {
            "type": "boolean"
          }
        },
        "required": [
          "reachable",
          "location",
          "locations",
          "connection",
          "canManage"
        ]
      },
      "BookingLocation": {
        "type": "object",
        "properties": {
          "locationId": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "siteUrl": {
            "type": [
              "string",
              "null"
            ]
          },
          "kind": {
            "type": "string",
            "enum": [
              "place",
              "online"
            ]
          },
          "timeZone": {
            "type": "string"
          },
          "currency": {
            "type": "string"
          },
          "logoUrl": {
            "type": [
              "string",
              "null"
            ]
          }
        },
        "required": [
          "locationId",
          "slug",
          "name",
          "siteUrl",
          "kind",
          "timeZone",
          "currency",
          "logoUrl"
        ]
      },
      "CareersConnection": {
        "type": "object",
        "properties": {
          "reachable": {
            "type": "boolean"
          },
          "site": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "slug": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "siteUrl": {
                "type": "string"
              },
              "logoUrl": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "languages": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              },
              "defaultLanguage": {
                "type": "string"
              }
            },
            "required": [
              "slug",
              "name",
              "siteUrl",
              "logoUrl",
              "languages",
              "defaultLanguage"
            ]
          },
          "connection": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "siteSlug": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "siteUrl": {
                "type": "string"
              },
              "connectedAt": {
                "type": "string",
                "format": "date-time"
              },
              "connectedBy": {
                "type": [
                  "string",
                  "null"
                ]
              }
            },
            "required": [
              "siteSlug",
              "name",
              "siteUrl",
              "connectedAt",
              "connectedBy"
            ]
          },
          "canManage": {
            "type": "boolean"
          }
        },
        "required": [
          "reachable",
          "site",
          "connection",
          "canManage"
        ]
      },
      "CommerceConnection": {
        "type": "object",
        "properties": {
          "reachable": {
            "type": "boolean"
          },
          "store": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/CommerceStore"
              },
              {
                "type": "null"
              }
            ]
          },
          "stores": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/CommerceStore"
            }
          },
          "connection": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "storeSlug": {
                "type": "string"
              },
              "brandName": {
                "type": "string"
              },
              "siteUrl": {
                "type": "string"
              },
              "connectedAt": {
                "type": "string",
                "format": "date-time"
              },
              "connectedBy": {
                "type": [
                  "string",
                  "null"
                ]
              }
            },
            "required": [
              "storeSlug",
              "brandName",
              "siteUrl",
              "connectedAt",
              "connectedBy"
            ]
          },
          "canManage": {
            "type": "boolean"
          }
        },
        "required": [
          "reachable",
          "store",
          "stores",
          "connection",
          "canManage"
        ]
      },
      "CommerceStore": {
        "type": "object",
        "properties": {
          "shopId": {
            "type": "string"
          },
          "storeSlug": {
            "type": "string"
          },
          "brandName": {
            "type": "string"
          },
          "siteUrl": {
            "type": "string"
          },
          "locales": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "defaultLocale": {
            "type": "string"
          },
          "currency": {
            "type": "string"
          },
          "currencies": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        },
        "required": [
          "shopId",
          "storeSlug",
          "brandName",
          "siteUrl",
          "locales",
          "defaultLocale",
          "currency",
          "currencies"
        ]
      },
      "PresenceConnection": {
        "type": "object",
        "properties": {
          "reachable": {
            "type": "boolean"
          },
          "brandName": {
            "type": [
              "string",
              "null"
            ]
          },
          "locations": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/PresenceLocation"
            }
          },
          "connection": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "siteSlug": {
                "type": "string"
              },
              "brandName": {
                "type": "string"
              },
              "connectedAt": {
                "type": "string",
                "format": "date-time"
              },
              "connectedBy": {
                "type": [
                  "string",
                  "null"
                ]
              }
            },
            "required": [
              "siteSlug",
              "brandName",
              "connectedAt",
              "connectedBy"
            ]
          },
          "canManage": {
            "type": "boolean"
          }
        },
        "required": [
          "reachable",
          "brandName",
          "locations",
          "connection",
          "canManage"
        ]
      },
      "PresenceLocation": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "city": {
            "type": "string"
          },
          "average": {
            "type": [
              "number",
              "null"
            ],
            "description": "The average rating."
          },
          "total": {
            "type": "integer",
            "description": "Reviews counted."
          }
        },
        "required": [
          "id",
          "name",
          "slug",
          "city",
          "average",
          "total"
        ]
      },
      "TravelConnection": {
        "type": "object",
        "properties": {
          "reachable": {
            "type": "boolean"
          },
          "brands": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/TravelBrand"
            }
          },
          "site": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/TravelBrand"
              },
              {
                "type": "null"
              }
            ]
          },
          "connection": {
            "type": [
              "object",
              "null"
            ],
            "properties": {
              "brandId": {
                "type": "string"
              },
              "bookingSlug": {
                "type": "string"
              },
              "brandName": {
                "type": "string"
              },
              "siteUrl": {
                "type": "string"
              },
              "connectedAt": {
                "type": "string",
                "format": "date-time"
              },
              "connectedBy": {
                "type": [
                  "string",
                  "null"
                ]
              }
            },
            "required": [
              "bookingSlug",
              "brandName",
              "siteUrl",
              "connectedAt",
              "connectedBy"
            ]
          },
          "canManage": {
            "type": "boolean"
          }
        },
        "required": [
          "reachable",
          "brands",
          "site",
          "connection",
          "canManage"
        ]
      },
      "InsightsConnection": {
        "type": "object",
        "properties": {
          "linked": {
            "type": [
              "object",
              "null"
            ],
            "description": "The linked Insights Orbit site.",
            "properties": {
              "site": {
                "type": "string"
              },
              "name": {
                "type": "string"
              }
            },
            "required": [
              "site",
              "name"
            ]
          },
          "sites": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "site": {
                  "type": "string"
                },
                "name": {
                  "type": "string"
                },
                "domains": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                },
                "spaces": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "spaceId": {
                        "type": "string",
                        "description": "An id."
                      },
                      "name": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "spaceId",
                      "name"
                    ]
                  }
                }
              },
              "required": [
                "site",
                "name",
                "domains",
                "spaces"
              ]
            }
          },
          "canManage": {
            "type": "boolean"
          },
          "canEdit": {
            "type": "boolean"
          },
          "suggestion": {
            "type": "object",
            "description": "A name and domains for a new site, from the space's domains.",
            "properties": {
              "name": {
                "type": "string"
              },
              "domains": {
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            },
            "required": [
              "name",
              "domains"
            ]
          },
          "reportUrl": {
            "type": [
              "string",
              "null"
            ]
          },
          "error": {
            "type": [
              "string",
              "null"
            ]
          }
        },
        "required": [
          "linked",
          "sites",
          "canManage",
          "canEdit",
          "suggestion",
          "reportUrl",
          "error"
        ]
      },
      "TravelBrand": {
        "type": "object",
        "properties": {
          "brandId": {
            "type": "string"
          },
          "bookingSlug": {
            "type": "string"
          },
          "brandName": {
            "type": "string"
          },
          "logoUrl": {
            "type": [
              "string",
              "null"
            ]
          },
          "siteUrl": {
            "type": "string"
          },
          "locales": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "defaultLocale": {
            "type": "string"
          }
        },
        "required": [
          "brandId",
          "bookingSlug",
          "brandName",
          "siteUrl",
          "locales",
          "defaultLocale"
        ]
      },
      "SpaceSummary": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "An id."
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "description": {
            "type": [
              "string",
              "null"
            ]
          },
          "logoUrl": {
            "type": [
              "string",
              "null"
            ]
          },
          "environments": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "An id."
                },
                "name": {
                  "type": "string"
                },
                "key": {
                  "type": "string"
                },
                "kind": {
                  "type": "string"
                }
              },
              "required": [
                "id",
                "name",
                "key",
                "kind"
              ]
            }
          },
          "regionCount": {
            "type": "integer"
          },
          "localeCount": {
            "type": "integer"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          },
          "snapshotUrl": {
            "type": [
              "string",
              "null"
            ],
            "description": "A screenshot of the website's home page."
          },
          "pages": {
            "type": "object",
            "properties": {
              "live": {
                "type": "integer"
              },
              "changed": {
                "type": "integer",
                "description": "Published pages with unpublished changes."
              }
            },
            "required": [
              "live",
              "changed"
            ]
          }
        },
        "required": [
          "id",
          "name",
          "slug",
          "description",
          "logoUrl",
          "environments",
          "regionCount",
          "localeCount",
          "updatedAt",
          "snapshotUrl",
          "pages"
        ]
      },
      "Schedule": {
        "type": "object",
        "properties": {
          "releaseId": {
            "type": "string",
            "description": "The release it's in."
          },
          "action": {
            "type": "string",
            "enum": [
              "publish",
              "unpublish"
            ]
          },
          "at": {
            "type": "string",
            "format": "date-time"
          },
          "sharedWith": {
            "type": "integer",
            "description": "Other pages in the same release."
          }
        },
        "required": [
          "releaseId",
          "action",
          "at",
          "sharedWith"
        ]
      }
    },
    "securitySchemes": {
      "bearer": {
        "type": "http",
        "scheme": "bearer",
        "description": "A management token, cms_mt_…. Keep it on a server."
      }
    }
  }
}
