{
  "openapi": "3.1.0",
  "info": { "title": "Field-Viewer API", "version": "1.0.0" },
  "servers": [
    { "url": "https://api.field-viewer.com", "description": "Production" }
  ],
  "security": [{ "bearerAuth": [] }],
  "tags": [
    { "name": "annotation" },
    { "name": "annotations" },
    { "name": "apiContext" },
    { "name": "apiToken" },
    { "name": "apiTokens" },
    { "name": "auditEvents" },
    { "name": "auditLogExport" },
    { "name": "betaAccessCode" },
    { "name": "betaAccessCodes" },
    { "name": "billingAccount" },
    { "name": "billingPortalSession" },
    { "name": "checkoutSession" },
    { "name": "currentProjectRevision" },
    { "name": "deepLink" },
    { "name": "document" },
    { "name": "documentText" },
    { "name": "documentVersion" },
    { "name": "documentVersionArtifacts" },
    { "name": "documentVersionPageScale" },
    { "name": "documentVersionProcessing" },
    { "name": "documentVersionSource" },
    { "name": "documentVersionUpload" },
    { "name": "documentVersions" },
    { "name": "documents" },
    { "name": "elements" },
    { "name": "emailChange" },
    { "name": "emailSignIn" },
    { "name": "emailSignInCode" },
    { "name": "emailVerification" },
    { "name": "entitlements" },
    { "name": "failedModelVersions" },
    { "name": "feedback" },
    { "name": "invitation" },
    { "name": "invitationPreview" },
    { "name": "invitations" },
    { "name": "invoices" },
    { "name": "joinLink" },
    { "name": "layerRule" },
    { "name": "layerSet" },
    { "name": "layerSets" },
    { "name": "layerTemplate" },
    { "name": "layerTemplates" },
    { "name": "legalDocumentVersions" },
    { "name": "legalDocuments" },
    { "name": "link" },
    { "name": "linkCoverage" },
    { "name": "linkDiscoveryRun" },
    { "name": "linkImport" },
    { "name": "linkRule" },
    { "name": "linkRuleRun" },
    { "name": "linkRules" },
    { "name": "links" },
    { "name": "me" },
    { "name": "member" },
    { "name": "memberRole" },
    { "name": "members" },
    { "name": "model" },
    { "name": "modelVersion" },
    { "name": "modelVersionAsSupport" },
    { "name": "modelVersionSource" },
    { "name": "modelVersionUpload" },
    { "name": "myAccess" },
    { "name": "myAccount" },
    { "name": "myDataExport" },
    { "name": "myInvitation" },
    { "name": "myInvitations" },
    { "name": "myNotifications" },
    { "name": "myOAuthGrant" },
    { "name": "myOAuthGrants" },
    { "name": "myOrganizations" },
    { "name": "mySecurityState" },
    { "name": "mySessions" },
    { "name": "notificationRead" },
    { "name": "oAuthAuthorizationRequest" },
    { "name": "oAuthGrant" },
    { "name": "oAuthGrants" },
    { "name": "onboardingStatus" },
    { "name": "organization" },
    { "name": "organizationActivations" },
    { "name": "organizationDeletion" },
    { "name": "organizationDiscount" },
    { "name": "organizationEntitlements" },
    { "name": "organizationLogoUpload" },
    { "name": "organizationSupportAccess" },
    { "name": "ownership" },
    { "name": "planPrice" },
    { "name": "plans" },
    { "name": "platformFlag" },
    { "name": "platformFlags" },
    { "name": "platformOrganization" },
    { "name": "platformOrganizations" },
    { "name": "platformRuntime" },
    { "name": "platformTryoutStats" },
    { "name": "priceToSubscriptions" },
    { "name": "pricing" },
    { "name": "pricingSettings" },
    { "name": "project" },
    { "name": "projectAccessMode" },
    { "name": "projectMember" },
    { "name": "projectMembers" },
    { "name": "projectRevision" },
    { "name": "projectRevisions" },
    { "name": "projectScene" },
    { "name": "projects" },
    { "name": "researchConsent" },
    { "name": "roles" },
    { "name": "sampleProject" },
    { "name": "sampleScene" },
    { "name": "samples" },
    { "name": "savedView" },
    { "name": "scheduledPriceChanges" },
    { "name": "serviceStatus" },
    { "name": "sharedViewOrder" },
    { "name": "signInMethods" },
    { "name": "spatialTree" },
    { "name": "subscription" },
    { "name": "supportAccess" },
    { "name": "supportAccessRequest" },
    { "name": "supportAccessRequests" },
    { "name": "surveyResponse" },
    { "name": "telemetryBatch" },
    { "name": "trial" },
    { "name": "tryout" },
    { "name": "tryoutDrawings" },
    { "name": "usageSummary" },
    { "name": "view" },
    { "name": "views" },
    { "name": "workstation" },
    { "name": "workstationHeartbeat" },
    { "name": "workstationPairing" },
    { "name": "workstationPairingCode" },
    { "name": "workstationPreset" },
    { "name": "workstations" }
  ],
  "paths": {
    "/v1/auth/email-sign-in": {
      "post": {
        "operationId": "requestEmailSignIn",
        "summary": "Request a sign-in code by e-mail",
        "description": "Sends a branded e-mail carrying both a magic sign-in link (completes on the SAME device) and a 6-digit one-time code (completes on a DIFFERENT device -- the tablet/phone case E02-S19 exists for). Always returns the same `{ challengeId }` shape regardless of whether `email` has an account, and never reveals that fact (§6.6: an own OTP endpoint is a brute-force target; generic responses are the mitigation). A caller already signed in with a second factor still receives a code here -- `verifyEmailSignInCode` is what refuses it (BR-5). Throttled to 5 requests/address/hour and 20/IP/hour (BR-4); a request past either limit fails `429 rate_limit.exceeded`. Requesting again for the same address supersedes every still-open challenge for it (AC-3): their codes stop verifying immediately, even within their own 10-minute TTL. A network retry of the exact same call (same Idempotency-Key) never mints or mails a second code. Bot protection (E02-S34): while reCAPTCHA enforcement is on, a request without a passing `recaptchaToken` for the `request_email_sign_in` action fails `403 auth.recaptcha_failed` before anything is sent.",
        "tags": ["emailSignIn"],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "email": {
                    "type": "string",
                    "format": "email",
                    "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
                  },
                  "locale": { "type": "string", "enum": ["nl", "en", "fr"] },
                  "continueUrl": { "type": "string", "format": "uri" },
                  "recaptchaToken": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 4096
                  }
                },
                "additionalProperties": false,
                "required": ["continueUrl", "email", "locale"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Request a sign-in code by e-mail",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/requestEmailSignInOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "auth.recaptcha_failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "429": {
            "description": "rate_limit.exceeded",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "security": [],
        "x-fv-capability": "public",
        "x-fv-side-effect": "write",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_request_email_sign_in",
        "x-fv-rate-limit-class": "auth"
      }
    },
    "/v1/auth/email-sign-in/verify": {
      "post": {
        "operationId": "verifyEmailSignInCode",
        "summary": "Verify a sign-in code and sign in",
        "description": "Verifies the 6-digit code from `requestEmailSignIn`'s e-mail against the given challenge and, on success, mints a Firebase custom token the caller's client completes sign-in with (`signInWithCustomToken`). Refuses `403 auth.sign_in_code_invalid` for a wrong code, an unknown/expired/superseded/already-used challenge, or one whose 5 attempts (BR-4) are already spent -- deliberately the SAME code for all of these, so a caller can never tell them apart (§6.6). The 6th attempt against a challenge is refused regardless of whether the code submitted this time is correct (AC-2). Refuses `403 auth.second_factor_required` for an account with an enrolled second factor (BR-5) -- code sign-in never completes for it; the caller falls back to the magic link or a password. With `linkAnonymous: true` the caller's own anonymous session (a website tryout) gets the verified address and keeps its uid; an address that already has an account is `409 auth.email_in_use`, and the code then stays valid to sign in to that account (without `linkAnonymous`). Fires `user.signedInWithCode` on success.",
        "tags": ["emailSignInCode"],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "challengeId": {
                    "type": "string",
                    "pattern": "^sic_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A sic identifier (TypeID, conventions C5)."
                  },
                  "code": {
                    "type": "string",
                    "pattern": "^[0-9]{6}$",
                    "description": "6-digit numeric one-time code."
                  },
                  "linkAnonymous": {
                    "description": "true: verify the code for the caller's own anonymous session (keeping a tryout); the address is added to that account instead of signing in to another one.",
                    "type": "boolean",
                    "const": true
                  }
                },
                "additionalProperties": false,
                "required": ["challengeId", "code"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Verify a sign-in code and sign in",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/verifyEmailSignInCodeOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "auth.second_factor_required, auth.sign_in_code_invalid",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "auth.email_in_use",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "security": [],
        "x-fv-capability": "public",
        "x-fv-side-effect": "write",
        "x-fv-events": ["user.signedInWithCode"],
        "x-fv-mcp-tool": "fv_verify_email_sign_in_code",
        "x-fv-rate-limit-class": "auth"
      }
    },
    "/v1/auth/sign-in-methods": {
      "post": {
        "operationId": "getSignInMethods",
        "summary": "Which sign-in methods an e-mail address uses",
        "description": "Returns the sign-in methods of the account for `email`, most direct first: `google`, `microsoft`, `password`, `emailLink`. Used by the sign-in screen after a Google or Microsoft sign-in found an existing account under another method, so it can name that method and link the new one after the user signed in with it. Public. Throttled per IP (`auth` rate class, `429 rate_limit.exceeded` past it). Always answers the same shape: an address without an account answers `[\"emailLink\"]`, the same as an account that signs in by e-mail link or code only.",
        "tags": ["signInMethods"],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "email": {
                    "type": "string",
                    "format": "email",
                    "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
                  }
                },
                "additionalProperties": false,
                "required": ["email"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Which sign-in methods an e-mail address uses",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getSignInMethodsOutput"
                }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "429": {
            "description": "rate_limit.exceeded",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "security": [],
        "x-fv-capability": "public",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_sign_in_methods",
        "x-fv-rate-limit-class": "auth"
      }
    },
    "/v1/context": {
      "get": {
        "operationId": "getApiContext",
        "summary": "Get the context of the current credential",
        "description": "Returns what the credential on this call resolves to: the principal type (API token, connected OAuth app, user or workstation), its id and -- for an API token or a connected app -- its name, the organisation an org-bound credential belongs to, its scopes, and this environment's MCP server URL and API reference. Use it to check that a newly created token or connection works. Read-only and side-effect free.",
        "tags": ["apiContext"],
        "responses": {
          "200": {
            "description": "Get the context of the current credential",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/getApiContextOutput" }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "authenticated",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_api_context",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/invitations/accept": {
      "post": {
        "operationId": "acceptInvitation",
        "summary": "Accept a pending invitation",
        "description": "Accepts a pending invitation with the signed-in account (BR-22/BR-23). For role `admin`, the account's verified e-mail must equal the invited address (`403 invitation.email_mismatch`); any other role allows a mismatch, stored as `acceptedEmail` and flagged. An existing active membership's role never changes (BR-23) -- only the invitation's own project access is added. A join link (`kind: link`, FV-69) is multi-use: each join increments `useCount` and the join that reaches `maxUses` sets `status: exhausted`; a caller who is already an active member gets `200` with `alreadyMember: true` and nothing changes (§5.6). `404 resource.not_found` for an unknown, expired, revoked, exhausted or already-accepted token. A new membership takes a seat (or guest slot): `403 entitlement.limit_reached` when the plan is full at accept time -- nothing is written and the invitation stays pending (FV-434). Fires `invitation.accepted`, `member.joined` (new/reactivated membership only) and `project.member.added` per project; every join through a link also notifies the organisation's owners and admins.",
        "tags": ["invitation"],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "token": {
                    "type": "string",
                    "minLength": 1,
                    "description": "The raw accept token from the invitation link, in the JSON body (never in the URL)."
                  }
                },
                "additionalProperties": false,
                "required": ["token"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Accept a pending invitation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/acceptInvitationOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "entitlement.limit_reached, invitation.email_mismatch, permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "write",
        "x-fv-events": [
          "invitation.accepted",
          "member.joined",
          "project.member.added"
        ],
        "x-fv-mcp-tool": "fv_accept_invitation",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/invitations/preview": {
      "get": {
        "operationId": "getInvitationPreview",
        "summary": "Preview an invitation before signing in",
        "description": "Returns the kind (`email` invitation or `link` join link), organisation name, role, projects (guest invitations) and the inviter's display name for a pending, unexpired invitation token, sent in the `X-Invitation-Token` request header (never in the URL, so it stays out of request logs). Public (no authentication). Returns `404 resource.not_found` for any token that is unknown, malformed, expired, revoked or already accepted, or a join link that is exhausted -- deliberately without distinguishing which, to avoid token enumeration.",
        "tags": ["invitationPreview"],
        "parameters": [
          {
            "name": "X-Invitation-Token",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1,
              "description": "The raw accept token from the invitation link. Sent as the `X-Invitation-Token` header."
            },
            "x-fv-input": "token"
          }
        ],
        "responses": {
          "200": {
            "description": "Preview an invitation before signing in",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getInvitationPreviewOutput"
                }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "security": [],
        "x-fv-capability": "public",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_invitation_preview",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/legal/documents": {
      "get": {
        "operationId": "getLegalDocumentVersions",
        "summary": "Get the current legal document versions",
        "description": "Returns the terms of use, privacy notice, data processing agreement (DPA), sub-processor list and cookie notice: for each its current `version`, `publishedAt`, whether that version is `material` (asks owners to accept again), the newest material version, where the web app shows it (`path`, readable without an account), the languages its text exists in (nl is the master text) and a changelog entry per version. Public (no authentication).",
        "tags": ["legalDocumentVersions"],
        "responses": {
          "200": {
            "description": "Get the current legal document versions",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getLegalDocumentVersionsOutput"
                }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "security": [],
        "x-fv-capability": "public",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_legal_document_versions",
        "x-fv-rate-limit-class": "read",
        "x-fv-anonymous-access": true
      }
    },
    "/v1/me": {
      "get": {
        "operationId": "getMe",
        "summary": "Get the current user profile",
        "description": "Returns the profile of the user making this call, resolved from the caller's own credential (a verified Firebase ID token). Use it to read the caller's own id, display name, locale, sign-in providers and preferences, for example to greet them or feed other `self`-scoped operations. A signed-in caller who has never called `updateMe` yet still gets a minimal, schema-valid profile derived from their own token, never a 404.",
        "tags": ["me"],
        "parameters": [
          {
            "name": "If-None-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "One or more entity tags (`\"4\"`, `W/\"4\"` or `*`). When one matches the current revision the answer is 304 Not Modified with no body."
          }
        ],
        "responses": {
          "200": {
            "description": "Get the current user profile",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/getMeOutput" }
              }
            }
          },
          "304": {
            "description": "Not Modified: the If-None-Match entity tag still matches.",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_me",
        "x-fv-rate-limit-class": "read",
        "x-fv-anonymous-access": true
      },
      "patch": {
        "operationId": "updateMe",
        "summary": "Update the current user's profile",
        "description": "Upserts the caller's own profile: `displayName` (1-80 chars, §5.4), `locale` (nl | en | fr), an optional `localeChosen` (FV-452: true when the user explicitly chose `locale`, so every device follows it), an optional `lastOrgId` (E02-S09 AC-2: the organisation switcher writes this on every switch) and an optional `onboardingChecklistDismissed` (FV-208 AC-3: the get-started checklist's own per-user dismiss flag) and an optional `gesturesCoached` (FV-219: the viewer gesture coach-marks the caller has been shown, merged into the stored list, never removed) and an optional `lengthUnit` (FV-238: mm, cm or m, how measured lengths are displayed) and an optional `measureSnap` (FV-433: the measure tool's snap targets switched off and its snap radius) and an optional `trackpadScroll` (FV-472: pan or zoom on a two-finger trackpad scroll) and an optional `modelColours` (FV-515: the file's own colours or always the Field-Viewer palette in the 3D viewer) and an optional `layers` (FV-513: the caller's personal layer defaults, merged in) and an optional `analyticsOptOut` (FV-464: switches the app's technical measurements off) and an optional `privacyAcknowledgedVersion` (FV-174: the privacy notice version the caller acknowledged). Creates `users/{uid}` with `schemaVersion: 1` on the caller's first call (AC-1); on every later call, merges these fields and bumps `revision`, preserving `security`/`createdAt`/`createdBy` and any part of `preferences` not passed. Fires `user.profileUpdated`.",
        "tags": ["me"],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "displayName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 80,
                    "description": "Display name shown in the UI (1-80 chars, §5.4)."
                  },
                  "locale": { "type": "string", "enum": ["nl", "en", "fr"] },
                  "localeChosen": {
                    "description": "True when the user explicitly chose `locale` (profile screen): every device then opens in it (FV-452). Omit to leave `localeChosen` unchanged.",
                    "type": "boolean"
                  },
                  "lastOrgId": {
                    "description": "The organisation the caller just switched into (E02-S09). Omit to leave `preferences.lastOrgId` unchanged.",
                    "type": "string",
                    "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
                  },
                  "onboardingChecklistDismissed": {
                    "description": "Dismiss (true) or re-show (false) the get-started checklist panel (FV-208). Omit to leave `preferences.onboardingChecklistDismissed` unchanged.",
                    "type": "boolean"
                  },
                  "gesturesCoached": {
                    "description": "Viewer gesture coach-marks the caller has now been shown (orbit, zoom, select; FV-219). Added to `preferences.gesturesCoached`, never removed from it. Omit to leave it unchanged.",
                    "maxItems": 3,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "enum": ["orbit", "zoom", "select"]
                    }
                  },
                  "lengthUnit": {
                    "description": "Display unit for measured lengths: mm, cm or m (FV-238). Display only. Omit to leave `preferences.lengthUnit` unchanged.",
                    "type": "string",
                    "enum": ["mm", "cm", "m"]
                  },
                  "measureSnap": {
                    "description": "Measure snap settings (FV-433): the snap targets switched off and the snap radius (small, medium or large). Replaces `preferences.measureSnap`; omit to leave it unchanged.",
                    "type": "object",
                    "properties": {
                      "off": {
                        "maxItems": 7,
                        "type": "array",
                        "items": {
                          "type": "string",
                          "enum": [
                            "vertex",
                            "edgeIntersection",
                            "edgeMidpoint",
                            "circleCentre",
                            "perpendicular",
                            "edgePoint",
                            "facePoint"
                          ]
                        },
                        "description": "Snap targets switched off: vertex, edgeIntersection, edgeMidpoint, circleCentre, perpendicular, edgePoint, facePoint."
                      },
                      "radius": {
                        "type": "string",
                        "enum": ["small", "medium", "large"],
                        "description": "Snap radius: small, medium (default) or large."
                      }
                    },
                    "required": ["off", "radius"],
                    "additionalProperties": false
                  },
                  "trackpadScroll": {
                    "description": "What a two-finger trackpad scroll does in the 3D viewer: pan or zoom (FV-472). Omit to leave `preferences.trackpadScroll` unchanged.",
                    "type": "string",
                    "enum": ["pan", "zoom"]
                  },
                  "modelColours": {
                    "description": "How the 3D viewer colours a model: file (the file's own colours, the Field-Viewer palette where it has none) or palette (always the Field-Viewer palette) (FV-515). Omit to leave `preferences.modelColours` unchanged.",
                    "type": "string",
                    "enum": ["file", "palette"]
                  },
                  "layers": {
                    "description": "Personal layer defaults (FV-513), merged into `preferences.layers`: `projects` sets a project's own on/off overrides (or forgets it with null; the 30 most recently saved are kept), `mine` sets or removes (null) my default by template layer or derivation key, `clear` forgets everything first. Omit to leave them unchanged.",
                    "type": "object",
                    "properties": {
                      "clear": {
                        "description": "Forget every personal layer state first.",
                        "type": "boolean"
                      },
                      "projects": {
                        "description": "Per project: its overrides to keep (replacing the stored ones), or null to forget it.",
                        "type": "object",
                        "propertyNames": {
                          "type": "string",
                          "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A prj identifier (TypeID, conventions C5)."
                        },
                        "additionalProperties": {
                          "anyOf": [
                            {
                              "type": "object",
                              "properties": {
                                "layerSetId": {
                                  "type": "string",
                                  "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                  "description": "A lys identifier (TypeID, conventions C5)."
                                },
                                "overrides": {
                                  "type": "object",
                                  "propertyNames": {
                                    "type": "string",
                                    "pattern": "^[a-z0-9][a-z0-9-]{0,63}$"
                                  },
                                  "additionalProperties": { "type": "boolean" },
                                  "description": "Layer entry id -> on, at most 100."
                                },
                                "mode": {
                                  "type": "string",
                                  "enum": ["project-default"]
                                }
                              },
                              "required": ["layerSetId", "overrides"],
                              "additionalProperties": false
                            },
                            { "type": "null" }
                          ]
                        }
                      },
                      "mine": {
                        "description": "My default: key -> on, or null to remove the key.",
                        "type": "object",
                        "propertyNames": {
                          "type": "string",
                          "maxLength": 120,
                          "pattern": "^(?:template:ltp_[0-9a-z]{26}:[a-z0-9][a-z0-9-]{0,39}|(?:assignment|type|attribute):\\S.*)$"
                        },
                        "additionalProperties": { "type": ["boolean", "null"] }
                      }
                    },
                    "additionalProperties": false
                  },
                  "analyticsOptOut": {
                    "description": "Switch the app's technical measurements (web vitals, client logs) off (true) or on (false) for the caller (FV-464). Omit to leave `preferences.analyticsOptOut` unchanged.",
                    "type": "boolean"
                  },
                  "privacyAcknowledgedVersion": {
                    "description": "The privacy notice version the caller acknowledges (FV-174); must be the current version (409 legal.version_outdated otherwise). Stored with the time as `legal`. Omit to leave it unchanged.",
                    "type": "string",
                    "pattern": "^\\d{1,3}\\.\\d{1,3}$"
                  }
                },
                "additionalProperties": false,
                "required": ["displayName", "locale"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Update the current user's profile",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/updateMeOutput" }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "legal.version_outdated",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "write",
        "x-fv-events": ["user.profileUpdated"],
        "x-fv-mcp-tool": "fv_update_me",
        "x-fv-rate-limit-class": "write",
        "x-fv-anonymous-access": true
      },
      "delete": {
        "operationId": "deleteMyAccount",
        "summary": "Delete my account",
        "description": "Deletes the caller's account immediately (BR-46): every membership is removed (tombstoned as a former member, with name and e-mail erased), the caller's own documents, data exports and Firebase Auth user are deleted, and their OAuth grants are revoked. Content they created in an organisation stays and is shown as \"Deleted user\". Refused with `403 member.last_owner` while the caller is the only active owner of any organisation (BR-11); the `organizationIds` extension lists them -- transfer ownership or delete those organisations first. Requires a fresh re-authentication (BR-8, `403 auth.reauthentication_required`). Fires `user.deleted` and one `member.removed` per membership.",
        "tags": ["myAccount"],
        "parameters": [
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "responses": {
          "204": {
            "description": "No Content",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "member.last_owner, permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["user.deleted", "member.removed", "oauthGrant.revoked"],
        "x-fv-mcp-tool": "fv_delete_my_account",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/me/email-change": {
      "post": {
        "operationId": "requestEmailChange",
        "summary": "Request an e-mail address change",
        "description": "Records the caller's request to change the e-mail address they sign in with (BR-7) and mails a confirmation link to the new address, in the caller's profile language. Requires a fresh re-authentication (BR-8, `403 auth.reauthentication_required`). The address changes only once that link is opened; the old address is told about the change. Refused with `409 user.email_unchanged` for the address the account already uses, `409 conflict.already_exists` when another account signs in with it, and `409 conflict.state` for an account without an address. `503 dependency.unavailable` when the mail could not be sent. Fires `user.emailChangeRequested`, later `user.emailChanged`.",
        "tags": ["emailChange"],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "newEmail": {
                    "type": "string",
                    "maxLength": 254,
                    "format": "email",
                    "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$",
                    "description": "The address the account should move to."
                  }
                },
                "additionalProperties": false,
                "required": ["newEmail"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Request an e-mail address change",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/requestEmailChangeOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.already_exists, conflict.state, user.email_unchanged",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "503": {
            "description": "dependency.unavailable",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "write",
        "x-fv-events": ["user.emailChangeRequested"],
        "x-fv-mcp-tool": "fv_request_email_change",
        "x-fv-rate-limit-class": "auth"
      }
    },
    "/v1/me/email-verification": {
      "post": {
        "operationId": "requestEmailVerification",
        "summary": "Send me the e-mail verification link",
        "description": "Mails the caller a link that confirms the e-mail address they sign in with (BR-7), unless it is already confirmed. `409 conflict.state` for an account without an address; `503 dependency.unavailable` when the mail could not be sent. Writes nothing and fires no event: the address is confirmed once the link is opened.",
        "tags": ["emailVerification"],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "locale": {
                    "description": "Language of the mail (the app's active language). Omitted: the profile language, then the request's Accept-Language, then en.",
                    "type": "string",
                    "enum": ["nl", "en", "fr"]
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Send me the e-mail verification link",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/requestEmailVerificationOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "503": {
            "description": "dependency.unavailable",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "write",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_request_email_verification",
        "x-fv-rate-limit-class": "auth"
      }
    },
    "/v1/me/exports": {
      "post": {
        "operationId": "requestMyDataExport",
        "summary": "Request an export of my personal data",
        "description": "Starts an export of everything Field-Viewer holds about the caller (BR-45): profile, sign-in providers, memberships, invitations sent and received, and 12 months of audit events where the caller is the actor, as one JSON file. Returns the export with `status: pending`; poll `getMyDataExport` until it is `ready` (within 15 minutes) and download it within 24 h. One request per 24 h: a second one is refused with `429 user.data_export_limit`, whose `exportId` extension names the export that holds the slot (unless that export failed). Fires `user.dataExportRequested`, then `user.dataExportReady`.",
        "tags": ["myDataExport"],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Request an export of my personal data",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/requestMyDataExportOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "429": {
            "description": "user.data_export_limit",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "write",
        "x-fv-events": ["user.dataExportRequested", "user.dataExportReady"],
        "x-fv-mcp-tool": "fv_request_my_data_export",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/me/exports/{exportId}": {
      "get": {
        "operationId": "getMyDataExport",
        "summary": "Get one of my personal data exports",
        "description": "Returns the caller's own export (`requestMyDataExport`): its status and, while it is `ready` and inside its 24 h window (BR-45), a `download` ticket -- a signed URL valid for 15 minutes (C13); call again for a fresh one. `expired` and `failed` exports have no link. Another user's export id answers `404 resource.not_found`.",
        "tags": ["myDataExport"],
        "parameters": [
          {
            "name": "exportId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^dex_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A dex identifier (TypeID, conventions C5)."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Get one of my personal data exports",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getMyDataExportOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_my_data_export",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/me/oauth-grants": {
      "get": {
        "operationId": "listMyOAuthGrants",
        "summary": "List my connected AI apps",
        "description": "Lists the OAuth grants (connected AI apps such as claude.ai) the caller approved, in every organisation, active and revoked alike, newest first by default. Never returns a refresh token or its hash. `revokedReason: 'reuse_detected'` marks a grant revoked for security.",
        "tags": ["myOAuthGrants"],
        "parameters": [
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: createdAt | -createdAt | lastUsedAt | -lastUsedAt.",
              "type": "string",
              "enum": ["createdAt", "-createdAt", "lastUsedAt", "-lastUsedAt"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List my connected AI apps",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/listMyOAuthGrantsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_my_oauth_grants",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/me/oauth-grants/{grantId}/revoke": {
      "post": {
        "operationId": "revokeMyOAuthGrant",
        "summary": "Disconnect one of my AI apps",
        "description": "Revokes one of the caller's own OAuth grants at once: `status: 'revoked'`, the app's next refresh fails with `invalid_grant` and its access tokens stop working on the next request. Revoking an already-revoked grant returns it unchanged. Fires `oauthGrant.revoked`.",
        "tags": ["myOAuthGrant"],
        "parameters": [
          {
            "name": "grantId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^grt_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A grt identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Disconnect one of my AI apps",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/revokeMyOAuthGrantOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["oauthGrant.revoked"],
        "x-fv-mcp-tool": "fv_revoke_my_oauth_grant",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/me/organizations": {
      "get": {
        "operationId": "listMyOrganizations",
        "summary": "List the organisations the current user belongs to",
        "description": "Lists the organisations the caller has an active membership in, each with the caller's own role (FV-42 / E02-S09 AC-1). A freshly created user with no memberships yet gets `{ data: [] }` (AC-3), not an error.",
        "tags": ["myOrganizations"],
        "parameters": [
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: name | -name.",
              "type": "string",
              "enum": ["name", "-name"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List the organisations the current user belongs to",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/listMyOrganizationsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_my_organizations",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/me/security/refresh": {
      "post": {
        "operationId": "refreshMySecurityState",
        "summary": "Refresh my sign-in methods",
        "description": "Re-reads the caller's account from the identity provider and stores its sign-in methods (`security.providers`, `security.passwordSet`), two-step verification state (`security.mfaEnrolled`) and e-mail address on the caller's profile. A changed e-mail address is also updated on every membership (§5.6). Returns the profile (same shape as `getMe`). Fires `user.signInMethodChanged`, `user.mfaEnrolled`, `user.mfaUnenrolled` and `user.emailChanged` for whatever changed; nothing when nothing changed.",
        "tags": ["mySecurityState"],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Refresh my sign-in methods",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/refreshMySecurityStateOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "write",
        "x-fv-events": [
          "user.signInMethodChanged",
          "user.mfaEnrolled",
          "user.mfaUnenrolled",
          "user.emailChanged"
        ],
        "x-fv-mcp-tool": "fv_refresh_my_security_state",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/me/sessions/revoke": {
      "post": {
        "operationId": "revokeMySessions",
        "summary": "Sign out everywhere",
        "description": "Ends every session of the caller on every device (BR-42), including the one making this call: `sessionsValidAfter` is stamped on each of the caller's memberships and on their account, so Firestore refuses older sessions at once and the API answers `401 auth.token_revoked` within 60 seconds; refresh tokens are revoked as well. Downloaded projects on a device stay until that device signs out. Fires `user.sessionsRevoked`.",
        "tags": ["mySessions"],
        "parameters": [
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Sign out everywhere",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/revokeMySessionsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["user.sessionsRevoked"],
        "x-fv-mcp-tool": "fv_revoke_my_sessions",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/oauth/authorization-requests/{requestId}": {
      "get": {
        "operationId": "getOAuthAuthorizationRequest",
        "summary": "Read an OAuth authorization request for consent",
        "description": "Reads the client host, redirect host, loopback flag, requested scopes and status of a pending OAuth authorization request -- what the `/oauth/consent` web route renders. Never returns the raw `client_id`/`redirect_uri` (BR-14: only their hosts). A request past its 10-minute TTL (§4.4) is returned with `status: 'expired'`.",
        "tags": ["oAuthAuthorizationRequest"],
        "parameters": [
          {
            "name": "requestId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^oar_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A oar identifier (TypeID, conventions C5)."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Read an OAuth authorization request for consent",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getOAuthAuthorizationRequestOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_oauth_authorization_request",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/oauth/authorization-requests/{requestId}/approve": {
      "post": {
        "operationId": "approveOAuthAuthorizationRequest",
        "summary": "Approve an OAuth authorization request",
        "description": "Approves a pending OAuth authorization request for the caller's chosen organisation and access level (`fv.read`/`fv.write`/`fv.full`), creating an active `OAuthGrant` and a single-use, 60-second authorization code. Returns the redirect URL (the client's own `redirect_uri` with `code`, `state`, `iss`) the browser is sent to next. Requires `mcp.connect` in the chosen organisation (BR-14). Fires `oauthGrant.created`.",
        "tags": ["oAuthAuthorizationRequest"],
        "parameters": [
          {
            "name": "requestId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^oar_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A oar identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "organizationId": {
                    "type": "string",
                    "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A org identifier (TypeID, conventions C5)."
                  },
                  "accessLevel": {
                    "type": "string",
                    "enum": ["fv.read", "fv.write", "fv.full"]
                  }
                },
                "additionalProperties": false,
                "required": ["accessLevel", "organizationId"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Approve an OAuth authorization request",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/approveOAuthAuthorizationRequestOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "mcp.connect",
        "x-fv-side-effect": "write",
        "x-fv-events": ["oauthGrant.created"],
        "x-fv-mcp-tool": "fv_approve_oauth_authorization_request",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/oauth/authorization-requests/{requestId}/deny": {
      "post": {
        "operationId": "denyOAuthAuthorizationRequest",
        "summary": "Deny an OAuth authorization request",
        "description": "Denies a pending OAuth authorization request. No grant is created. Returns the redirect URL (the client's own `redirect_uri` with `error=access_denied` and `state`) the browser is sent to next.",
        "tags": ["oAuthAuthorizationRequest"],
        "parameters": [
          {
            "name": "requestId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^oar_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A oar identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Deny an OAuth authorization request",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/denyOAuthAuthorizationRequestOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "write",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_deny_oauth_authorization_request",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations": {
      "post": {
        "operationId": "createOrganization",
        "summary": "Create an organisation",
        "description": "Creates a new organisation and seeds the caller as its sole `owner` (BR-11: an organisation always has >= 1 active owner). `name` (2-80 chars after trimming, BR-10) need not be unique. Requires a verified e-mail (BR-7) and is subject to the BR-9 owner cap (at most 5 owned organisations); no access code is needed. `legalAcceptance` (required) names the current terms, privacy notice, DPA and sub-processor list versions the caller accepts (`getLegalDocumentVersions`); they are recorded on the organisation as `legal`, an outdated version is `409 legal.version_outdated`. Fires `organization.created`, `member.joined` and `organization.legalAccepted`.",
        "tags": ["organization"],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 2,
                    "maxLength": 80,
                    "description": "Organisation display name (2-80 chars after trimming, BR-10)."
                  },
                  "defaultLocale": {
                    "type": "string",
                    "enum": ["nl", "en", "fr"]
                  },
                  "id": {
                    "description": "Optional client-generated id (C11). Omit to let the server generate one.",
                    "type": "string",
                    "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
                  },
                  "legalAcceptance": {
                    "type": "object",
                    "properties": {
                      "termsVersion": {
                        "type": "string",
                        "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                        "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
                      },
                      "privacyVersion": {
                        "type": "string",
                        "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                        "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
                      },
                      "dpaVersion": {
                        "type": "string",
                        "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                        "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
                      },
                      "subprocessorsVersion": {
                        "type": "string",
                        "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                        "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
                      }
                    },
                    "required": [
                      "termsVersion",
                      "privacyVersion",
                      "dpaVersion",
                      "subprocessorsVersion"
                    ],
                    "additionalProperties": false,
                    "description": "The current terms, privacy notice, DPA and sub-processor list versions the caller accepts for the organisation (from getLegalDocumentVersions). Required."
                  }
                },
                "additionalProperties": false,
                "required": ["defaultLocale", "legalAcceptance", "name"]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Create an organisation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createOrganizationOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "auth.email_not_verified, org.owner_limit_reached, permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "legal.version_outdated",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "write",
        "x-fv-events": [
          "organization.created",
          "member.joined",
          "organization.legalAccepted"
        ],
        "x-fv-mcp-tool": "fv_create_organization",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}": {
      "get": {
        "operationId": "getOrganization",
        "summary": "Get an organisation",
        "description": "Reads one organisation: `name`, `defaultLocale`, `status` (`active` or `pending_deletion`) and, when deletion was requested, `deletion` (`requestedAt`, `requestedBy`, `purgeAfter`, `cancelledAt`, `purgeStartedAt`), `orgStatus` (`suspended` while Field-Viewer has paused its changes), `planId` and the beta `cohort` when set, and, when it has a logo, a signed `logoUrl` (15 minutes). Any member may read it, including while the organisation is pending deletion and their membership is blocked (BR-13).",
        "tags": ["organization"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-None-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "One or more entity tags (`\"4\"`, `W/\"4\"` or `*`). When one matches the current revision the answer is 304 Not Modified with no body."
          }
        ],
        "responses": {
          "200": {
            "description": "Get an organisation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getOrganizationOutput"
                }
              }
            }
          },
          "304": {
            "description": "Not Modified: the If-None-Match entity tag still matches.",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "org.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_organization",
        "x-fv-rate-limit-class": "read"
      },
      "patch": {
        "operationId": "updateOrganization",
        "summary": "Update an organisation's name, language, logo, analytics or CAD drawing settings",
        "description": "Patches `name` (2-80 characters after trimming), `defaultLocale` (`nl`, `en` or `fr`) and/or `logo` (JSON Merge Patch, C2: an omitted field is left unchanged). To set a logo, call `createOrganizationLogoUpload`, PUT the image to its ticket, then send `logo: {uploadId, contentType}` here (`409 conflict.state` while the image has not arrived; `422 validation.failed` when it is over 2 MB). `logo: null` removes the logo. `settings.analytics.mode` (`enabled`, the default, or `disabled`) switches product analytics on or off for every member: disabled, no usage event is recorded for anyone in the organisation. `settings.cad.producerDetailTags` (an object with the seven tags `scale`, `xFactor`, `yFactor`, `xMin`, `yMin`, `xMax`, `yMax`, or `null` to remove it) tells the drawing processor which block attributes of the organisation's CAD producer state a scaled detail's scale and extents; drawings uploaded afterwards measure those details in real millimetres (already processed drawings are not reprocessed). Returns the organisation with a signed `logoUrl` (15 minutes). An optional `If-Match`/`expectedRevision` is checked against the current revision (412 on mismatch). Requires `org.update` (owner, admin). Fires `organization.updated` when something changes.",
        "tags": ["organization"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "The revision you last read, as an entity tag (`\"4\"`, from the `ETag` header). A stale one answers 412 `precondition.failed` and changes nothing. `*` matches any current revision (not accepted where a precondition is required). MCP/SDK: `expectedRevision`."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 2,
                    "maxLength": 80,
                    "description": "Organisation display name (2-80 chars after trimming, BR-10)."
                  },
                  "defaultLocale": {
                    "description": "The organisation's default UI locale: nl, en or fr.",
                    "type": "string",
                    "enum": ["nl", "en", "fr"]
                  },
                  "logo": {
                    "description": "The uploaded logo to use ({uploadId, contentType} from createOrganizationLogoUpload, after the PUT finished), or null to remove the logo.",
                    "anyOf": [
                      {
                        "type": "object",
                        "properties": {
                          "uploadId": {
                            "type": "string",
                            "pattern": "^upl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                            "description": "A upl identifier (TypeID, conventions C5)."
                          },
                          "contentType": {
                            "type": "string",
                            "enum": ["image/png", "image/jpeg", "image/webp"],
                            "description": "The content type the upload declared: image/png, image/jpeg or image/webp."
                          }
                        },
                        "required": ["uploadId", "contentType"],
                        "additionalProperties": false
                      },
                      { "type": "null" }
                    ]
                  },
                  "settings": {
                    "description": "Organisation-wide settings. settings.analytics.mode switches product analytics (anonymous usage events) on or off for every member (FV-168). settings.cad.producerDetailTags names the CAD producer's detail attribute tags, so panel drawings measure at their real scale (FV-560).",
                    "type": "object",
                    "properties": {
                      "analytics": {
                        "type": "object",
                        "properties": {
                          "mode": {
                            "type": "string",
                            "enum": ["enabled", "disabled"],
                            "description": "enabled (the default) or disabled: product analytics for every member."
                          }
                        },
                        "required": ["mode"],
                        "additionalProperties": false
                      },
                      "cad": {
                        "type": "object",
                        "properties": {
                          "producerDetailTags": {
                            "description": "The CAD producer's detail attribute tags (all seven), or null to remove them. New DXF/DWG uploads of the organisation read scaled model-space details with them (FV-560).",
                            "anyOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "scale": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 64,
                                    "pattern": "^\\S+$",
                                    "description": "Tag of the attribute holding the detail's scale text (1:n)."
                                  },
                                  "xFactor": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 64,
                                    "pattern": "^\\S+$",
                                    "description": "Tag of the attribute holding the detail's x factor (1/n)."
                                  },
                                  "yFactor": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 64,
                                    "pattern": "^\\S+$",
                                    "description": "Tag of the attribute holding the detail's y factor (1/n)."
                                  },
                                  "xMin": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 64,
                                    "pattern": "^\\S+$",
                                    "description": "Tag of the attribute holding the detail region's minimum x."
                                  },
                                  "yMin": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 64,
                                    "pattern": "^\\S+$",
                                    "description": "Tag of the attribute holding the detail region's minimum y."
                                  },
                                  "xMax": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 64,
                                    "pattern": "^\\S+$",
                                    "description": "Tag of the attribute holding the detail region's maximum x."
                                  },
                                  "yMax": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 64,
                                    "pattern": "^\\S+$",
                                    "description": "Tag of the attribute holding the detail region's maximum y."
                                  }
                                },
                                "required": [
                                  "scale",
                                  "xFactor",
                                  "yFactor",
                                  "xMin",
                                  "yMin",
                                  "xMax",
                                  "yMax"
                                ],
                                "additionalProperties": false,
                                "description": "The CAD producer's detail attribute tags: all seven, each the tag (not the value) of one block attribute. With them, scaled details in model space measure in real millimetres at their own scale; without them they read 'scale unknown'."
                              },
                              { "type": "null" }
                            ]
                          }
                        },
                        "additionalProperties": false
                      }
                    },
                    "additionalProperties": false
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Update an organisation's name, language, logo, analytics or CAD drawing settings",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/updateOrganizationOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "org.update",
        "x-fv-side-effect": "write",
        "x-fv-events": ["organization.updated"],
        "x-fv-mcp-tool": "fv_update_organization",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/access": {
      "get": {
        "operationId": "getMyAccess",
        "summary": "Get the caller's effective capabilities",
        "description": "Returns the caller's own effective capability list for `organizationId` (Conventions Part B §2.3), optionally narrowed to one `projectId` (§2.5: `caps(principal, org, project)` -- an org-role publisher/member on a `restricted` project they are not listed in, or a guest not listed in the named project at all, gets `{ capabilities: [] }`). Owner/admin always get their full bundle. Cheap: served from a per-instance cache with a documented staleness bound of at most 60 seconds across API instances (§4.4).",
        "tags": ["myAccess"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Optional project id (Part B §2.5). When given, the returned capabilities are narrowed by that project's access mode/memberIds; when omitted, only org-scoped capabilities are returned.",
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Get the caller's effective capabilities",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/getMyAccessOutput" }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "org.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_my_access",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/api-tokens": {
      "get": {
        "operationId": "listApiTokens",
        "summary": "List an organisation's API tokens",
        "description": "Lists every API token (active and revoked) for an organisation, paginated per C10. Never returns a secret/hash. Requires `apiToken.read`.",
        "tags": ["apiTokens"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: name | -name | createdAt | -createdAt.",
              "type": "string",
              "enum": ["name", "-name", "createdAt", "-createdAt"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List an organisation's API tokens",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/listApiTokensOutput" }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "api_token.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_api_tokens",
        "x-fv-rate-limit-class": "read"
      },
      "post": {
        "operationId": "createApiToken",
        "summary": "Create an organisation API token",
        "description": "Mints a new org-owned API token: `fvt_<env>_<tokenId>_<secret><checksum>` (BR-8, SHA-256- peppered hash stored, secret shown once). `scopes` is one or more capability ids or bundles (`fv.read`/`fv.write`/`fv.full`). `expiresInDays` (1-365, default 90, BR-9). At most 25 active tokens per organisation. Requires `apiToken.manage`; `apiToken` principals may never call this (BR-10). Fires `apiToken.created`.",
        "tags": ["apiToken"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 100
                  },
                  "scopes": {
                    "minItems": 1,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "minLength": 1,
                      "description": "A capability id (e.g. \"project.read\") or bundle: fv.read | fv.write | fv.full."
                    }
                  },
                  "expiresInDays": {
                    "description": "1-365 days (BR-9). Defaults to 90.",
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 365
                  },
                  "id": {
                    "description": "Optional client-generated id (C11). Omit to let the server generate one.",
                    "type": "string",
                    "pattern": "^tok_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
                  }
                },
                "additionalProperties": false,
                "required": ["name", "scopes"]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Create an organisation API token",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createApiTokenOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "entitlement.limit_reached, permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "api_token.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["apiToken.created"],
        "x-fv-mcp-tool": "fv_create_api_token",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/api-tokens/{apiTokenId}": {
      "get": {
        "operationId": "getApiToken",
        "summary": "Get an API token",
        "description": "Returns the full token record (never the secret/hash, BR-8/BR-26). Requires `apiToken.read`.",
        "tags": ["apiToken"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "apiTokenId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^tok_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A tok identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-None-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "One or more entity tags (`\"4\"`, `W/\"4\"` or `*`). When one matches the current revision the answer is 304 Not Modified with no body."
          }
        ],
        "responses": {
          "200": {
            "description": "Get an API token",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/getApiTokenOutput" }
              }
            }
          },
          "304": {
            "description": "Not Modified: the If-None-Match entity tag still matches.",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "api_token.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_api_token",
        "x-fv-rate-limit-class": "read"
      },
      "patch": {
        "operationId": "updateApiToken",
        "summary": "Rename or rescope an API token",
        "description": "Patches `name`/`scopes` on an existing, non-revoked token (JSON Merge Patch, C2: an omitted field is left unchanged). Bumps `revision` and fires `apiToken.updated` only when the patch actually changes something. Requires `apiToken.manage`.",
        "tags": ["apiToken"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "apiTokenId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^tok_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A tok identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "The revision you last read, as an entity tag (`\"4\"`, from the `ETag` header). A stale one answers 412 `precondition.failed` and changes nothing. `*` matches any current revision (not accepted where a precondition is required). MCP/SDK: `expectedRevision`."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 100
                  },
                  "scopes": {
                    "minItems": 1,
                    "type": "array",
                    "items": { "type": "string", "minLength": 1 }
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Rename or rescope an API token",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/updateApiTokenOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "api_token.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["apiToken.updated"],
        "x-fv-mcp-tool": "fv_update_api_token",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/api-tokens/{apiTokenId}/revoke": {
      "post": {
        "operationId": "revokeApiToken",
        "summary": "Revoke an API token",
        "description": "Immediately revokes a token: `status: 'revoked'`, `revokedAt` stamped, its name freed for reuse. Every API instance rejects the credential (`401 auth.token_revoked`) within 60 s (BR-11). Idempotent: revoking an already-revoked token returns it unchanged, no new event. Fires `apiToken.revoked`.",
        "tags": ["apiToken"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "apiTokenId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^tok_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A tok identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Revoke an API token",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/revokeApiTokenOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "api_token.manage",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["apiToken.revoked"],
        "x-fv-mcp-tool": "fv_revoke_api_token",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/api-tokens/{apiTokenId}/rotate": {
      "post": {
        "operationId": "rotateApiToken",
        "summary": "Rotate an API token's secret",
        "description": "Issues a fresh secret for an existing token (same `tokenPrefix`/id). The OLD secret keeps authenticating for `graceHours` (0-168, default 24, BR-12) before it returns `401 auth.token_revoked`. Requires `apiToken.manage`; `apiToken` principals may never call this (BR-10). Fires `apiToken.rotated`.",
        "tags": ["apiToken"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "apiTokenId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^tok_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A tok identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "graceHours": {
                    "description": "0-168 h the OLD secret stays valid (BR-12). Defaults to 24.",
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 168
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Rotate an API token's secret",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/rotateApiTokenOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "api_token.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["apiToken.rotated"],
        "x-fv-mcp-tool": "fv_rotate_api_token",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/audit-events": {
      "get": {
        "operationId": "listAuditEvents",
        "summary": "List an organisation's activity log",
        "description": "Lists the organisation's business audit log (who did what, when, to which resource), newest first. Filters (C10): `type` (comma-separated, max 10), `actor`, `occurredAfter`, `occurredBefore`. Paginated with an opaque cursor; `fields` projects each row. Owner/admin only (`audit.read`): any other role gets `403 permission.denied`; another organisation's id answers `404`.",
        "tags": ["auditEvents"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "actor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Only events by this actor id (a `usr_`/`tok_`/`wks_` id, as in `actor.id`).",
              "type": "string",
              "minLength": 1,
              "maxLength": 128
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "occurredAfter",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Only events at or after this instant (RFC 3339).",
              "type": "string",
              "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))$"
            }
          },
          {
            "name": "occurredBefore",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Only events before this instant (RFC 3339).",
              "type": "string",
              "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))$"
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: -occurredAt.",
              "type": "string",
              "enum": ["-occurredAt"]
            }
          },
          {
            "name": "type",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Only events of these types, comma-separated (max 10), e.g. `member.roleChanged,member.removed`. A denied attempt has the type `<type>.denied`.",
              "type": "string",
              "pattern": "^[a-zA-Z0-9._]+(,[a-zA-Z0-9._]+)*$"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List an organisation's activity log",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/listAuditEventsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "audit.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_audit_events",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/audit-log-exports": {
      "post": {
        "operationId": "requestAuditLogExport",
        "summary": "Export an organisation's activity log as CSV",
        "description": "Starts an export of the organisation's activity log as one CSV file (one row per event, every field except `metadata`), with the same filters as `listAuditEvents`. Answers `202` with the export `pending`; poll `getAuditLogExport` (or `waitAuditLogExport`) until it is `ready` -- usually within seconds -- and download it within 24 h. Owner/admin only (`audit.read`), on a plan that includes `features.auditLogExport` (otherwise `403 entitlement.feature_unavailable`). Fires `auditLogExport.requested`.",
        "tags": ["auditLogExport"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "type": {
                    "description": "Only events of these types, comma-separated (max 10), e.g. `member.roleChanged,member.removed`. A denied attempt has the type `<type>.denied`.",
                    "type": "string",
                    "pattern": "^[a-zA-Z0-9._]+(,[a-zA-Z0-9._]+)*$"
                  },
                  "actor": {
                    "description": "Only events by this actor id (a `usr_`/`tok_`/`wks_` id, as in `actor.id`).",
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 128
                  },
                  "occurredAfter": {
                    "description": "Only events at or after this instant (RFC 3339).",
                    "type": "string",
                    "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))$"
                  },
                  "occurredBefore": {
                    "description": "Only events before this instant (RFC 3339).",
                    "type": "string",
                    "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))$"
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "202": {
            "description": "Export an organisation's activity log as CSV",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/requestAuditLogExportOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "entitlement.feature_unavailable, permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "audit.read",
        "x-fv-side-effect": "write",
        "x-fv-events": ["auditLogExport.requested"],
        "x-fv-mcp-tool": "fv_request_audit_log_export",
        "x-fv-rate-limit-class": "write",
        "x-fv-feature": "auditLogExport"
      }
    },
    "/v1/organizations/{organizationId}/audit-log-exports/{exportId}": {
      "get": {
        "operationId": "getAuditLogExport",
        "summary": "Get an activity log export",
        "description": "Returns one activity log export (`requestAuditLogExport`): its status and, while it is `ready` and inside its 24 h window, a `download` ticket -- a signed URL valid for 15 minutes (C13); call again for a fresh one. Owner/admin only (`audit.read`).",
        "tags": ["auditLogExport"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "exportId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^alx_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A alx identifier (TypeID, conventions C5)."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Get an activity log export",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getAuditLogExportOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "audit.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_audit_log_export",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/audit-log-exports/{exportId}/wait": {
      "get": {
        "operationId": "waitAuditLogExport",
        "summary": "Wait for an activity log export to finish",
        "description": "Long-polls until the export leaves `pending` (`ready`, `failed` or `expired`) or the timeout elapses (C12, <= 25 s). Use after `requestAuditLogExport` instead of tight-polling `getAuditLogExport`; a `ready` result carries the download ticket.",
        "tags": ["auditLogExport"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "exportId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^alx_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A alx identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "timeoutSeconds",
            "in": "query",
            "required": false,
            "schema": { "type": "integer", "minimum": 1, "maximum": 25 }
          }
        ],
        "responses": {
          "200": {
            "description": "Wait for an activity log export to finish",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/waitAuditLogExportOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "audit.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_wait_for_audit_log_export",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/billing": {
      "get": {
        "operationId": "getBillingAccount",
        "summary": "Get an organisation's plan and billing state",
        "description": "Returns the organisation's billing state: `status` (none, trialing, active, past_due, canceled), `provider`, `interval`, `currentPeriodEnd` (the next invoice date), `cancelAtPeriodEnd`, `trialEndsAt`, `graceUntil`, the applied `discount`, a `paymentMethod` summary and `vatIdStatus`, plus `plan` (id and name per language) and `price`, the Team price for this organisation in EUR cents excl. VAT, and `paymentsAvailable`: whether this deployment takes payments (Checkout, the Customer Portal, cancelling); the trial works either way. An organisation that never paid reads `status: none`. Never returns a payment provider id. Owners and admins only.",
        "tags": ["billingAccount"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Get an organisation's plan and billing state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getBillingAccountOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "billing.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_billing_account",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/billing/checkout": {
      "post": {
        "operationId": "createCheckoutSession",
        "summary": "Start paying for Team through the provider's payment page",
        "description": "Creates a payment page for the Team plan, monthly or yearly, at the price `getBillingAccount` shows (the organisation's own discount applied), and returns its `url` and `expiresAt`. The organisation moves to Team once the payment is confirmed. Refused with `409 billing.subscription_exists` while a subscription is live, and with `409 billing.price_changed` (the current `price` in the problem) when `expectedPriceRevision` is not the current one. Refused with `409 billing.payments_unavailable` while `getBillingAccount.paymentsAvailable` is false (this deployment takes no payments); the trial works either way. Owners and admins only, in the app.",
        "tags": ["checkoutSession"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "interval": { "type": "string", "enum": ["month", "year"] },
                  "expectedPriceRevision": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991,
                    "description": "The `price.revision` the screen showed (`getBillingAccount`); an older one is `409 billing.price_changed`."
                  }
                },
                "additionalProperties": false,
                "required": ["expectedPriceRevision", "interval"]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Start paying for Team through the provider's payment page",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createCheckoutSessionOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "billing.payments_unavailable, billing.price_changed, billing.subscription_exists",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "billing.provider_misconfigured, internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "503": {
            "description": "dependency.unavailable",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "billing.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["billing.checkoutStarted"],
        "x-fv-mcp-tool": "fv_create_checkout_session",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/billing/invoices": {
      "get": {
        "operationId": "listInvoices",
        "summary": "List an organisation's invoices",
        "description": "Lists the organisation's invoices from the payment provider, newest first: number, status, amounts in cents, `currency` (EUR), period, `createdAt`, the hosted invoice page and the PDF. Paginated with `limit` and `cursor`. Read through and cached for 60 seconds, never stored. An organisation that never paid has none. Owners and admins only.",
        "tags": ["invoices"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: -createdAt.",
              "type": "string",
              "enum": ["-createdAt"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List an organisation's invoices",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/listInvoicesOutput" }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "billing.provider_misconfigured, internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "503": {
            "description": "dependency.unavailable",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "billing.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_invoices",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/billing/portal": {
      "post": {
        "operationId": "createBillingPortalSession",
        "summary": "Open the payment provider's Customer Portal",
        "description": "Returns a short-lived, single-use link to the payment provider's Customer Portal, where an owner or admin changes the payment method and billing details, switches between monthly and yearly, downloads invoices, and cancels or resumes the subscription. `flow` opens one task directly. The Portal returns to the plan screen. `404 billing.no_customer` while the organisation never paid; `404 billing.no_subscription` for a subscription flow without a subscription. Owners and admins only, in the app.",
        "tags": ["billingPortalSession"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "flow": {
                    "description": "Opens one task directly: change the payment method, cancel, or switch the interval.",
                    "type": "string",
                    "enum": [
                      "payment_method_update",
                      "subscription_cancel",
                      "subscription_update"
                    ]
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Open the payment provider's Customer Portal",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createBillingPortalSessionOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "billing.no_customer, billing.no_subscription, resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "billing.provider_misconfigured, internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "503": {
            "description": "dependency.unavailable",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "billing.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["billing.portalOpened"],
        "x-fv-mcp-tool": "fv_create_billing_portal_session",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/billing/subscription/cancel": {
      "post": {
        "operationId": "cancelSubscription",
        "summary": "Cancel the subscription at the end of the paid period",
        "description": "Cancels the organisation's subscription at the end of the running period, never at once: the plan stays until `currentPeriodEnd`, then the organisation moves to the free plan. Nothing is refunded and nothing is deleted; resuming is possible in the Portal until that date. Calling it again while a cancellation is scheduled answers the same. `404 billing.no_subscription` without a live subscription. Owners and admins only, in the app.",
        "tags": ["subscription"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Cancel the subscription at the end of the paid period",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/cancelSubscriptionOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "billing.no_subscription, resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "billing.provider_misconfigured, internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "503": {
            "description": "dependency.unavailable",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "billing.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["billing.cancellationScheduled"],
        "x-fv-mcp-tool": "fv_cancel_subscription",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/billing/trial": {
      "post": {
        "operationId": "createTrial",
        "summary": "Try the paid plan for free, without a card",
        "description": "Starts the organisation's one trial of the paid plan, without a payment method: the plan changes at once and `trialEndsAt` says when the trial ends. Then the organisation returns to the free plan unless it paid; nothing is deleted. Paying during the trial ends it. `409 billing.trial_already_used` once the organisation had a trial or a subscription; `409 billing.subscription_exists` while one is running. Owners and admins only, in the app.",
        "tags": ["trial"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Try the paid plan for free, without a card",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/createTrialOutput" }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "organization.suspended, permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "billing.subscription_exists, billing.trial_already_used",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "billing.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": [
          "billing.trialStarted",
          "organization.entitlements.updated"
        ],
        "x-fv-mcp-tool": "fv_create_trial",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/deletion": {
      "post": {
        "operationId": "requestOrganizationDeletion",
        "summary": "Request organisation deletion",
        "description": "Starts a 30-day soft-deletion window (BR-13): `status` becomes `pending_deletion`, every principal document (members and workstations) is immediately `blocked: true` -- denied at the Firestore rules level, no propagation delay (AC-1, AC-6) -- and `deletion.purgeAfter` names the instant an out-of-band purge job irreversibly removes everything. Requires a fresh re-authentication (BR-8, `403 auth.reauthentication_required`) and the `org.delete` capability (owner-only). Refused `409 org.already_pending_deletion` if already pending. Fires `organization.deletionRequested`.",
        "tags": ["organizationDeletion"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Request organisation deletion",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/requestOrganizationDeletionOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "org.already_pending_deletion",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "org.delete",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["organization.deletionRequested"],
        "x-fv-mcp-tool": "fv_request_organization_deletion",
        "x-fv-rate-limit-class": "write"
      },
      "delete": {
        "operationId": "cancelOrganizationDeletion",
        "summary": "Cancel a pending organisation deletion",
        "description": "Within the 30-day window (BR-13), returns `status` to `active` and clears `blocked` on every principal document. Refused `409 org.not_pending_deletion` when the organisation is not currently `pending_deletion`, and `409 org.purge_in_progress` once the purge job has started deleting it. Owner-only. Fires `organization.deletionCancelled`.",
        "tags": ["organizationDeletion"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "responses": {
          "204": {
            "description": "No Content",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "org.not_pending_deletion, org.purge_in_progress",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "org.delete",
        "x-fv-side-effect": "write",
        "x-fv-events": ["organization.deletionCancelled"],
        "x-fv-mcp-tool": "fv_cancel_organization_deletion",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/entitlements": {
      "get": {
        "operationId": "getEntitlements",
        "summary": "Get an organisation's entitlements",
        "description": "Reads the organisation's plan (`planId`), `orgStatus` and its effective `limits` (seats, guests, workstations, projects, storageBytes, maxModelFileBytes, maxModelsPerProject, processingMinutesPerMonth, apiTokens, maxDocumentFileBytes) and `features`. When a platform override is in force its values are already applied and the override itself is returned as `overrides`; without one there is no `overrides` key. `plan` names the plan in NL, EN and FR from the plan catalogue, and `planSource` says who last set it (default, billing, platform or migration). Owners and admins only.",
        "tags": ["entitlements"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Get an organisation's entitlements",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getEntitlementsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "entitlements.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_entitlements",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/feedback": {
      "post": {
        "operationId": "createFeedback",
        "summary": "Report a problem to the Field-Viewer team",
        "description": "Files a problem report: a short `text`, an optional screenshot and the `context` the app captured (project, model version, a `viewState` deep link reproducing the view, app version, locale and page URL). Declaring `screenshot: {contentType, sizeBytes}` returns an `upload` ticket (`{method:'PUT', url, headers, expiresAt, maxBytes, resumable:true, chunkSizeBytes}`) -- PUT the image directly to `url`, never through this API (C13). Omit it for a text-only report. Every role may report, guests included (`feedback.create`). Fires `feedback.created`; the team is notified by e-mail.",
        "tags": ["feedback"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "id": {
                    "description": "Optional client-generated fbk_ id (C11, offline outbox). Omit to let the server generate one.",
                    "type": "string",
                    "pattern": "^fbk_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
                  },
                  "text": {
                    "type": "string",
                    "maxLength": 2000,
                    "description": "What went wrong, in the reporter's own words (1-2000 chars)."
                  },
                  "category": {
                    "description": "problem (the default when omitted) or support.",
                    "type": "string",
                    "enum": ["problem", "support"]
                  },
                  "screenshot": {
                    "description": "Declare a screenshot to get an upload ticket for it; omit for a text-only report.",
                    "type": "object",
                    "properties": {
                      "contentType": {
                        "type": "string",
                        "enum": ["image/png", "image/jpeg", "image/webp"],
                        "description": "image/png, image/jpeg or image/webp."
                      },
                      "sizeBytes": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 5242880,
                        "description": "The image size in bytes (max 5242880)."
                      }
                    },
                    "required": ["contentType", "sizeBytes"],
                    "additionalProperties": false
                  },
                  "context": {
                    "type": "object",
                    "properties": {
                      "projectId": {
                        "description": "The project open when the report was made, if any.",
                        "type": "string",
                        "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
                      },
                      "modelVersionId": {
                        "description": "The model version open in the viewer, if any.",
                        "type": "string",
                        "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
                      },
                      "viewState": {
                        "description": "A viewer deep link (E05-S16 format: ?c=camera&s=selection) reproducing the reporter's view.",
                        "type": "string",
                        "maxLength": 2048,
                        "format": "uri"
                      },
                      "appVersion": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "description": "The app build the report came from."
                      },
                      "locale": {
                        "type": "string",
                        "enum": ["nl", "en", "fr"],
                        "description": "The app language at the time (nl, en or fr)."
                      },
                      "url": {
                        "type": "string",
                        "maxLength": 2048,
                        "format": "uri",
                        "description": "The page the report was made on."
                      }
                    },
                    "required": ["appVersion", "locale", "url"],
                    "additionalProperties": false,
                    "description": "Captured by the app: projectId?, modelVersionId?, viewState? (deep link), appVersion, locale, url."
                  }
                },
                "additionalProperties": false,
                "required": ["context", "text"]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Report a problem to the Field-Viewer team",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createFeedbackOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.already_exists",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "feedback.create",
        "x-fv-side-effect": "write",
        "x-fv-events": ["feedback.created"],
        "x-fv-mcp-tool": "fv_create_feedback",
        "x-fv-rate-limit-class": "write",
        "x-fv-anonymous-access": true
      }
    },
    "/v1/organizations/{organizationId}/invitations": {
      "get": {
        "operationId": "listInvitations",
        "summary": "List an organisation's invitations",
        "description": "Lists an organisation's e-mail invitations, newest first, optionally filtered by `kind`/`status`. Never returns `tokenHash`. Owner/admin only.",
        "tags": ["invitations"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "kind",
            "in": "query",
            "required": false,
            "schema": { "type": "string", "enum": ["email", "link"] }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: createdAt | -createdAt.",
              "type": "string",
              "enum": ["createdAt", "-createdAt"]
            }
          },
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": ["pending", "accepted", "revoked", "expired", "exhausted"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List an organisation's invitations",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/listInvitationsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "member.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_invitations",
        "x-fv-rate-limit-class": "read"
      },
      "post": {
        "operationId": "createInvitation",
        "summary": "Invite a teammate by e-mail",
        "description": "Invites someone by e-mail with a role (AC-1). Rejects `role: 'owner'` (BR-20). Refused `403 permission.denied` unless the actor's rank is strictly above the requested role's (BR-15, AC-3). Refused `409 member.already_member` if the address already belongs to an active member (AC-4), or `409 invitation.already_pending` if a pending invitation already exists for it (BR-21). A guest invitation needs `projectIds.length >= 1`, each naming a project in this organisation the inviter manages (BR-26, AC-7) -- `422 invitation.guest_needs_project` / `403 invitation.project_not_manageable`. Stores only a SHA-256 hash of the 256-bit token (BR-20); sends the accept e-mail. Refused `403 entitlement.limit_reached` (`resource: seats`, or `guests` for a guest) when active members plus pending (unexpired, unrevoked) invitations already fill the plan; `used` counts both (FV-434). Fires `invitation.created`.",
        "tags": ["invitation"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "email": {
                    "type": "string",
                    "maxLength": 254,
                    "format": "email",
                    "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$",
                    "description": "The invitee's e-mail address (case-insensitive, BR-20)."
                  },
                  "role": {
                    "type": "string",
                    "enum": ["admin", "publisher", "member", "guest"],
                    "description": "The invited role: admin | publisher | member | guest (BR-20 -- never owner)."
                  },
                  "projectIds": {
                    "default": [],
                    "description": "Required (>= 1) when role is guest (BR-26); every project must exist in this organisation and be manageable by the inviter.",
                    "maxItems": 10,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A prj identifier (TypeID, conventions C5)."
                    }
                  },
                  "locale": {
                    "type": "string",
                    "enum": ["nl", "en", "fr"],
                    "description": "The invitation e-mail's locale."
                  },
                  "continueUrl": {
                    "type": "string",
                    "format": "uri",
                    "description": "URL of the web app's accept-invitation page. Only its path and query are used: the e-mailed link always uses this environment's own web app origin. The handler adds the token as the `#t=...` fragment."
                  }
                },
                "additionalProperties": false,
                "required": [
                  "continueUrl",
                  "email",
                  "locale",
                  "projectIds",
                  "role"
                ]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Invite a teammate by e-mail",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createInvitationOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "entitlement.limit_reached, invitation.project_not_manageable, permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "invitation.already_pending, member.already_member",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "invitation.guest_needs_project, validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "member.invite",
        "x-fv-side-effect": "write",
        "x-fv-events": ["invitation.created"],
        "x-fv-mcp-tool": "fv_create_invitation",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/invitations/{id}/resend": {
      "post": {
        "operationId": "resendInvitation",
        "summary": "Resend a pending invitation",
        "description": "Replaces the invitation's token, resets `expiresAt` to now + 14 days and increments `resendCount` (AC-5, BR-20), e-mails the fresh accept link and returns it once as `link`. Refused `409 invitation.resend_limit_reached` on a 6th resend, or `409 invitation.not_pending` once the invitation has been accepted or revoked; `403 permission.denied` unless the caller's rank is strictly above the invitation's role (BR-15). Resending an EXPIRED invitation reserves a seat (or guest slot) again: `403 entitlement.limit_reached` when active plus pending ones already fill the plan (FV-434). Fires `invitation.resent`.",
        "tags": ["invitation"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^inv_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A inv identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Resend a pending invitation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/resendInvitationOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "entitlement.limit_reached, permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "invitation.not_pending, invitation.resend_limit_reached",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "member.invite",
        "x-fv-side-effect": "write",
        "x-fv-events": ["invitation.resent"],
        "x-fv-mcp-tool": "fv_resend_invitation",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/invitations/{id}/revoke": {
      "post": {
        "operationId": "revokeInvitation",
        "summary": "Revoke a pending invitation",
        "description": "Sets a pending invitation's `status` to `revoked` (AC-6); its token no longer verifies. Refused `409 invitation.not_pending` once already accepted or revoked, `404 resource.not_found` for an unknown id, `403 permission.denied` unless the caller's rank is strictly above the invitation's role (BR-15). Fires `invitation.revoked`.",
        "tags": ["invitation"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^inv_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A inv identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Revoke a pending invitation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/revokeInvitationOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "invitation.not_pending",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "member.invite",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["invitation.revoked"],
        "x-fv-mcp-tool": "fv_revoke_invitation",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/join-links": {
      "post": {
        "operationId": "createJoinLink",
        "summary": "Create a join link or QR code for an organisation",
        "description": "Creates a multi-use join link (AC-1): role `member` or `guest` only (BR-24, AC-7), `expiresInHours` 1-720 (default 168), `maxUses` 1-250 (default 25). A guest link carries 1-10 projects the joiner gets (`422 invitation.guest_needs_project` without; `403 invitation.project_not_manageable` for a project outside this organisation); a member link carries none. Returns the link once, with its raw `token` and shareable `url`; only a SHA-256 of the token is stored. Anyone holding the URL can join until it expires, is exhausted or is revoked (`revokeInvitation`); every join is audited and notifies the owners and admins. Refused `403 entitlement.limit_reached` (`resource: seats`, or `guests` for a guest link) when active members plus pending e-mail invitations leave no slot (FV-434); every join is checked again. Fires `joinLink.created`.",
        "tags": ["joinLink"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "role": {
                    "type": "string",
                    "enum": ["member", "guest"],
                    "description": "member | guest (BR-24 -- never admin, publisher or owner)."
                  },
                  "projectIds": {
                    "default": [],
                    "description": "Guest links only: 1-10 projects the joiner gets access to. Must be empty for a member link.",
                    "maxItems": 10,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A prj identifier (TypeID, conventions C5)."
                    }
                  },
                  "expiresInHours": {
                    "default": 168,
                    "description": "Hours until the link expires: 1-720, default 168 (7 days).",
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 720
                  },
                  "maxUses": {
                    "default": 25,
                    "description": "How many people can join through the link: 1-250, default 25.",
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 250
                  },
                  "locale": {
                    "type": "string",
                    "enum": ["nl", "en", "fr"],
                    "description": "Locale of the owner/admin notice sent on every join."
                  },
                  "continueUrl": {
                    "type": "string",
                    "format": "uri",
                    "description": "Base URL of the web app's join page; the response's `url` is this with the token in the `#t=...` fragment."
                  }
                },
                "additionalProperties": false,
                "required": [
                  "continueUrl",
                  "expiresInHours",
                  "locale",
                  "maxUses",
                  "projectIds",
                  "role"
                ]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Create a join link or QR code for an organisation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createJoinLinkOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "entitlement.limit_reached, invitation.project_not_manageable, permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "invitation.guest_needs_project, validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "member.invite",
        "x-fv-side-effect": "write",
        "x-fv-events": ["joinLink.created"],
        "x-fv-mcp-tool": "fv_create_join_link",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/layer-templates": {
      "get": {
        "operationId": "listLayerTemplates",
        "summary": "List an organisation's layer templates",
        "description": "Lists the organisation's layer templates (at most 10): the company's own layer scheme, with each layer's rule, colour, default-on, hidden-from-field and lock, and how it was last applied (`applyTo`, `projectIds`). Requires `layertemplate.read` (every organisation role). Paginated per C10.",
        "tags": ["layerTemplates"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: name | -name | createdAt | -createdAt.",
              "type": "string",
              "enum": ["name", "-name", "createdAt", "-createdAt"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List an organisation's layer templates",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/listLayerTemplatesOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "layertemplate.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_layer_templates",
        "x-fv-rate-limit-class": "read"
      },
      "post": {
        "operationId": "createLayerTemplate",
        "summary": "Create a layer template",
        "description": "Creates a company-wide layer template: empty, with explicit `layers`, from a discipline preset (`fromPreset`) or from a project's rule layers (`fromProjectId`). Each layer is one rule (name, material, IFC class, panel or property) with a name, colour, default-on, hidden-from-field and `locked` (projects keep a locked layer's name, colour and default-on). At most 10 templates per organisation (`409 conflict.state`). Apply it with `applyLayerTemplate`. Fires `layerTemplate.created`. Requires `layertemplate.manage` (owner, admin).",
        "tags": ["layerTemplate"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "id": {
                    "type": "string",
                    "pattern": "^ltp_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A ltp identifier (TypeID, conventions C5)."
                  },
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 60,
                    "description": "Name of the template, 1-60 characters."
                  },
                  "layers": {
                    "description": "The template's layers (at most 50).",
                    "maxItems": 50,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string",
                          "pattern": "^[a-z0-9][a-z0-9-]{0,39}$",
                          "description": "Stable id of the layer within the template (lower-case letters, digits, hyphens; at most 40). Projects match the layer by it, so keep it when you rename the layer."
                        },
                        "displayName": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 60,
                          "description": "Name, 1-60 characters."
                        },
                        "colorHex": {
                          "description": "Colour as #rgb or #rrggbb.",
                          "type": "string",
                          "pattern": "^#(?:[0-9a-fA-F]{3}|[0-9a-fA-F]{6})$"
                        },
                        "rule": {
                          "type": "object",
                          "properties": {
                            "source": {
                              "description": "What the rule tests: `property` (the default) a property value (`psetName`, `propName`); `name` the element name, `material` its material, `ifcClass` its IFC class, `panel` the name or tag of the panel (`IfcElementAssembly`) it is part of -- these four take no psetName/propName, are counted on the device and work offline.",
                              "type": "string",
                              "enum": [
                                "property",
                                "name",
                                "material",
                                "ifcClass",
                                "panel"
                              ]
                            },
                            "psetName": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 255,
                              "description": "Property (or quantity) set name exactly as in the model, e.g. `Pset_WallCommon`. Property rules only."
                            },
                            "propName": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 255,
                              "description": "Property name exactly as in the model, e.g. `IsExternal`. Property rules only."
                            },
                            "op": {
                              "type": "string",
                              "enum": ["eq", "neq", "contains"],
                              "description": "`eq` equals, `neq` differs from (elements without the property never match), `contains` contains the value."
                            },
                            "value": {
                              "type": "string",
                              "maxLength": 1000,
                              "description": "Text to compare; case, accents and surrounding spaces are ignored. Booleans read `true`/`false`; a number also matches numerically (`0,24` = `0.24`). For name, material, ifcClass and panel rules several values may be separated by commas (any matches), and an empty value with eq/contains matches every element that has one (e.g. part of any panel)."
                            }
                          },
                          "required": ["op", "value"],
                          "additionalProperties": false
                        },
                        "defaultOn": {
                          "description": "On when a project opens. Default true.",
                          "type": "boolean"
                        },
                        "hiddenFromField": {
                          "description": "Hidden from the field panel. Default false.",
                          "type": "boolean"
                        },
                        "locked": {
                          "description": "Locked: every project keeps the template's name, colour and default-on. Unlocked (the default): a project may change them. Default false.",
                          "type": "boolean"
                        }
                      },
                      "required": ["id", "displayName", "rule"],
                      "additionalProperties": false
                    }
                  },
                  "fromPreset": {
                    "description": "Start from a discipline preset: `timberFrame`, `finishing` or `services` (layers named in the request's language).",
                    "type": "string",
                    "enum": ["timberFrame", "finishing", "services"]
                  },
                  "fromProjectId": {
                    "description": "Start from this project's rule layers (name, material, IFC class, panel and property rules) with their names, colours and visibility.",
                    "type": "string",
                    "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
                  }
                },
                "additionalProperties": false,
                "required": ["name"]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Create a layer template",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createLayerTemplateOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.already_exists, conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "layertemplate.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["layerTemplate.created"],
        "x-fv-mcp-tool": "fv_create_layer_template",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/layer-templates/{templateId}": {
      "get": {
        "operationId": "getLayerTemplate",
        "summary": "Get a layer template",
        "description": "Returns one of the organisation's layer templates. `404 resource.not_found` for an unknown id. Requires `layertemplate.read` (every organisation role).",
        "tags": ["layerTemplate"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "templateId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ltp_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ltp identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-None-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "One or more entity tags (`\"4\"`, `W/\"4\"` or `*`). When one matches the current revision the answer is 304 Not Modified with no body."
          }
        ],
        "responses": {
          "200": {
            "description": "Get a layer template",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getLayerTemplateOutput"
                }
              }
            }
          },
          "304": {
            "description": "Not Modified: the If-None-Match entity tag still matches.",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "layertemplate.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_layer_template",
        "x-fv-rate-limit-class": "read"
      },
      "patch": {
        "operationId": "updateLayerTemplate",
        "summary": "Update a layer template",
        "description": "Renames a layer template and/or replaces its layers (the whole list; a layer is matched in the projects by its `id`). Requires `expectedRevision`/`If-Match` (`428` without, `412` when stale). On an applied template a changed layer list reaches every project that follows it through the outbox: new layers are added, removed ones go, locked ones are reset to the template, unlocked ones keep a project's own name, colour and default-on. Fires `layerTemplate.updated` and one `layerTemplate.applied` per active project. Requires `layertemplate.manage` (owner, admin).",
        "tags": ["layerTemplate"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "templateId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ltp_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ltp identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-Match",
            "in": "header",
            "required": true,
            "schema": { "type": "string" },
            "description": "The revision you last read, as an entity tag (`\"4\"`, from the `ETag` header). A stale one answers 412 `precondition.failed` and changes nothing. `*` matches any current revision (not accepted where a precondition is required). MCP/SDK: `expectedRevision`."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "description": "New name, 1-60 characters.",
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 60
                  },
                  "layers": {
                    "description": "The template's complete new layer list (replaces the old one). Keep a layer's id to keep it in the projects; a layer left out disappears from them.",
                    "maxItems": 50,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string",
                          "pattern": "^[a-z0-9][a-z0-9-]{0,39}$",
                          "description": "Stable id of the layer within the template (lower-case letters, digits, hyphens; at most 40). Projects match the layer by it, so keep it when you rename the layer."
                        },
                        "displayName": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 60,
                          "description": "Name, 1-60 characters."
                        },
                        "colorHex": {
                          "description": "Colour as #rgb or #rrggbb.",
                          "type": "string",
                          "pattern": "^#(?:[0-9a-fA-F]{3}|[0-9a-fA-F]{6})$"
                        },
                        "rule": {
                          "type": "object",
                          "properties": {
                            "source": {
                              "description": "What the rule tests: `property` (the default) a property value (`psetName`, `propName`); `name` the element name, `material` its material, `ifcClass` its IFC class, `panel` the name or tag of the panel (`IfcElementAssembly`) it is part of -- these four take no psetName/propName, are counted on the device and work offline.",
                              "type": "string",
                              "enum": [
                                "property",
                                "name",
                                "material",
                                "ifcClass",
                                "panel"
                              ]
                            },
                            "psetName": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 255,
                              "description": "Property (or quantity) set name exactly as in the model, e.g. `Pset_WallCommon`. Property rules only."
                            },
                            "propName": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 255,
                              "description": "Property name exactly as in the model, e.g. `IsExternal`. Property rules only."
                            },
                            "op": {
                              "type": "string",
                              "enum": ["eq", "neq", "contains"],
                              "description": "`eq` equals, `neq` differs from (elements without the property never match), `contains` contains the value."
                            },
                            "value": {
                              "type": "string",
                              "maxLength": 1000,
                              "description": "Text to compare; case, accents and surrounding spaces are ignored. Booleans read `true`/`false`; a number also matches numerically (`0,24` = `0.24`). For name, material, ifcClass and panel rules several values may be separated by commas (any matches), and an empty value with eq/contains matches every element that has one (e.g. part of any panel)."
                            }
                          },
                          "required": ["op", "value"],
                          "additionalProperties": false
                        },
                        "defaultOn": {
                          "description": "On when a project opens. Default true.",
                          "type": "boolean"
                        },
                        "hiddenFromField": {
                          "description": "Hidden from the field panel. Default false.",
                          "type": "boolean"
                        },
                        "locked": {
                          "description": "Locked: every project keeps the template's name, colour and default-on. Unlocked (the default): a project may change them. Default false.",
                          "type": "boolean"
                        }
                      },
                      "required": ["id", "displayName", "rule"],
                      "additionalProperties": false
                    }
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Update a layer template",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/updateLayerTemplateOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "layertemplate.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["layerTemplate.updated", "layerTemplate.applied"],
        "x-fv-mcp-tool": "fv_update_layer_template",
        "x-fv-rate-limit-class": "write"
      },
      "delete": {
        "operationId": "deleteLayerTemplate",
        "summary": "Delete a layer template",
        "description": "Deletes a layer template permanently. Every project that follows it loses the template's layers in the background; the projects' own layers stay. Destructive: MCP calls need the two-phase confirmation, REST supports `?dryRun=true`. Fires `layerTemplate.deleted` and one `layerTemplate.applied` per active project. Requires `layertemplate.manage` (owner, admin).",
        "tags": ["layerTemplate"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "templateId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ltp_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ltp identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "responses": {
          "204": {
            "description": "No Content",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "layertemplate.manage",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["layerTemplate.deleted", "layerTemplate.applied"],
        "x-fv-mcp-tool": "fv_delete_layer_template",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/layer-templates/{templateId}/apply": {
      "post": {
        "operationId": "applyLayerTemplate",
        "summary": "Apply a layer template to projects",
        "description": "Applies a layer template to every active project (`applyTo: all`, also every project published later) or to `projectIds` (`chosen`). Each project syncs in the background through the outbox (one `layerTemplate.applied` per project): the template's layers are added with their element counts, a project's earlier template layers are replaced, its own layers stay. A project with nothing published gets them on its first publish. `404` for an unknown template or project; `409 conflict.state` above 400 projects (choose projects instead). Requires `layertemplate.manage` (owner, admin).",
        "tags": ["layerTemplate"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "templateId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ltp_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ltp identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "applyTo": {
                    "type": "string",
                    "enum": ["all", "chosen"],
                    "description": "`all`: every active project, and every project published later; `chosen`: the projects in projectIds."
                  },
                  "projectIds": {
                    "description": "With applyTo chosen: the projects (at most 400).",
                    "minItems": 1,
                    "maxItems": 400,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A prj identifier (TypeID, conventions C5)."
                    }
                  }
                },
                "additionalProperties": false,
                "required": ["applyTo"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Apply a layer template to projects",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/applyLayerTemplateOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "layertemplate.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["layerTemplate.applied"],
        "x-fv-mcp-tool": "fv_apply_layer_template",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/legal-acceptances": {
      "post": {
        "operationId": "acceptLegalDocuments",
        "summary": "Accept the current legal documents for an organisation",
        "description": "Records that the calling owner accepted the current versions of the terms of use, privacy notice, data processing agreement (DPA) and sub-processor list for the organisation, as `legal` on the organisation (versions, `acceptedAt`, `acceptedBy`). The versions sent must be the current ones (`getLegalDocumentVersions`), else `409 legal.version_outdated`. Owners only (`403 permission.denied` for an admin). Fires `organization.legalAccepted`.",
        "tags": ["legalDocuments"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "termsVersion": {
                    "type": "string",
                    "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                    "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
                  },
                  "privacyVersion": {
                    "type": "string",
                    "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                    "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
                  },
                  "dpaVersion": {
                    "type": "string",
                    "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                    "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
                  },
                  "subprocessorsVersion": {
                    "type": "string",
                    "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                    "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
                  }
                },
                "additionalProperties": false,
                "required": [
                  "dpaVersion",
                  "privacyVersion",
                  "subprocessorsVersion",
                  "termsVersion"
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Accept the current legal documents for an organisation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/acceptLegalDocumentsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "legal.version_outdated",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "org.update",
        "x-fv-side-effect": "write",
        "x-fv-events": ["organization.legalAccepted"],
        "x-fv-mcp-tool": "fv_accept_legal_documents",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/logo-upload": {
      "post": {
        "operationId": "createOrganizationLogoUpload",
        "summary": "Start uploading an organisation logo",
        "description": "Declares a logo image (`contentType`: `image/png`, `image/jpeg` or `image/webp`; `sizeBytes` at most 2 MB) and returns `uploadId` plus an `upload` ticket (`{method:'PUT', url, headers, expiresAt, maxBytes, resumable:true, chunkSizeBytes}`). PUT the image directly to `upload.url`, never through this API (C13), then call `updateOrganization` with `logo: {uploadId, contentType}` to use it. Requires `org.update` (owner, admin).",
        "tags": ["organizationLogoUpload"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "contentType": {
                    "type": "string",
                    "enum": ["image/png", "image/jpeg", "image/webp"],
                    "description": "image/png, image/jpeg or image/webp."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 2097152,
                    "description": "The image size in bytes (max 2097152, 2 MB)."
                  }
                },
                "additionalProperties": false,
                "required": ["contentType", "sizeBytes"]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Start uploading an organisation logo",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createOrganizationLogoUploadOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "org.update",
        "x-fv-side-effect": "write",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_create_organization_logo_upload",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/members": {
      "get": {
        "operationId": "listMembers",
        "summary": "List an organisation's members",
        "description": "Lists every member of an organisation (`userId`, `displayName`, `email`, `role`, `status`, `blocked`, timestamps and `revision`; never the internal `grants`/`sessionsValidAfter` fields, OQ-4). Owner/admin only.",
        "tags": ["members"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: createdAt | -createdAt.",
              "type": "string",
              "enum": ["createdAt", "-createdAt"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List an organisation's members",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/listMembersOutput" }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "member.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_members",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/members/me": {
      "delete": {
        "operationId": "leaveOrganization",
        "summary": "Leave an organisation",
        "description": "The caller removes themselves from the organisation, the same way `removeMember` removes someone else (BR-18 tombstone: `status: 'removed'`, display name kept, e-mail erased; ProjectMember rows and the switcher index entry deleted in the same transaction). Refused with `403 member.last_owner` when the caller is the organisation's only active owner (BR-11). Fires `member.left` and is recorded in the business audit log. Calling this again once already removed is a harmless no-op (idempotent).",
        "tags": ["organization"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "responses": {
          "204": {
            "description": "No Content",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "member.last_owner, permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "member.leave",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["member.left"],
        "x-fv-mcp-tool": "fv_leave_organization",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/members/{uid}": {
      "get": {
        "operationId": "getMember",
        "summary": "Get one organisation member",
        "description": "Reads one member of an organisation (`role`, `status`, `blocked`, timestamps and `revision`). Owner/admin only (same capability as `listMembers`).",
        "tags": ["member"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "uid",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1,
              "description": "The member's Firebase Auth uid."
            }
          },
          {
            "name": "If-None-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "One or more entity tags (`\"4\"`, `W/\"4\"` or `*`). When one matches the current revision the answer is 304 Not Modified with no body."
          }
        ],
        "responses": {
          "200": {
            "description": "Get one organisation member",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/getMemberOutput" }
              }
            }
          },
          "304": {
            "description": "Not Modified: the If-None-Match entity tag still matches.",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "member.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_member",
        "x-fv-rate-limit-class": "read"
      },
      "patch": {
        "operationId": "updateMemberRole",
        "summary": "Change an organisation member's role",
        "description": "Changes a member's org role, subject to BR-15 (the actor manages only strictly-lower ranks, for both the member's current AND the requested role -- owners manage everyone), BR-16 (nobody changes their own role, except an owner self-demoting while another owner exists) and BR-19 (converting a `member`/`publisher` to `guest` requires the member to already have at least one `ProjectMember` row, `422 member.guest_needs_project`). An optional `If-Match`/`expectedRevision` is checked against the member's current revision (`412` on mismatch). Fires `member.roleChanged` and is recorded in the business audit log with the previous and new role.",
        "tags": ["memberRole"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "uid",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1,
              "description": "The member's Firebase Auth uid."
            }
          },
          {
            "name": "If-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "The revision you last read, as an entity tag (`\"4\"`, from the `ETag` header). A stale one answers 412 `precondition.failed` and changes nothing. `*` matches any current revision (not accepted where a precondition is required). MCP/SDK: `expectedRevision`."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "role": {
                    "type": "string",
                    "enum": ["owner", "admin", "publisher", "member", "guest"],
                    "description": "The new org role to set."
                  }
                },
                "additionalProperties": false,
                "required": ["role"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Change an organisation member's role",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/updateMemberRoleOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "member.last_owner, permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "member.guest_needs_project, validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "member.update_role",
        "x-fv-side-effect": "write",
        "x-fv-events": ["member.roleChanged"],
        "x-fv-mcp-tool": "fv_update_member_role",
        "x-fv-rate-limit-class": "write"
      },
      "delete": {
        "operationId": "removeMember",
        "summary": "Remove a member from an organisation",
        "description": "Removes a member (BR-15: the actor manages only strictly-lower ranks -- owners manage everyone; BR-11: the organisation's last active owner cannot be removed, `403 member.last_owner`). The Membership becomes a tombstone (`status: 'removed'`, display name kept for attribution, e-mail erased) rather than being deleted outright; the member's ProjectMember rows and `users/{uid}/memberships/{organizationId}` switcher index entry are deleted in the same transaction (BR-18). Authored content stays, attributed to the tombstoned member. Re-inviting the same address reactivates this same document. Fires `member.removed` and is recorded in the business audit log. Calling this again on an already-removed member is a harmless no-op (idempotent).",
        "tags": ["member"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "uid",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1,
              "description": "The member's Firebase Auth uid."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "responses": {
          "204": {
            "description": "No Content",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "member.last_owner, permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "member.remove",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["member.removed"],
        "x-fv-mcp-tool": "fv_remove_member",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/oauth-grants": {
      "get": {
        "operationId": "listOAuthGrants",
        "summary": "List an organisation's connected AI apps",
        "description": "Lists every OAuth grant (connected AI app) any member approved for this organisation, active and revoked alike, newest first by default. Never returns a refresh token or its hash. Requires `oauthGrant.manage`.",
        "tags": ["oAuthGrants"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: createdAt | -createdAt | lastUsedAt | -lastUsedAt.",
              "type": "string",
              "enum": ["createdAt", "-createdAt", "lastUsedAt", "-lastUsedAt"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List an organisation's connected AI apps",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/listOAuthGrantsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "oauth_grant.manage",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_oauth_grants",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/oauth-grants/{grantId}/revoke": {
      "post": {
        "operationId": "revokeOAuthGrant",
        "summary": "Disconnect a member's AI app",
        "description": "Revokes any OAuth grant of this organisation at once: `status: 'revoked'`, the app's next refresh fails with `invalid_grant` and its access tokens stop working on the next request. Revoking an already-revoked grant returns it unchanged. Requires `oauthGrant.manage`. Fires `oauthGrant.revoked`.",
        "tags": ["oAuthGrant"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "grantId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^grt_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A grt identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Disconnect a member's AI app",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/revokeOAuthGrantOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "oauth_grant.manage",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["oauthGrant.revoked"],
        "x-fv-mcp-tool": "fv_revoke_oauth_grant",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/onboarding-status": {
      "get": {
        "operationId": "getOnboardingStatus",
        "summary": "Get the get-started checklist status",
        "description": "Returns the two computed facts the get-started checklist panel needs (FV-208 / E03-S05, BR-8): whether the organisation has published a non-sample model of its own, and whether it has at least 2 active members. Nothing here is stored -- every call recomputes both from existing project/model/member reads, so the panel is correct the instant the underlying fact changes (AC-2). The panel itself (and its per-user dismiss flag, `updateMe`'s `onboardingChecklistDismissed`) is shown only to owner/admin/publisher. FV-715: also `demoProjects`, the new organisation's demo projects being prepared (state, total, ready, startedAt), derived from the provisioning's own records.",
        "tags": ["onboardingStatus"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Get the get-started checklist status",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getOnboardingStatusOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "org.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_onboarding_status",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/ownership-transfers": {
      "post": {
        "operationId": "transferOwnership",
        "summary": "Transfer organisation ownership",
        "description": "Promotes `targetUid` to `owner` (BR-12: must be an active, non-guest member with a verified e-mail -- `403 org.transfer_target_ineligible`), optionally also demoting the caller to `admin` in the SAME atomic transaction (`selfDemote: true`, AC-4). Requires a fresh re-authentication (BR-8, `403 auth.reauthentication_required` if the caller's ID token `auth_time` is more than 5 minutes old) and the `org.transfer_ownership` capability (owner-only). Fires `organization.ownershipTransferred` and `member.roleChanged`.",
        "tags": ["ownership"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "targetUid": {
                    "type": "string",
                    "minLength": 1,
                    "description": "The member's Firebase Auth uid to promote to owner (BR-12)."
                  },
                  "selfDemote": {
                    "default": false,
                    "description": "Also demote the caller to admin, atomically (AC-4).",
                    "type": "boolean"
                  }
                },
                "additionalProperties": false,
                "required": ["selfDemote", "targetUid"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Transfer organisation ownership",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/transferOwnershipOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "org.transfer_target_ineligible, permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "org.transfer_ownership",
        "x-fv-side-effect": "destructive",
        "x-fv-events": [
          "organization.ownershipTransferred",
          "member.roleChanged"
        ],
        "x-fv-mcp-tool": "fv_transfer_ownership",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects": {
      "get": {
        "operationId": "listProjects",
        "summary": "List the projects in an organisation the caller can see",
        "description": "Lists the active projects in an organisation, most-recently-updated first by default (AC-1). Only projects the caller can read are returned: every `access:'org'` project, plus any `access:'restricted'` project the caller's uid is a member of (Part B §2.5 point 5, AC-3) -- a restricted project the caller cannot read is silently omitted, not an error. Only `active` projects by default; `status: 'archived'` lists archived projects (needs `project.archive`) and `status: 'deleted'` the \"Recently deleted\" view with each project's `purgeAfter` (needs `project.delete`) -- FV-134. Requires the `project.read` capability (every org role). Empty for an organisation with no projects yet (AC-5).",
        "tags": ["projects"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: updatedAt | -updatedAt.",
              "type": "string",
              "enum": ["updatedAt", "-updatedAt"]
            }
          },
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Which projects to list (FV-134): active (default, every field list), archived, or deleted (the 'Recently deleted' view). archived needs project.archive, deleted needs project.delete (owner/admin).",
              "type": "string",
              "enum": ["active", "archived", "deleted"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List the projects in an organisation the caller can see",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/listProjectsOutput" }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "project.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_projects",
        "x-fv-rate-limit-class": "read"
      },
      "post": {
        "operationId": "createProject",
        "summary": "Create a project",
        "description": "Creates a new project inside an organisation. `name` (1-80 chars after trimming) is required; `reference` (<= 40 chars) and `description` (<= 500 chars) are optional. Initialises `status: 'active'`, `access: 'org'` and `memberIds: []` (Conventions Part B §2.5 -- every org role can read an `access: 'org'` project by default; restricting access is a separate operation). Requires the `project.create` capability (owner/admin/publisher). Refused with `entitlement.limit_reached` when the organisation's plan `projects` limit is reached. The project's one 3D model is created with it (FV-384): upload revisions with `createProjectRevision`. Fires `project.created` and `model.created`.",
        "tags": ["project"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 80,
                    "description": "Project display name (1-80 chars after trimming, BR-2)."
                  },
                  "reference": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 40,
                    "description": "Free-form job/reference code, e.g. \"2026-041\" (BR-2)."
                  },
                  "description": {
                    "type": "string",
                    "maxLength": 500,
                    "description": "Free-form project description (BR-2)."
                  },
                  "id": {
                    "description": "Optional client-generated id (C11). Omit to let the server generate one.",
                    "type": "string",
                    "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
                  }
                },
                "additionalProperties": false,
                "required": ["name"]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Create a project",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/createProjectOutput" }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "entitlement.limit_reached, permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "project.create",
        "x-fv-side-effect": "write",
        "x-fv-events": ["project.created", "model.created"],
        "x-fv-mcp-tool": "fv_create_project",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}": {
      "get": {
        "operationId": "getProject",
        "summary": "Get one project and who can open it",
        "description": "Reads one project the caller can open: name, reference, lifecycle status, last update and its access (mode, how many people can open it, pending invitations, and everyone by name, owners and admins first). A guest caller gets the mode and the counts only. A restricted project the caller is not a member of answers 404, as if it did not exist. Requires `project.read` on the project.",
        "tags": ["project"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Get one project and who can open it",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/getProjectOutput" }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "project.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_project",
        "x-fv-rate-limit-class": "read"
      },
      "patch": {
        "operationId": "updateProject",
        "summary": "Update a project",
        "description": "Patches `name`/`reference`/`description`/`access`/`sheetMetadata` on an existing project (JSON Merge Patch semantics, C2: an omitted field is left unchanged; `reference`/`description`/`sheetMetadata` accept `null` to clear them). `sheetMetadata` is replaced as a whole: `fileNamePattern` is a regex with named groups `sheetNumber`/`discipline` matched against PDF file names (max 200 chars, no backreferences or nested repeats -- 422 otherwise), `disciplineMap` maps a captured designator to a discipline. Bumps `revision` and fires `project.updated` only when the patch actually changes something. Requires the `project.update` capability (owner/admin/publisher). An optional `If-Match`/`expectedRevision` is checked against the project's current revision (412 on mismatch).",
        "tags": ["project"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "The revision you last read, as an entity tag (`\"4\"`, from the `ETag` header). A stale one answers 412 `precondition.failed` and changes nothing. `*` matches any current revision (not accepted where a precondition is required). MCP/SDK: `expectedRevision`."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 80,
                    "description": "Project display name (1-80 chars after trimming, BR-2)."
                  },
                  "reference": {
                    "anyOf": [
                      {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 40,
                        "description": "Free-form job/reference code, e.g. \"2026-041\" (BR-2)."
                      },
                      { "type": "null" }
                    ]
                  },
                  "description": {
                    "anyOf": [
                      {
                        "type": "string",
                        "maxLength": 500,
                        "description": "Free-form project description (BR-2)."
                      },
                      { "type": "null" }
                    ]
                  },
                  "access": { "type": "string", "enum": ["org", "restricted"] },
                  "sheetMetadata": {
                    "anyOf": [
                      {
                        "type": "object",
                        "properties": {
                          "fileNamePattern": {
                            "type": "string",
                            "description": "Regular expression matched against the file name without its .pdf extension, with named groups sheetNumber and/or discipline, e.g. ^(?<discipline>[A-Z])-(?<sheetNumber>\\d+) (max 200 chars; no backreferences or nested repeats)."
                          },
                          "disciplineMap": {
                            "type": "object",
                            "propertyNames": {
                              "type": "string",
                              "pattern": "^[A-Za-z0-9]{1,8}$"
                            },
                            "additionalProperties": {
                              "type": "string",
                              "enum": [
                                "architecture",
                                "structure",
                                "mechanical",
                                "electrical",
                                "plumbing",
                                "fire_protection",
                                "civil",
                                "landscape",
                                "general"
                              ]
                            }
                          }
                        },
                        "additionalProperties": false,
                        "description": "How this project's PDF file names map to sheet number and discipline (BR-11). Without a fileNamePattern the file-name stem is the sheet number."
                      },
                      { "type": "null" }
                    ]
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Update a project",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/updateProjectOutput" }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "project.update",
        "x-fv-side-effect": "write",
        "x-fv-events": ["project.updated"],
        "x-fv-mcp-tool": "fv_update_project",
        "x-fv-rate-limit-class": "write"
      },
      "delete": {
        "operationId": "deleteProject",
        "summary": "Delete a project (restorable for 30 days)",
        "description": "Soft-deletes an active or archived project (BR-3): `status` becomes `deleted`, `purgeAfter` is set 30 days ahead, and the project disappears from every list except `listProjects` with `status: 'deleted'`. Until `purgeAfter` it can be restored with `restoreProject`; after that, a system job purges its models, versions, annotations, uploads and artefacts permanently (BR-38). Destructive: MCP calls need the two-phase confirmation, REST supports `?dryRun=true` (BR-5). Deleting a deleted project changes nothing. Requires `project.delete` (owner/admin).",
        "tags": ["project"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "responses": {
          "204": {
            "description": "No Content",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "project.delete",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["project.deleted"],
        "x-fv-mcp-tool": "fv_delete_project",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/access": {
      "patch": {
        "operationId": "setProjectAccessMode",
        "summary": "Switch a project's access mode",
        "description": "Switches a project between `'org'` (every org-scoped role, BR-27 default) and `'restricted'` (publisher/member also need a `ProjectMember` row, Part B §2.5). Switching to `restricted` auto-adds the caller to `memberIds` if not already listed (BR-30) and returns `impactCount`, the number of org-scoped members who lose implicit access; switching back to `'org'` keeps every existing `ProjectMember` row untouched and `impactCount` is 0. Fires `project.access.changed`.",
        "tags": ["projectAccessMode"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "access": { "type": "string", "enum": ["org", "restricted"] }
                },
                "additionalProperties": false,
                "required": ["access"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Switch a project's access mode",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/setProjectAccessModeOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "project.manage_access",
        "x-fv-side-effect": "write",
        "x-fv-events": ["project.access.changed"],
        "x-fv-mcp-tool": "fv_set_project_access_mode",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/annotations": {
      "get": {
        "operationId": "listAnnotations",
        "summary": "List annotations in a project",
        "description": "Lists the annotations the caller may see in a project: every `shared` one plus the caller's own `personal` ones. Each row is an `AnnotationSummary` (kind, value, label, visibility, needsCheck, creator, timestamps); use `getAnnotation` for anchors and the viewpoint. A measurement taken on a CAD drawing carries `drawing` (documentId, documentVersionId, page). Filters: `subtype`, `visibility`, `documentId` (the measurements on one drawing). Sort `createdAt`/`-createdAt` (default `-createdAt`). Paginated per C10. Requires `annotation.read`.",
        "tags": ["annotations"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "documentId",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Only measurements taken on this drawing (document).",
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: createdAt | -createdAt.",
              "type": "string",
              "enum": ["createdAt", "-createdAt"]
            }
          },
          {
            "name": "subtype",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Only annotations of this subtype.",
              "type": "string",
              "enum": ["measurement"]
            }
          },
          {
            "name": "visibility",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Only personal (your own private ones) or only shared annotations.",
              "type": "string",
              "enum": ["personal", "shared"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List annotations in a project",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/listAnnotationsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "annotation.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_annotations",
        "x-fv-rate-limit-class": "read"
      },
      "post": {
        "operationId": "createAnnotation",
        "summary": "Save a measurement annotation",
        "description": "Saves a measurement as an annotation in a project (`subtype: 'measurement'`). The `measurement` carries its `kind` (distance, edgeLength, angle, areaFace, perpendicularPointFace, perpendicularFaceFace, areaPolygon, overallDimensions), the snapped `anchors` (2 for distance/edgeLength/perpendicular kinds; for angle 2 (two edges or two faces), 3 with `vertexIndex` (three points) or 1 with `slopeReference` (a slope); 1 for areaFace and overallDimensions, 3-100 for areaPolygon), the value that kind reports (`valueMm`, `valueDeg` or `valueM2`; for overallDimensions `dimensions`, 1-3 `{name, valueMm, axis}` extents of the element's oriented box, its one anchor at the box's centre), optional `axisComponentsMm` and `tessellated`, and for a distance, edge length or angle measured in a view `inPlane` (`{normal, valueMm | valueDeg}`: the view's normal and the value in its plane; the measurement's own value stays the 3D one). Values are taken as measured by the client; the server only checks they are consistent. `visibility` defaults to `personal` (`shared` for a workstation). A measurement on a CAD drawing (distance, angle, areaPolygon) has document anchors `{kind: 'document', documentId, documentVersionId, page, point {x,y} (drawing units), snapKind?, entityHandle?}`, all on one page of one version of this project (else `404 resource.not_found`), and its viewpoint is `{document: {page, cad: {center, scale}}}`. Requires `annotation.create` (every role). Fires `annotation.created`.",
        "tags": ["annotation"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "id": {
                    "description": "Optional client-generated ann_ id (C11, offline outbox). Omit to let the server generate one.",
                    "type": "string",
                    "pattern": "^ann_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
                  },
                  "subtype": {
                    "type": "string",
                    "enum": ["measurement"],
                    "description": "Annotation subtype; only 'measurement' exists today."
                  },
                  "visibility": {
                    "description": "personal (only you) or shared (everyone in the project). Default personal; shared for a workstation.",
                    "type": "string",
                    "enum": ["personal", "shared"]
                  },
                  "measurement": {
                    "type": "object",
                    "properties": {
                      "kind": {
                        "type": "string",
                        "enum": [
                          "distance",
                          "edgeLength",
                          "angle",
                          "areaFace",
                          "perpendicularPointFace",
                          "perpendicularFaceFace",
                          "areaPolygon",
                          "overallDimensions"
                        ]
                      },
                      "anchors": {
                        "minItems": 1,
                        "maxItems": 100,
                        "type": "array",
                        "items": {
                          "oneOf": [
                            {
                              "type": "object",
                              "properties": {
                                "kind": {
                                  "type": "string",
                                  "const": "element"
                                },
                                "globalId": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 64,
                                  "description": "IFC GlobalId of the anchored element."
                                },
                                "modelId": {
                                  "type": "string",
                                  "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                  "description": "A mdl identifier (TypeID, conventions C5)."
                                },
                                "versionId": {
                                  "type": "string",
                                  "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                  "description": "A ver identifier (TypeID, conventions C5)."
                                },
                                "localPointMm": {
                                  "type": "object",
                                  "properties": {
                                    "x": { "type": "number" },
                                    "y": { "type": "number" },
                                    "z": { "type": "number" }
                                  },
                                  "required": ["x", "y", "z"],
                                  "additionalProperties": false,
                                  "description": "Snapped point in the version's coordinates, millimetres."
                                },
                                "edgeDirection": {
                                  "description": "For an angle taken off an edge: the edge's unit direction in the version's coordinates.",
                                  "type": "object",
                                  "properties": {
                                    "x": { "type": "number" },
                                    "y": { "type": "number" },
                                    "z": { "type": "number" }
                                  },
                                  "required": ["x", "y", "z"],
                                  "additionalProperties": false
                                },
                                "faceNormal": {
                                  "description": "For an angle or a face area taken off a face: the face's unit normal in the version's coordinates.",
                                  "type": "object",
                                  "properties": {
                                    "x": { "type": "number" },
                                    "y": { "type": "number" },
                                    "z": { "type": "number" }
                                  },
                                  "required": ["x", "y", "z"],
                                  "additionalProperties": false
                                }
                              },
                              "required": [
                                "globalId",
                                "versionId",
                                "localPointMm"
                              ],
                              "additionalProperties": false
                            },
                            {
                              "type": "object",
                              "properties": {
                                "kind": {
                                  "type": "string",
                                  "const": "document"
                                },
                                "documentId": {
                                  "type": "string",
                                  "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                  "description": "A doc identifier (TypeID, conventions C5)."
                                },
                                "documentVersionId": {
                                  "type": "string",
                                  "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                  "description": "A dvr identifier (TypeID, conventions C5)."
                                },
                                "page": {
                                  "type": "integer",
                                  "minimum": 1,
                                  "maximum": 9007199254740991,
                                  "description": "1-based page (sheet) number."
                                },
                                "point": {
                                  "type": "object",
                                  "properties": {
                                    "x": { "type": "number" },
                                    "y": { "type": "number" }
                                  },
                                  "required": ["x", "y"],
                                  "additionalProperties": false,
                                  "description": "The point on the page, in the page's drawing units."
                                },
                                "entityHandle": {
                                  "description": "The CAD entity handle the point snapped to.",
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 32
                                },
                                "snapKind": {
                                  "description": "How the point snapped; absent for a free point.",
                                  "type": "string",
                                  "enum": [
                                    "endpoint",
                                    "intersection",
                                    "midpoint",
                                    "centre",
                                    "quadrant",
                                    "perpendicular",
                                    "nearest"
                                  ]
                                }
                              },
                              "required": [
                                "kind",
                                "documentId",
                                "documentVersionId",
                                "page",
                                "point"
                              ],
                              "additionalProperties": false
                            }
                          ]
                        }
                      },
                      "valueMm": { "type": "number", "minimum": 0 },
                      "valueDeg": {
                        "type": "number",
                        "minimum": 0,
                        "maximum": 180
                      },
                      "valueM2": { "type": "number", "minimum": 0 },
                      "axisComponentsMm": {
                        "type": "object",
                        "properties": {
                          "dx": { "type": "number" },
                          "dy": { "type": "number" },
                          "dz": { "type": "number" }
                        },
                        "required": ["dx", "dy", "dz"],
                        "additionalProperties": false
                      },
                      "vertexIndex": {
                        "description": "For a three-point angle: the index of the anchor the angle is measured at (its vertex).",
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 2
                      },
                      "slopeReference": {
                        "description": "For a slope (an angle with one anchor): what its edge or face is measured against.",
                        "type": "string",
                        "enum": ["horizontal", "vertical"]
                      },
                      "dimensions": {
                        "minItems": 1,
                        "maxItems": 3,
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "name": {
                              "type": "string",
                              "enum": ["length", "width", "height", "thickness"]
                            },
                            "valueMm": { "type": "number", "minimum": 0 },
                            "axis": {
                              "type": "object",
                              "properties": {
                                "x": { "type": "number" },
                                "y": { "type": "number" },
                                "z": { "type": "number" }
                              },
                              "required": ["x", "y", "z"],
                              "additionalProperties": false
                            }
                          },
                          "required": ["name", "valueMm", "axis"],
                          "additionalProperties": false
                        }
                      },
                      "tessellated": { "type": "boolean" },
                      "inPlane": {
                        "description": "For a distance, edge length or angle measured in a view: the view's normal and the value in its plane.",
                        "type": "object",
                        "properties": {
                          "normal": {
                            "type": "object",
                            "properties": {
                              "x": { "type": "number" },
                              "y": { "type": "number" },
                              "z": { "type": "number" }
                            },
                            "required": ["x", "y", "z"],
                            "additionalProperties": false,
                            "description": "The view's unit normal (towards the viewer) in the version's coordinates."
                          },
                          "valueMm": {
                            "description": "A distance's length in the view plane, millimetres.",
                            "type": "number",
                            "minimum": 0
                          },
                          "valueDeg": {
                            "description": "An angle as the view showed it, degrees.",
                            "type": "number",
                            "minimum": 0,
                            "maximum": 180
                          }
                        },
                        "required": ["normal"],
                        "additionalProperties": false
                      },
                      "basis": {
                        "description": "For a drawing measurement: real (read at the drawing's scale) or paper (millimetres on the sheet, no scale). Absent means real.",
                        "type": "string",
                        "enum": ["real", "paper"]
                      }
                    },
                    "required": ["kind", "anchors", "tessellated"],
                    "additionalProperties": false,
                    "description": "kind, anchors (2 for distance/edgeLength/angle/perpendicular*, 1 for areaFace, 3-100 for areaPolygon), the kind's value (valueMm, valueDeg or valueM2) and tessellated. Anchors are on model elements, or (kind: 'document') all on one page of one drawing version."
                  },
                  "label": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 60,
                    "description": "User-given name, 1-60 chars after trimming."
                  },
                  "viewpoint": {
                    "description": "What to restore when the measurement is reopened: the camera, or for a drawing measurement the sheet's view (document: page, centre, scale).",
                    "type": "object",
                    "properties": {
                      "camera": {
                        "type": "object",
                        "properties": {
                          "position": {
                            "type": "object",
                            "properties": {
                              "x": {
                                "type": "number",
                                "minimum": -100000,
                                "maximum": 100000
                              },
                              "y": {
                                "type": "number",
                                "minimum": -100000,
                                "maximum": 100000
                              },
                              "z": {
                                "type": "number",
                                "minimum": -100000,
                                "maximum": 100000
                              }
                            },
                            "required": ["x", "y", "z"],
                            "additionalProperties": false
                          },
                          "target": {
                            "type": "object",
                            "properties": {
                              "x": {
                                "type": "number",
                                "minimum": -100000,
                                "maximum": 100000
                              },
                              "y": {
                                "type": "number",
                                "minimum": -100000,
                                "maximum": 100000
                              },
                              "z": {
                                "type": "number",
                                "minimum": -100000,
                                "maximum": 100000
                              }
                            },
                            "required": ["x", "y", "z"],
                            "additionalProperties": false
                          },
                          "up": { "type": "string", "const": "z" },
                          "fovDeg": {
                            "type": "number",
                            "minimum": 20,
                            "maximum": 90
                          },
                          "orthoHeightM": {
                            "type": "number",
                            "exclusiveMinimum": 0
                          }
                        },
                        "additionalProperties": false
                      },
                      "document": {
                        "type": "object",
                        "properties": {
                          "page": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 9007199254740991
                          },
                          "cad": {
                            "type": "object",
                            "properties": {
                              "center": {
                                "type": "object",
                                "properties": {
                                  "x": { "type": "number" },
                                  "y": { "type": "number" }
                                },
                                "required": ["x", "y"],
                                "additionalProperties": false
                              },
                              "scale": {
                                "type": "number",
                                "exclusiveMinimum": 0
                              }
                            },
                            "required": ["center", "scale"],
                            "additionalProperties": false
                          }
                        },
                        "required": ["page", "cad"],
                        "additionalProperties": false
                      }
                    },
                    "additionalProperties": false
                  }
                },
                "additionalProperties": false,
                "required": ["measurement", "subtype"]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Save a measurement annotation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createAnnotationOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.already_exists",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "annotation.create",
        "x-fv-side-effect": "write",
        "x-fv-events": ["annotation.created"],
        "x-fv-mcp-tool": "fv_create_annotation",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/annotations/{annotationId}": {
      "get": {
        "operationId": "getAnnotation",
        "summary": "Get an annotation",
        "description": "Returns one annotation in full, including the measurement's anchors and the saved viewpoint. A `personal` annotation is only returned to its creator; for anyone else it is `404 resource.not_found`, the same as a missing one. Requires `annotation.read`.",
        "tags": ["annotation"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "annotationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ann_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ann identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-None-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "One or more entity tags (`\"4\"`, `W/\"4\"` or `*`). When one matches the current revision the answer is 304 Not Modified with no body."
          }
        ],
        "responses": {
          "200": {
            "description": "Get an annotation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/getAnnotationOutput" }
              }
            }
          },
          "304": {
            "description": "Not Modified: the If-None-Match entity tag still matches.",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "annotation.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_annotation",
        "x-fv-rate-limit-class": "read"
      },
      "patch": {
        "operationId": "updateAnnotation",
        "summary": "Update an annotation",
        "description": "Renames (`label`, `null` clears it), shares/unshares (`visibility`) or dismisses the needs-check flag (`needsCheck: null`) of the caller's own annotation. Every other field is immutable -- re-measure to create a new annotation. Only the creator may update: someone else's shared annotation is `403 permission.denied`, someone else's personal one `404`. Bumps `revision` and fires `annotation.updated` only when something changes. Optional `If-Match`/`expectedRevision` (412 on mismatch). Requires `annotation.update`.",
        "tags": ["annotation"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "annotationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ann_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ann identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "The revision you last read, as an entity tag (`\"4\"`, from the `ETag` header). A stale one answers 412 `precondition.failed` and changes nothing. `*` matches any current revision (not accepted where a precondition is required). MCP/SDK: `expectedRevision`."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "label": {
                    "description": "New label (max 60 chars), or null to remove it.",
                    "anyOf": [
                      {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 60,
                        "description": "User-given name, 1-60 chars after trimming."
                      },
                      { "type": "null" }
                    ]
                  },
                  "visibility": {
                    "description": "personal (only you) or shared (everyone in the project).",
                    "type": "string",
                    "enum": ["personal", "shared"]
                  },
                  "needsCheck": {
                    "description": "Send null to dismiss the 'needs check' flag after a new model version (still fine).",
                    "type": "null"
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Update an annotation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/updateAnnotationOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "annotation.update",
        "x-fv-side-effect": "write",
        "x-fv-events": ["annotation.updated"],
        "x-fv-mcp-tool": "fv_update_annotation",
        "x-fv-rate-limit-class": "write"
      },
      "delete": {
        "operationId": "deleteAnnotation",
        "summary": "Delete an annotation",
        "description": "Permanently deletes an annotation. The creator may always delete their own (`annotation.delete`); deleting someone else's shared annotation needs `annotation.delete_any` (owner/admin/publisher), otherwise `403 permission.denied`. Someone else's personal annotation is `404 resource.not_found`. Fires `annotation.deleted`.",
        "tags": ["annotation"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "annotationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ann_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ann identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "responses": {
          "204": {
            "description": "No Content",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "annotation.delete",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["annotation.deleted"],
        "x-fv-mcp-tool": "fv_delete_annotation",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/archive": {
      "post": {
        "operationId": "archiveProject",
        "summary": "Archive a project",
        "description": "Archives an active project (BR-3): `status` becomes `archived`, the project disappears from field lists, and it becomes read-only -- no new model, version or publish and no settings change until it is restored (BR-4). Published pointers are kept, so a restore is instant. Idempotent: archiving an archived project returns it unchanged. `409 conflict.state` for a deleted project. Requires `project.archive` (owner/admin).",
        "tags": ["project"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Archive a project",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/archiveProjectOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "project.archive",
        "x-fv-side-effect": "write",
        "x-fv-events": ["project.archived"],
        "x-fv-mcp-tool": "fv_archive_project",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/deep-links:resolve": {
      "get": {
        "operationId": "resolveDeepLink",
        "summary": "Resolve a deep link's elements across versions",
        "description": "Resolves the element refs of a viewer deep link (BR-19: a link targets the project, not a version). For each GlobalId: `present` when a currently published model version has it, `missing` when none does -- then `lastSeen` names the most recent earlier released version of that model that still had it -- or `unknown` when a current element index could not be read. Only versions released to the field are searched, never drafts.",
        "tags": ["deepLink"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "globalIds",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^[0-9A-Za-z_$]{22}(,[0-9A-Za-z_$]{22}){0,19}$",
              "description": "The link's element refs: 1-20 IFC GlobalIds (22 characters of `[0-9A-Za-z_$]`), comma-separated."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Resolve a deep link's elements across versions",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/resolveDeepLinkOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "project.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_resolve_deep_link",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/documents": {
      "get": {
        "operationId": "listDocuments",
        "summary": "List the documents (PDF, DXF and DWG drawings) in a project",
        "description": "Lists the documents in a project, by title by default. Each row carries the version a tap opens (`latestVersion`: number, status, page count, page 1's sheet number and sheet title, a signed URL to page 1's thumbnail, why it failed (`failure`) and its processing `warnings`). Callers with `document.read_unpublished` see every active document with its newest version; everyone else sees only documents with a published version, and that version (BR-6). `status: 'archived'` lists archived documents (needs `document.upload`), `status: 'deleted'` the recently deleted ones with `purgeAfter` (needs `document.delete`). Each row carries the document's `format` (pdf, dxf or dwg) once it has a version; `format` filters on it. Requires `document.read`. Paginated per C10.",
        "tags": ["documents"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "format",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Only documents of this file format: pdf, dxf or dwg (FV-481). A document without a version yet has no format and is left out.",
              "type": "string",
              "enum": ["pdf", "dxf", "dwg"]
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: title | -title | updatedAt | -updatedAt.",
              "type": "string",
              "enum": ["title", "-title", "updatedAt", "-updatedAt"]
            }
          },
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Which documents to list: active (default, every field list), archived (needs document.upload) or deleted (the 'Recently deleted' view, needs document.delete).",
              "type": "string",
              "enum": ["active", "archived", "deleted"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List the documents (PDF, DXF and DWG drawings) in a project",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/listDocumentsOutput" }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "document.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_documents",
        "x-fv-rate-limit-class": "read"
      },
      "post": {
        "operationId": "createDocument",
        "summary": "Create a document (PDF drawing)",
        "description": "Creates a document -- one PDF drawing or drawing set -- inside a project, with `status: 'active'` and `nextVersionNumber: 1`. `title` is optional (1-200 chars after trimming). Call `createDocumentVersion` next to upload the PDF. Requires the `document.upload` capability (owner/admin/publisher). Fires `document.created`.",
        "tags": ["document"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "title": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 200,
                    "description": "Document display title (1-200 chars after trimming)."
                  },
                  "id": {
                    "description": "Optional client-generated id (C11). Omit to let the server generate one.",
                    "type": "string",
                    "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Create a document (PDF drawing)",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createDocumentOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "document.upload",
        "x-fv-side-effect": "write",
        "x-fv-events": ["document.created"],
        "x-fv-mcp-tool": "fv_create_document",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/documents/{documentId}": {
      "patch": {
        "operationId": "updateDocument",
        "summary": "Rename a document",
        "description": "Sets (`title`) or clears (`title: null`) a document's display title (1-200 chars after trimming). JSON Merge Patch (C2): an omitted field is left alone. Bumps `revision` and fires `document.updated` only when the title changes. `409 conflict.state` while the document or its project is archived or deleted. Optional `If-Match`/`expectedRevision` (412 on mismatch). Requires `document.upload` (owner/admin/publisher).",
        "tags": ["document"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "documentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "The revision you last read, as an entity tag (`\"4\"`, from the `ETag` header). A stale one answers 412 `precondition.failed` and changes nothing. `*` matches any current revision (not accepted where a precondition is required). MCP/SDK: `expectedRevision`."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "title": {
                    "anyOf": [
                      {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 200,
                        "description": "Document display title (1-200 chars after trimming)."
                      },
                      { "type": "null" }
                    ]
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Rename a document",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/updateDocumentOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "document.upload",
        "x-fv-side-effect": "write",
        "x-fv-events": ["document.updated"],
        "x-fv-mcp-tool": "fv_update_document",
        "x-fv-rate-limit-class": "write"
      },
      "delete": {
        "operationId": "deleteDocument",
        "summary": "Delete a document (restorable for 30 days)",
        "description": "Soft-deletes an active or archived document: `status` becomes `deleted`, `purgeAfter` is set 30 days ahead, and it disappears from every list except `listDocuments` with `status: 'deleted'`. Until `purgeAfter` it can be restored with `restoreDocument`; after that a system job purges its versions and stored files permanently. `409 conflict.state` for an active document with a published version (archive or unpublish it first) or an archived/deleted project. Destructive: MCP calls need the two-phase confirmation, REST supports `?dryRun=true`. Deleting a deleted document changes nothing. Requires `document.delete` (owner/admin/publisher).",
        "tags": ["document"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "documentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "responses": {
          "204": {
            "description": "No Content",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "document.delete",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["document.deleted"],
        "x-fv-mcp-tool": "fv_delete_document",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/documents/{documentId}/archive": {
      "post": {
        "operationId": "archiveDocument",
        "summary": "Archive a document",
        "description": "Archives an active document: `status` becomes `archived`, it disappears from field lists, and it takes no new version, rename or metadata edit until it is restored. Its published pointer is kept, so a restore is instant. Idempotent: archiving an archived document returns it unchanged. `409 conflict.state` for a deleted document or an archived/deleted project. Requires `document.upload` (owner/admin/publisher).",
        "tags": ["document"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "documentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Archive a document",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/archiveDocumentOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "document.upload",
        "x-fv-side-effect": "write",
        "x-fv-events": ["document.archived"],
        "x-fv-mcp-tool": "fv_archive_document",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/documents/{documentId}/restore": {
      "post": {
        "operationId": "restoreDocument",
        "summary": "Restore an archived or deleted document",
        "description": "Restores a document: an archived document becomes `active` again; a deleted document returns to the status it had before it was deleted -- only within its 30-day window (`purgeAfter`) and before the purge has started, otherwise `409 conflict.state`. Idempotent on an active document. Requires `document.upload` (owner/admin/publisher).",
        "tags": ["document"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "documentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Restore an archived or deleted document",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/restoreDocumentOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "document.upload",
        "x-fv-side-effect": "write",
        "x-fv-events": ["document.restored"],
        "x-fv-mcp-tool": "fv_restore_document",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/documents/{documentId}/unpublish": {
      "post": {
        "operationId": "unpublishDocument",
        "summary": "Unpublish a document",
        "description": "Takes a PDF drawing off the floor: `Document.published` is cleared and the published version becomes `superseded` with `fieldVisible: false` (it stays released, so `publishDocumentVersion` on it is a rollback). Field roles no longer see the drawing until a version is published again. Returns the Document without a `published` pointer; a document with nothing published is returned unchanged. An optional `expectedPublishedVersionId` guards against a concurrent publish; a mismatch is `409 document.publish_conflict`. `409 conflict.state` while the document or project is archived or deleted. Requires `document.publish` (owner/admin/publisher).",
        "tags": ["document"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "documentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "expectedPublishedVersionId": {
                    "type": "string",
                    "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A dvr identifier (TypeID, conventions C5)."
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Unpublish a document",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/unpublishDocumentOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state, document.publish_conflict",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "document.publish",
        "x-fv-side-effect": "write",
        "x-fv-events": ["document.unpublished"],
        "x-fv-mcp-tool": "fv_unpublish_document",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/documents/{documentId}/versions": {
      "get": {
        "operationId": "listDocumentVersions",
        "summary": "List the versions of a drawing",
        "description": "Lists the versions of one drawing, newest first by default (`sort`: `-versionNumber` or `versionNumber`), each as `getDocumentVersion` returns it. Callers who may see drafts (`document.read_unpublished`) get every version; anyone else only the versions released to the field. Requires `document.read`. Paginated per C10.",
        "tags": ["documentVersions"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "documentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: -versionNumber | versionNumber.",
              "type": "string",
              "enum": ["-versionNumber", "versionNumber"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List the versions of a drawing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/listDocumentVersionsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "document.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_document_versions",
        "x-fv-rate-limit-class": "read"
      },
      "post": {
        "operationId": "createDocumentVersion",
        "summary": "Start a drawing upload (PDF, DXF or DWG)",
        "description": "Creates a new version of a document and starts a resumable upload session (conventions C13). `fileName` must end `.pdf`, `.dxf` or `.dwg` (BR-2, E13 BR-1); DXF and DWG need the organisation's CAD drawings switched on, else `422 validation.failed`. The extension sets `source.format`, and a document's first version fixes its format: a file of another format is `422 document.format_mismatch` (upload it as a new document). `sizeBytes` must be within the organisation's limit -- beta default 100 MB, hard ceiling 300 MB for a PDF (BR-3, D-3), and the organisation's storage must have room for it -- else `403 entitlement.limit_reached`; a DXF above 200 MiB or a DWG above 20 MB is `422 validation.failed` (save a larger DWG as DXF or PDF). `versionNumber` comes from the document's own counter. The response's `upload` field is a `{method:'PUT', url, headers, expiresAt, maxBytes, resumable:true, chunkSizeBytes}` ticket -- PUT the PDF bytes directly to `url`, never through this API. The version becomes `uploaded` when storage confirms the file (or on `completeDocumentVersionUpload`). Instead of uploading, `source: {kind:'url', url, sha256?}` imports the PDF from a public HTTPS URL (FV-81, BR-24): no `upload` ticket and no `sizeBytes`; the server downloads it, or the version ends `failed` with an `import.*` code. A URL that is not HTTPS or not public answers `422 import.url_not_allowed`. Requires the `document.upload` capability (owner/admin/publisher). Fires `document.version.created`.",
        "tags": ["documentVersion"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "documentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "description": "The file's size in bytes (BR-3). Required for an upload; leave out with source.kind url.",
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824
                  },
                  "contentType": {
                    "type": "string",
                    "minLength": 1,
                    "description": "The source file's MIME type: application/pdf for a PDF; for a DXF or DWG whatever the browser reports (often application/octet-stream)."
                  },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  },
                  "id": {
                    "description": "Optional client-generated id (C11). Omit to let the server generate one.",
                    "type": "string",
                    "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
                  },
                  "source": {
                    "type": "object",
                    "properties": {
                      "kind": { "type": "string", "const": "url" },
                      "url": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 2048,
                        "description": "Where to download the file: a public HTTPS URL (at most 2,048 characters, no user:password@), e.g. a signed CDN or cloud-storage link. It must stay valid for 25 minutes. Only its scheme, host and path are stored; the query string is not."
                      },
                      "sha256": {
                        "description": "Optional SHA-256 of the file (64 hex). A download that does not match fails with import.checksum_mismatch.",
                        "type": "string",
                        "pattern": "^[0-9a-f]{64}$"
                      }
                    },
                    "required": ["kind", "url"],
                    "additionalProperties": false,
                    "description": "Import the file from a URL instead of uploading it: the server downloads it and the response carries no `upload` ticket. Leave out sizeBytes and the top-level sha256."
                  }
                },
                "additionalProperties": false,
                "required": ["contentType", "fileName"]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Start a drawing upload (PDF, DXF or DWG)",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createDocumentVersionOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "entitlement.limit_reached, permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "document.format_mismatch, import.url_not_allowed, validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "503": {
            "description": "dependency.unavailable",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "document.upload",
        "x-fv-side-effect": "write",
        "x-fv-events": ["document.version.created"],
        "x-fv-mcp-tool": "fv_create_document_version",
        "x-fv-rate-limit-class": "upload"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/documents/{documentId}/versions/{versionId}": {
      "get": {
        "operationId": "getDocumentVersion",
        "summary": "Get a drawing version",
        "description": "Returns one version of a drawing: `status` (uploading, uploaded, processing, ready, failed, cancelled), `publication`, `source` (file name, size, `format`: pdf, dxf or dwg), `pageCount` and `pages[]` (sheet number, title, discipline; on a CAD page its `layout` and primary `titleBlock`), the CAD reader summary `cad` (units, version, layouts), `warnings` and, for a failed version, `failure`. A draft version (not published) is found only by callers who may see drafts (`document.read_unpublished`); for anyone else it is `404`. Requires `document.read`.",
        "tags": ["documentVersion"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "documentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "versionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A dvr identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-None-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "One or more entity tags (`\"4\"`, `W/\"4\"` or `*`). When one matches the current revision the answer is 304 Not Modified with no body."
          }
        ],
        "responses": {
          "200": {
            "description": "Get a drawing version",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getDocumentVersionOutput"
                }
              }
            }
          },
          "304": {
            "description": "Not Modified: the If-None-Match entity tag still matches.",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "document.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_document_version",
        "x-fv-rate-limit-class": "read"
      },
      "patch": {
        "operationId": "updateDocumentVersion",
        "summary": "Correct a document version's sheet metadata or a CAD drawing's units",
        "description": "Sets or clears the `sheetNumber`, `title` and `discipline` of one or more pages of a processed PDF version (BR-11's auto-extracted values, BR-5). JSON Merge Patch per page (C2): omit a field to keep it, `null` clears it. Every field a call sets or clears is a manual override: processing the same version again keeps it (listed in the page's `overridden`). `409 conflict.state` while the version has not finished processing or the project is archived or deleted; `422 validation.failed` for a page the version does not have. `cad.unitsOverride` sets (or `null` clears) the units of a CAD drawing whose file declares none -- metadata only, its measurements rescale without reprocessing; `422 validation.failed` on a PDF version or a drawing whose units were read from the file. `cad.defaultLayersOff` sets the layers a CAD drawing opens with off for everyone (at most 256 names; a person's own choice on their device still wins); `422` on a PDF version. `layerDefault.off` sets that default for any drawing: a CAD drawing's layers or a PDF's optional content groups, by name (`#n` for a group without one). Optional `If-Match`/`expectedRevision` (412 on mismatch). Requires `document.upload` (owner/admin/publisher).",
        "tags": ["documentVersion"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "documentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "versionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A dvr identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "The revision you last read, as an entity tag (`\"4\"`, from the `ETag` header). A stale one answers 412 `precondition.failed` and changes nothing. `*` matches any current revision (not accepted where a precondition is required). MCP/SDK: `expectedRevision`."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "pages": {
                    "description": "Per-page metadata to set (a value) or clear (null); omitted fields are left alone.",
                    "minItems": 1,
                    "maxItems": 500,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "pageNumber": {
                          "type": "integer",
                          "exclusiveMinimum": 0,
                          "maximum": 9007199254740991
                        },
                        "sheetNumber": {
                          "anyOf": [
                            {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 100,
                              "description": "Sheet number, e.g. \"W-101\" (BR-11)."
                            },
                            { "type": "null" }
                          ]
                        },
                        "title": {
                          "anyOf": [
                            {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 200,
                              "description": "Sheet title, e.g. from the PDF outline (BR-11)."
                            },
                            { "type": "null" }
                          ]
                        },
                        "discipline": {
                          "anyOf": [
                            {
                              "type": "string",
                              "enum": [
                                "architecture",
                                "structure",
                                "mechanical",
                                "electrical",
                                "plumbing",
                                "fire_protection",
                                "civil",
                                "landscape",
                                "general"
                              ]
                            },
                            { "type": "null" }
                          ]
                        }
                      },
                      "required": ["pageNumber"],
                      "additionalProperties": false
                    }
                  },
                  "cad": {
                    "description": "FV-488: a unitless CAD drawing's units (mm, cm, m, in, ft), or null to clear them (CAD versions whose file declares no units only). FV-500: defaultLayersOff, the layers off by default for everyone (CAD versions only; superseded by layerDefault).",
                    "type": "object",
                    "properties": {
                      "unitsOverride": {
                        "anyOf": [
                          {
                            "type": "string",
                            "enum": ["mm", "cm", "m", "in", "ft"],
                            "description": "The drawing's units, set by a publisher because the file declares none: mm, cm, m, in or ft."
                          },
                          { "type": "null" }
                        ]
                      },
                      "defaultLayersOff": {
                        "maxItems": 256,
                        "type": "array",
                        "items": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 255
                        },
                        "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
                      }
                    },
                    "additionalProperties": false
                  },
                  "layerDefault": {
                    "type": "object",
                    "properties": {
                      "off": {
                        "maxItems": 256,
                        "type": "array",
                        "items": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 255
                        },
                        "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
                      }
                    },
                    "required": ["off"],
                    "additionalProperties": false,
                    "description": "The layers off by default for everyone who opens this drawing (CAD layers or PDF optional content groups, by name). A person's own choice on their device still wins."
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Correct a document version's sheet metadata or a CAD drawing's units",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/updateDocumentVersionOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "document.upload",
        "x-fv-side-effect": "write",
        "x-fv-events": ["document.version.updated"],
        "x-fv-mcp-tool": "fv_update_document_version",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/documents/{documentId}/versions/{versionId}/artifacts": {
      "get": {
        "operationId": "getDocumentVersionArtifacts",
        "summary": "Get signed URLs to a drawing version's artefacts",
        "description": "Resolves artefact-set paths of a processed document version (the PDF's manifest, per-page tile index, text layer, thumbnails and tiles) to short-lived (15 min) signed GET URLs, for the drawing viewer. Ask for at most 64 paths per call, comma-separated. A version that is still processing (or failed) returns its `status` and no `files`; a failed one also returns its `failure` (code, i18n message key, support reference). A draft version is visible only with `document.read_unpublished` (owner/admin/publisher).",
        "tags": ["documentVersionArtifacts"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "documentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "versionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A dvr identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "paths",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 3072,
              "description": "Comma-separated artefact-set-relative paths to sign, e.g. `manifest.json,pages/1/tiles.json,pages/1/text.json.gz`."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Get signed URLs to a drawing version's artefacts",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getDocumentVersionArtifactsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "document.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_document_version_artifacts",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/documents/{documentId}/versions/{versionId}/cancel": {
      "post": {
        "operationId": "cancelDocumentVersionUpload",
        "summary": "Cancel a PDF drawing upload",
        "description": "Cancels a document version that is still `uploading`: sets `status: 'cancelled'`, deletes the uploaded bytes, and fires `document.version.cancelled`. Destructive -- automatically audited. `409 conflict.state` for a version that is not `uploading`. Requires the `document.upload` capability (owner/admin/publisher).",
        "tags": ["documentVersionUpload"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "documentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "versionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A dvr identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Cancel a PDF drawing upload",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/cancelDocumentVersionUploadOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "document.upload",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["document.version.cancelled"],
        "x-fv-mcp-tool": "fv_cancel_document_version_upload",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/documents/{documentId}/versions/{versionId}/complete": {
      "post": {
        "operationId": "completeDocumentVersionUpload",
        "summary": "Confirm a PDF drawing upload has finished",
        "description": "Confirms the client has finished PUTting the PDF: reads the object's real size from storage and, if it matches the size declared at `createDocumentVersion`, moves the version `uploading -> uploaded` and fires `document.version.uploaded`. Idempotent -- once `uploaded`, calling again is a no-op. `409 conflict.state` if the object is not in storage yet, its size differs, or the version is not `uploading`/`uploaded`. Requires the `document.upload` capability (owner/admin/publisher).",
        "tags": ["documentVersionUpload"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "documentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "versionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A dvr identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Confirm a PDF drawing upload has finished",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/completeDocumentVersionUploadOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "document.upload",
        "x-fv-side-effect": "write",
        "x-fv-events": ["document.version.uploaded"],
        "x-fv-mcp-tool": "fv_complete_document_version_upload",
        "x-fv-rate-limit-class": "write",
        "x-fv-anonymous-access": true
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/documents/{documentId}/versions/{versionId}/pages/{pageNumber}/scale": {
      "patch": {
        "operationId": "setDocumentVersionPageScale",
        "summary": "Set or clear the scale of a PDF drawing's page",
        "description": "Stores the scale of one page of a processed PDF version for every project member: a calibration (`source: calibration`, two points on the page as fractions and the real length between them) or a confirmed title-block scale (`source: label`). `factor` is real millimetres per paper millimetre (1:50 is 50; `422` above 10 000 or at or below 0). The server records who set it and when (`setBy`, `setAt`); a second call replaces it. `scale: null` clears it -- the person who set it may, and so may an owner, admin or publisher for anyone's (`403 permission.denied` otherwise). Metadata only: no reprocessing; the page's measurements read real millimetres at once. `409 conflict.state` while the version has not finished processing or the project is archived; `422` for a CAD version (its scale is read from the file) or a page the version does not have. Fires `document.version.updated` (with `pageScale`). Requires `annotation.create` (every project member); not for workstation sessions.",
        "tags": ["documentVersionPageScale"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "documentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "versionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A dvr identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "pageNumber",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991,
              "description": "The 1-based page (sheet) of the version."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "scale": {
                    "anyOf": [
                      {
                        "type": "object",
                        "properties": {
                          "factor": {
                            "type": "number",
                            "exclusiveMinimum": 0,
                            "maximum": 10000,
                            "description": "Real millimetres per paper millimetre (1:50 is 50)."
                          },
                          "source": {
                            "type": "string",
                            "enum": ["calibration", "label"],
                            "description": "calibration: two points and a known length; label: the title-block scale, confirmed."
                          },
                          "basis": {
                            "description": "For a calibration: the two points (fractions of the page) and the real length in mm.",
                            "type": "object",
                            "properties": {
                              "a": {
                                "type": "object",
                                "properties": {
                                  "xPct": {
                                    "type": "number",
                                    "minimum": 0,
                                    "maximum": 1
                                  },
                                  "yPct": {
                                    "type": "number",
                                    "minimum": 0,
                                    "maximum": 1
                                  }
                                },
                                "required": ["xPct", "yPct"],
                                "additionalProperties": false
                              },
                              "b": {
                                "type": "object",
                                "properties": {
                                  "xPct": {
                                    "type": "number",
                                    "minimum": 0,
                                    "maximum": 1
                                  },
                                  "yPct": {
                                    "type": "number",
                                    "minimum": 0,
                                    "maximum": 1
                                  }
                                },
                                "required": ["xPct", "yPct"],
                                "additionalProperties": false
                              },
                              "lengthMm": {
                                "type": "number",
                                "exclusiveMinimum": 0
                              }
                            },
                            "required": ["a", "b", "lengthMm"],
                            "additionalProperties": false
                          }
                        },
                        "required": ["factor", "source"],
                        "additionalProperties": false
                      },
                      { "type": "null" }
                    ],
                    "description": "The page's scale: factor (real mm per paper mm, 1:50 is 50, at most 10 000), source (calibration | label) and, for a calibration, the two points and the real length; null clears it."
                  }
                },
                "additionalProperties": false,
                "required": ["scale"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Set or clear the scale of a PDF drawing's page",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/setDocumentVersionPageScaleOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "annotation.create",
        "x-fv-side-effect": "write",
        "x-fv-events": ["document.version.updated"],
        "x-fv-mcp-tool": "fv_set_document_version_page_scale",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/documents/{documentId}/versions/{versionId}/publish": {
      "post": {
        "operationId": "publishDocumentVersion",
        "summary": "Publish a document version",
        "description": "Publishes a `ready` PDF drawing version so the field sees it: `Document.published` moves to it, `publication` becomes `published`, `fieldVisible` becomes `true`, `releasedAt` is set, and the previously published version (if any) becomes `superseded` (hidden from field roles). Publishing an older, previously released version is a rollback (event `kind: rollback`). `409 conflict.state` if the version is not `ready`, is archived, or the document or project is archived/deleted. An optional `expectedPublishedVersionId` (or `If-Match` on the document's revision) guards against a concurrent publish; a mismatch is `409 document.publish_conflict`. Requires `document.publish` (owner/admin/publisher).",
        "tags": ["documentVersion"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "documentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "versionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A dvr identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "The revision you last read, as an entity tag (`\"4\"`, from the `ETag` header). A stale one answers 412 `precondition.failed` and changes nothing. `*` matches any current revision (not accepted where a precondition is required). MCP/SDK: `expectedRevision`."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "expectedPublishedVersionId": {
                    "anyOf": [
                      {
                        "type": "string",
                        "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                        "description": "A dvr identifier (TypeID, conventions C5)."
                      },
                      { "type": "null" }
                    ]
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Publish a document version",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/publishDocumentVersionOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state, document.publish_conflict",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "document.publish",
        "x-fv-side-effect": "write",
        "x-fv-events": ["document.version.published"],
        "x-fv-mcp-tool": "fv_publish_document_version",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/documents/{documentId}/versions/{versionId}/source": {
      "get": {
        "operationId": "getDocumentVersionSource",
        "summary": "Download a drawing version's original file",
        "description": "Returns a short-lived (15 min) signed URL to the original file of a drawing version (PDF, DXF or DWG, see `format`), which saves it under its original name, with its size, content type and SHA-256. The file itself never passes through the API. Needs `document.download_source` (owner/admin/publisher, or a platform admin's support grant); a draft also needs `document.read_unpublished`. A version whose upload never finished, or whose source was removed (a failed version's source is kept 14 days), is `resource.not_found`. Every download is audited.",
        "tags": ["documentVersionSource"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "documentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "versionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A dvr identifier (TypeID, conventions C5)."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Download a drawing version's original file",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getDocumentVersionSourceOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "document.download_source",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_document_version_source",
        "x-fv-rate-limit-class": "heavy"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/documents/{documentId}/versions/{versionId}/start-processing": {
      "post": {
        "operationId": "startDocumentVersionProcessing",
        "summary": "Retry a drawing that was uploaded but never processed",
        "description": "Starts processing a document version that is stuck in `uploaded`: the upload finished, but its processing never started (for example when the storage notification raced ahead of `completeDocumentVersionUpload`). The version is queued for the processor (`processing.queuedAt`) and processing starts as soon as a slot is free; the version then moves to `processing` and on to `ready` or `failed` as usual. Returns the version. A version counts as stuck once it has been `uploaded` for 2 minutes without starting; retrying earlier is harmless (a version is never processed twice). `409 conflict.state` if the version is not `uploaded` (still uploading, processing, or finished). Requires the `document.upload` capability (owner/admin/publisher) and an `Idempotency-Key`.",
        "tags": ["documentVersionProcessing"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "documentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "versionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A dvr identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Retry a drawing that was uploaded but never processed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/startDocumentVersionProcessingOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "document.upload",
        "x-fv-side-effect": "write",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_start_document_version_processing",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/documents/{documentId}/versions/{versionId}/wait": {
      "get": {
        "operationId": "waitDocumentVersion",
        "summary": "Wait for a drawing version to finish processing",
        "description": "Long-polls until the drawing version's `status` reaches an outcome (`ready`, `failed` or `cancelled`) or the timeout elapses (C12, <= 25 s). Use after `completeDocumentVersionUpload` or a URL import instead of polling `getDocumentVersion`. Drafts only for callers with `document.read_unpublished`.",
        "tags": ["documentVersion"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "documentId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "versionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A dvr identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "timeoutSeconds",
            "in": "query",
            "required": false,
            "schema": { "type": "integer", "minimum": 1, "maximum": 25 }
          }
        ],
        "responses": {
          "200": {
            "description": "Wait for a drawing version to finish processing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/waitDocumentVersionOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "document.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_wait_for_document_version",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/documents:search-text": {
      "get": {
        "operationId": "searchDocumentText",
        "summary": "Search the text printed on a project's drawings",
        "description": "Finds every word on the project's drawings (PDF and CAD) that contains `query` -- a sheet number, a mark, a title-block value -- case- and accent-insensitive, the same matching as the drawing viewer's search. Each hit names its drawing, version and page, the word, and its box as page fractions (on a CAD sheet also `box` in drawing units). Searches each drawing's published version; callers who may see drafts (`document.read_unpublished`) search the newest processed version instead. Paged by drawing (`limit` <= 50 drawings per page, `cursor`). Requires `document.read`.",
        "tags": ["documentText"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque cursor from a previous page's nextCursor (same query and documentIds).",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "documentIds",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Only these drawings: a comma-separated list of up to 50 document ids.",
              "type": "string",
              "pattern": "^doc_[0-9a-z]{26}(,doc_[0-9a-z]{26}){0,49}$"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Drawings searched per page (1-50). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 50
            }
          },
          {
            "name": "query",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 2,
              "maxLength": 200,
              "description": "The text to find on the drawings, e.g. `W-103` (at least 2 characters). A word matches when it contains the query; case and accents are ignored."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Search the text printed on a project's drawings",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/searchDocumentTextOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "document.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_search_document_text",
        "x-fv-rate-limit-class": "heavy"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/elements:search": {
      "get": {
        "operationId": "searchElements",
        "summary": "Search a project's elements by name, tag or type",
        "description": "Finds elements of the project's current revision whose name, tag or IFC class contains every word of `q` (case- and accent-insensitive), best match first: an exact tag or name, then a tag or name starting with `q`, then the rest in model order. Same matching as the viewer's search. Each hit carries its GlobalId, name, tag, IFC class and storey. Empty when the project has no published revision yet. Paged with `limit`/`cursor`; a cursor only continues the query and revision it was issued for.",
        "tags": ["elements"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque cursor from a previous page's nextCursor (same q).",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max hits per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "q",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 200,
              "description": "What to look for in the element's name, tag or IFC class, e.g. `W-103`. Case and accents are ignored; every word must occur."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Search a project's elements by name, tag or type",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/searchElementsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "project.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_search_elements",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/layer-sets": {
      "get": {
        "operationId": "listLayerSets",
        "summary": "List a project's layer sets",
        "description": "Lists the project's LayerSets as summaries (id, status, derivation source, entry count, revision, updatedAt). A project has at most one in beta, created on its first publish; an empty page means nothing is published yet. Requires `layerset.read` (every project role). Paginated per C10.",
        "tags": ["layerSets"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: updatedAt | -updatedAt.",
              "type": "string",
              "enum": ["updatedAt", "-updatedAt"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List a project's layer sets",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/listLayerSetsOutput" }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "layerset.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_layer_sets",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/layer-sets/{layerSetId}": {
      "get": {
        "operationId": "getLayerSet",
        "summary": "Get a project's layer set",
        "description": "Returns the project's LayerSet: its entries (layers) with name, colour, order, element count and whether each is on by default. `view=field` (the default) leaves out the entries a publisher hid from the field (`hiddenFromField`); `view=all` returns every entry, for curation. A set left `materializing` for more than 5 minutes (an interrupted rule save) is re-materialised before it is returned, or -- after 3 runs -- returned `failed` with `failure.supportRef`. Requires `layerset.read` (every project role).",
        "tags": ["layerSet"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "layerSetId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A lys identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "view",
            "in": "query",
            "required": false,
            "schema": {
              "description": "`field` (default): without the entries hidden from the field. `all`: every entry, for curation.",
              "type": "string",
              "enum": ["field", "all"]
            }
          },
          {
            "name": "If-None-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "One or more entity tags (`\"4\"`, `W/\"4\"` or `*`). When one matches the current revision the answer is 304 Not Modified with no body."
          }
        ],
        "responses": {
          "200": {
            "description": "Get a project's layer set",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/getLayerSetOutput" }
              }
            }
          },
          "304": {
            "description": "Not Modified: the If-None-Match entity tag still matches.",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "layerset.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_layer_set",
        "x-fv-rate-limit-class": "read"
      },
      "patch": {
        "operationId": "updateLayerSet",
        "summary": "Curate a project's layer set",
        "description": "Renames, recolours, reorders, merges, hides from the field (`hiddenFromField`) or switches off by default (`defaultOn`) the entries of a LayerSet. JSON Merge Patch per entry, addressed by `id` (C2): omit a field to keep it, `colorHex: null` removes the colour. `mergeEntryIds` merges those entries into this one; their derivation keys move with them, so the next publish's re-derivation still finds them. Curation survives every re-derivation (BR-5). `422 validation.failed` for an unknown entry, a blank name or a merge across derivation kinds; `409 conflict.state` while the project is archived or deleted. Optional `If-Match`/`expectedRevision` (412 on mismatch). Fires `layerSet.updated` when something changes. Requires `layerset.manage` (owner/admin/publisher).\n\nRule layers (BR-4): send a new `id` (e.g. `rule-external-walls`) with `displayName` and `rule` `{psetName, propName, op: eq|neq|contains, value}` to create one; `rule` on a rule layer changes it, `remove: true` deletes it. At most 50 rule layers per set. A new or changed rule answers `202` with `status: materializing`: the members (`materializedGlobalIds`) are computed from the published models' properties and the set returns to `ready` -- call `waitForLayerSet`. Every later publish recomputes them. A rule that matches nothing is a layer with 0 elements, not an error.\n\nA rule with `source` `name`, `material`, `ifcClass` or `panel` (no psetName/propName) is answered by the element table: saved at once (`200`), counted as the viewer counts it, and it works offline in the field. A new `id` with `displayName` and `manualGlobalIds` (at most 500 GlobalIds) saves a layer of exactly those elements; `remove: true` deletes it again.\n\nA layer of the company's layer template (`origin: template`) cannot be removed or given another rule (`409 conflict.state`); hide it with `hiddenFromField`. A locked one also keeps the template's name, colour and default-on (`409`). `followTemplate: true` hands an unlocked one back to the template: a later template update sets its name, colour and default-on again.",
        "tags": ["layerSet"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "layerSetId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A lys identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "The revision you last read, as an entity tag (`\"4\"`, from the `ETag` header). A stale one answers 412 `precondition.failed` and changes nothing. `*` matches any current revision (not accepted where a precondition is required). MCP/SDK: `expectedRevision`."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "entries": {
                    "minItems": 1,
                    "maxItems": 100,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "id": {
                          "type": "string",
                          "pattern": "^[a-z0-9][a-z0-9-]{0,63}$",
                          "description": "The entry to change."
                        },
                        "displayName": {
                          "description": "New name, 1-60 characters (trimmed).",
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 60
                        },
                        "colorHex": {
                          "description": "Colour as #rgb or #rrggbb (stored as lower-case #rrggbb); null removes it.",
                          "anyOf": [
                            {
                              "type": "string",
                              "pattern": "^#(?:[0-9a-fA-F]{3}|[0-9a-fA-F]{6})$"
                            },
                            { "type": "null" }
                          ]
                        },
                        "order": {
                          "description": "New position (0 = first). The entries are renumbered 0..n-1; a moved entry goes before an unmoved one at the same position.",
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 99
                        },
                        "defaultOn": { "type": "boolean" },
                        "hiddenFromField": { "type": "boolean" },
                        "mergeEntryIds": {
                          "description": "Entries to merge into this one: their derivation keys move here and they disappear. Same derivation kind only.",
                          "minItems": 1,
                          "maxItems": 99,
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "^[a-z0-9][a-z0-9-]{0,63}$"
                          }
                        },
                        "rule": {
                          "description": "A rule layer's predicate. With an id the set does not have yet (and a displayName), creates that rule layer; on an existing rule layer, replaces its rule.",
                          "type": "object",
                          "properties": {
                            "source": {
                              "description": "What the rule tests: `property` (the default) a property value (`psetName`, `propName`); `name` the element name, `material` its material, `ifcClass` its IFC class, `panel` the name or tag of the panel (`IfcElementAssembly`) it is part of -- these four take no psetName/propName, are counted on the device and work offline.",
                              "type": "string",
                              "enum": [
                                "property",
                                "name",
                                "material",
                                "ifcClass",
                                "panel"
                              ]
                            },
                            "psetName": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 255,
                              "description": "Property (or quantity) set name exactly as in the model, e.g. `Pset_WallCommon`. Property rules only."
                            },
                            "propName": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 255,
                              "description": "Property name exactly as in the model, e.g. `IsExternal`. Property rules only."
                            },
                            "op": {
                              "type": "string",
                              "enum": ["eq", "neq", "contains"],
                              "description": "`eq` equals, `neq` differs from (elements without the property never match), `contains` contains the value."
                            },
                            "value": {
                              "type": "string",
                              "maxLength": 1000,
                              "description": "Text to compare; case, accents and surrounding spaces are ignored. Booleans read `true`/`false`; a number also matches numerically (`0,24` = `0.24`). For name, material, ifcClass and panel rules several values may be separated by commas (any matches), and an empty value with eq/contains matches every element that has one (e.g. part of any panel)."
                            }
                          },
                          "required": ["op", "value"],
                          "additionalProperties": false
                        },
                        "remove": {
                          "description": "Deletes this rule or saved (manual) layer. Derived layers cannot be removed.",
                          "type": "boolean",
                          "const": true
                        },
                        "manualGlobalIds": {
                          "description": "With an id the set does not have yet (and a displayName): saves a layer of exactly these elements (IFC GlobalIds, at most 500), e.g. a search result.",
                          "minItems": 1,
                          "maxItems": 500,
                          "type": "array",
                          "items": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 64
                          }
                        },
                        "followTemplate": {
                          "description": "On a layer of the company's layer template: it follows the template again, so a later template update sets its name, colour and default-on. Send the template's values with it to take them at once.",
                          "type": "boolean",
                          "const": true
                        }
                      },
                      "required": ["id"],
                      "additionalProperties": false
                    }
                  }
                },
                "additionalProperties": false,
                "required": ["entries"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Curate a project's layer set",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/updateLayerSetOutput"
                }
              }
            }
          },
          "202": {
            "description": "Accepted: `status` is `materializing` until the work finishes.",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/updateLayerSetOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "layerset.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["layerSet.updated"],
        "x-fv-mcp-tool": "fv_update_layer_set",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/layer-sets/{layerSetId}/reprocess": {
      "post": {
        "operationId": "reprocessLayerSet",
        "summary": "Reset a layer set to its derived defaults",
        "description": "Resets every curation of a LayerSet (names, colours, order, default-on, hidden-from-field, merges) to what the derivation makes of the currently published models (AC-4). Membership is unaffected. `409 conflict.state` when nothing is published or the project is archived or deleted. Optional `If-Match`/`expectedRevision` (412 on mismatch). Fires `layerSet.reset`. Requires `layerset.manage` (owner/admin/publisher).\n\n`grouping` (optional) chooses how the automatic layers are grouped from now on -- by the role in the element name (`name-role`), `material`, `classification` or `object-type`, optionally followed by a second source for what the first leaves. It is kept on the set (`grouping`) for every later publish; a reset without it returns to the automatic choice.\n\n`merges` (optional) merges layers of the reset set in the same write, addressed by derivation key (`{ into, keys }`): the rows a publisher merged inside a suggested proposal before using it. `422 validation.failed` when a key names no derived layer of the reset set.",
        "tags": ["layerSet"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "layerSetId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A lys identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "The revision you last read, as an entity tag (`\"4\"`, from the `ETag` header). A stale one answers 412 `precondition.failed` and changes nothing. `*` matches any current revision (not accepted where a precondition is required). MCP/SDK: `expectedRevision`."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "grouping": {
                    "description": "Group the automatic layers by these element attributes from now on: one source, or a source and the complement that groups what it leaves (e.g. `[\"name-role\", \"material\"]`). Omit to let the derivation choose.",
                    "minItems": 1,
                    "maxItems": 2,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "enum": [
                        "classification",
                        "name-role",
                        "material",
                        "object-type"
                      ]
                    }
                  },
                  "merges": {
                    "description": "FV-504: merge layers of the reset set, by derivation key: the layers derived from `keys` go into the layer derived from `into`, as `updateLayerSet`'s `mergeEntryIds` would. Each key may appear once across all merges.",
                    "minItems": 1,
                    "maxItems": 100,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "into": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 512
                        },
                        "keys": {
                          "minItems": 1,
                          "maxItems": 100,
                          "type": "array",
                          "items": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 512
                          }
                        }
                      },
                      "required": ["into", "keys"],
                      "additionalProperties": false
                    }
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Reset a layer set to its derived defaults",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/reprocessLayerSetOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "layerset.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["layerSet.reset"],
        "x-fv-mcp-tool": "fv_reprocess_layer_set",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/layer-sets/{layerSetId}/wait": {
      "get": {
        "operationId": "waitLayerSet",
        "summary": "Wait for a layer set's rule layers to be computed",
        "description": "Long-polls until the LayerSet's `status` is `ready` -- the rule layers a `202` `updateLayerSet` started computing have their members (`materializedGlobalIds`) -- or `failed`, or the timeout elapses (C12, <= 25s). A set left `materializing` for more than 5 minutes (the save was interrupted) is re-materialised by this call; after 3 interrupted runs it resolves `failed` with `failure.supportRef`. `view` as `getLayerSet`.",
        "tags": ["layerSet"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "layerSetId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A lys identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "timeoutSeconds",
            "in": "query",
            "required": false,
            "schema": { "type": "integer", "minimum": 1, "maximum": 25 }
          },
          {
            "name": "view",
            "in": "query",
            "required": false,
            "schema": {
              "description": "`field` (default): without the entries hidden from the field. `all`: every entry, for curation.",
              "type": "string",
              "enum": ["field", "all"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Wait for a layer set's rule layers to be computed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/waitLayerSetOutput" }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "layerset.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_wait_for_layer_set",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/layer-sets:preview-rule": {
      "post": {
        "operationId": "previewLayerRule",
        "summary": "Count the elements a rule-based layer would hold",
        "description": "Dry run of a rule layer (nothing is saved): counts the elements of the project's published models whose property `psetName`.`propName` matches `op` (`eq`, `neq`, `contains`) and `value` -- case, accents and surrounding spaces ignored, an element without the property never matches. `includeProperties: true` also lists the property sets and properties the elements carry, with up to 20 values each, to build a rule from. `elementCount` 0 is a valid answer, not an error. Requires `layerset.manage` (owner/admin/publisher).",
        "tags": ["layerRule"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "rule": {
                    "description": "The rule to count, as updateLayerSet takes it. Omit it to only list the properties.",
                    "type": "object",
                    "properties": {
                      "source": {
                        "description": "What the rule tests: `property` (the default) a property value (`psetName`, `propName`); `name` the element name, `material` its material, `ifcClass` its IFC class, `panel` the name or tag of the panel (`IfcElementAssembly`) it is part of -- these four take no psetName/propName, are counted on the device and work offline.",
                        "type": "string",
                        "enum": [
                          "property",
                          "name",
                          "material",
                          "ifcClass",
                          "panel"
                        ]
                      },
                      "psetName": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 255,
                        "description": "Property (or quantity) set name exactly as in the model, e.g. `Pset_WallCommon`. Property rules only."
                      },
                      "propName": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 255,
                        "description": "Property name exactly as in the model, e.g. `IsExternal`. Property rules only."
                      },
                      "op": {
                        "type": "string",
                        "enum": ["eq", "neq", "contains"],
                        "description": "`eq` equals, `neq` differs from (elements without the property never match), `contains` contains the value."
                      },
                      "value": {
                        "type": "string",
                        "maxLength": 1000,
                        "description": "Text to compare; case, accents and surrounding spaces are ignored. Booleans read `true`/`false`; a number also matches numerically (`0,24` = `0.24`). For name, material, ifcClass and panel rules several values may be separated by commas (any matches), and an empty value with eq/contains matches every element that has one (e.g. part of any panel)."
                      }
                    },
                    "required": ["op", "value"],
                    "additionalProperties": false
                  },
                  "includeProperties": {
                    "description": "`true`: also list the property sets and properties of the published elements, with some of their values (for building a rule).",
                    "type": "boolean"
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Count the elements a rule-based layer would hold",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/previewLayerRuleOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "layerset.manage",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_preview_layer_rule",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/link-coverage": {
      "get": {
        "operationId": "getLinkCoverage",
        "summary": "Get how many panels have a drawing",
        "description": "Returns link coverage from the model's side: `panels`, the assemblies (by their mark) of the project's published models; `linked`, how many of them have at least one active link to a drawing (a link on the mark, or on the assembly element); and `unlinked`, the panels without one, by mark (at most 200; `truncated` when there are more). Requires `link.read` (every role).",
        "tags": ["linkCoverage"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Get how many panels have a drawing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getLinkCoverageOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_link_coverage",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/link-discovery-runs": {
      "post": {
        "operationId": "createLinkDiscoveryRun",
        "summary": "Find how a project's drawings link to its model",
        "description": "Starts a link discovery run over the project's published drawings (PDF, DXF, DWG) and models: every strategy -- file name, layout name, title-block attribute, sheet text, model property -- is scored by how many drawings it links unambiguously (keys printed on more than one drawing count against it; very short keys are halved), and the best ones form the proposed profile (`result.recommended`). Answers `202` with the run `running`; poll `getLinkDiscoveryRun` or wait with `waitForLinkDiscoveryRun`. Writes no links: accept the profile with `acceptLinkDiscoveryRun`. Requires `link.manage` (owner/admin/publisher). Fires `linkDiscoveryRun.completed`.",
        "tags": ["linkDiscoveryRun"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "trigger": {
                    "description": "manual (default): started from the links settings; upload_batch: started after a bulk upload.",
                    "type": "string",
                    "enum": ["manual", "upload_batch"]
                  },
                  "scope": {
                    "description": "Only these published drawings (<= 500) and models (<= 4); default: every published one.",
                    "type": "object",
                    "properties": {
                      "documentIds": {
                        "minItems": 1,
                        "maxItems": 500,
                        "type": "array",
                        "items": {
                          "type": "string",
                          "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A doc identifier (TypeID, conventions C5)."
                        }
                      },
                      "modelIds": {
                        "minItems": 1,
                        "maxItems": 4,
                        "type": "array",
                        "items": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        }
                      }
                    },
                    "additionalProperties": false
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "202": {
            "description": "Find how a project's drawings link to its model",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createLinkDiscoveryRunOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["linkDiscoveryRun.completed"],
        "x-fv-mcp-tool": "fv_create_link_discovery_run",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/link-discovery-runs/{runId}": {
      "get": {
        "operationId": "getLinkDiscoveryRun",
        "summary": "Get a link discovery run",
        "description": "Returns one link discovery run of the project: `status` (running, done, failed), and once done its `result` -- the ranked `strategies` (rule draft, score, coverage, matched and ambiguous drawing counts, samples) and `recommended`, the proposed profile -- and whether it was accepted. Requires `link.read` (every role).",
        "tags": ["linkDiscoveryRun"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "runId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ldr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ldr identifier (TypeID, conventions C5)."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Get a link discovery run",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getLinkDiscoveryRunOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_link_discovery_run",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/link-discovery-runs/{runId}/accept": {
      "post": {
        "operationId": "acceptLinkDiscoveryRun",
        "summary": "Accept a discovered link profile",
        "description": "Accepts the chosen strategies of a `done` discovery run (`strategyIndexes`, usually `result.recommended`): creates one link rule per strategy with `autoApply: true` and the run's id as `discoveryRunId` (priority by rank), and applies them -- a drawing an earlier strategy links is never linked again by a later one, and ambiguous keys are never linked. A run is accepted once: a second accept is `409 link_discovery.already_accepted`; a run that is not `done` is `409 conflict.state`; an index outside the result is `422`. Requires `link.manage` (owner/admin/publisher) and an `Idempotency-Key`. Fires `linkDiscoveryRun.accepted`, `linkRule.created` per rule and `linkRuleRun.completed` per run.",
        "tags": ["linkDiscoveryRun"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "runId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ldr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ldr identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "strategyIndexes": {
                    "minItems": 1,
                    "maxItems": 10,
                    "type": "array",
                    "items": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "description": "Indexes into result.strategies to accept, usually result.recommended (e.g. [0])."
                  }
                },
                "additionalProperties": false,
                "required": ["strategyIndexes"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Accept a discovered link profile",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/acceptLinkDiscoveryRunOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state, link_discovery.already_accepted",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": [
          "linkDiscoveryRun.accepted",
          "linkRule.created",
          "linkRuleRun.completed",
          "link.created",
          "link.updated"
        ],
        "x-fv-mcp-tool": "fv_accept_link_discovery_run",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/link-discovery-runs/{runId}/wait": {
      "get": {
        "operationId": "waitLinkDiscoveryRun",
        "summary": "Wait for a link discovery run to finish",
        "description": "Long-polls until the discovery run's `status` is `done` or `failed`, or the timeout elapses (C12, <= 25s).",
        "tags": ["linkDiscoveryRun"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "runId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ldr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ldr identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "timeoutSeconds",
            "in": "query",
            "required": false,
            "schema": { "type": "integer", "minimum": 1, "maximum": 25 }
          }
        ],
        "responses": {
          "200": {
            "description": "Wait for a link discovery run to finish",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/waitLinkDiscoveryRunOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_wait_for_link_discovery_run",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/link-imports": {
      "post": {
        "operationId": "createLinkImport",
        "summary": "Start a bulk link import from a CSV file",
        "description": "Starts linking many model elements to drawing sheets from one CSV file. Returns the `LinkImport` (`status: uploading`) with an `upload` ticket (`{method:'PUT', url, headers, expiresAt, maxBytes, resumable:true, chunkSizeBytes}`) -- PUT the CSV directly to `url`, never through this API (C13). The CSV is UTF-8 (a byte-order mark is fine), `,`- or `;`-separated, with the header `elementTag,sheetNumber,page,regionXPct,regionYPct,regionWPct,regionHPct` (any order). Each row links the element of the published model whose IFC `Tag` is `elementTag` (when no element has that Tag: the assembly whose panel mark it is) to the published drawing page carrying `sheetNumber` (`page` picks another page of that drawing; empty: the sheet's own page), optionally to a region given as percentages (0-100) of the page; all four region columns empty links the whole page. Once storage has the file it is processed row by row (BR-19): one `origin: manual` Link per row, a row that cannot be linked becomes a `result.errors` entry (`element_not_found`, `ambiguous_element`, `sheet_not_found`, `sheet_not_ready`, `ambiguous_sheet`, `page_out_of_range`, `invalid_page`, `invalid_region`, `missing_value`) and an identical existing link is `skipped`. `sheet_not_ready`: a drawing goes by that sheet number (title, file name or sheet number) but its newest version is still uploading or processing -- import a CSV of only the rejected rows (`errors[].row`) again once it is ready; rows already linked are `skipped`, never linked twice. The import ends `done` with `result {rows, created, skipped, errors}`, or `failed` with `error.code` when the file itself is unusable. At most 5000 rows and 2097152 bytes: a larger `sizeBytes` or `rowCount` is `422 import.csv_too_large`. Poll with `waitLinkImport`. Requires `link.manage` (owner/admin/publisher) and an `Idempotency-Key`. Fires `linkImport.created`, then `linkImport.completed`.",
        "tags": ["linkImport"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "fileName": {
                    "type": "string",
                    "minLength": 5,
                    "maxLength": 255,
                    "description": "The CSV's file name, ending .csv (max 255 chars)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991,
                    "description": "The CSV's size in bytes; over 2097152 is 422 import.csv_too_large."
                  },
                  "rowCount": {
                    "description": "Optional: the CSV's data rows (header not counted); over 5000 is 422 import.csv_too_large.",
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "id": {
                    "description": "Optional client-generated id (C11). Omit to let the server generate one.",
                    "type": "string",
                    "pattern": "^lim_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
                  }
                },
                "additionalProperties": false,
                "required": ["fileName", "sizeBytes"]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Start a bulk link import from a CSV file",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createLinkImportOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.already_exists, conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "import.csv_too_large, validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["linkImport.created", "linkImport.completed"],
        "x-fv-mcp-tool": "fv_create_link_import",
        "x-fv-rate-limit-class": "heavy"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/link-imports/{importId}": {
      "get": {
        "operationId": "getLinkImport",
        "summary": "Get a bulk link import",
        "description": "Returns one link import of the project: its `status` (`uploading`, `processing`, `done`, `failed`), `progress` while processing, `result {rows, created, skipped, errors}` once done (`errors`: one `{row, code}` per row that was not linked, `row` counted as a spreadsheet does, the header being row 1) and `error {code, detail}` when the file was refused. Requires `link.read` (every role).",
        "tags": ["linkImport"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "importId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^lim_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A lim identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-None-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "One or more entity tags (`\"4\"`, `W/\"4\"` or `*`). When one matches the current revision the answer is 304 Not Modified with no body."
          }
        ],
        "responses": {
          "200": {
            "description": "Get a bulk link import",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/getLinkImportOutput" }
              }
            }
          },
          "304": {
            "description": "Not Modified: the If-None-Match entity tag still matches.",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_link_import",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/link-imports/{importId}/wait": {
      "get": {
        "operationId": "waitLinkImport",
        "summary": "Wait for a bulk link import to finish",
        "description": "Long-polls until the link import's `status` is `done` or `failed`, or the timeout elapses (C12, <= 25s). An import still `uploading` waits for its CSV to arrive.",
        "tags": ["linkImport"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "importId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^lim_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A lim identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "timeoutSeconds",
            "in": "query",
            "required": false,
            "schema": { "type": "integer", "minimum": 1, "maximum": 25 }
          }
        ],
        "responses": {
          "200": {
            "description": "Wait for a bulk link import to finish",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/waitLinkImportOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_wait_for_link_import",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/link-rule-runs": {
      "post": {
        "operationId": "createLinkRuleRun",
        "summary": "Preview or apply an auto-linking rule",
        "description": "Runs a link rule over the project's published models and published drawings and stores the result as a `LinkRuleRun`: `result.candidates` (source element/assembly/storey, target document + page, the shared `key`, `confidence` 1.0 for an exact match after normalisation, `ambiguous` when the key matched more than one sheet), `wouldCreate` (unambiguous candidates), `ambiguous`, `unmatched` keys per side, `truncated` (more than 2000 candidates) and `warnings` (an artefact that could not be read). `dryRun` (default true): nothing is linked. `dryRun: false` applies the run: every unambiguous candidate becomes a `Link` (`origin: rule`, `ruleId`, `confidence`), a stale link of the rule whose key still matches is healed (new GlobalId, `status: active`), ambiguous groups and sources with a manual link are never touched; `result.applied` = `{created, updated, unchanged, manual, remaining}` (at most 128 changes per run -- run again while `remaining` > 0). The run completes within the request (`status: done`). Requires `link.manage` (owner/admin/publisher). Fires `linkRuleRun.completed`, and `link.created`/`link.updated` per link.",
        "tags": ["linkRuleRun"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "ruleId": {
                    "type": "string",
                    "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A lkr identifier (TypeID, conventions C5)."
                  },
                  "dryRun": {
                    "description": "`true` (the default): preview only, nothing is linked. `false`: apply -- create the unambiguous links (at most 128 per run; run again while `result.applied.remaining` > 0).",
                    "type": "boolean"
                  }
                },
                "additionalProperties": false,
                "required": ["ruleId"]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Preview or apply an auto-linking rule",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createLinkRuleRunOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": [
          "linkRuleRun.completed",
          "link.created",
          "link.updated"
        ],
        "x-fv-mcp-tool": "fv_create_link_rule_run",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/link-rule-runs/{runId}": {
      "get": {
        "operationId": "getLinkRuleRun",
        "summary": "Get an auto-linking preview run",
        "description": "Returns one link-rule run of the project: its status, rule and result (candidates, counts, warnings). Requires `link.read` (every role).",
        "tags": ["linkRuleRun"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "runId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^lrr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A lrr identifier (TypeID, conventions C5)."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Get an auto-linking preview run",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getLinkRuleRunOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_link_rule_run",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/link-rule-runs/{runId}/wait": {
      "get": {
        "operationId": "waitLinkRuleRun",
        "summary": "Wait for an auto-linking run to finish",
        "description": "Long-polls until the link-rule run's `status` is `done` or `failed`, or the timeout elapses (C12, <= 25s).",
        "tags": ["linkRuleRun"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "runId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^lrr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A lrr identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "timeoutSeconds",
            "in": "query",
            "required": false,
            "schema": { "type": "integer", "minimum": 1, "maximum": 25 }
          }
        ],
        "responses": {
          "200": {
            "description": "Wait for an auto-linking run to finish",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/waitLinkRuleRunOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_wait_for_link_rule_run",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/link-rules": {
      "get": {
        "operationId": "listLinkRules",
        "summary": "List the auto-linking rules of a project",
        "description": "Lists a project's link rules, by `priority` (then name) by default; `autoApply=true|false` filters on whether a rule runs on every new drawing version. Requires `link.read` (every role). Paginated per C10.",
        "tags": ["linkRules"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "autoApply",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Only rules that run on every new drawing version (true) or only those that do not (false).",
              "type": "string",
              "enum": ["true", "false"]
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: priority | -priority | name | -name.",
              "type": "string",
              "enum": ["priority", "-priority", "name", "-name"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List the auto-linking rules of a project",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/listLinkRulesOutput" }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_link_rules",
        "x-fv-rate-limit-class": "read"
      },
      "post": {
        "operationId": "createLinkRule",
        "summary": "Create an auto-linking rule",
        "description": "Stores a rule that links model elements to drawing sheets by a shared key: `matchModel.field` (`tag` -- an element's IFC Tag, `assemblyMark` -- an assembly's mark, `storeyName`, `name` -- an element's IFC Name, `property` -- one property's value, named by `matchModel.property {set, name}`) against `matchDocument.field` (`sheetNumber`, `outlineTitle`, `fileName` -- the file-name stem without .pdf/.dxf/.dwg, page 1 --, `titleBlock` -- the words printed on the sheet that match `normalization.regex`, which a titleBlock rule requires --, `layoutName` -- a CAD layout's name --, `blockAttribute` -- one attribute of a CAD page's title block, named by `matchDocument.attributeTag` (e.g. PLANNR) -- or `sheetText` -- the key-like words printed on the sheet). `normalization` (every flag defaults to false): `caseInsensitive`, `stripWhitespace`, `stripLeadingZeros`, `regex`. `enabled` defaults to true, `priority` to 0, `autoApply` to false. Nothing is linked yet: preview with `createLinkRuleRun`. Requires `link.manage` (owner/admin/publisher). Fires `linkRule.created`.",
        "tags": ["linkRule"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 100,
                    "description": "Rule name, 1-100 chars after trimming."
                  },
                  "enabled": { "type": "boolean" },
                  "priority": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 1000,
                    "description": "0-1000; lower runs first when rules run together."
                  },
                  "matchModel": {
                    "type": "object",
                    "properties": {
                      "field": {
                        "type": "string",
                        "enum": [
                          "tag",
                          "assemblyMark",
                          "storeyName",
                          "name",
                          "property"
                        ]
                      },
                      "property": {
                        "type": "object",
                        "properties": {
                          "set": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 128,
                            "description": "Property set, e.g. Pset_Panel."
                          },
                          "name": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 128,
                            "description": "Property name, e.g. Drawing."
                          }
                        },
                        "required": ["set", "name"],
                        "additionalProperties": false
                      }
                    },
                    "required": ["field"],
                    "additionalProperties": false
                  },
                  "matchDocument": {
                    "type": "object",
                    "properties": {
                      "field": {
                        "type": "string",
                        "enum": [
                          "fileName",
                          "sheetNumber",
                          "outlineTitle",
                          "titleBlock",
                          "layoutName",
                          "blockAttribute",
                          "sheetText"
                        ]
                      },
                      "attributeTag": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 128
                      }
                    },
                    "required": ["field"],
                    "additionalProperties": false
                  },
                  "normalization": {
                    "type": "object",
                    "properties": {
                      "caseInsensitive": { "type": "boolean" },
                      "stripWhitespace": { "type": "boolean" },
                      "stripLeadingZeros": { "type": "boolean" },
                      "regex": {
                        "type": "string",
                        "description": "Regular expression applied to both sides after the other normalisation steps: a value that does not match is ignored, otherwise the match (or its named group `key`) is the value compared, e.g. W-\\d{3} (max 200 chars; no backreferences or nested repeats)."
                      }
                    },
                    "additionalProperties": false
                  },
                  "autoApply": {
                    "description": "Run this rule on every newly published drawing version and after each model publish (default false).",
                    "type": "boolean"
                  }
                },
                "additionalProperties": false,
                "required": ["matchDocument", "matchModel", "name"]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Create an auto-linking rule",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createLinkRuleOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["linkRule.created"],
        "x-fv-mcp-tool": "fv_create_link_rule",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/link-rules/{ruleId}": {
      "get": {
        "operationId": "getLinkRule",
        "summary": "Get an auto-linking rule",
        "description": "Returns one link rule of the project: `name`, `enabled`, `priority`, `matchModel`, `matchDocument` (a sheet field, or on CAD drawings a text on a layer or a title-block field), `normalization` and `autoApply` (a published revision or drawing re-runs it on its own). Requires `link.read` (every role).",
        "tags": ["linkRule"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "ruleId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A lkr identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-None-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "One or more entity tags (`\"4\"`, `W/\"4\"` or `*`). When one matches the current revision the answer is 304 Not Modified with no body."
          }
        ],
        "responses": {
          "200": {
            "description": "Get an auto-linking rule",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/getLinkRuleOutput" }
              }
            }
          },
          "304": {
            "description": "Not Modified: the If-None-Match entity tag still matches.",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_link_rule",
        "x-fv-rate-limit-class": "read"
      },
      "patch": {
        "operationId": "updateLinkRule",
        "summary": "Change an auto-linking rule",
        "description": "Changes a link rule (JSON Merge Patch, C2): `name`, `enabled`, `priority`, `matchModel`, `matchDocument` (with `property`/`attributeTag` for a property/blockAttribute rule), `autoApply`, and `normalization` flag by flag (`regex: null` clears the regex). A `titleBlock` rule must keep a regex (`422`). Bumps `revision` and fires `linkRule.updated` only when something changes. Optional `If-Match`/`expectedRevision` (412 on mismatch). Requires `link.manage` (owner/admin/publisher).",
        "tags": ["linkRule"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "ruleId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A lkr identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "The revision you last read, as an entity tag (`\"4\"`, from the `ETag` header). A stale one answers 412 `precondition.failed` and changes nothing. `*` matches any current revision (not accepted where a precondition is required). MCP/SDK: `expectedRevision`."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 100,
                    "description": "Rule name, 1-100 chars after trimming."
                  },
                  "enabled": { "type": "boolean" },
                  "priority": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 1000,
                    "description": "0-1000; lower runs first when rules run together."
                  },
                  "matchModel": {
                    "type": "object",
                    "properties": {
                      "field": {
                        "type": "string",
                        "enum": [
                          "tag",
                          "assemblyMark",
                          "storeyName",
                          "name",
                          "property"
                        ]
                      },
                      "property": {
                        "type": "object",
                        "properties": {
                          "set": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 128,
                            "description": "Property set, e.g. Pset_Panel."
                          },
                          "name": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 128,
                            "description": "Property name, e.g. Drawing."
                          }
                        },
                        "required": ["set", "name"],
                        "additionalProperties": false
                      }
                    },
                    "required": ["field"],
                    "additionalProperties": false
                  },
                  "matchDocument": {
                    "type": "object",
                    "properties": {
                      "field": {
                        "type": "string",
                        "enum": [
                          "fileName",
                          "sheetNumber",
                          "outlineTitle",
                          "titleBlock",
                          "layoutName",
                          "blockAttribute",
                          "sheetText"
                        ]
                      },
                      "attributeTag": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 128
                      }
                    },
                    "required": ["field"],
                    "additionalProperties": false
                  },
                  "normalization": {
                    "type": "object",
                    "properties": {
                      "caseInsensitive": { "type": "boolean" },
                      "stripWhitespace": { "type": "boolean" },
                      "stripLeadingZeros": { "type": "boolean" },
                      "regex": {
                        "anyOf": [
                          {
                            "type": "string",
                            "description": "Regular expression applied to both sides after the other normalisation steps: a value that does not match is ignored, otherwise the match (or its named group `key`) is the value compared, e.g. W-\\d{3} (max 200 chars; no backreferences or nested repeats)."
                          },
                          { "type": "null" }
                        ]
                      }
                    },
                    "additionalProperties": false
                  },
                  "autoApply": { "type": "boolean" }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Change an auto-linking rule",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/updateLinkRuleOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["linkRule.updated"],
        "x-fv-mcp-tool": "fv_update_link_rule",
        "x-fv-rate-limit-class": "write"
      },
      "delete": {
        "operationId": "deleteLinkRule",
        "summary": "Delete an auto-linking rule",
        "description": "Deletes a link rule permanently. Its past preview runs stay readable. Destructive: MCP calls need the two-phase confirmation, REST supports `?dryRun=true`. Requires `link.manage` (owner/admin/publisher). Fires `linkRule.deleted`.",
        "tags": ["linkRule"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "ruleId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A lkr identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "responses": {
          "204": {
            "description": "No Content",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.manage",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["linkRule.deleted"],
        "x-fv-mcp-tool": "fv_delete_link_rule",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/links": {
      "get": {
        "operationId": "listLinks",
        "summary": "List the model-to-drawing links of a project",
        "description": "Lists a project's links: `source` (element by GlobalId, assembly by mark, or storey, in one model), `target` (document, page, optional region), `origin` (rule/manual/connector), `ruleId`, `confidence`, `status` (`stale`: the element is gone from the published model; kept, never deleted). Filters: `status`, `origin`, `modelId`, `documentId`. Newest first by default. Requires `link.read` (every role). Paginated per C10.",
        "tags": ["links"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "documentId",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Only links to this drawing.",
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "modelId",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Only links from this model.",
              "type": "string",
              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
            }
          },
          {
            "name": "origin",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Only links created by a rule, by hand or by a connector.",
              "type": "string",
              "enum": ["rule", "manual", "connector"]
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: -createdAt | createdAt.",
              "type": "string",
              "enum": ["-createdAt", "createdAt"]
            }
          },
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Only active or only stale links.",
              "type": "string",
              "enum": ["active", "stale"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List the model-to-drawing links of a project",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/listLinksOutput" }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_links",
        "x-fv-rate-limit-class": "read"
      },
      "post": {
        "operationId": "createLink",
        "summary": "Link model elements to a drawing page",
        "description": "Links 1-50 model sources (`sources`: elements by `globalId`, assemblies by `assemblyMark`, storeys by `storeyId`, each with its `modelId`) to one page of an active, published drawing of the project (`target.documentId`, `target.page`), optionally to a `target.region` given as fractions (0-1) of the page. Every source gets its own manual link (`origin: manual`, no `ruleId`/`confidence`), all in one write; a source already linked to exactly that page and region keeps its link and is not linked twice. An unknown model, drawing or page is `404`. Requires `link.manage` (owner/admin/publisher) and an `Idempotency-Key`. Fires `link.created` per new link.",
        "tags": ["link"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "sources": {
                    "minItems": 1,
                    "maxItems": 50,
                    "type": "array",
                    "items": {
                      "oneOf": [
                        {
                          "type": "object",
                          "properties": {
                            "kind": { "type": "string", "const": "element" },
                            "modelId": {
                              "type": "string",
                              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                              "description": "A mdl identifier (TypeID, conventions C5)."
                            },
                            "globalId": { "type": "string", "minLength": 1 }
                          },
                          "required": ["kind", "modelId", "globalId"],
                          "additionalProperties": false
                        },
                        {
                          "type": "object",
                          "properties": {
                            "kind": { "type": "string", "const": "assembly" },
                            "modelId": {
                              "type": "string",
                              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                              "description": "A mdl identifier (TypeID, conventions C5)."
                            },
                            "assemblyMark": { "type": "string", "minLength": 1 }
                          },
                          "required": ["kind", "modelId", "assemblyMark"],
                          "additionalProperties": false
                        },
                        {
                          "type": "object",
                          "properties": {
                            "kind": { "type": "string", "const": "storey" },
                            "modelId": {
                              "type": "string",
                              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                              "description": "A mdl identifier (TypeID, conventions C5)."
                            },
                            "storeyId": { "type": "string", "minLength": 1 }
                          },
                          "required": ["kind", "modelId", "storeyId"],
                          "additionalProperties": false
                        }
                      ]
                    },
                    "description": "What to link: 1-50 sources, each an element (modelId + globalId), an assembly (modelId + assemblyMark) or a storey (modelId + storeyId)."
                  },
                  "target": {
                    "type": "object",
                    "properties": {
                      "documentId": {
                        "type": "string",
                        "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                        "description": "A doc identifier (TypeID, conventions C5)."
                      },
                      "page": {
                        "type": "integer",
                        "exclusiveMinimum": 0,
                        "maximum": 9007199254740991
                      },
                      "region": {
                        "description": "Part of the page as fractions (0-1) of its width and height (D-8: never pixels, so it holds at any zoom); omitted: the whole page.",
                        "type": "object",
                        "properties": {
                          "xPct": {
                            "type": "number",
                            "minimum": 0,
                            "maximum": 1
                          },
                          "yPct": {
                            "type": "number",
                            "minimum": 0,
                            "maximum": 1
                          },
                          "wPct": {
                            "type": "number",
                            "minimum": 0,
                            "maximum": 1
                          },
                          "hPct": {
                            "type": "number",
                            "minimum": 0,
                            "maximum": 1
                          }
                        },
                        "required": ["xPct", "yPct", "wPct", "hPct"],
                        "additionalProperties": false
                      },
                      "cadRegion": {
                        "description": "CAD drawings: part of the page in drawing units ({x, y, w, h} with w, h > 0) and the space it is drawn in (model or paper). Not together with region or textRef.",
                        "type": "object",
                        "properties": {
                          "x": { "type": "number" },
                          "y": { "type": "number" },
                          "w": { "type": "number", "exclusiveMinimum": 0 },
                          "h": { "type": "number", "exclusiveMinimum": 0 },
                          "space": {
                            "type": "string",
                            "enum": ["model", "paper"]
                          }
                        },
                        "required": ["x", "y", "w", "h", "space"],
                        "additionalProperties": false
                      },
                      "textRef": {
                        "description": "CAD drawings: one text of the page -- its index in the page's text layer and its content, which heals the link when the text moves. The text must be a word of that page (422 validation.failed, pointer /target/textRef, otherwise); the index is a hint: when it names another word, the occurrence nearest to it is stored. Not together with region or cadRegion.",
                        "type": "object",
                        "properties": {
                          "textIndex": {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          },
                          "text": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 200
                          }
                        },
                        "required": ["textIndex", "text"],
                        "additionalProperties": false
                      },
                      "layoutName": {
                        "description": "CAD drawings: the page's layout name. When a later version moves that layout to another page, the link follows it.",
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 255
                      }
                    },
                    "required": ["documentId", "page"],
                    "additionalProperties": false,
                    "description": "A page of a published drawing of this project."
                  }
                },
                "additionalProperties": false,
                "required": ["sources", "target"]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Link model elements to a drawing page",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/createLinkOutput" }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["link.created"],
        "x-fv-mcp-tool": "fv_create_link",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/links/{linkId}": {
      "get": {
        "operationId": "getLink",
        "summary": "Get a model-to-drawing link",
        "description": "Returns one link of the project: `source` (element, assembly or storey of a model), `target` (document, page, and a `region` in page fractions -- or on a CAD sheet a `cadRegion` in drawing units or a `textRef` to one text of the page), `origin`, `ruleId`, `confidence`, `key` and `status`. Requires `link.read` (every role).",
        "tags": ["link"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "linkId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^lnk_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A lnk identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-None-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "One or more entity tags (`\"4\"`, `W/\"4\"` or `*`). When one matches the current revision the answer is 304 Not Modified with no body."
          }
        ],
        "responses": {
          "200": {
            "description": "Get a model-to-drawing link",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/getLinkOutput" }
              }
            }
          },
          "304": {
            "description": "Not Modified: the If-None-Match entity tag still matches.",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_link",
        "x-fv-rate-limit-class": "read"
      },
      "patch": {
        "operationId": "updateLink",
        "summary": "Move a link to another drawing page",
        "description": "Changes a link's `target` (document, page and optional `region` as page fractions, or on a CAD drawing a `cadRegion` in drawing units or a `textRef`, plus its `layoutName`). The target must be a page of an active, published drawing of the same project (`422` otherwise). Changing the target of a rule-created link turns it manual (`origin: manual`, `ruleId`/`confidence` cleared): later rule runs leave it alone. Bumps `revision` and fires `link.updated` only when something changes. Optional `If-Match` (412 on mismatch). Requires `link.manage` (owner/admin/publisher).",
        "tags": ["link"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "linkId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^lnk_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A lnk identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "The revision you last read, as an entity tag (`\"4\"`, from the `ETag` header). A stale one answers 412 `precondition.failed` and changes nothing. `*` matches any current revision (not accepted where a precondition is required). MCP/SDK: `expectedRevision`."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "target": {
                    "description": "The new target, replacing the old one: a page of a published drawing of this project.",
                    "type": "object",
                    "properties": {
                      "documentId": {
                        "type": "string",
                        "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                        "description": "A doc identifier (TypeID, conventions C5)."
                      },
                      "page": {
                        "type": "integer",
                        "exclusiveMinimum": 0,
                        "maximum": 9007199254740991
                      },
                      "region": {
                        "description": "Part of the page as fractions (0-1) of its width and height (D-8: never pixels, so it holds at any zoom); omitted: the whole page.",
                        "type": "object",
                        "properties": {
                          "xPct": {
                            "type": "number",
                            "minimum": 0,
                            "maximum": 1
                          },
                          "yPct": {
                            "type": "number",
                            "minimum": 0,
                            "maximum": 1
                          },
                          "wPct": {
                            "type": "number",
                            "minimum": 0,
                            "maximum": 1
                          },
                          "hPct": {
                            "type": "number",
                            "minimum": 0,
                            "maximum": 1
                          }
                        },
                        "required": ["xPct", "yPct", "wPct", "hPct"],
                        "additionalProperties": false
                      },
                      "cadRegion": {
                        "description": "CAD drawings: part of the page in drawing units ({x, y, w, h} with w, h > 0) and the space it is drawn in (model or paper). Not together with region or textRef.",
                        "type": "object",
                        "properties": {
                          "x": { "type": "number" },
                          "y": { "type": "number" },
                          "w": { "type": "number", "exclusiveMinimum": 0 },
                          "h": { "type": "number", "exclusiveMinimum": 0 },
                          "space": {
                            "type": "string",
                            "enum": ["model", "paper"]
                          }
                        },
                        "required": ["x", "y", "w", "h", "space"],
                        "additionalProperties": false
                      },
                      "textRef": {
                        "description": "CAD drawings: one text of the page -- its index in the page's text layer and its content, which heals the link when the text moves. The text must be a word of that page (422 validation.failed, pointer /target/textRef, otherwise); the index is a hint: when it names another word, the occurrence nearest to it is stored. Not together with region or cadRegion.",
                        "type": "object",
                        "properties": {
                          "textIndex": {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          },
                          "text": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 200
                          }
                        },
                        "required": ["textIndex", "text"],
                        "additionalProperties": false
                      },
                      "layoutName": {
                        "description": "CAD drawings: the page's layout name. When a later version moves that layout to another page, the link follows it.",
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 255
                      }
                    },
                    "required": ["documentId", "page"],
                    "additionalProperties": false
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Move a link to another drawing page",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/updateLinkOutput" }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["link.updated"],
        "x-fv-mcp-tool": "fv_update_link",
        "x-fv-rate-limit-class": "write"
      },
      "delete": {
        "operationId": "deleteLink",
        "summary": "Delete a drawing link",
        "description": "Deletes one model-to-drawing link permanently. A rule-created link can come back the next time its rule is applied; to keep a correction, move the link with `updateLink` instead (it then turns manual). Destructive: MCP calls need the two-phase confirmation, REST supports `?dryRun=true`. Requires `link.manage` (owner/admin/publisher). Fires `link.deleted`.",
        "tags": ["link"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "linkId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^lnk_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A lnk identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "responses": {
          "204": {
            "description": "No Content",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "link.manage",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["link.deleted"],
        "x-fv-mcp-tool": "fv_delete_link",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/members": {
      "get": {
        "operationId": "listProjectMembers",
        "summary": "List project members",
        "description": "Lists every `ProjectMember` row for a project, newest first (BR-31: up to 500 rows), with the member's `displayName`/`email` when known. Paginated per conventions C10.",
        "tags": ["projectMembers"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: addedAt | -addedAt.",
              "type": "string",
              "enum": ["addedAt", "-addedAt"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List project members",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/listProjectMembersOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "project.manage_access",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_project_members",
        "x-fv-rate-limit-class": "read"
      },
      "post": {
        "operationId": "addProjectMember",
        "summary": "Add a project member",
        "description": "Adds a member to a project's member list -- by `uid` (from `listMembers`) or by `email`, resolved server-side (`409 project.member_not_found` when nobody in the organisation has that address: invite them with `createInvitation` instead). Required for a publisher/member to reach a `restricted` project (Part B §2.5). Adding an already-listed `uid` is a no-op (C11 natural idempotency). Refused (`403 project.member_limit_reached`) past 500 members (BR-31), and (`409 project.member_not_active`) for someone already removed from the organisation -- re-invite them instead. Adding a project to a guest keeps them a guest (E02-S18). Fires `project.member.added`.",
        "tags": ["projectMember"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "uid": {
                    "description": "The member's uid (from `listMembers`), or a workstation's. Give this or `email`.",
                    "type": "string",
                    "minLength": 1
                  },
                  "email": {
                    "description": "The member's e-mail address, resolved server-side. Give this or `uid`.",
                    "type": "string",
                    "maxLength": 254,
                    "format": "email",
                    "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Add a project member",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/addProjectMemberOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient, project.member_limit_reached",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "project.member_not_active, project.member_not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "project.manage_access",
        "x-fv-side-effect": "write",
        "x-fv-events": ["project.member.added"],
        "x-fv-mcp-tool": "fv_add_project_member",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/members/{uid}": {
      "delete": {
        "operationId": "removeProjectMember",
        "summary": "Remove a project member",
        "description": "Removes `uid` from a project's member list. Removing a `uid` that is not currently listed is a no-op (204-shaped idempotent delete). Fires `project.member.removed`. Removing a guest's last project also removes the guest from the organisation (BR-32) and fires `member.removed` as well.",
        "tags": ["projectMember"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "uid",
            "in": "path",
            "required": true,
            "schema": { "type": "string", "minLength": 1 }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "responses": {
          "204": {
            "description": "No Content",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "project.manage_access",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["project.member.removed", "member.removed"],
        "x-fv-mcp-tool": "fv_remove_project_member",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/models/{modelId}/unpublish": {
      "post": {
        "operationId": "unpublishModel",
        "summary": "Unpublish a model",
        "description": "Takes a model off the floor (BR-20): `Model.published` is cleared, the previously published version becomes `superseded` with `fieldVisible: false` (it stays released, so `publishProjectRevision` on its revision is a rollback), and `Project.fieldVersionIds` drops it, so field devices stop showing the model until a version is published again. Returns the Model without a `published` pointer; a model with nothing published is returned unchanged. An optional `expectedPublishedVersionId` guards against a concurrent publish (BR-17); mismatch is `409 model.publish_conflict`. `409 conflict.state` while the project is archived or deleted. Requires the `model.publish` capability (owner/admin/publisher).",
        "tags": ["model"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "modelId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A mdl identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "expectedPublishedVersionId": {
                    "type": "string",
                    "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A ver identifier (TypeID, conventions C5)."
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Unpublish a model",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/unpublishModelOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state, model.publish_conflict",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "model.publish",
        "x-fv-side-effect": "write",
        "x-fv-events": ["model.unpublished"],
        "x-fv-mcp-tool": "fv_unpublish_model",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/models/{modelId}/versions/{versionId}": {
      "patch": {
        "operationId": "updateModelVersion",
        "summary": "Update a model version's label and notes",
        "description": "Sets or clears a version's `label` (max 40 chars) and `notes` (max 2 000 chars) -- the only fields of a version that change after upload (BR-10). JSON Merge Patch (C2): omit a field to keep it, `null` clears it. An edit sent later than it was made carries `editedAt`; it is dropped when a newer edit is already stored (last-write-wins). `409 conflict.state` while the project is archived or deleted. Optional `If-Match`/`expectedRevision` (412 on mismatch). Requires `model.upload` (owner/admin/publisher).",
        "tags": ["modelVersion"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "modelId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A mdl identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "versionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ver identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "The revision you last read, as an entity tag (`\"4\"`, from the `ETag` header). A stale one answers 412 `precondition.failed` and changes nothing. `*` matches any current revision (not accepted where a precondition is required). MCP/SDK: `expectedRevision`."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "label": {
                    "anyOf": [
                      {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 40,
                        "description": "Short version name, e.g. \"Roof fix\" (1-40 chars after trimming, BR-10)."
                      },
                      { "type": "null" }
                    ]
                  },
                  "notes": {
                    "anyOf": [
                      {
                        "type": "string",
                        "maxLength": 2000,
                        "description": "Free-form notes for the crew (max 2000 chars, BR-10)."
                      },
                      { "type": "null" }
                    ]
                  },
                  "editedAt": {
                    "description": "When the edit was made (RFC 3339), for an edit sent later than it was made: an edit older than the one already stored is dropped (last-write-wins). Omit for a live edit.",
                    "type": "string",
                    "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))$"
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Update a model version's label and notes",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/updateModelVersionOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "model.upload",
        "x-fv-side-effect": "write",
        "x-fv-events": ["model.version.updated"],
        "x-fv-mcp-tool": "fv_update_model_version",
        "x-fv-rate-limit-class": "write"
      },
      "delete": {
        "operationId": "deleteModelVersion",
        "summary": "Delete a never-published model version",
        "description": "Deletes a version that was never published (`cancelled`, `failed`, or a `ready`/`archived` draft). The version disappears at once; its stored source file and processed artefacts are removed after a 24-hour grace period (`objectsRemovedAfter`). `409 conflict.state` for a version that was ever published (BR-21), one still uploading or processing, or while the project is archived or deleted. Destructive: MCP calls need the two-phase confirmation, REST supports `?dryRun=true`. Requires `model.delete` (owner/admin/publisher).",
        "tags": ["modelVersion"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "modelId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A mdl identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "versionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ver identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "responses": {
          "204": {
            "description": "No Content",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "model.delete",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["model.version.deleted"],
        "x-fv-mcp-tool": "fv_delete_model_version",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/models/{modelId}/versions/{versionId}/archive": {
      "post": {
        "operationId": "archiveModelVersion",
        "summary": "Archive a model version",
        "description": "Archives a `ready` version that is not currently published (§3.4; BR-21: a published version cannot be archived). Nothing is deleted; `restoreModelVersion` brings it back through the pipeline. Idempotent on an archived version. `409 conflict.state` for the published version, a version that is not `ready`, or while the project is archived or deleted. Requires `model.upload` (owner/admin/publisher).",
        "tags": ["modelVersion"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "modelId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A mdl identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "versionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ver identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Archive a model version",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/archiveModelVersionOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "model.upload",
        "x-fv-side-effect": "write",
        "x-fv-events": ["model.version.archived"],
        "x-fv-mcp-tool": "fv_archive_model_version",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/models/{modelId}/versions/{versionId}/cancel": {
      "post": {
        "operationId": "cancelModelVersionUpload",
        "summary": "Cancel a model version upload",
        "description": "Cancels a version that is still `uploading` (AC-2): sets `status: 'cancelled'`, deletes the GCS object, and fires `model.version.cancelled`. Destructive -- automatically audited. `409 conflict.state` for a version that is not `uploading` (already finished, already cancelled, or never existed as `uploading`). Requires the `model.upload` capability (owner/admin/publisher).",
        "tags": ["modelVersionUpload"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "modelId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A mdl identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "versionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ver identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Cancel a model version upload",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/cancelModelVersionUploadOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "model.upload",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["model.version.cancelled"],
        "x-fv-mcp-tool": "fv_cancel_model_version_upload",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/models/{modelId}/versions/{versionId}/complete": {
      "post": {
        "operationId": "completeModelVersionUpload",
        "summary": "Confirm a model version upload has finished",
        "description": "Confirms the client has finished PUTting the file and asks the server to verify it: reads the object's real size from storage and, if it matches the size declared at `createProjectRevision` time, transitions `status: 'uploading' -> 'uploaded'` and fires `model.version.uploaded`. Idempotent -- calling this again once already `uploaded` is a no-op. `409 conflict.state` if the object does not exist yet or the size does not match, or if the version is not `uploading`/`uploaded`. Requires the `model.upload` capability (owner/admin/publisher).",
        "tags": ["modelVersionUpload"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "modelId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A mdl identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "versionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ver identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Confirm a model version upload has finished",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/completeModelVersionUploadOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "model.upload",
        "x-fv-side-effect": "write",
        "x-fv-events": ["model.version.uploaded"],
        "x-fv-mcp-tool": "fv_complete_model_version_upload",
        "x-fv-rate-limit-class": "write",
        "x-fv-anonymous-access": true
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/models/{modelId}/versions/{versionId}/reprocess": {
      "post": {
        "operationId": "reprocessModelVersion",
        "summary": "Retry a failed model version, or reprocess it on a newer pipeline",
        "description": "Retries a `failed` version whose `failure.retryable` is `true` (AC-3): sets `status: 'uploaded'`, increments `reprocessing.attempt`, clears `failure`, fires `model.version.processing_requested`, and re-dispatches processing through the same path a fresh upload finalize uses. FV-162: on a `ready` version whose `activeArtifactSet.pipelineVersion` is older than the platform's pipeline, it starts a run on the newer pipeline BESIDE the active artefact set: `status`, `publication` and `fieldVisible` do not change, only `reprocessing` (`reason: 'pipeline_upgrade'`, `state`) does, and the new set replaces the active one in one write when it is complete. `409 conflict.state` if the version is neither, is `failed` but `failure.retryable` is `false` (AC-4) -- a deterministic failure needs a new upload, not a retry -- or is already being reprocessed. Requires the `model.upload` capability (owner/admin/publisher).",
        "tags": ["modelVersion"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "modelId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A mdl identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "versionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ver identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Retry a failed model version, or reprocess it on a newer pipeline",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/reprocessModelVersionOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "model.upload",
        "x-fv-side-effect": "write",
        "x-fv-events": ["model.version.processingRequested"],
        "x-fv-mcp-tool": "fv_reprocess_model_version",
        "x-fv-rate-limit-class": "heavy"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/models/{modelId}/versions/{versionId}/restore": {
      "post": {
        "operationId": "restoreModelVersion",
        "summary": "Restore an archived model version",
        "description": "Restores an archived version (§3.4): `status` becomes `uploaded` and the version is processed again from its stored source file, ending `ready`. `409 conflict.state` when the version is not archived, its source file is no longer stored, or the project is archived or deleted; `409 model.too_many_in_flight` when the model already has 3 versions in flight (BR-13). Needs an `Idempotency-Key`. Requires `model.upload` (owner/admin/publisher).",
        "tags": ["modelVersion"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "modelId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A mdl identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "versionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ver identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Restore an archived model version",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/restoreModelVersionOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state, model.too_many_in_flight",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "model.upload",
        "x-fv-side-effect": "write",
        "x-fv-events": ["model.version.restored"],
        "x-fv-mcp-tool": "fv_restore_model_version",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/models/{modelId}/versions/{versionId}/source": {
      "get": {
        "operationId": "getModelVersionSource",
        "summary": "Download a model version's original file",
        "description": "Returns a short-lived (15 min) signed URL to the original IFC file of a model version, which saves it under its original name, with its size, content type and SHA-256. The file itself never passes through the API. Needs `model.download_source` (owner/admin/publisher, or a platform admin's support grant); a draft also needs `model.read_unpublished`. A version whose upload never finished, or whose source was removed (a failed version's source is kept 14 days), is `resource.not_found`. Every download is audited.",
        "tags": ["modelVersionSource"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "modelId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A mdl identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "versionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ver identifier (TypeID, conventions C5)."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Download a model version's original file",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getModelVersionSourceOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "model.download_source",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_model_version_source",
        "x-fv-rate-limit-class": "heavy"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/models/{modelId}/versions/{versionId}/wait": {
      "get": {
        "operationId": "waitModelVersion",
        "summary": "Wait for a model version to finish processing",
        "description": "Long-polls until the model version's `status` reaches a terminal processing outcome (`ready` or `failed`) or the timeout elapses (C12, <= 25s). Use after `createProjectRevision`/upload finalize instead of tight-polling `getProjectRevision`.",
        "tags": ["modelVersion"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "modelId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A mdl identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "versionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ver identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "timeoutSeconds",
            "in": "query",
            "required": false,
            "schema": { "type": "integer", "minimum": 1, "maximum": 25 }
          }
        ],
        "responses": {
          "200": {
            "description": "Wait for a model version to finish processing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/waitModelVersionOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "model.read_unpublished",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_wait_for_model_version",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/restore": {
      "post": {
        "operationId": "restoreProject",
        "summary": "Restore an archived or deleted project",
        "description": "Restores a project (BR-3): an archived project becomes `active` again; a deleted project returns to the status it had before it was deleted (`active` or `archived`) -- only within its 30-day window (`purgeAfter`) and before the purge has started, otherwise `409 conflict.state`. Idempotent on an active project. Requires `project.archive` (owner/admin).",
        "tags": ["project"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Restore an archived or deleted project",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/restoreProjectOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "project.archive",
        "x-fv-side-effect": "write",
        "x-fv-events": ["project.restored"],
        "x-fv-mcp-tool": "fv_restore_project",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/revisions": {
      "get": {
        "operationId": "listProjectRevisions",
        "summary": "List a project's revisions",
        "description": "Lists the revisions of the project's 3D model, newest first. A project has one 3D model; each new file uploaded to it is a new revision (1, 2, 3...). Each row carries `number`, `status`, `publication`, `current` (the revision the field sees now) and, once published, `publishedAt`/`publishedBy`. Empty for a project with no revision yet. Requires the `model.read` capability (every org role).",
        "tags": ["projectRevisions"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: -number.",
              "type": "string",
              "enum": ["-number"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List a project's revisions",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/listProjectRevisionsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "model.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_project_revisions",
        "x-fv-rate-limit-class": "read"
      },
      "post": {
        "operationId": "createProjectRevision",
        "summary": "Start a new revision of a project's 3D model",
        "description": "Starts a new revision of the project's 3D model and its resumable upload session (conventions C13). `fileName` must end `.ifc` or `.ifczip`; `sizeBytes` must fit the plan's file-size limit and the organisation's storage (`entitlement.limit_reached` otherwise). The revision `number` is the next one in the project. The response's `upload` ticket is where the file bytes go (PUT, never through this API); then call `completeModelVersionUpload` with the revision's `modelId` and `id`. Instead of uploading, `source: {kind:'url', url, sha256?}` imports the file from a public HTTPS URL (FV-81, BR-24): no `upload` ticket and no `sizeBytes`; the server downloads it and the revision moves on to `processing` by itself, or ends `failed` with an `import.*` code. A URL that is not HTTPS or does not resolve to a public address answers `422 import.url_not_allowed`. `publishOnReady: true` publishes it as soon as it is ready. Requires the `model.upload` capability (owner/admin/publisher). Fires `model.version.created` (and `model.created` the first time on a project created before FV-384).",
        "tags": ["projectRevision"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "description": "The file's size in bytes (BR-24). Required for an upload; leave out with source.kind url.",
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824
                  },
                  "contentType": {
                    "type": "string",
                    "minLength": 1,
                    "description": "The source file's MIME type, e.g. application/octet-stream."
                  },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  },
                  "id": {
                    "description": "Optional client-generated id (C11). Omit to let the server generate one.",
                    "type": "string",
                    "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
                  },
                  "publishOnReady": {
                    "description": "Publish this revision automatically as soon as processing marks it ready (FV-383). Default false: publish with publishProjectRevision.",
                    "type": "boolean"
                  },
                  "source": {
                    "type": "object",
                    "properties": {
                      "kind": { "type": "string", "const": "url" },
                      "url": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 2048,
                        "description": "Where to download the file: a public HTTPS URL (at most 2,048 characters, no user:password@), e.g. a signed CDN or cloud-storage link. It must stay valid for 25 minutes. Only its scheme, host and path are stored; the query string is not."
                      },
                      "sha256": {
                        "description": "Optional SHA-256 of the file (64 hex). A download that does not match fails with import.checksum_mismatch.",
                        "type": "string",
                        "pattern": "^[0-9a-f]{64}$"
                      }
                    },
                    "required": ["kind", "url"],
                    "additionalProperties": false,
                    "description": "Import the file from a URL instead of uploading it: the server downloads it and the response carries no `upload` ticket. Leave out sizeBytes and the top-level sha256."
                  }
                },
                "additionalProperties": false,
                "required": ["contentType", "fileName"]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Start a new revision of a project's 3D model",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createProjectRevisionOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "entitlement.limit_reached, permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "model.duplicate_source, model.too_many_in_flight",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "import.url_not_allowed, validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "503": {
            "description": "dependency.unavailable",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "model.upload",
        "x-fv-side-effect": "write",
        "x-fv-events": ["model.version.created", "model.created"],
        "x-fv-mcp-tool": "fv_create_project_revision",
        "x-fv-rate-limit-class": "heavy"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/revisions/{number}": {
      "get": {
        "operationId": "getProjectRevision",
        "summary": "Get one revision of a project",
        "description": "Reads one revision of the project's 3D model by its `number`: status, processing `progress`, `failure`, `publication`, `current`, and `publishedAt`/`publishedBy` once published. `404 resource.not_found` for a number the project has no revision for. Requires the `model.read` capability (every org role).",
        "tags": ["projectRevision"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "number",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991,
              "description": "The revision number within the project."
            }
          },
          {
            "name": "If-None-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "One or more entity tags (`\"4\"`, `W/\"4\"` or `*`). When one matches the current revision the answer is 304 Not Modified with no body."
          }
        ],
        "responses": {
          "200": {
            "description": "Get one revision of a project",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getProjectRevisionOutput"
                }
              }
            }
          },
          "304": {
            "description": "Not Modified: the If-None-Match entity tag still matches.",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "model.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_project_revision",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/revisions/{number}/make-current": {
      "post": {
        "operationId": "setCurrentProjectRevision",
        "summary": "Make an earlier revision of a project current again",
        "description": "Makes a previously published revision the project's current revision again (the field sees it from now on). `409 conflict.state` for a revision that was never published (use `publishProjectRevision`) or that is archived (restore it first). Requires the `model.publish` capability (owner/admin/publisher). Fires `model.version.published`.",
        "tags": ["currentProjectRevision"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "number",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991,
              "description": "The revision number within the project."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Make an earlier revision of a project current again",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/setCurrentProjectRevisionOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "model.publish",
        "x-fv-side-effect": "write",
        "x-fv-events": ["model.version.published"],
        "x-fv-mcp-tool": "fv_set_current_project_revision",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/revisions/{number}/publish": {
      "post": {
        "operationId": "publishProjectRevision",
        "summary": "Publish a revision of a project",
        "description": "Publishes a `ready` revision: it becomes the project's current revision, the one the field sees, and the previous current revision is superseded. `409 conflict.state` when the revision is not ready; `409 model.publish_requires_acknowledgement` for blocking warnings unless `acknowledgeWarnings: true`; `409 model.publish_conflict` when `expectedCurrentRevision` no longer matches. Requires the `model.publish` capability (owner/admin/publisher). Fires `model.version.published`.",
        "tags": ["projectRevision"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "number",
            "in": "path",
            "required": true,
            "schema": {
              "type": "integer",
              "exclusiveMinimum": 0,
              "maximum": 9007199254740991,
              "description": "The revision number within the project."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "note": { "type": "string", "maxLength": 500 },
                  "acknowledgeWarnings": { "type": "boolean" },
                  "expectedCurrentRevision": {
                    "description": "Optimistic concurrency: the revision number you expect to be current now (null: none). A mismatch is model.publish_conflict.",
                    "anyOf": [
                      {
                        "type": "integer",
                        "exclusiveMinimum": 0,
                        "maximum": 9007199254740991
                      },
                      { "type": "null" }
                    ]
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Publish a revision of a project",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/publishProjectRevisionOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state, model.publish_conflict, model.publish_requires_acknowledgement",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "model.publish",
        "x-fv-side-effect": "write",
        "x-fv-events": ["model.version.published"],
        "x-fv-mcp-tool": "fv_publish_project_revision",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/scene": {
      "get": {
        "operationId": "getProjectScene",
        "summary": "Get a project's federated 3D scene",
        "description": "Resolves a project's federated scene: at most 4 models (the federation cap, `truncated: true` when more exist), each at its currently PUBLISHED version -- never a draft, for any role (BR-1/BR-2). Each model's `artifacts` are short-lived (15 min) signed URLs for its `manifest.json`/`geometry.frag` (plus `spatial-tree.json.gz`/`elements.json.gz` when the version has them), ready to open in the 3D viewer. `empty: true` when the project has no published model yet -- render the viewer's empty state, never an error.",
        "tags": ["projectScene"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Get a project's federated 3D scene",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getProjectSceneOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "project.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_project_scene",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/shared-view-order": {
      "patch": {
        "operationId": "updateSharedViewOrder",
        "summary": "Reorder the project's shared views",
        "description": "Sets the order of a project's shared views: send their ids first to last. Each view whose place changed gets `order` = its index, in one write. A view not listed keeps its place value. An id that is not a shared view of this project is `404 resource.not_found` and nothing changes. Requires `view.manage`. Fires `savedView.updated` for each moved view.",
        "tags": ["sharedViewOrder"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "viewIds": {
                    "minItems": 1,
                    "maxItems": 100,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A vw identifier (TypeID, conventions C5)."
                    },
                    "description": "The project's shared views, first to last (1-100 distinct vw_ ids)."
                  }
                },
                "additionalProperties": false,
                "required": ["viewIds"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Reorder the project's shared views",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/updateSharedViewOrderOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "view.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["savedView.updated"],
        "x-fv-mcp-tool": "fv_update_shared_view_order",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/spatial-tree": {
      "get": {
        "operationId": "getSpatialTree",
        "summary": "Get a project's storeys and zones",
        "description": "Returns the spatial structure of the project's current revision: `nodes` (project, site, building, storeys, spaces -- depth first, each with its `parentId`), `levels` (every storey by ascending elevation with its element count, as the viewer's Storeys panel lists them) and `zones` (with the spaces they group). All three empty when the project has no published revision yet.",
        "tags": ["spatialTree"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Get a project's storeys and zones",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getSpatialTreeOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "project.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_spatial_tree",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/views": {
      "get": {
        "operationId": "listViews",
        "summary": "List saved views in a project",
        "description": "Lists the saved views the caller may see in a project: every `shared` view (the project's views, `isProjectDefault: true` on its default, `order` their place in the list) and the caller's own `personal` views. Someone else's personal view is never returned. Each row is a full `SavedView` with a signed `thumbnailUrl` once its image is uploaded. Sort `createdAt`/`-createdAt`/`name` (default `-createdAt`). Paginated per C10. Requires `view.read`.",
        "tags": ["views"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: createdAt | -createdAt | name.",
              "type": "string",
              "enum": ["createdAt", "-createdAt", "name"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List saved views in a project",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/listViewsOutput" }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "view.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_views",
        "x-fv-rate-limit-class": "read"
      },
      "post": {
        "operationId": "createSavedView",
        "summary": "Save a view",
        "description": "Saves a named view of a project: a full `ViewState` (camera, visibility, section plane, layer overrides, selection, theme) captured by the client, plus the scene `originOffsetMm` it was captured against. The view is `personal` -- only its owner sees it -- unless `scope: 'shared'` makes it a project view everyone in the project sees; `isProjectDefault: true` (shared only) also makes it the project default, clearing the previous one. Both need `view.manage` (`403 permission.denied` otherwise). Declaring `thumbnail: {contentType, sizeBytes}` (image/webp or image/png, max 1 MB) returns an `upload` ticket -- PUT the image directly to `upload.url`, never through this API (C13). A client-generated `id` makes a retry idempotent. Requires `view.create`. Fires `savedView.created`.",
        "tags": ["savedView"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "id": {
                    "description": "Optional client-generated vw_ id (C11, offline outbox). Omit to let the server generate one.",
                    "type": "string",
                    "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
                  },
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 80,
                    "description": "The view's name, 1-80 characters."
                  },
                  "description": {
                    "type": "string",
                    "maxLength": 280,
                    "description": "Optional note, max 280 characters."
                  },
                  "scope": {
                    "description": "personal (only you see it, the default) or shared (everyone in the project; needs view.manage).",
                    "type": "string",
                    "enum": ["personal", "shared"]
                  },
                  "isProjectDefault": {
                    "description": "true: the project's default view -- the one people land on when they open the project (scope shared; needs view.manage). Clears the previous default in the same write.",
                    "type": "boolean"
                  },
                  "state": {
                    "type": "object",
                    "properties": {
                      "schemaVersion": { "type": "number", "const": 1 },
                      "camera": {
                        "type": "object",
                        "properties": {
                          "position": {
                            "type": "object",
                            "properties": {
                              "x": {
                                "type": "number",
                                "minimum": -100000,
                                "maximum": 100000
                              },
                              "y": {
                                "type": "number",
                                "minimum": -100000,
                                "maximum": 100000
                              },
                              "z": {
                                "type": "number",
                                "minimum": -100000,
                                "maximum": 100000
                              }
                            },
                            "required": ["x", "y", "z"],
                            "additionalProperties": false
                          },
                          "target": {
                            "type": "object",
                            "properties": {
                              "x": {
                                "type": "number",
                                "minimum": -100000,
                                "maximum": 100000
                              },
                              "y": {
                                "type": "number",
                                "minimum": -100000,
                                "maximum": 100000
                              },
                              "z": {
                                "type": "number",
                                "minimum": -100000,
                                "maximum": 100000
                              }
                            },
                            "required": ["x", "y", "z"],
                            "additionalProperties": false
                          },
                          "up": { "type": "string", "const": "z" },
                          "fovDeg": {
                            "type": "number",
                            "minimum": 20,
                            "maximum": 90
                          },
                          "orthoHeightM": {
                            "type": "number",
                            "exclusiveMinimum": 0
                          }
                        },
                        "required": ["position", "target", "up"],
                        "additionalProperties": false
                      },
                      "visibility": {
                        "type": "object",
                        "properties": {
                          "hiddenRefs": {
                            "maxItems": 5000,
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "globalId": {
                                  "type": "string",
                                  "minLength": 1
                                },
                                "modelId": {
                                  "type": "string",
                                  "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                  "description": "A mdl identifier (TypeID, conventions C5)."
                                }
                              },
                              "required": ["globalId"],
                              "additionalProperties": false
                            }
                          },
                          "isolateRefs": {
                            "maxItems": 5000,
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "globalId": {
                                  "type": "string",
                                  "minLength": 1
                                },
                                "modelId": {
                                  "type": "string",
                                  "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                  "description": "A mdl identifier (TypeID, conventions C5)."
                                }
                              },
                              "required": ["globalId"],
                              "additionalProperties": false
                            }
                          },
                          "ghost": { "type": "boolean" },
                          "isolateSource": {
                            "type": "string",
                            "const": "storey"
                          }
                        },
                        "required": ["hiddenRefs", "isolateRefs", "ghost"],
                        "additionalProperties": false
                      },
                      "section": {
                        "type": "object",
                        "properties": {
                          "axis": { "type": "string", "enum": ["x", "y", "z"] },
                          "offsetMm": { "type": "number" },
                          "flipped": { "type": "boolean" }
                        },
                        "required": ["axis", "offsetMm", "flipped"],
                        "additionalProperties": false
                      },
                      "layerSetRef": {
                        "type": "object",
                        "properties": {
                          "layerSetId": {
                            "type": "string",
                            "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                            "description": "A lys identifier (TypeID, conventions C5)."
                          },
                          "overrides": {
                            "type": "object",
                            "propertyNames": { "type": "string" },
                            "additionalProperties": { "type": "boolean" }
                          }
                        },
                        "required": ["layerSetId", "overrides"],
                        "additionalProperties": false
                      },
                      "selection": {
                        "maxItems": 50,
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "globalId": { "type": "string", "minLength": 1 },
                            "modelId": {
                              "type": "string",
                              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                              "description": "A mdl identifier (TypeID, conventions C5)."
                            }
                          },
                          "required": ["globalId"],
                          "additionalProperties": false
                        }
                      },
                      "activeTool": { "type": "string", "minLength": 1 },
                      "theme": {
                        "type": "string",
                        "enum": ["sunlight", "dim"]
                      },
                      "storeyFocusId": { "type": "string" },
                      "splitView": {
                        "type": "object",
                        "properties": {
                          "active": { "type": "boolean" },
                          "ratio": {
                            "type": "number",
                            "minimum": 0.1,
                            "maximum": 0.9
                          },
                          "primaryPane": {
                            "type": "string",
                            "enum": ["model", "document"]
                          },
                          "document": {
                            "type": "object",
                            "properties": {
                              "documentId": {
                                "type": "string",
                                "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                "description": "A doc identifier (TypeID, conventions C5)."
                              },
                              "page": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 9007199254740991
                              },
                              "zoom": {
                                "type": "number",
                                "exclusiveMinimum": 0
                              },
                              "panPct": {
                                "type": "object",
                                "properties": {
                                  "x": { "type": "number" },
                                  "y": { "type": "number" }
                                },
                                "required": ["x", "y"],
                                "additionalProperties": false
                              },
                              "cad": {
                                "description": "FV-497: a CAD sheet's view -- the drawing point at the pane's centre (drawing units) and the scale in CSS px per drawing unit.",
                                "type": "object",
                                "properties": {
                                  "center": {
                                    "type": "object",
                                    "properties": {
                                      "x": { "type": "number" },
                                      "y": { "type": "number" }
                                    },
                                    "required": ["x", "y"],
                                    "additionalProperties": false
                                  },
                                  "scale": {
                                    "type": "number",
                                    "exclusiveMinimum": 0
                                  }
                                },
                                "required": ["center", "scale"],
                                "additionalProperties": false
                              }
                            },
                            "required": ["documentId", "page"],
                            "additionalProperties": false
                          },
                          "fullscreenPane": {
                            "type": "string",
                            "enum": ["model", "document"]
                          }
                        },
                        "required": ["active", "ratio", "primaryPane"],
                        "additionalProperties": false
                      },
                      "filter": {
                        "description": "FV-473: the filter terms behind the hidden and isolate sets, and the built-in layers (panels, loose parts) that are off.",
                        "type": "object",
                        "properties": {
                          "terms": {
                            "maxItems": 20,
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "mode": {
                                  "type": "string",
                                  "enum": ["only", "hide"]
                                },
                                "key": {
                                  "type": "string",
                                  "enum": [
                                    "search",
                                    "class",
                                    "type",
                                    "material",
                                    "layer",
                                    "panel",
                                    "storey",
                                    "property",
                                    "elements"
                                  ]
                                },
                                "value": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 500
                                },
                                "name": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 200
                                },
                                "set": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 200
                                }
                              },
                              "required": ["mode", "key", "value"],
                              "additionalProperties": false
                            }
                          },
                          "builtInOff": {
                            "maxItems": 2,
                            "type": "array",
                            "items": {
                              "type": "string",
                              "enum": ["panels", "loose"]
                            }
                          }
                        },
                        "required": ["terms"],
                        "additionalProperties": false
                      }
                    },
                    "required": [
                      "schemaVersion",
                      "camera",
                      "visibility",
                      "selection",
                      "activeTool",
                      "theme"
                    ],
                    "additionalProperties": false,
                    "description": "A full ViewState v1 (E05 §4.2): camera, visibility, section, layerSetRef, selection, activeTool, theme, storeyFocusId, splitView, filter."
                  },
                  "originOffsetMm": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3,
                    "description": "The scene's origin offset in millimetres the state's camera and section are relative to."
                  },
                  "thumbnail": {
                    "description": "Declare a thumbnail to get an upload ticket for it; omit for a view without a picture.",
                    "type": "object",
                    "properties": {
                      "contentType": {
                        "type": "string",
                        "enum": ["image/webp", "image/png"],
                        "description": "image/webp or image/png."
                      },
                      "sizeBytes": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 1048576,
                        "description": "The image size in bytes (max 1048576)."
                      }
                    },
                    "required": ["contentType", "sizeBytes"],
                    "additionalProperties": false
                  }
                },
                "additionalProperties": false,
                "required": ["name", "state"]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Save a view",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createSavedViewOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.already_exists, conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "view.create",
        "x-fv-side-effect": "write",
        "x-fv-events": ["savedView.created"],
        "x-fv-mcp-tool": "fv_create_saved_view",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/projects/{projectId}/views/{viewId}": {
      "get": {
        "operationId": "getView",
        "summary": "Get a saved view",
        "description": "Returns one saved view: its name, scope, full `ViewState` and a signed `thumbnailUrl` once the image is uploaded. Someone else's personal view is `404 resource.not_found`, the same as a missing one. Requires `view.read`.",
        "tags": ["view"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "viewId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A vw identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-None-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "One or more entity tags (`\"4\"`, `W/\"4\"` or `*`). When one matches the current revision the answer is 304 Not Modified with no body."
          }
        ],
        "responses": {
          "200": {
            "description": "Get a saved view",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/getViewOutput" }
              }
            }
          },
          "304": {
            "description": "Not Modified: the If-None-Match entity tag still matches.",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "view.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_view",
        "x-fv-rate-limit-class": "read"
      },
      "patch": {
        "operationId": "updateSavedView",
        "summary": "Rename, share or set a saved view as the project default",
        "description": "Renames a saved view or changes its note (`description`, `null` clears it). `scope: 'shared'` promotes your personal view to the project: every project member, guest and workstation then sees it. `isProjectDefault: true` makes a shared view the project default -- the view people land on when they open the project -- and clears the previous default in the same write; `false` clears it. Only the owner may change a personal view; sharing, the default and any change to a shared view need `view.manage` (`403 permission.denied` otherwise). A personal view cannot be the default (`409 conflict.state`). The captured view state cannot change -- save a new view instead. Requires `view.create`. Fires `savedView.updated`.",
        "tags": ["savedView"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "viewId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A vw identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "The revision you last read, as an entity tag (`\"4\"`, from the `ETag` header). A stale one answers 412 `precondition.failed` and changes nothing. `*` matches any current revision (not accepted where a precondition is required). MCP/SDK: `expectedRevision`."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 80,
                    "description": "The view's name, 1-80 characters."
                  },
                  "description": {
                    "description": "New note (max 280 chars), or null to remove it.",
                    "anyOf": [
                      {
                        "type": "string",
                        "maxLength": 280,
                        "description": "Optional note, max 280 characters."
                      },
                      { "type": "null" }
                    ]
                  },
                  "scope": {
                    "description": "shared: promote your personal view to the project, so everyone in it sees it. Needs view.manage. A shared view cannot go back to personal.",
                    "type": "string",
                    "const": "shared"
                  },
                  "isProjectDefault": {
                    "description": "true: make this shared view the project default (the previous default is cleared in the same write); false: the project has no default any more. Needs view.manage.",
                    "type": "boolean"
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Rename, share or set a saved view as the project default",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/updateSavedViewOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "view.create",
        "x-fv-side-effect": "write",
        "x-fv-events": ["savedView.updated"],
        "x-fv-mcp-tool": "fv_update_saved_view",
        "x-fv-rate-limit-class": "write"
      },
      "delete": {
        "operationId": "deleteSavedView",
        "summary": "Delete a saved view",
        "description": "Permanently deletes a saved view. Only its owner may delete a personal view; anyone else gets `403 permission.denied`. Fires `savedView.deleted`.",
        "tags": ["savedView"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "viewId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A vw identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "responses": {
          "204": {
            "description": "No Content",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "view.create",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["savedView.deleted"],
        "x-fv-mcp-tool": "fv_delete_saved_view",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/research-consent": {
      "get": {
        "operationId": "getResearchConsent",
        "summary": "Get the research copy answer of an organisation",
        "description": "Returns the research consent answer of a tryout, or of the tryout an organisation was (Settings -> Privacy): its status, when it was given or withdrawn, and the privacy notice version. An organisation that never was a tryout (or never answered) reads `not_asked`; a tryout past its 7 days is `410 tryout.expired`.",
        "tags": ["researchConsent"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Get the research copy answer of an organisation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getResearchConsentOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "410": {
            "description": "tryout.expired",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "org.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_research_consent",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/sample-project": {
      "post": {
        "operationId": "provisionSampleProject",
        "summary": "Provision the organisation's sample project",
        "description": "Creates the organisation's sample project (`isSample: true`, named \"Sample project\") with one model whose version is a server-side copy of an already-processed reference model, published straight away -- no upload, no processing wait. The platform calls this automatically when an organisation is created. Idempotent: while the sample project exists, the existing one is returned. After it was deleted, a new one is created. Returns `503 onboarding.sample_project_unavailable` when this environment has no reference model. Requires the `project.create` capability (owner/admin/publisher).",
        "tags": ["sampleProject"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Provision the organisation's sample project",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/provisionSampleProjectOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "503": {
            "description": "onboarding.sample_project_unavailable",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "project.create",
        "x-fv-side-effect": "write",
        "x-fv-events": [
          "sampleProject.provisioned",
          "project.created",
          "model.created",
          "model.version.created",
          "model.version.published"
        ],
        "x-fv-mcp-tool": "fv_provision_sample_project",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/support-access": {
      "get": {
        "operationId": "listSupportAccess",
        "summary": "List support access to an organisation",
        "description": "Lists the support grants Field-Viewer's platform admins opened on the organisation, newest first: who, why, when it started, when it ends or ended, and whether it is `active`, `ended` or `expired`. Owner/admin only (`audit.read`); another organisation's id answers `404`. The full start/end history is also in the activity log.",
        "tags": ["supportAccess"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: -startedAt.",
              "type": "string",
              "enum": ["-startedAt"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List support access to an organisation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/listSupportAccessOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "audit.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_support_access",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/support-access-requests": {
      "get": {
        "operationId": "listSupportAccessRequests",
        "summary": "List support access requests to an organisation",
        "description": "Lists the requests Field-Viewer's platform admins made for support access to the organisation, newest first: who, why, for how long, and whether the request is `pending`, `approved`, `denied`, `used` or `expired`. Owner/admin only (`audit.read`); another organisation's id answers `404`. Only an owner can approve or deny, in the web app.",
        "tags": ["supportAccessRequests"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: -requestedAt.",
              "type": "string",
              "enum": ["-requestedAt"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List support access requests to an organisation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/listSupportAccessRequestsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "audit.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_support_access_requests",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/support-access-requests/{uid}/approve": {
      "post": {
        "operationId": "approveSupportAccessRequest",
        "summary": "Approve a support access request",
        "description": "Approves a platform admin's pending support access request: that admin may then start one read-only support grant, within the request's 24 hours. Owner only (`support_access.approve`), signed in to the web app: not available over MCP or to API tokens (interactive consent). `409 conflict.state` when the request was already decided or used, or lapsed; `404` when there is none. Fires `supportAccess.approved`, recorded in the organisation's audit log and the platform log.",
        "tags": ["supportAccessRequest"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "uid",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 128,
              "description": "The platform admin whose request it is (the request's uid)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Approve a support access request",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/approveSupportAccessRequestOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "support_access.approve",
        "x-fv-side-effect": "write",
        "x-fv-events": ["supportAccess.approved"],
        "x-fv-mcp-tool": "fv_approve_support_access_request",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/support-access-requests/{uid}/deny": {
      "post": {
        "operationId": "denySupportAccessRequest",
        "summary": "Deny a support access request",
        "description": "Denies a platform admin's pending support access request: no grant can start from it. Owner only (`support_access.approve`), signed in to the web app: not available over MCP or to API tokens (interactive consent). `409 conflict.state` when the request was already decided or used, or lapsed; `404` when there is none. Fires `supportAccess.refused`, recorded in the organisation's audit log and the platform log.",
        "tags": ["supportAccessRequest"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "uid",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 128,
              "description": "The platform admin whose request it is (the request's uid)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Deny a support access request",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/denySupportAccessRequestOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "support_access.approve",
        "x-fv-side-effect": "write",
        "x-fv-events": ["supportAccess.refused"],
        "x-fv-mcp-tool": "fv_deny_support_access_request",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/support-access-setting": {
      "patch": {
        "operationId": "setOrganizationSupportAccess",
        "summary": "Choose whether support must ask before opening access",
        "description": "Sets the organisation's `supportAccess`: `allowed` (the default; Field-Viewer support may open read-only access for a reason, the owners are e-mailed and it is logged) or `ask` (an owner approves every request first). Owner/admin (`org.update`), signed in to the web app: not available over MCP or to API tokens (interactive consent). Returns the organisation. Fires `organization.supportAccessChanged` when the setting changes.",
        "tags": ["organizationSupportAccess"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "supportAccess": {
                    "type": "string",
                    "enum": ["allowed", "ask"],
                    "description": "allowed: support may open access, owners are e-mailed. ask: an owner approves first."
                  }
                },
                "additionalProperties": false,
                "required": ["supportAccess"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Choose whether support must ask before opening access",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/setOrganizationSupportAccessOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "org.update",
        "x-fv-side-effect": "write",
        "x-fv-events": ["organization.supportAccessChanged"],
        "x-fv-mcp-tool": "fv_set_organization_support_access",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/survey-responses": {
      "post": {
        "operationId": "createSurveyResponse",
        "summary": "Answer a milestone survey",
        "description": "Stores the caller's answers to a milestone survey wave (`wave`, e.g. `m3`): for `kind: 'sus'` the ten System Usability Scale `answers` (1-5, questionnaire order), for `kind: 'nps'` one 0-10 `score`, plus an optional `comment`. One response per person per wave: the response id is `{organizationId}_{userId}_{wave}`, and a second call for a wave already answered returns the stored response unchanged. Fires `surveyResponse.created`; the SUS score (0-100) is computed from the raw answers by the server.",
        "tags": ["surveyResponse"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "wave": {
                    "type": "string",
                    "pattern": "^m[0-9]{1,2}$",
                    "description": "The survey wave: a milestone, lower case (m3, m4)."
                  },
                  "kind": {
                    "type": "string",
                    "enum": ["sus", "nps"],
                    "description": "sus (ten 1-5 answers) or nps (one 0-10 score)."
                  },
                  "answers": {
                    "description": "SUS only: the ten answers, 1-5, in questionnaire order.",
                    "minItems": 10,
                    "maxItems": 10,
                    "type": "array",
                    "items": { "type": "integer", "minimum": 1, "maximum": 5 }
                  },
                  "score": {
                    "description": "NPS only: the 0-10 score.",
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 10
                  },
                  "comment": {
                    "type": "string",
                    "maxLength": 1000,
                    "description": "An optional remark in the person's own words (at most 1000 chars)."
                  }
                },
                "additionalProperties": false,
                "required": ["kind", "wave"]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Answer a milestone survey",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createSurveyResponseOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "feedback.create",
        "x-fv-side-effect": "write",
        "x-fv-events": ["surveyResponse.created"],
        "x-fv-mcp-tool": "fv_create_survey_response",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/tryout": {
      "get": {
        "operationId": "getTryout",
        "summary": "Get a tryout",
        "description": "Returns the tryout block of a tryout organisation: when it expires, where the visitor came from and the research consent answer. Never the claim token or its hash. A standard organisation has none (`404`); a tryout past `expiresAt` that is not purged yet is `410 tryout.expired`.",
        "tags": ["tryout"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Get a tryout",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/getTryoutOutput" }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "410": {
            "description": "tryout.expired",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "org.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_tryout",
        "x-fv-rate-limit-class": "read"
      },
      "patch": {
        "operationId": "updateTryout",
        "summary": "Answer the research copy question of a tryout",
        "description": "Records the research consent answer of a tryout (BR-11): `consented` lets Field-Viewer keep an anonymised copy of the IFC for at most 24 months, internally only; `declined` (from `not_asked` or `consented`) and `withdrawn` (only after `consented`) mean no copy. The answer stores when it was given and the privacy notice version it was given under, and the platform's consent register follows. On an organisation that was a tryout, the answer kept under Settings -> Privacy is changed the same way. The same answer again changes nothing; any other transition is `409 conflict.state`, as is an organisation being deleted. A tryout past its 7 days is `410 tryout.expired`. Open to the tryout's anonymous owner. Fires `tryout.researchConsentChanged` when the answer changes.",
        "tags": ["tryout"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "researchConsent": {
                    "type": "string",
                    "enum": ["consented", "declined", "withdrawn"],
                    "description": "consented: Field-Viewer may keep an anonymised copy of the IFC for 24 months. declined: no copy (the box unticked). withdrawn: a consent taken back later."
                  }
                },
                "additionalProperties": false,
                "required": ["researchConsent"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Answer the research copy question of a tryout",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/updateTryoutOutput" }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "410": {
            "description": "tryout.expired",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "org.update",
        "x-fv-side-effect": "write",
        "x-fv-events": ["tryout.researchConsentChanged"],
        "x-fv-mcp-tool": "fv_update_tryout",
        "x-fv-rate-limit-class": "write",
        "x-fv-anonymous-access": true
      }
    },
    "/v1/organizations/{organizationId}/tryout/convert": {
      "post": {
        "operationId": "convertTryout",
        "summary": "Keep a tryout as an ordinary organisation",
        "description": "Turns the caller's tryout into an ordinary organisation on the free plan, under `organizationName`: `kind` becomes `standard`, the `tryout` block (and its expiry) is removed, the research consent answer moves to `settings/privacy`, and every project, model, version and artefact stays where it is. The caller must be the tryout's owner, signed in with a verified e-mail (an anonymous session is `403 auth.anonymous_not_allowed`, an unverified one `403 auth.email_not_verified`). An organisation that is no tryout (already converted) is `409 conflict.state`. `legalAcceptance` names the current legal versions (an outdated one is `409 legal.version_outdated`). Fires `tryout.converted`, `organization.updated`, `organization.entitlements.updated` and `organization.legalAccepted`.",
        "tags": ["tryout"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "organizationName": {
                    "type": "string",
                    "minLength": 2,
                    "maxLength": 80,
                    "description": "Organisation display name (2-80 chars after trimming, BR-10)."
                  },
                  "locale": {
                    "type": "string",
                    "enum": ["nl", "en", "fr"],
                    "description": "The organisation's default language (nl, en or fr)."
                  },
                  "legalAcceptance": {
                    "type": "object",
                    "properties": {
                      "termsVersion": {
                        "type": "string",
                        "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                        "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
                      },
                      "privacyVersion": {
                        "type": "string",
                        "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                        "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
                      },
                      "dpaVersion": {
                        "type": "string",
                        "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                        "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
                      },
                      "subprocessorsVersion": {
                        "type": "string",
                        "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                        "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
                      }
                    },
                    "required": [
                      "termsVersion",
                      "privacyVersion",
                      "dpaVersion",
                      "subprocessorsVersion"
                    ],
                    "additionalProperties": false,
                    "description": "The current terms, privacy notice, DPA and sub-processor list versions the caller accepts for the organisation (from the legal documents list). Required."
                  }
                },
                "additionalProperties": false,
                "required": ["legalAcceptance", "locale", "organizationName"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Keep a tryout as an ordinary organisation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/convertTryoutOutput" }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "auth.email_not_verified, permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state, legal.version_outdated",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "org.update",
        "x-fv-side-effect": "write",
        "x-fv-events": [
          "tryout.converted",
          "organization.updated",
          "organization.entitlements.updated",
          "organization.legalAccepted"
        ],
        "x-fv-mcp-tool": "fv_convert_tryout",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/tryout/deletion": {
      "post": {
        "operationId": "deleteTryout",
        "summary": "Delete a tryout now",
        "description": "Deletes the caller's tryout now instead of after its 7 days: the organisation becomes `pending_deletion` with `purgeAfter` now, and the next purge sweep removes its documents and files. A research consent is withdrawn (BR-12). Open to the tryout's anonymous owner. An organisation that is no tryout is `404`; one already pending deletion is `409 org.already_pending_deletion`. Fires `organization.deletionRequested`.",
        "tags": ["tryout"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Delete a tryout now",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/deleteTryoutOutput" }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "org.already_pending_deletion",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "org.delete",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["organization.deletionRequested"],
        "x-fv-mcp-tool": "fv_delete_tryout",
        "x-fv-rate-limit-class": "write",
        "x-fv-anonymous-access": true
      }
    },
    "/v1/organizations/{organizationId}/tryout/drawings": {
      "post": {
        "operationId": "addTryoutDrawings",
        "summary": "Add drawings to a tryout",
        "description": "Adds drawings (PDF, DXF or DWG) to the caller's tryout, into its one project: a document per file with its first version and resumable upload ticket (conventions C13), each published automatically once ready. The project holds at most the tryout plan's `maxDocumentsPerProject` drawings; more, or a file above `maxDocumentFileBytes`, is `403 entitlement.limit_reached`. A DXF or DWG while CAD drawings are off, or above its format's ceiling, is `422 validation.failed`. The daily cap counts processor jobs (`429 tryout.daily_cap_reached`). An organisation that is no tryout is `404`; an expired one `410 tryout.expired`. An App Check token is always required. Open to the tryout's anonymous owner. Fires `document.created` and `document.version.created` per drawing.",
        "tags": ["tryoutDrawings"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "projectId": {
                    "type": "string",
                    "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "The tryout's one project (createTryout's projectId)."
                  },
                  "drawings": {
                    "minItems": 1,
                    "maxItems": 20,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "fileName": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 255,
                          "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                        },
                        "sizeBytes": {
                          "type": "integer",
                          "minimum": 1,
                          "maximum": 1073741824,
                          "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                        },
                        "contentType": {
                          "type": "string",
                          "minLength": 1,
                          "description": "The drawing's MIME type: application/pdf, or whatever the browser reports for a DXF or DWG."
                        }
                      },
                      "required": ["fileName", "sizeBytes", "contentType"],
                      "additionalProperties": false
                    },
                    "description": "The drawings (PDF, DXF or DWG), up to the tryout plan's maxDocumentsPerProject."
                  }
                },
                "additionalProperties": false,
                "required": ["drawings", "projectId"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Add drawings to a tryout",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/addTryoutDrawingsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "entitlement.limit_reached, permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "410": {
            "description": "tryout.expired",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "429": {
            "description": "tryout.daily_cap_reached",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "503": {
            "description": "processing.paused",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "document.upload",
        "x-fv-side-effect": "write",
        "x-fv-events": ["document.created", "document.version.created"],
        "x-fv-mcp-tool": "fv_add_tryout_drawings",
        "x-fv-rate-limit-class": "heavy",
        "x-fv-anonymous-access": true,
        "x-fv-app-check": "required"
      }
    },
    "/v1/organizations/{organizationId}/usage": {
      "get": {
        "operationId": "getUsageSummary",
        "summary": "Get an organisation's usage against its plan limits",
        "description": "For every organisation-wide plan limit whose usage is measured (seats, guests, workstations, projects, storageBytes, processingMinutesPerMonth, apiTokens, in that order) returns the current `used` value next to the effective `limit`. `used` is 0 when nothing has been counted yet. A limit whose counter is not built yet is left out of `resources` (today processingMinutesPerMonth) and appears once it is counted; when present, `processingMinutesPerMonth` also carries `resetsAt`, the 1st of next month (UTC). `fileLimits` gives the per-item ceilings (maxModelFileBytes, maxDocumentFileBytes, maxModelsPerProject) from the same effective entitlements, an override applied. `plan` names the plan in NL, EN and FR from the plan catalogue; `planSource` says who last set it. `owners` names the active owners to ask for a larger plan. Owners, admins and publishers; members, guests and workstations are refused.",
        "tags": ["usageSummary"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Get an organisation's usage against its plan limits",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getUsageSummaryOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "usage.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_usage_summary",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/organizations/{organizationId}/workstations": {
      "get": {
        "operationId": "listWorkstations",
        "summary": "List an organisation's workstations",
        "description": "Lists every workstation (unpaired, active and revoked) with its status, projects, `pairedAt` and `lastSeenAt` (updated at most once a day), paginated per C10. Requires `workstation.read`.",
        "tags": ["workstations"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: name | -name | createdAt | -createdAt.",
              "type": "string",
              "enum": ["name", "-name", "createdAt", "-createdAt"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List an organisation's workstations",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/listWorkstationsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "workstation.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_workstations",
        "x-fv-rate-limit-class": "read"
      },
      "post": {
        "operationId": "createWorkstation",
        "summary": "Create a workstation",
        "description": "Creates a shared device (a crew tablet or a fixed screen) as an `unpaired` workstation with a name (1-60 characters, unique in the organisation, case-insensitive) and up to 20 projects it may open. Pair a device with `createWorkstationPairingCode`. Fires `workstation.created`. Requires `workstation.manage`.",
        "tags": ["workstation"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "id": {
                    "type": "string",
                    "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A wks identifier (TypeID, conventions C5)."
                  },
                  "name": { "type": "string", "minLength": 1, "maxLength": 60 },
                  "projectIds": {
                    "maxItems": 20,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A prj identifier (TypeID, conventions C5)."
                    }
                  }
                },
                "additionalProperties": false,
                "required": ["name"]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Create a workstation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createWorkstationOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "entitlement.limit_reached, permission.denied, permission.scope_insufficient, project.member_limit_reached",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.already_exists, conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "workstation.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["workstation.created", "project.member.added"],
        "x-fv-mcp-tool": "fv_create_workstation",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/workstations/{workstationId}": {
      "get": {
        "operationId": "getWorkstation",
        "summary": "Get a workstation",
        "description": "Returns one workstation: name, status, projects, `pairedAt`, `lastSeenAt`. Requires `workstation.read`.",
        "tags": ["workstation"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "workstationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A wks identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-None-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "One or more entity tags (`\"4\"`, `W/\"4\"` or `*`). When one matches the current revision the answer is 304 Not Modified with no body."
          }
        ],
        "responses": {
          "200": {
            "description": "Get a workstation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getWorkstationOutput"
                }
              }
            }
          },
          "304": {
            "description": "Not Modified: the If-None-Match entity tag still matches.",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "workstation.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_workstation",
        "x-fv-rate-limit-class": "read"
      },
      "patch": {
        "operationId": "updateWorkstation",
        "summary": "Rename a workstation or change its projects",
        "description": "Patches `name` and/or `projectIds` (JSON Merge Patch, C2: an omitted field is left unchanged; `projectIds` replaces the whole list, at most 20, BR-31). Fires `workstation.updated` (plus `project.member.added`/`project.member.removed` per project change) only when something changes. Requires `workstation.manage`.",
        "tags": ["workstation"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "workstationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A wks identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": { "type": "string", "minLength": 1, "maxLength": 60 },
                  "projectIds": {
                    "maxItems": 20,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A prj identifier (TypeID, conventions C5)."
                    }
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Rename a workstation or change its projects",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/updateWorkstationOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient, project.member_limit_reached",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.already_exists, conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "workstation.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": [
          "workstation.updated",
          "project.member.added",
          "project.member.removed"
        ],
        "x-fv-mcp-tool": "fv_update_workstation",
        "x-fv-rate-limit-class": "write"
      },
      "delete": {
        "operationId": "deleteWorkstation",
        "summary": "Delete a revoked workstation",
        "description": "Permanently deletes a workstation that was revoked first (`409 conflict.state` otherwise): its document, its project memberships and its device account. What it created stays. Fires `workstation.deleted`. Requires `workstation.manage`.",
        "tags": ["workstation"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "workstationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A wks identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "responses": {
          "204": {
            "description": "No Content",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "workstation.manage",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["workstation.deleted", "project.member.removed"],
        "x-fv-mcp-tool": "fv_delete_workstation",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/workstations/{workstationId}/heartbeat": {
      "post": {
        "operationId": "sendWorkstationHeartbeat",
        "summary": "Report that a workstation's screen is running",
        "description": "Called by a paired workstation for itself, every 2 minutes while it is online: records `runtime.heartbeatAt` (server time) with the project on screen (`currentProjectId`, kept only when it is one of the workstation's projects), the app build (`appVersion`) and the scene's health (`state`). Admins see the screen as online while the last heartbeat is at most 6 minutes old. A heartbeat within 30 seconds of the last recorded one is not written (`recorded: false`). A device naming another workstation is refused `403`. No event, and never in the audit log. Requires `workstation.heartbeat` (workstations only).",
        "tags": ["workstationHeartbeat"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "workstationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "The calling device's own workstation id."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "currentProjectId": {
                    "description": "The project on screen. Kept only when it is one of the workstation's own projects.",
                    "type": "string",
                    "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
                  },
                  "appVersion": {
                    "description": "The app build the screen runs.",
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 64
                  },
                  "state": {
                    "description": "`ready` while the scene is interactive; `error` once it has failed to open three times in a row.",
                    "type": "string",
                    "enum": ["ready", "error"]
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Report that a workstation's screen is running",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/sendWorkstationHeartbeatOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "workstation.heartbeat",
        "x-fv-side-effect": "write",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_send_workstation_heartbeat",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/workstations/{workstationId}/pairing-codes": {
      "post": {
        "operationId": "createWorkstationPairingCode",
        "summary": "Create a pairing code for a workstation",
        "description": "Issues a one-time pairing code (`XXXX-XXXX`, valid 15 minutes) to type on the device's `/pair` screen. A new code voids any earlier one. Pairing a new device revokes the previous device's session (one device per workstation). A revoked workstation goes back to `unpaired`. Fires `workstation.pairingCodeCreated`. Requires `workstation.manage`.",
        "tags": ["workstationPairingCode"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "workstationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A wks identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Create a pairing code for a workstation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createWorkstationPairingCodeOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "workstation.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["workstation.pairingCodeCreated"],
        "x-fv-mcp-tool": "fv_create_workstation_pairing_code",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/workstations/{workstationId}/preset": {
      "patch": {
        "operationId": "assignWorkstationPreset",
        "summary": "Set what a workstation's screen shows",
        "description": "Replaces the workstation's preset: `mode` `fixed` (one `projectId`) or `crew` (`projectIds`, all among the workstation's own projects, BR-14), the model policy (`latest_published`), an optional shared `viewId` of the project the screen opens on, an optional `toolbarConfig` (up to 7 ids, in order) and `lockedSettings`. A paired screen boots straight into it; re-pairing keeps it. Refuses `422 validation.failed` for a project the workstation does not have and `404 resource.not_found` for a view that is not a shared view of that project. Fires `workstation.presetAssigned` when something changes. Requires `workstation.manage`.",
        "tags": ["workstationPreset"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "workstationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A wks identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "mode": {
                    "type": "string",
                    "enum": ["fixed", "crew"],
                    "description": "`fixed`: one project (`projectId`). `crew`: several (`projectIds`), all among the workstation's own projects; the screen opens on the first."
                  },
                  "projectId": {
                    "type": "string",
                    "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A prj identifier (TypeID, conventions C5)."
                  },
                  "projectIds": {
                    "minItems": 1,
                    "maxItems": 20,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A prj identifier (TypeID, conventions C5)."
                    }
                  },
                  "modelPolicy": {
                    "description": "Which model version the screen shows. `latest_published` (the default) is the only option.",
                    "type": "string",
                    "const": "latest_published"
                  },
                  "viewId": {
                    "description": "A shared view of the project the screen opens on; without one it opens on the project's default view.",
                    "type": "string",
                    "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
                  },
                  "toolbarConfig": {
                    "description": "Up to 7 toolbar ids, in the order they show (e.g. `measure`, `section`, `layers`). An id a screen does not know is skipped there. Without it the screen shows its usual toolbar.",
                    "maxItems": 7,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^[a-z][a-zA-Z0-9-]{0,39}$"
                    }
                  },
                  "lockedSettings": {
                    "description": "Defaults: no project switching, no sharing, the device's own theme, back to the preset view after 10 idle minutes.",
                    "type": "object",
                    "properties": {
                      "allowProjectSwitch": { "type": "boolean" },
                      "allowShare": { "type": "boolean" },
                      "theme": {
                        "type": "string",
                        "enum": ["sunlight", "dim"]
                      },
                      "idleResetMinutes": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 120
                      }
                    },
                    "additionalProperties": false
                  }
                },
                "additionalProperties": false,
                "required": ["mode"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Set what a workstation's screen shows",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/assignWorkstationPresetOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "workstation.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["workstation.presetAssigned"],
        "x-fv-mcp-tool": "fv_assign_workstation_preset",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/organizations/{organizationId}/workstations/{workstationId}/revoke": {
      "post": {
        "operationId": "revokeWorkstation",
        "summary": "Revoke a workstation",
        "description": "Signs the paired device out for good: its account is disabled, its sessions are revoked and its status becomes `revoked`, so it loses access at once. What it created stays, attributed to the workstation. A new pairing code makes it usable again. Idempotent. Fires `workstation.revoked`. Requires `workstation.manage`.",
        "tags": ["workstation"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "workstationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A wks identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Revoke a workstation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/revokeWorkstationOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "workstation.manage",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["workstation.revoked"],
        "x-fv-mcp-tool": "fv_revoke_workstation",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/plans": {
      "get": {
        "operationId": "listPlans",
        "summary": "List Field-Viewer's plans",
        "description": "Returns Field-Viewer's plans with their name in Dutch, English and French, their limits (projects, seats, guests, workstations, storage, file sizes, API tokens; `hiddenLimits` names the keys not to show, such as models per project) and features, and on `team` its `price` (EUR cents, excl. VAT, per month and per year), its trial length (`trial.days`) and its grace length after a failed payment (`graceDays`). Every row says whether the plan takes DXF and DWG drawings (`features.cadDrawings`) and how long its content is kept (`limits.retentionDays`, `null` when it does not expire). Public (no authentication): `free`, `team` and `enterprise` with the list price, cached for 5 minutes. An owner or admin can pass `organizationId` to get that organisation's own price, its discount applied (not cached). A platform admin can add `includeInternal=true` to also get `internal` and `tryout`; anyone else gets `403 permission.denied` for either. Anyone may add `includeTryout=true` to get the `tryout` row (a tryout's limits, as the try page shows them).",
        "tags": ["plans"],
        "parameters": [
          {
            "name": "includeInternal",
            "in": "query",
            "required": false,
            "schema": {
              "description": "`true` also returns the plans that are not offered publicly (`internal`, `tryout`). Platform admins only.",
              "type": "string",
              "enum": ["true", "false"]
            }
          },
          {
            "name": "includeTryout",
            "in": "query",
            "required": false,
            "schema": {
              "description": "`true` also returns the `tryout` row (the limits of a tryout without an account), as the try page reads its size cap. Open to anyone.",
              "type": "string",
              "enum": ["true", "false"]
            }
          },
          {
            "name": "organizationId",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Returns this organisation's own price (its discount applied) instead of the list price. Owners and admins of the organisation only.",
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
            }
          },
          {
            "name": "If-None-Match",
            "in": "header",
            "required": false,
            "schema": { "type": "string" },
            "description": "One or more entity tags (`\"4\"`, `W/\"4\"` or `*`). When one matches the current revision the answer is 304 Not Modified with no body."
          }
        ],
        "responses": {
          "200": {
            "description": "List Field-Viewer's plans",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/listPlansOutput" }
              }
            }
          },
          "304": {
            "description": "Not Modified: the If-None-Match entity tag still matches.",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            }
          },
          "401": {
            "description": "auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "security": [],
        "x-fv-capability": "public",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_plans",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/platform/beta-access-codes": {
      "get": {
        "operationId": "listBetaAccessCodes",
        "summary": "List beta access codes",
        "description": "Lists every beta access code, newest first (AC-4). Never returns the opaque `code` value itself -- only shown once, at creation. Platform-admin only.",
        "tags": ["betaAccessCodes"],
        "deprecated": true,
        "x-sunset": "2026-12-10",
        "x-fv-deprecation": {
          "since": "2026-11-10",
          "replacement": "createOrganization"
        },
        "parameters": [
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: createdAt | -createdAt.",
              "type": "string",
              "enum": ["createdAt", "-createdAt"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List beta access codes",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/listBetaAccessCodesOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.beta_access.manage",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_beta_access_codes",
        "x-fv-rate-limit-class": "read"
      },
      "post": {
        "operationId": "createBetaAccessCode",
        "summary": "Issue a beta access code",
        "description": "Mints an active beta access code bound to a reviewed lead's e-mail (AC-1). Fails `409 conflict.already_exists` if that e-mail already has an active code (AC-3) -- revoke it first. Sends e-mail #8 to the recipient. Platform-admin only.",
        "tags": ["betaAccessCode"],
        "deprecated": true,
        "x-sunset": "2026-12-10",
        "x-fv-deprecation": {
          "since": "2026-11-10",
          "replacement": "createOrganization"
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "boundEmail": {
                    "type": "string",
                    "format": "email",
                    "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$",
                    "description": "The reviewed lead's e-mail address (case-insensitive)."
                  },
                  "maxRedemptions": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991,
                    "description": "How many organisations this code may be redeemed into."
                  },
                  "expiresInDays": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 365,
                    "description": "Days from now until the code expires."
                  }
                },
                "additionalProperties": false,
                "required": ["boundEmail", "expiresInDays", "maxRedemptions"]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Issue a beta access code",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createBetaAccessCodeOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.already_exists",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.beta_access.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["betaAccessCode.created"],
        "x-fv-mcp-tool": "fv_create_beta_access_code",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/platform/beta-access-codes/{id}/revoke": {
      "post": {
        "operationId": "revokeBetaAccessCode",
        "summary": "Revoke a beta access code",
        "description": "Revokes an active beta access code (AC-3): `status` becomes `revoked` and its `boundEmail` is freed for a fresh `createBetaAccessCode` call. Fails `409 conflict.state` if the code is not currently active, `404 resource.not_found` for an unknown id. Platform-admin only.",
        "tags": ["betaAccessCode"],
        "deprecated": true,
        "x-sunset": "2026-12-10",
        "x-fv-deprecation": {
          "since": "2026-11-10",
          "replacement": "createOrganization"
        },
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^bac_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A bac identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Revoke a beta access code",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/revokeBetaAccessCodeOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.beta_access.manage",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["betaAccessCode.revoked"],
        "x-fv-mcp-tool": "fv_revoke_beta_access_code",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/platform/flags": {
      "get": {
        "operationId": "getPlatformFlags",
        "summary": "List the feature flags with their live values in this environment",
        "description": "Platform admins only. Every flag in the registry (docs/flags.md) with its purpose, owner, repo default and, per Remote Config template it lives in (`client`: the web app, `server`: the API), its live unconditional default and one rule per rollout group (a `cohort` or a `planId` condition), in the template's priority order. `inSync` is false when a flag in both templates differs between them. `templates` carries each template's ETag, which `updatePlatformFlag` needs. Read live from the environment the API runs in. Needs an MFA session (`403 auth.mfa_required`); Remote Config unreachable is `503 dependency.unavailable`.",
        "tags": ["platformFlags"],
        "responses": {
          "200": {
            "description": "List the feature flags with their live values in this environment",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getPlatformFlagsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "503": {
            "description": "dependency.unavailable",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.flags.manage",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_platform_flags",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/platform/flags/{flag}": {
      "patch": {
        "operationId": "updatePlatformFlag",
        "summary": "Switch a feature flag on or off, for everyone or one rollout group",
        "description": "Platform admins only. Sets a registered flag's unconditional default, or its value for one rollout group (`group`: a cohort or a plan; the condition is added when missing, and `value: null` removes the group's rule), in EVERY Remote Config template the flag lives in: a flag read by the app and the API changes in both at once, and when the second publish fails the first is put back. `etags` must hold the ETag of each of those templates (`428 precondition.required` without one, `412 precondition.failed` with the current ETags when one is stale). The app follows within its fetch interval (1 hour in staging and production); the API instance that published at once, the others within a minute. A later deploy keeps the value (docs/flags.md). `reason` is required. Needs an MFA session signed in within the last 5 minutes (`403 auth.reauthentication_required`). Fires `platform.featureFlag.updated`, recorded in the platform log with the value before and after.",
        "tags": ["platformFlag"],
        "parameters": [
          {
            "name": "flag",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ff_e\\d{2}_[a-z0-9]+(?:_[a-z0-9]+)*$",
              "description": "A registered flag key, `ff_<epic>_<feature>` (docs/flags.md)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "group": {
                    "description": "The rollout group to switch: a cohort, or a plan. Absent: the flag's unconditional default for everyone.",
                    "oneOf": [
                      {
                        "type": "object",
                        "properties": {
                          "kind": { "type": "string", "const": "cohort" },
                          "cohort": {
                            "type": "string",
                            "pattern": "^[a-z0-9][a-z0-9_-]{0,39}$",
                            "description": "The cohort tag, e.g. `wave1`."
                          }
                        },
                        "required": ["kind", "cohort"],
                        "additionalProperties": false
                      },
                      {
                        "type": "object",
                        "properties": {
                          "kind": { "type": "string", "const": "plan" },
                          "planId": {
                            "type": "string",
                            "enum": [
                              "free",
                              "team",
                              "enterprise",
                              "internal",
                              "tryout"
                            ]
                          }
                        },
                        "required": ["kind", "planId"],
                        "additionalProperties": false
                      }
                    ]
                  },
                  "value": {
                    "description": "On or off. `null` (only with `group`) removes the group's rule, so it follows the default again.",
                    "type": ["boolean", "null"]
                  },
                  "reason": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 500,
                    "description": "Why the flag changes; kept in the platform log."
                  },
                  "etags": {
                    "type": "object",
                    "properties": {
                      "client": { "type": "string", "minLength": 1 },
                      "server": { "type": "string", "minLength": 1 }
                    },
                    "additionalProperties": false,
                    "description": "The ETag of every template the flag lives in, from `getPlatformFlags` (`*` for a template that does not exist yet)."
                  }
                },
                "additionalProperties": false,
                "required": ["etags", "reason", "value"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Switch a feature flag on or off, for everyone or one rollout group",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/updatePlatformFlagOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "412": {
            "description": "precondition.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "428": {
            "description": "precondition.required",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "503": {
            "description": "dependency.unavailable",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.flags.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["platform.featureFlag.updated"],
        "x-fv-mcp-tool": "fv_update_platform_flag",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/platform/model-versions": {
      "get": {
        "operationId": "listFailedModelVersions",
        "summary": "List failed model versions across organisations",
        "description": "Platform admins only. Every failed model version, newest failure first, each with its organisation, project, model and version ids, `attempt` (which processing run failed), `failedAt` and the full `failure` (`code`, `messageKey`, `params`, `retryable`, `supportRef`) -- no second call needed. `organizationId` narrows it to one organisation (the organisation detail's pipeline section). Paginated per C10. Needs an MFA session (`403 auth.mfa_required`).",
        "tags": ["failedModelVersions"],
        "parameters": [
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "organizationId",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Only this organisation's failures.",
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: -failedAt.",
              "type": "string",
              "enum": ["-failedAt"]
            }
          },
          {
            "name": "status",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Only `failed` (the default): the versions the pipeline gave up on.",
              "type": "string",
              "const": "failed"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List failed model versions across organisations",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/listFailedModelVersionsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.pipeline.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_failed_model_versions",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/platform/organization-activations": {
      "get": {
        "operationId": "listOrganizationActivations",
        "summary": "List every organisation's activation for the beta cohort overview",
        "description": "Platform admins only. One row per organisation, sorted by name: `cohort`, the activation funnel `stage` reached (`signed_up` -> `org_created` -> `first_project_created` -> `first_model_published` -> `first_field_open`), `lastActiveAt` and `activeWeeksCount` (consecutive calendar weeks with a model opened by a member or workstation, E12 §9.6's beta-exit definition). Computed from the product-analytics events and reused for 5 minutes. `cohort` filters on the beta wave tag. `503 dependency.unavailable` when the analytics events cannot be read. Paginated per C10. Needs an MFA session (`403 auth.mfa_required`).",
        "tags": ["organizationActivations"],
        "parameters": [
          {
            "name": "cohort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Only organisations tagged with exactly this beta cohort, e.g. `wave1`.",
              "type": "string",
              "minLength": 1,
              "maxLength": 100
            }
          },
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: name.",
              "type": "string",
              "enum": ["name"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List every organisation's activation for the beta cohort overview",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/listOrganizationActivationsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "503": {
            "description": "dependency.unavailable",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.org.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_organization_activations",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/platform/organizations": {
      "get": {
        "operationId": "listPlatformOrganizations",
        "summary": "List and search every organisation",
        "description": "Platform admins only. Lists every organisation, sorted by name: `id`, `name`, `planId`, `orgStatus` (`active` or `suspended`) and `createdAt`. `q` matches part of the name (ignoring case and accents) or an exact organisation id; `planId` and `orgStatus` filter. Paginated per C10. Needs an MFA session (`403 auth.mfa_required`).",
        "tags": ["platformOrganizations"],
        "parameters": [
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "orgStatus",
            "in": "query",
            "required": false,
            "schema": { "type": "string", "enum": ["active", "suspended"] }
          },
          {
            "name": "planId",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "enum": [
                "beta",
                "free",
                "team",
                "enterprise",
                "internal",
                "tryout"
              ]
            }
          },
          {
            "name": "q",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Part of the organisation's name (case- and accent-insensitive), or its exact id.",
              "type": "string",
              "maxLength": 200
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: name.",
              "type": "string",
              "enum": ["name"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List and search every organisation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/listPlatformOrganizationsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.org.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_platform_organizations",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/platform/organizations/{organizationId}": {
      "get": {
        "operationId": "getPlatformOrganization",
        "summary": "Get an organisation's plan, usage and health",
        "description": "Platform admins only. One organisation's support picture: plan, `orgStatus`, effective `limits`/`features` (with any override), `usage` against each limit, `membersCount` (active members) and `lastActivityAt` -- the newest change anyone but a platform admin made, from the activity log. `plan` names the plan per language, `planSource` who set it and `planChange` its newest change in the activity log. `entitlementsRevision` is the If-Match for `updateOrganizationEntitlements`; `billing` is the billing status and whether a provider subscription runs (no provider id). Its failed model versions are `listFailedModelVersions` with `organizationId`. `404 resource.not_found` for an unknown id. Needs an MFA session (`403 auth.mfa_required`).",
        "tags": ["platformOrganization"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Get an organisation's plan, usage and health",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getPlatformOrganizationOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.org.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_platform_organization",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/platform/organizations/{organizationId}/billing/discount": {
      "post": {
        "operationId": "grantOrganizationDiscount",
        "summary": "Give one organisation a discount",
        "description": "Platform admins only. Gives one organisation a discount on the priced plans: `percent` (`value`, more than 0 and at most 100) or `amount_off` (`cents`, EUR excl. VAT), for `{ months }` or `{ forever: true }`. A coupon is created at the payment provider first; the organisation's next Checkout uses it, and with `applyToCurrentSubscription` its running subscription gets it now. Discounts never stack: the lowest resulting price applies. Anonymous callers and the website never see it. `422 pricing.amount_invalid` for a discount of nothing; `503 dependency.unavailable` when the provider cannot be reached, with nothing written. Needs an `Idempotency-Key` and an MFA session signed in within the last 5 minutes. Recorded in the organisation's log and the platform log.",
        "tags": ["organizationDiscount"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 80,
                    "description": "The discount's name, e.g. 'case study'. The organisation sees only the resulting price."
                  },
                  "discount": {
                    "oneOf": [
                      {
                        "type": "object",
                        "properties": {
                          "type": { "type": "string", "const": "percent" },
                          "value": {
                            "type": "number",
                            "exclusiveMinimum": 0,
                            "maximum": 100
                          }
                        },
                        "required": ["type", "value"],
                        "additionalProperties": false
                      },
                      {
                        "type": "object",
                        "properties": {
                          "type": { "type": "string", "const": "amount_off" },
                          "cents": {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          }
                        },
                        "required": ["type", "cents"],
                        "additionalProperties": false
                      }
                    ]
                  },
                  "duration": {
                    "anyOf": [
                      {
                        "type": "object",
                        "properties": {
                          "months": {
                            "type": "integer",
                            "exclusiveMinimum": 0,
                            "maximum": 9007199254740991
                          }
                        },
                        "required": ["months"],
                        "additionalProperties": false
                      },
                      {
                        "type": "object",
                        "properties": {
                          "forever": { "type": "boolean", "const": true }
                        },
                        "required": ["forever"],
                        "additionalProperties": false
                      }
                    ]
                  },
                  "note": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 500
                  },
                  "applyToCurrentSubscription": {
                    "description": "Also put the discount on the organisation's running subscription now. Default: only new Checkouts get it.",
                    "type": "boolean"
                  }
                },
                "additionalProperties": false,
                "required": ["discount", "duration", "name"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Give one organisation a discount",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/grantOrganizationDiscountOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "pricing.amount_invalid, validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "billing.provider_misconfigured, internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "503": {
            "description": "dependency.unavailable",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.billing.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["billing.discountGranted", "pricing.changed"],
        "x-fv-mcp-tool": "fv_grant_organization_discount",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/platform/organizations/{organizationId}/billing/discount/revoke": {
      "post": {
        "operationId": "revokeOrganizationDiscount",
        "summary": "End one organisation's discount",
        "description": "Platform admins only. Ends the organisation's active discount (`discountId`), or every active one when omitted, and takes the coupon off its running subscription at the payment provider. The next invoice and the plan screen show the list price. `404 billing.no_discount` without an active discount. Needs an MFA session signed in within the last 5 minutes; on MCP a confirmation first.",
        "tags": ["organizationDiscount"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "discountId": { "type": "string", "minLength": 1 },
                  "note": { "type": "string", "minLength": 1, "maxLength": 500 }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "End one organisation's discount",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/revokeOrganizationDiscountOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "billing.no_discount, resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "billing.provider_misconfigured, internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "503": {
            "description": "dependency.unavailable",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.billing.manage",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["pricing.changed"],
        "x-fv-mcp-tool": "fv_revoke_organization_discount",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/platform/organizations/{organizationId}/entitlements": {
      "patch": {
        "operationId": "updateOrganizationEntitlements",
        "summary": "Change an organisation's plan or override its limits",
        "description": "Platform admins only. A JSON Merge Patch on the organisation's entitlements: `planId` moves it to that plan (limits and features become the plan's catalogue values; an override stays in place), `overrides` merges into the override in force (`null` removes the override, or one limit, feature or `expiresAt` inside it) and `cohort` sets or removes the beta wave tag. Every override change needs a `reason` (`422 validation.failed` at `/overrides/reason`), and `maxModelFileBytes` can never exceed the 1 GiB system ceiling. An override with `expiresAt` stops applying at that moment. `If-Match`/`expectedRevision` is required (`428 precondition.required`, `412 precondition.failed`). Needs an MFA session (`403 auth.mfa_required`) signed in within the last 5 minutes (`403 auth.reauthentication_required`). Fires `organization.entitlements.updated`, recorded in the organisation's audit log and the platform log.",
        "tags": ["organizationEntitlements"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "If-Match",
            "in": "header",
            "required": true,
            "schema": { "type": "string" },
            "description": "The revision you last read, as an entity tag (`\"4\"`, from the `ETag` header). A stale one answers 412 `precondition.failed` and changes nothing. `*` matches any current revision (not accepted where a precondition is required). MCP/SDK: `expectedRevision`."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "planId": {
                    "description": "Moves the organisation to this plan: its limits and features become the plan's catalogue row. An override stays as it is.",
                    "type": "string",
                    "enum": [
                      "beta",
                      "free",
                      "team",
                      "enterprise",
                      "internal",
                      "tryout"
                    ]
                  },
                  "cohort": {
                    "description": "Beta wave tag. `null` removes it.",
                    "anyOf": [
                      { "type": "string", "minLength": 1 },
                      { "type": "null" }
                    ]
                  },
                  "overrides": {
                    "description": "Merged into the current override. `null` removes the override entirely.",
                    "anyOf": [
                      {
                        "type": "object",
                        "properties": {
                          "limits": {
                            "type": "object",
                            "properties": {
                              "seats": {
                                "anyOf": [
                                  {
                                    "type": "integer",
                                    "minimum": 0,
                                    "maximum": 9007199254740991
                                  },
                                  { "type": "null" }
                                ]
                              },
                              "guests": {
                                "anyOf": [
                                  {
                                    "type": "integer",
                                    "minimum": 0,
                                    "maximum": 9007199254740991
                                  },
                                  { "type": "null" }
                                ]
                              },
                              "workstations": {
                                "anyOf": [
                                  {
                                    "type": "integer",
                                    "minimum": 0,
                                    "maximum": 9007199254740991
                                  },
                                  { "type": "null" }
                                ]
                              },
                              "projects": {
                                "anyOf": [
                                  {
                                    "type": "integer",
                                    "minimum": 0,
                                    "maximum": 9007199254740991
                                  },
                                  { "type": "null" }
                                ]
                              },
                              "storageBytes": {
                                "anyOf": [
                                  {
                                    "type": "integer",
                                    "minimum": 0,
                                    "maximum": 9007199254740991
                                  },
                                  { "type": "null" }
                                ]
                              },
                              "maxModelFileBytes": {
                                "anyOf": [
                                  {
                                    "type": "integer",
                                    "minimum": 0,
                                    "maximum": 1073741824,
                                    "description": "Largest single model file, in bytes, for direct upload and URL import. Never above 1 GiB (BR-10)."
                                  },
                                  { "type": "null" }
                                ]
                              },
                              "maxModelsPerProject": {
                                "anyOf": [
                                  {
                                    "type": "integer",
                                    "minimum": 0,
                                    "maximum": 9007199254740991
                                  },
                                  { "type": "null" }
                                ]
                              },
                              "processingMinutesPerMonth": {
                                "anyOf": [
                                  {
                                    "type": "integer",
                                    "minimum": 0,
                                    "maximum": 9007199254740991
                                  },
                                  { "type": "null" }
                                ]
                              },
                              "apiTokens": {
                                "anyOf": [
                                  {
                                    "type": "integer",
                                    "minimum": 0,
                                    "maximum": 9007199254740991
                                  },
                                  { "type": "null" }
                                ]
                              },
                              "maxDocumentFileBytes": {
                                "anyOf": [
                                  {
                                    "type": "integer",
                                    "minimum": 0,
                                    "maximum": 9007199254740991,
                                    "description": "Largest single drawing file (PDF, DXF, DWG), in bytes. The format's own ceiling still applies on top."
                                  },
                                  { "type": "null" }
                                ]
                              },
                              "maxDocumentsPerProject": {
                                "anyOf": [
                                  {
                                    "type": "integer",
                                    "minimum": 0,
                                    "maximum": 9007199254740991
                                  },
                                  { "type": "null" }
                                ]
                              }
                            },
                            "additionalProperties": false
                          },
                          "features": {
                            "type": "object",
                            "properties": {
                              "autoDimensions": { "type": ["boolean", "null"] },
                              "workstationMode": {
                                "type": ["boolean", "null"]
                              },
                              "auditLogExport": { "type": ["boolean", "null"] },
                              "sso": { "type": ["boolean", "null"] }
                            },
                            "additionalProperties": false
                          },
                          "reason": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 500,
                            "description": "Why the override is set, e.g. a support ticket. Required for every override change; kept in the audit log."
                          },
                          "expiresAt": {
                            "description": "When the override stops applying. Omit to keep the current expiry; `null` makes it permanent.",
                            "anyOf": [
                              {
                                "type": "string",
                                "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))$"
                              },
                              { "type": "null" }
                            ]
                          }
                        },
                        "required": ["reason"],
                        "additionalProperties": false
                      },
                      { "type": "null" }
                    ]
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Change an organisation's plan or override its limits",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/updateOrganizationEntitlementsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.entitlements.update",
        "x-fv-side-effect": "write",
        "x-fv-events": ["organization.entitlements.updated"],
        "x-fv-mcp-tool": "fv_update_organization_entitlements",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/platform/organizations/{organizationId}/projects/{projectId}/models/{modelId}/versions/{versionId}/reprocess-as-support": {
      "post": {
        "operationId": "reprocessModelVersionAsSupport",
        "summary": "Reprocess a failed model version as platform support",
        "description": "Platform admins only. Queues one failed model version for processing again, through the same internal reprocess path the pipeline-upgrade campaign uses -- never the tenant `reprocessModelVersion` operation, and no tenant capability is involved (BR-8). Fires `model.version.processing_requested`, requested by platform support. `409 conflict.state` when the version is not failed, its failure is not retryable (`reason: not_retryable`), its source file is no longer stored -- removed by retention, or a link import that never landed (`reason: source_unavailable`) -- or its project is archived. Needs an MFA session (`403 auth.mfa_required`) signed in within the last 5 minutes (`403 auth.reauthentication_required`).",
        "tags": ["modelVersionAsSupport"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "projectId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "modelId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A mdl identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "versionId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ver identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Reprocess a failed model version as platform support",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/reprocessModelVersionAsSupportOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.pipeline.reprocess",
        "x-fv-side-effect": "write",
        "x-fv-events": ["model.version.processingRequested"],
        "x-fv-mcp-tool": "fv_reprocess_model_version_as_support",
        "x-fv-rate-limit-class": "heavy"
      }
    },
    "/v1/platform/organizations/{organizationId}/reactivate": {
      "post": {
        "operationId": "reactivateOrganization",
        "summary": "Reactivate a suspended organisation",
        "description": "Platform admins only. Ends a suspension at once: the organisation's members can change things again, with everything exactly as it was. An optional `reason` is kept in the audit log. Reactivating an active organisation changes nothing. Needs an MFA session (`403 auth.mfa_required`). Fires `organization.reactivated`, recorded in the organisation's audit log and the platform log.",
        "tags": ["organization"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "reason": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 500
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Reactivate a suspended organisation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/reactivateOrganizationOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.org.suspend",
        "x-fv-side-effect": "write",
        "x-fv-events": ["organization.reactivated"],
        "x-fv-mcp-tool": "fv_reactivate_organization",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/platform/organizations/{organizationId}/support-access": {
      "post": {
        "operationId": "startSupportAccess",
        "summary": "Start read-only support access to an organisation",
        "description": "Platform admins only. Opens a time-boxed, read-only support grant on one organisation: until it ends, the caller can read every project of that organisation, drafts included, but never change anything. Needs a `reason` of at least 10 characters (`422 validation.failed`); `durationMinutes` defaults to 60, at most 120. Starting again replaces the caller's earlier grant on the organisation. The organisation's owners are e-mailed. When the organisation's `supportAccess` is `ask` (FV-464), an owner must first approve a `requestSupportAccess` of the caller (`409 support_access.approval_required` until then); the start uses that approval up. Needs an MFA session (`403 auth.mfa_required`) signed in within the last 5 minutes (`403 auth.reauthentication_required`). Fires `supportAccess.started`, recorded in the organisation's audit log and the platform log.",
        "tags": ["supportAccess"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "reason": {
                    "type": "string",
                    "minLength": 10,
                    "maxLength": 500,
                    "description": "Why support needs access, at least 10 characters (BR-44). Shown to the organisation's owners."
                  },
                  "durationMinutes": {
                    "description": "How long the grant lasts, in minutes. Default 60, at most 120.",
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 120
                  }
                },
                "additionalProperties": false,
                "required": ["reason"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Start read-only support access to an organisation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/startSupportAccessOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "support_access.approval_required",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.support_access",
        "x-fv-side-effect": "write",
        "x-fv-events": ["supportAccess.started"],
        "x-fv-mcp-tool": "fv_start_support_access",
        "x-fv-rate-limit-class": "write"
      },
      "delete": {
        "operationId": "endSupportAccess",
        "summary": "End your support access to an organisation",
        "description": "Platform admins only. Ends the caller's active support grant on the organisation now; from then on its content is closed to the caller again. `404 resource.not_found` when the caller has no active grant there (never started, already ended, or expired). Needs an MFA session. Fires `supportAccess.ended`, recorded in the organisation's audit log and the platform log.",
        "tags": ["supportAccess"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "responses": {
          "204": {
            "description": "No Content",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.support_access",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["supportAccess.ended"],
        "x-fv-mcp-tool": "fv_end_support_access",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/platform/organizations/{organizationId}/support-access-requests": {
      "post": {
        "operationId": "requestSupportAccess",
        "summary": "Ask an organisation's owners for support access",
        "description": "Platform admins only. For an organisation whose `supportAccess` is `ask`: asks its owners to approve read-only support access, with a `reason` (at least 10 characters) and `durationMinutes` (default 60, at most 120). The owners are e-mailed a link to approve or deny it in the app; the request lapses after 24 hours. Asking again replaces the caller's earlier request. Once an owner approves, `startSupportAccess` starts the grant. `409 conflict.state` when the organisation allows support access without asking (start it directly). Needs an MFA session. Fires `supportAccess.requested`, recorded in the organisation's audit log and the platform log.",
        "tags": ["supportAccess"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "reason": {
                    "type": "string",
                    "minLength": 10,
                    "maxLength": 500,
                    "description": "Why support needs access, at least 10 characters (BR-44). Shown to the organisation's owners."
                  },
                  "durationMinutes": {
                    "description": "How long the grant lasts, in minutes. Default 60, at most 120.",
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 120
                  }
                },
                "additionalProperties": false,
                "required": ["reason"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Ask an organisation's owners for support access",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/requestSupportAccessOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.support_access",
        "x-fv-side-effect": "write",
        "x-fv-events": ["supportAccess.requested"],
        "x-fv-mcp-tool": "fv_request_support_access",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/platform/organizations/{organizationId}/suspend": {
      "post": {
        "operationId": "suspendOrganization",
        "summary": "Suspend an organisation",
        "description": "Platform admins only. Pauses every change by the organisation's members, tokens, apps and workstations: their writes answer `403 organization.suspended`, reads keep working, nothing is deleted and nobody is signed out. Needs a `reason` (`422 validation.failed`), kept in the audit log. Suspending a suspended organisation changes nothing. Needs an MFA session (`403 auth.mfa_required`) signed in within the last 5 minutes (`403 auth.reauthentication_required`). Over MCP it is confirmed in two steps. Fires `organization.suspended`, recorded in the organisation's audit log and the platform log.",
        "tags": ["organization"],
        "parameters": [
          {
            "name": "organizationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            }
          },
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "reason": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 500,
                    "description": "Why the organisation is suspended, e.g. a support ticket. Kept in the audit log."
                  }
                },
                "additionalProperties": false,
                "required": ["reason"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Suspend an organisation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/suspendOrganizationOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.org.suspend",
        "x-fv-side-effect": "write",
        "x-fv-events": ["organization.suspended"],
        "x-fv-mcp-tool": "fv_suspend_organization",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/platform/pricing": {
      "get": {
        "operationId": "getPricing",
        "summary": "Read the list prices and the active discounts",
        "description": "Platform admins only. The list price of every priced plan per interval (EUR cents, excl. VAT), with its history (when, who, from, the note), and every active per-organisation discount with its terms and end date, and our marginal cost per organisation (`marginalCostCents`, the margin hint; `null` while not set). No provider id is returned. Needs an MFA session signed in within the last 5 minutes.",
        "tags": ["pricing"],
        "responses": {
          "200": {
            "description": "Read the list prices and the active discounts",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/getPricingOutput" }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.billing.manage",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_pricing",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/platform/pricing/price-changes/cancel": {
      "post": {
        "operationId": "cancelScheduledPriceChanges",
        "summary": "Cancel scheduled price changes",
        "description": "Platform admins only. Cancels the price changes `applyPriceToSubscriptions` scheduled that have not taken effect yet, for every organisation (`target: { kind: 'all' }`) or the ones named: the schedule at the payment provider goes, the subscription keeps its current price, `settings/billing.pendingPriceChange` is removed, and both logs record it. `404 billing.no_price_change` when there is nothing to cancel. Needs an MFA session signed in within the last 5 minutes; on MCP a confirmation first.",
        "tags": ["scheduledPriceChanges"],
        "parameters": [
          {
            "name": "dryRun",
            "in": "query",
            "required": false,
            "schema": { "type": "boolean" },
            "description": "true: perform nothing and answer 200 { dryRun: true, operationId, summary } -- the impact summary, localised from Accept-Language. No confirmation token is needed for the real call."
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "target": {
                    "oneOf": [
                      {
                        "type": "object",
                        "properties": {
                          "kind": { "type": "string", "const": "all" }
                        },
                        "required": ["kind"],
                        "additionalProperties": false
                      },
                      {
                        "type": "object",
                        "properties": {
                          "kind": {
                            "type": "string",
                            "const": "organizations"
                          },
                          "organizationIds": {
                            "minItems": 1,
                            "maxItems": 100,
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                              "description": "A org identifier (TypeID, conventions C5)."
                            }
                          }
                        },
                        "required": ["kind", "organizationIds"],
                        "additionalProperties": false
                      }
                    ],
                    "description": "Every organisation with a running subscription on the plan (`all`), or the organisations named (at most 100)."
                  },
                  "note": { "type": "string", "minLength": 1, "maxLength": 500 }
                },
                "additionalProperties": false,
                "required": ["target"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Cancel scheduled price changes",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/cancelScheduledPriceChangesOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "billing.no_price_change",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "billing.provider_misconfigured, internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "503": {
            "description": "dependency.unavailable",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.billing.manage",
        "x-fv-side-effect": "destructive",
        "x-fv-events": ["billing.priceChangeCanceled"],
        "x-fv-mcp-tool": "fv_cancel_scheduled_price_changes",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/platform/pricing/prices/{planId}": {
      "patch": {
        "operationId": "updatePlanPrice",
        "summary": "Change a plan's list price",
        "description": "Platform admins only. Sets a plan's list price for one or both intervals, in EUR cents excl. VAT. A new price is created at the payment provider first and the previous one is archived for new sales; the price document then holds the new amount, the old one in its history, and `revision + 1`. The plan screen, `listPlans` and the website follow within minutes, without a deploy. **Running subscriptions keep their price.** An amount of 0 or less answers `422 pricing.amount_invalid`; an unreachable provider `503 dependency.unavailable`, with nothing written. Needs an `Idempotency-Key` and an MFA session signed in within the last 5 minutes.",
        "tags": ["planPrice"],
        "parameters": [
          {
            "name": "planId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "enum": ["free", "team", "enterprise", "internal", "tryout"]
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "intervals": {
                    "type": "object",
                    "properties": {
                      "monthly": {
                        "type": "object",
                        "properties": {
                          "amountCents": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991,
                            "description": "The new amount in EUR cents, excl. VAT; more than 0."
                          }
                        },
                        "required": ["amountCents"],
                        "additionalProperties": false
                      },
                      "yearly": {
                        "type": "object",
                        "properties": {
                          "amountCents": {
                            "type": "integer",
                            "minimum": -9007199254740991,
                            "maximum": 9007199254740991,
                            "description": "The new amount in EUR cents, excl. VAT; more than 0."
                          }
                        },
                        "required": ["amountCents"],
                        "additionalProperties": false
                      }
                    },
                    "additionalProperties": false
                  },
                  "note": {
                    "description": "Why the price changes; kept in the history and the log.",
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 500
                  }
                },
                "additionalProperties": false,
                "required": ["intervals"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Change a plan's list price",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/updatePlanPriceOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "pricing.amount_invalid, validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "billing.provider_misconfigured, internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "503": {
            "description": "dependency.unavailable",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.billing.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["pricing.changed"],
        "x-fv-mcp-tool": "fv_update_plan_price",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/platform/pricing/prices/{planId}/apply-to-subscriptions": {
      "post": {
        "operationId": "applyPriceToSubscriptions",
        "summary": "Apply a new price to existing subscriptions",
        "description": "Platform admins only. Moves running subscriptions of a plan (every one, or the organisations named) to the plan's list price, or to their own current price indexed by `indexPercent`, from each subscription's first renewal on or after `notBefore` (default: 90 days from now), without proration. An organisation's discount stays on the new price (the lowest-price rule). **`dryRun` defaults to true**: it lists, per organisation, the current and new amount (whole cents, EUR excl. VAT), what it will pay and the date, and writes nothing. With `dryRun: false` the change is scheduled at the payment provider, `settings/billing.pendingPriceChange` is set, the owners and admins get one e-mail, and both the organisation's log and the platform log record it. A `notBefore` less than 90 days away answers `422 pricing.notice_too_short` unless `force: true` with a `note`. `updatePlanPrice` alone never changes a running subscription. Needs an `Idempotency-Key` (a retry never makes a second schedule) and an MFA session signed in within the last 5 minutes.",
        "tags": ["priceToSubscriptions"],
        "parameters": [
          {
            "name": "planId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "enum": ["free", "team", "enterprise", "internal", "tryout"]
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "interval": {
                    "type": "string",
                    "enum": ["monthly", "yearly", "both"],
                    "description": "Which subscriptions: monthly, yearly or both."
                  },
                  "target": {
                    "oneOf": [
                      {
                        "type": "object",
                        "properties": {
                          "kind": { "type": "string", "const": "all" }
                        },
                        "required": ["kind"],
                        "additionalProperties": false
                      },
                      {
                        "type": "object",
                        "properties": {
                          "kind": {
                            "type": "string",
                            "const": "organizations"
                          },
                          "organizationIds": {
                            "minItems": 1,
                            "maxItems": 100,
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                              "description": "A org identifier (TypeID, conventions C5)."
                            }
                          }
                        },
                        "required": ["kind", "organizationIds"],
                        "additionalProperties": false
                      }
                    ],
                    "description": "Every organisation with a running subscription on the plan (`all`), or the organisations named (at most 100)."
                  },
                  "notBefore": {
                    "description": "The new price applies from each subscription's first renewal on or after this moment (RFC 3339 UTC). Default: now + 90 days; earlier needs `force`.",
                    "type": "string",
                    "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))$"
                  },
                  "indexPercent": {
                    "description": "Index each subscription's own current price by this percentage (rounded to whole cents) instead of applying the list price. The list price is left alone.",
                    "type": "number",
                    "exclusiveMinimum": 0,
                    "maximum": 100
                  },
                  "note": {
                    "description": "Why; kept on the platform log. Required with `force`.",
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 500
                  },
                  "dryRun": {
                    "default": true,
                    "description": "Only list what would change (the default). `false` applies it.",
                    "type": "boolean"
                  },
                  "force": {
                    "description": "Allow less than 90 days' notice (a platform override); needs a `note`.",
                    "type": "boolean"
                  }
                },
                "additionalProperties": false,
                "required": ["dryRun", "interval", "target"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Apply a new price to existing subscriptions",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/applyPriceToSubscriptionsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "pricing.notice_too_short, validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "billing.provider_misconfigured, internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "503": {
            "description": "dependency.unavailable",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.billing.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["billing.priceChangeScheduled"],
        "x-fv-mcp-tool": "fv_apply_price_to_subscriptions",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/platform/pricing/settings": {
      "patch": {
        "operationId": "updatePricingSettings",
        "summary": "Set the GA date and the marginal cost",
        "description": "Platform admins only. Sets `gaAt`, the moment Field-Viewer goes live (RFC 3339 UTC), or clears it with `null`. Nothing changes before that moment. Once it has passed, the daily billing tick gives every organisation from the beta its 30 days on Team at the list price (the same trial path and reminders as any organisation) and mails its owners and admins the GA notice. Also sets `marginalCostCents`, our marginal cost per organisation per month (EUR cents excl. VAT), which the backoffice shows next to a price; `null` clears it. A field left out stays as it is; setting the same values again changes nothing. Recorded in the platform log with the values before and after. Needs an MFA session signed in within the last 5 minutes.",
        "tags": ["pricingSettings"],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "gaAt": {
                    "description": "When Field-Viewer goes live, RFC 3339 UTC; null clears it. From then on every beta organisation gets its 30 days. Omit to leave it as it is.",
                    "anyOf": [
                      {
                        "type": "string",
                        "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))$"
                      },
                      { "type": "null" }
                    ]
                  },
                  "marginalCostCents": {
                    "description": "Our marginal cost per organisation per month, in EUR cents excl. VAT (more than 0); null clears it. Omit to leave it as it is.",
                    "anyOf": [
                      {
                        "type": "integer",
                        "exclusiveMinimum": 0,
                        "maximum": 9007199254740991
                      },
                      { "type": "null" }
                    ]
                  }
                },
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Set the GA date and the marginal cost",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/updatePricingSettingsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.billing.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["pricing.changed"],
        "x-fv-mcp-tool": "fv_update_pricing_settings",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/platform/runtime": {
      "patch": {
        "operationId": "updatePlatformRuntime",
        "summary": "Pause or resume new tryouts",
        "description": "Platform admins only. `tryoutsPaused: true` makes `createTryout` answer `503 processing.paused` with the tryout copy, while uploads by organisations keep working; `false` resumes. Every api instance follows within 60 seconds. Setting the current value changes nothing. The budget guard sets the same switch at its first production threshold. Needs an MFA session (`403 auth.mfa_required`). Fires `platform.runtime.updated`, recorded in the platform log.",
        "tags": ["platformRuntime"],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": { "tryoutsPaused": { "type": "boolean" } },
                "additionalProperties": false,
                "required": ["tryoutsPaused"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Pause or resume new tryouts",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/updatePlatformRuntimeOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.runtime.manage",
        "x-fv-side-effect": "write",
        "x-fv-events": ["platform.runtime.updated"],
        "x-fv-mcp-tool": "fv_update_platform_runtime",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/platform/tryout-stats": {
      "get": {
        "operationId": "getPlatformTryoutStats",
        "summary": "Get the tryout numbers for the platform cohort screen",
        "description": "Platform admins only. Tryouts created, cap refusals, conversions and research consents today (UTC) and over the last 7 days including today, with the estimated processing and storage cost (created times E15 §0.7's upper estimate per tryout), and whether tryouts are paused. Read live from the daily counters. Needs an MFA session (`403 auth.mfa_required`).",
        "tags": ["platformTryoutStats"],
        "responses": {
          "200": {
            "description": "Get the tryout numbers for the platform cohort screen",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getPlatformTryoutStatsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "platform.org.read",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_platform_tryout_stats",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/roles": {
      "get": {
        "operationId": "listRoles",
        "summary": "List the beta role catalogue",
        "description": "Lists every role in the beta capability catalogue (§2.3): owner, admin, publisher, member, guest and workstation, each with its rank and the full set of capabilities it holds. Static data -- the same table for every caller, not scoped to an organisation. Feeds `useCan()` and any UI that explains what a role can do (e.g. a role picker on the invite/manage-members screens, E02-S10/S14).",
        "tags": ["roles"],
        "parameters": [
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: rank | -rank.",
              "type": "string",
              "enum": ["rank", "-rank"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List the beta role catalogue",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/listRolesOutput" }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_roles",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/samples": {
      "get": {
        "operationId": "listSamples",
        "summary": "List Field-Viewer's sample models",
        "description": "Lists the synthetic sample models anyone can open without an account (`getSampleScene`), in the order the try page shows them: slug, name and audience line in the asked language, and a 24-hour signed URL of each model's card image. Public, no authentication.",
        "tags": ["samples"],
        "parameters": [
          {
            "name": "locale",
            "in": "query",
            "required": false,
            "schema": {
              "description": "The language of `name` and `audience` (nl, en or fr); the request's Accept-Language, else Dutch, when omitted.",
              "type": "string",
              "enum": ["nl", "en", "fr"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List Field-Viewer's sample models",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/listSamplesOutput" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "security": [],
        "x-fv-capability": "public",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_samples",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/samples/{slug}/scene": {
      "get": {
        "operationId": "getSampleScene",
        "summary": "Open a sample model's 3D scene",
        "description": "Returns the published 3D scene of one of Field-Viewer's synthetic sample models (the same shape as `getProjectScene`: per model a signed `manifest.json`, `geometry.frag` and, when the version has them, the spatial tree, elements, layers and openings), with `sample` (slug, name, audience line, card image). Public, no authentication. The URLs are valid for 24 hours and point at immutable artefacts. Only the configured samples can be opened: any other slug is `404 resource.not_found`. Nothing is written.",
        "tags": ["sampleScene"],
        "parameters": [
          {
            "name": "slug",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^[a-z0-9_]{1,64}$",
              "description": "The sample to open, e.g. `woning_lindehof` (as `listSamples` returns it)."
            }
          },
          {
            "name": "locale",
            "in": "query",
            "required": false,
            "schema": {
              "description": "The language of `name` and `audience` (nl, en or fr); the request's Accept-Language, else Dutch, when omitted.",
              "type": "string",
              "enum": ["nl", "en", "fr"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Open a sample model's 3D scene",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getSampleSceneOutput"
                }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "security": [],
        "x-fv-capability": "public",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_sample_scene",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/status": {
      "get": {
        "operationId": "getServiceStatus",
        "summary": "Get the API service status",
        "description": "Reports whether the Field-Viewer API is reachable and which build is currently serving traffic. Unauthenticated; safe to call as a first request before authenticating, or to poll from a status page.",
        "tags": ["serviceStatus"],
        "responses": {
          "200": {
            "description": "Get the API service status",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/getServiceStatusOutput"
                }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "security": [],
        "x-fv-capability": "public",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_get_service_status",
        "x-fv-rate-limit-class": "read",
        "x-fv-anonymous-access": true
      }
    },
    "/v1/telemetry-batches": {
      "post": {
        "operationId": "createTelemetryBatch",
        "summary": "Send a batch of client logs, errors and web-vitals",
        "description": "Accepts a batch of browser telemetry -- `log` lines, `error`s and `web_vital` measurements (CLS, LCP, INP) -- and writes each event as one redacted `logType=\"client\"` log line. Nothing is stored in the database and no event is emitted. Send at most 50 events and 16 KB per batch (larger is `422 telemetry.batch_too_large`, nothing written) and at most 60 batches per hour (`429 rate_limit.exceeded` with `Retry-After` after that). Use a fresh UUID per batch as the `Idempotency-Key`: replaying the same batch within 24 h is a no-op `202`. The client is never trusted: every event is redacted again server-side. A `log` event named `analytics.<name>` is a product-analytics event: it becomes a `logType=\"analytics\"` line only when `<name>` is catalogued, its `attributes` pass that entry's schema, the caller has not switched analytics off (`preferences.analyticsOptOut`) and its organisation (`attributes.orgId`, which the caller must belong to) has `settings.analytics.mode` enabled; otherwise it is dropped and not counted in `accepted`.",
        "tags": ["telemetryBatch"],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "events": {
                    "minItems": 1,
                    "type": "array",
                    "items": {
                      "oneOf": [
                        {
                          "type": "object",
                          "properties": {
                            "kind": { "type": "string", "const": "log" },
                            "at": {
                              "type": "string",
                              "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))$"
                            },
                            "level": {
                              "type": "string",
                              "enum": ["debug", "info", "warn", "error"]
                            },
                            "event": {
                              "type": "string",
                              "maxLength": 80,
                              "pattern": "^[a-z][a-z0-9_]*(\\.[a-z0-9_]+)*$"
                            },
                            "message": { "type": "string", "maxLength": 500 },
                            "route": { "type": "string", "maxLength": 200 },
                            "attributes": {
                              "description": "Flat facts about the event (ids, codes, counts). Denylisted keys are redacted server-side.",
                              "type": "object",
                              "propertyNames": {
                                "type": "string",
                                "maxLength": 64
                              },
                              "additionalProperties": {
                                "anyOf": [
                                  { "type": "string", "maxLength": 200 },
                                  { "type": "number" },
                                  { "type": "boolean" },
                                  { "type": "null" }
                                ]
                              }
                            }
                          },
                          "required": ["kind", "at", "level", "event"],
                          "additionalProperties": false
                        },
                        {
                          "type": "object",
                          "properties": {
                            "kind": { "type": "string", "const": "web_vital" },
                            "at": {
                              "type": "string",
                              "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))$"
                            },
                            "name": {
                              "type": "string",
                              "enum": ["CLS", "LCP", "INP"]
                            },
                            "value": { "type": "number", "minimum": 0 },
                            "rating": {
                              "type": "string",
                              "enum": ["good", "needs-improvement", "poor"]
                            },
                            "route": { "type": "string", "maxLength": 200 }
                          },
                          "required": ["kind", "at", "name", "value", "rating"],
                          "additionalProperties": false
                        },
                        {
                          "type": "object",
                          "properties": {
                            "kind": { "type": "string", "const": "error" },
                            "at": {
                              "type": "string",
                              "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))$"
                            },
                            "name": { "type": "string", "maxLength": 100 },
                            "message": { "type": "string", "maxLength": 500 },
                            "stack": { "type": "string", "maxLength": 4000 },
                            "route": { "type": "string", "maxLength": 200 }
                          },
                          "required": ["kind", "at", "name", "message"],
                          "additionalProperties": false
                        }
                      ]
                    }
                  },
                  "appVersion": {
                    "description": "The web build's git sha, when known.",
                    "type": "string",
                    "maxLength": 64
                  }
                },
                "additionalProperties": false,
                "required": ["events"]
              }
            }
          }
        },
        "responses": {
          "202": {
            "description": "Send a batch of client logs, errors and web-vitals",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/createTelemetryBatchOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "telemetry.batch_too_large, validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "authenticated",
        "x-fv-side-effect": "write",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_create_telemetry_batch",
        "x-fv-rate-limit-class": "write",
        "x-fv-anonymous-access": true
      }
    },
    "/v1/tryouts": {
      "post": {
        "operationId": "createTryout",
        "summary": "Start a tryout: an IFC and drawings, viewed free for 7 days",
        "description": "Creates a tryout for the caller: an organisation with `kind: tryout` on the `tryout` plan (expires 7 days from now, never extended), its project and model, the IFC's first revision (published automatically once ready) and that revision's resumable upload ticket (conventions C13), all in one transaction. FV-745: a tryout takes 0-1 IFC and 0-n drawings (`drawings`: PDF, DXF or DWG, n = the tryout plan's `maxDocumentsPerProject`), one file at least; each drawing becomes a document with its own upload ticket (`drawings` in the response), published automatically once ready. Too many drawings, or one above the plan's `maxDocumentFileBytes`, is `403 entitlement.limit_reached`; a DXF or DWG while CAD drawings are off, or above its format's ceiling, `422 validation.failed`. The daily cap counts processor jobs, one per file. Also returns the single-use `claimToken` (only its hash is stored). Caps (BR-5): 3 active tryouts and 5 a day per visitor and 20 a day per network (`403 tryout.limit_reached`), and a global daily cap (`429 tryout.daily_cap_reached`, `Retry-After` to midnight UTC). `sizeBytes` above the tryout plan's `maxModelFileBytes` is `403 entitlement.limit_reached`. An App Check token is always required. Open to an anonymous session; no demo projects are added. Fires `organization.created`, `member.joined`, `project.created`, `model.created`, `model.version.created` and `tryout.created`.",
        "tags": ["tryout"],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "fileName": {
                    "description": "The IFC's file name (.ifc or .ifczip). Omit, with sizeBytes and contentType, for a tryout of drawings only.",
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": {
                    "description": "The IFC file's MIME type, e.g. application/octet-stream.",
                    "type": "string",
                    "minLength": 1
                  },
                  "drawings": {
                    "maxItems": 20,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "fileName": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 255,
                          "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                        },
                        "sizeBytes": {
                          "type": "integer",
                          "minimum": 1,
                          "maximum": 1073741824,
                          "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                        },
                        "contentType": {
                          "type": "string",
                          "minLength": 1,
                          "description": "The drawing's MIME type: application/pdf, or whatever the browser reports for a DXF or DWG."
                        }
                      },
                      "required": ["fileName", "sizeBytes", "contentType"],
                      "additionalProperties": false
                    },
                    "description": "The drawings (PDF, DXF or DWG), up to the tryout plan's maxDocumentsPerProject."
                  },
                  "locale": {
                    "type": "string",
                    "enum": ["nl", "en", "fr"],
                    "description": "The visitor's language (nl, en or fr)."
                  },
                  "source": {
                    "type": "object",
                    "properties": {
                      "page": {
                        "type": "string",
                        "enum": ["site_try", "direct", "mail"],
                        "description": "Where the visitor started: site_try (the try page on field-viewer.com), direct (/try opened directly) or mail."
                      },
                      "utm": {
                        "description": "The campaign parameters of the try page, if any.",
                        "type": "object",
                        "properties": {
                          "source": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 100
                          },
                          "medium": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 100
                          },
                          "campaign": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 100
                          },
                          "term": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 100
                          },
                          "content": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 100
                          }
                        },
                        "additionalProperties": false
                      }
                    },
                    "required": ["page"],
                    "additionalProperties": false
                  }
                },
                "additionalProperties": false,
                "required": ["locale", "source"]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Start a tryout: an IFC and drawings, viewed free for 7 days",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/createTryoutOutput" }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "entitlement.limit_reached, permission.denied, tryout.limit_reached",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "429": {
            "description": "tryout.daily_cap_reached",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "503": {
            "description": "processing.paused",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "write",
        "x-fv-events": [
          "organization.created",
          "member.joined",
          "project.created",
          "model.created",
          "model.version.created",
          "document.created",
          "document.version.created",
          "tryout.created"
        ],
        "x-fv-mcp-tool": "fv_create_tryout",
        "x-fv-rate-limit-class": "heavy",
        "x-fv-anonymous-access": true,
        "x-fv-app-check": "required"
      }
    },
    "/v1/tryouts/claim": {
      "post": {
        "operationId": "claimTryout",
        "summary": "Keep a tryout in the caller's existing account",
        "description": "Moves a tryout into the caller's account and keeps it as an ordinary organisation on the free plan, under `organizationName`. The tryout's single-use claim token travels in the `X-Tryout-Claim-Token` header. In one transaction the caller becomes the owner, the tryout's anonymous owner is removed and the organisation is converted as `convertTryout` does; every project, model and artefact stays where it is, and the token is used up. A wrong, used or expired token is `403 tryout.claim_token_invalid` and changes nothing. The caller must be signed in (not anonymous) with a verified e-mail. Fires `tryout.claimed`, `organization.ownershipTransferred`, `member.joined`, `member.removed`, `tryout.converted`, `organization.updated`, `organization.entitlements.updated` and `organization.legalAccepted`.",
        "tags": ["tryout"],
        "parameters": [
          {
            "name": "X-Tryout-Claim-Token",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^[0-9a-f]{64}$",
              "description": "The claim token `createTryout` returned. Sent as the `X-Tryout-Claim-Token` header."
            },
            "x-fv-input": "claimToken"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "organizationId": {
                    "type": "string",
                    "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A org identifier (TypeID, conventions C5)."
                  },
                  "organizationName": {
                    "type": "string",
                    "minLength": 2,
                    "maxLength": 80,
                    "description": "Organisation display name (2-80 chars after trimming, BR-10)."
                  },
                  "locale": {
                    "type": "string",
                    "enum": ["nl", "en", "fr"],
                    "description": "The organisation's default language (nl, en or fr)."
                  },
                  "legalAcceptance": {
                    "type": "object",
                    "properties": {
                      "termsVersion": {
                        "type": "string",
                        "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                        "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
                      },
                      "privacyVersion": {
                        "type": "string",
                        "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                        "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
                      },
                      "dpaVersion": {
                        "type": "string",
                        "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                        "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
                      },
                      "subprocessorsVersion": {
                        "type": "string",
                        "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                        "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
                      }
                    },
                    "required": [
                      "termsVersion",
                      "privacyVersion",
                      "dpaVersion",
                      "subprocessorsVersion"
                    ],
                    "additionalProperties": false,
                    "description": "The current terms, privacy notice, DPA and sub-processor list versions the caller accepts for the organisation (from the legal documents list). Required."
                  }
                },
                "additionalProperties": false,
                "required": [
                  "legalAcceptance",
                  "locale",
                  "organizationId",
                  "organizationName"
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Keep a tryout in the caller's existing account",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": { "$ref": "#/components/schemas/claimTryoutOutput" }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "auth.email_not_verified, permission.denied, tryout.claim_token_invalid",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state, legal.version_outdated",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "write",
        "x-fv-events": [
          "tryout.claimed",
          "organization.ownershipTransferred",
          "member.joined",
          "member.removed",
          "tryout.converted",
          "organization.updated",
          "organization.entitlements.updated",
          "organization.legalAccepted"
        ],
        "x-fv-mcp-tool": "fv_claim_tryout",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/users/me/beta-access:redeem": {
      "post": {
        "operationId": "redeemBetaAccessCode",
        "summary": "Redeem a beta access code",
        "description": "Redeems a beta access code bound to the caller's own (lower-cased) e-mail address. On success, unlocks creating the caller's first organisation (`OrgCreationPolicy`, E03-S02) -- an existing customer with at least one active Membership never needs to call this at all (BR-1). Calling this again after a successful redemption returns the same grant, unchanged (C11 natural idempotency). Fails `403 auth.email_not_verified` for an unverified caller, or `403 beta_access.invalid_code` for any reason the code does not redeem -- deliberately generic, so a caller can never learn whether a code exists for another e-mail address. Fails `409 conflict.state` if the caller has no profile yet (FV-296) -- call `updateMe` first. Fires `betaAccessCode.redeemed`.",
        "tags": ["betaAccessCode"],
        "deprecated": true,
        "x-sunset": "2026-12-10",
        "x-fv-deprecation": {
          "since": "2026-11-10",
          "replacement": "createOrganization"
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "code": {
                    "type": "string",
                    "pattern": "^[23456789ABCDEFGHJKLMNPQRSTUVWXYZ]{10}$",
                    "description": "10-character opaque code, unambiguous alphabet (no 0/O/1/I)."
                  }
                },
                "additionalProperties": false,
                "required": ["code"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Redeem a beta access code",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/redeemBetaAccessCodeOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "auth.email_not_verified, beta_access.invalid_code, permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "409": {
            "description": "conflict.state",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "write",
        "x-fv-events": ["betaAccessCode.redeemed"],
        "x-fv-mcp-tool": "fv_redeem_beta_access_code",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/users/me/invitations": {
      "get": {
        "operationId": "listMyInvitations",
        "summary": "List the invitations addressed to the current user",
        "description": "Lists the pending, unexpired e-mail invitations addressed to the caller's own verified account e-mail, newest first, one per organisation, at most 20: organisation name, role, projects (guest invitations), expiry and the inviter's display name. Organisations the caller already belongs to, or that are pending deletion, are left out. An account whose e-mail is not verified gets `{ data: [] }`. Never returns token material; accept one with `acceptMyInvitation`.",
        "tags": ["myInvitations"],
        "responses": {
          "200": {
            "description": "List the invitations addressed to the current user",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/listMyInvitationsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_my_invitations",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/users/me/invitations/{invitationId}/accept": {
      "post": {
        "operationId": "acceptMyInvitation",
        "summary": "Accept an invitation addressed to the current user",
        "description": "Accepts a pending e-mail invitation by its id, without the link's token, when it is addressed to the caller's own verified account e-mail (any role). Same effects as `acceptInvitation`: a new membership takes a seat or guest slot (`403 entitlement.limit_reached` when the plan is full -- nothing is written), an existing active membership keeps its role and only gains the invitation's projects. `404 resource.not_found` for an unknown, expired, revoked or accepted invitation, a join link, an unverified account, or an invitation addressed to another e-mail -- deliberately without saying which. Fires `invitation.accepted`, `member.joined` (new or reactivated membership) and `project.member.added` per project.",
        "tags": ["myInvitation"],
        "parameters": [
          {
            "name": "invitationId",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^inv_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "The invitation's id, as `listMyInvitations` returned it."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "organizationId": {
                    "type": "string",
                    "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "The organisation the invitation belongs to."
                  }
                },
                "additionalProperties": false,
                "required": ["organizationId"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Accept an invitation addressed to the current user",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" },
              "ETag": { "$ref": "#/components/headers/ETag" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/acceptMyInvitationOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "entitlement.limit_reached, permission.denied",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "write",
        "x-fv-events": [
          "invitation.accepted",
          "member.joined",
          "project.member.added"
        ],
        "x-fv-mcp-tool": "fv_accept_my_invitation",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/users/me/notifications": {
      "get": {
        "operationId": "listMyNotifications",
        "summary": "List the current user's notifications",
        "description": "Lists the caller's own in-app notifications, newest first (BR-12: at most the newest 50; each expires 90 days after it was created). Today these say that a model version the caller can upload or publish finished processing (`processing_ready`) or failed (`processing_failed`); `linkPath` opens that version. A notification without `readAt` is unread. A user with no notifications gets `{ data: [] }`.",
        "tags": ["myNotifications"],
        "parameters": [
          {
            "name": "cursor",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Opaque pagination cursor from a previous page's nextCursor.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "fields",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Comma-separated top-level field names to project. 'id' is always included.",
              "type": "string",
              "minLength": 1
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
              "type": "integer",
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "name": "sort",
            "in": "query",
            "required": false,
            "schema": {
              "description": "Sort order: -createdAt.",
              "type": "string",
              "enum": ["-createdAt"]
            }
          }
        ],
        "responses": {
          "200": {
            "description": "List the current user's notifications",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/listMyNotificationsOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "read",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_list_my_notifications",
        "x-fv-rate-limit-class": "read"
      }
    },
    "/v1/users/me/notifications/{id}/read": {
      "post": {
        "operationId": "markNotificationRead",
        "summary": "Mark one of the current user's notifications as read",
        "description": "Sets `readAt` on one of the caller's own notifications and returns it. Marking a notification that is already read returns it unchanged. Fails `404 resource.not_found` for an unknown id, including another user's notification.",
        "tags": ["notificationRead"],
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "pattern": "^ntf_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ntf identifier (TypeID, conventions C5)."
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Mark one of the current user's notifications as read",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/markNotificationReadOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required, auth.credentials_invalid, auth.credentials_missing",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "permission.denied, permission.scope_insufficient",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "404": {
            "description": "resource.not_found",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "x-fv-capability": "self",
        "x-fv-side-effect": "write",
        "x-fv-events": [],
        "x-fv-mcp-tool": "fv_mark_notification_read",
        "x-fv-rate-limit-class": "write"
      }
    },
    "/v1/workstation-pairings/claim": {
      "post": {
        "operationId": "claimWorkstationPairing",
        "summary": "Pair this device as a workstation",
        "description": "Exchanges a pairing code from `createWorkstationPairingCode` for a Firebase custom token the device signs in with (`signInWithCustomToken`). The workstation becomes `active`; a device paired earlier is signed out (one device per workstation). Refuses `403 workstation.pairing_code_invalid` for an unknown, expired, used or replaced code -- always the same code -- and `429 rate_limit.exceeded` after 10 failed claims from one IP within 15 minutes. Fires `workstation.paired`.",
        "tags": ["workstationPairing"],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1, "maxLength": 32 }
                },
                "additionalProperties": false,
                "required": ["code"]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Pair this device as a workstation",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/claimWorkstationPairingOutput"
                }
              }
            }
          },
          "401": {
            "description": "auth.app_check_required",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "403": {
            "description": "workstation.pairing_code_invalid",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "422": {
            "description": "validation.failed",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "429": {
            "description": "rate_limit.exceeded",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          },
          "500": {
            "description": "internal.error",
            "headers": {
              "X-Request-Id": { "$ref": "#/components/headers/XRequestId" },
              "X-Build-Id": { "$ref": "#/components/headers/XBuildId" }
            },
            "content": {
              "application/problem+json": {
                "schema": { "$ref": "#/components/schemas/Problem" }
              }
            }
          }
        },
        "security": [],
        "x-fv-capability": "public",
        "x-fv-side-effect": "write",
        "x-fv-events": ["workstation.paired"],
        "x-fv-mcp-tool": "fv_claim_workstation_pairing",
        "x-fv-rate-limit-class": "auth"
      }
    }
  },
  "components": {
    "schemas": {
      "Problem": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "type": { "type": "string" },
          "title": { "type": "string" },
          "status": {
            "type": "integer",
            "minimum": -9007199254740991,
            "maximum": 9007199254740991
          },
          "detail": { "type": "string" },
          "instance": { "type": "string" },
          "code": { "type": "string" },
          "requestId": { "type": "string" },
          "errors": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "pointer": { "type": "string" },
                "code": { "type": "string" },
                "message": { "type": "string" }
              },
              "required": ["pointer", "code", "message"],
              "additionalProperties": false
            }
          },
          "retryAfterSeconds": { "type": "number" }
        },
        "required": [
          "type",
          "title",
          "status",
          "detail",
          "instance",
          "code",
          "requestId"
        ],
        "additionalProperties": false
      },
      "acceptInvitationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "token": {
            "type": "string",
            "minLength": 1,
            "description": "The raw accept token from the invitation link, in the JSON body (never in the URL)."
          }
        },
        "required": ["token"],
        "additionalProperties": false
      },
      "acceptInvitationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^inv_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A inv identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "kind": { "type": "string", "enum": ["email", "link"] },
          "role": {
            "type": "string",
            "enum": ["admin", "publisher", "member", "guest"]
          },
          "projectIds": {
            "maxItems": 10,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          "email": {
            "type": "string",
            "maxLength": 254,
            "format": "email",
            "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
          },
          "status": {
            "type": "string",
            "enum": ["pending", "accepted", "revoked", "expired", "exhausted"]
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "maxUses": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 250
          },
          "useCount": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "resendCount": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "lastSentAt": {
            "type": "string",
            "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))$"
          },
          "locale": { "type": "string", "enum": ["nl", "en", "fr"] },
          "acceptedBy": {
            "maxItems": 250,
            "type": "array",
            "items": { "type": "string", "minLength": 1 }
          },
          "acceptedAt": {
            "type": "string",
            "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))$"
          },
          "acceptedEmail": { "type": "string" },
          "revokedBy": { "type": "string", "minLength": 1 },
          "revokedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "alreadyMember": {
            "type": "boolean",
            "description": "True when the caller was already an active member: nothing was created and no seat used."
          }
        },
        "required": [
          "id",
          "organizationId",
          "kind",
          "role",
          "projectIds",
          "status",
          "expiresAt",
          "useCount",
          "resendCount",
          "locale",
          "acceptedBy",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy",
          "alreadyMember"
        ],
        "additionalProperties": false
      },
      "acceptLegalDocumentsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "termsVersion": {
            "type": "string",
            "pattern": "^\\d{1,3}\\.\\d{1,3}$",
            "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
          },
          "privacyVersion": {
            "type": "string",
            "pattern": "^\\d{1,3}\\.\\d{1,3}$",
            "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
          },
          "dpaVersion": {
            "type": "string",
            "pattern": "^\\d{1,3}\\.\\d{1,3}$",
            "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
          },
          "subprocessorsVersion": {
            "type": "string",
            "pattern": "^\\d{1,3}\\.\\d{1,3}$",
            "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": [
          "termsVersion",
          "privacyVersion",
          "dpaVersion",
          "subprocessorsVersion",
          "organizationId"
        ],
        "additionalProperties": false
      },
      "acceptLegalDocumentsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 2,
            "maxLength": 80,
            "description": "Organisation display name (2-80 chars after trimming, BR-10)."
          },
          "defaultLocale": {
            "type": "string",
            "enum": ["nl", "en", "fr"],
            "description": "The organisation's default UI locale, one of nl | en | fr."
          },
          "status": {
            "type": "string",
            "enum": ["active", "pending_deletion"]
          },
          "deletion": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "purgeAfter": {
                "type": "string",
                "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))$"
              },
              "cancelledAt": {
                "type": "string",
                "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))$"
              },
              "purgeStartedAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["requestedAt", "requestedBy", "purgeAfter"],
            "additionalProperties": false
          },
          "supportAccess": {
            "description": "Whether Field-Viewer support may open a read-only support session: allowed (default when absent; owners are e-mailed) or ask (an owner approves each request first).",
            "type": "string",
            "enum": ["allowed", "ask"]
          },
          "settings": {
            "type": "object",
            "properties": {
              "analytics": {
                "type": "object",
                "properties": {
                  "mode": {
                    "type": "string",
                    "enum": ["enabled", "disabled"],
                    "description": "Product analytics for every member: enabled (the default) or disabled. Disabled, no usage event is recorded for anyone in the organisation."
                  }
                },
                "required": ["mode"],
                "additionalProperties": false
              },
              "cad": {
                "type": "object",
                "properties": {
                  "producerDetailTags": {
                    "type": "object",
                    "properties": {
                      "scale": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's scale text (1:n)."
                      },
                      "xFactor": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's x factor (1/n)."
                      },
                      "yFactor": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's y factor (1/n)."
                      },
                      "xMin": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's minimum x."
                      },
                      "yMin": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's minimum y."
                      },
                      "xMax": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's maximum x."
                      },
                      "yMax": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's maximum y."
                      }
                    },
                    "required": [
                      "scale",
                      "xFactor",
                      "yFactor",
                      "xMin",
                      "yMin",
                      "xMax",
                      "yMax"
                    ],
                    "additionalProperties": false,
                    "description": "The CAD producer's detail attribute tags: all seven, each the tag (not the value) of one block attribute. With them, scaled details in model space measure in real millimetres at their own scale; without them they read 'scale unknown'."
                  }
                },
                "additionalProperties": false
              }
            },
            "additionalProperties": false
          },
          "legal": {
            "type": "object",
            "properties": {
              "termsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "privacyVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "dpaVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "subprocessorsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "acceptedAt": {
                "type": "string",
                "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))$"
              },
              "acceptedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              }
            },
            "required": [
              "termsVersion",
              "privacyVersion",
              "dpaVersion",
              "subprocessorsVersion",
              "acceptedAt",
              "acceptedBy"
            ],
            "additionalProperties": false,
            "description": "The terms, privacy notice, DPA and sub-processor list versions an owner accepted for the organisation."
          },
          "kind": {
            "description": "standard (default when absent) or tryout: an anonymous visitor's 7-day try-it organisation.",
            "type": "string",
            "enum": ["standard", "tryout"]
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "logoUrl": {
            "type": "object",
            "properties": {
              "url": { "type": "string" },
              "expiresAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["url", "expiresAt"],
            "additionalProperties": false,
            "description": "Signed URL of the organisation's logo (15 minutes). Absent when it has no logo."
          },
          "reacceptanceRequired": {
            "description": "True when an owner must accept a newer material version of the terms, the DPA or the sub-processor list (or never accepted them).",
            "type": "boolean"
          }
        },
        "required": [
          "id",
          "name",
          "defaultLocale",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "acceptLinkDiscoveryRunInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "runId": {
            "type": "string",
            "pattern": "^ldr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ldr identifier (TypeID, conventions C5)."
          },
          "strategyIndexes": {
            "minItems": 1,
            "maxItems": 10,
            "type": "array",
            "items": {
              "type": "integer",
              "minimum": 0,
              "maximum": 9007199254740991
            },
            "description": "Indexes into result.strategies to accept, usually result.recommended (e.g. [0])."
          }
        },
        "required": ["organizationId", "projectId", "runId", "strategyIndexes"],
        "additionalProperties": false
      },
      "acceptLinkDiscoveryRunOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "run": {
            "type": "object",
            "properties": {
              "schemaVersion": { "type": "number", "const": 1 },
              "id": {
                "type": "string",
                "pattern": "^ldr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A ldr identifier (TypeID, conventions C5)."
              },
              "organizationId": {
                "type": "string",
                "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A org identifier (TypeID, conventions C5)."
              },
              "projectId": {
                "type": "string",
                "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A prj identifier (TypeID, conventions C5)."
              },
              "status": {
                "type": "string",
                "enum": ["running", "done", "failed"]
              },
              "trigger": {
                "type": "string",
                "enum": ["manual", "upload_batch"]
              },
              "scope": {
                "type": "object",
                "properties": {
                  "documentIds": {
                    "minItems": 1,
                    "maxItems": 500,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A doc identifier (TypeID, conventions C5)."
                    }
                  },
                  "modelIds": {
                    "minItems": 1,
                    "maxItems": 4,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A mdl identifier (TypeID, conventions C5)."
                    }
                  }
                },
                "additionalProperties": false
              },
              "result": {
                "type": "object",
                "properties": {
                  "evaluatedDocuments": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "evaluatedElements": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "truncated": { "type": "boolean" },
                  "strategies": {
                    "maxItems": 20,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "strategy": {
                          "type": "string",
                          "enum": [
                            "file_name",
                            "layout_name",
                            "title_block_attribute",
                            "sheet_text",
                            "model_property",
                            "sheet_number"
                          ]
                        },
                        "ruleDraft": {
                          "type": "object",
                          "properties": {
                            "matchModel": {
                              "type": "object",
                              "properties": {
                                "field": {
                                  "type": "string",
                                  "enum": [
                                    "tag",
                                    "assemblyMark",
                                    "storeyName",
                                    "name",
                                    "property"
                                  ]
                                },
                                "property": {
                                  "type": "object",
                                  "properties": {
                                    "set": {
                                      "type": "string",
                                      "minLength": 1,
                                      "maxLength": 128,
                                      "description": "Property set, e.g. Pset_Panel."
                                    },
                                    "name": {
                                      "type": "string",
                                      "minLength": 1,
                                      "maxLength": 128,
                                      "description": "Property name, e.g. Drawing."
                                    }
                                  },
                                  "required": ["set", "name"],
                                  "additionalProperties": false
                                }
                              },
                              "required": ["field"],
                              "additionalProperties": false
                            },
                            "matchDocument": {
                              "type": "object",
                              "properties": {
                                "field": {
                                  "type": "string",
                                  "enum": [
                                    "fileName",
                                    "sheetNumber",
                                    "outlineTitle",
                                    "titleBlock",
                                    "layoutName",
                                    "blockAttribute",
                                    "sheetText"
                                  ]
                                },
                                "attributeTag": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 128
                                }
                              },
                              "required": ["field"],
                              "additionalProperties": false
                            },
                            "normalization": {
                              "type": "object",
                              "properties": {
                                "caseInsensitive": { "type": "boolean" },
                                "stripWhitespace": { "type": "boolean" },
                                "stripLeadingZeros": { "type": "boolean" },
                                "regex": {
                                  "type": "string",
                                  "description": "Regular expression applied to both sides after the other normalisation steps: a value that does not match is ignored, otherwise the match (or its named group `key`) is the value compared, e.g. W-\\d{3} (max 200 chars; no backreferences or nested repeats)."
                                }
                              },
                              "required": [
                                "caseInsensitive",
                                "stripWhitespace",
                                "stripLeadingZeros"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "required": [
                            "matchModel",
                            "matchDocument",
                            "normalization"
                          ],
                          "additionalProperties": false
                        },
                        "score": {
                          "type": "number",
                          "minimum": 0,
                          "maximum": 1
                        },
                        "coverage": {
                          "type": "number",
                          "minimum": 0,
                          "maximum": 1
                        },
                        "matched": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "ambiguous": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "unmatchedDocuments": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "unmatchedElements": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "sampleMatches": {
                          "maxItems": 10,
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "documentId": {
                                "type": "string",
                                "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                "description": "A doc identifier (TypeID, conventions C5)."
                              },
                              "page": {
                                "type": "integer",
                                "exclusiveMinimum": 0,
                                "maximum": 9007199254740991
                              },
                              "key": { "type": "string" },
                              "source": {
                                "oneOf": [
                                  {
                                    "type": "object",
                                    "properties": {
                                      "kind": {
                                        "type": "string",
                                        "const": "element"
                                      },
                                      "modelId": {
                                        "type": "string",
                                        "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                        "description": "A mdl identifier (TypeID, conventions C5)."
                                      },
                                      "globalId": {
                                        "type": "string",
                                        "minLength": 1
                                      }
                                    },
                                    "required": ["kind", "modelId", "globalId"],
                                    "additionalProperties": false
                                  },
                                  {
                                    "type": "object",
                                    "properties": {
                                      "kind": {
                                        "type": "string",
                                        "const": "assembly"
                                      },
                                      "modelId": {
                                        "type": "string",
                                        "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                        "description": "A mdl identifier (TypeID, conventions C5)."
                                      },
                                      "assemblyMark": {
                                        "type": "string",
                                        "minLength": 1
                                      }
                                    },
                                    "required": [
                                      "kind",
                                      "modelId",
                                      "assemblyMark"
                                    ],
                                    "additionalProperties": false
                                  },
                                  {
                                    "type": "object",
                                    "properties": {
                                      "kind": {
                                        "type": "string",
                                        "const": "storey"
                                      },
                                      "modelId": {
                                        "type": "string",
                                        "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                        "description": "A mdl identifier (TypeID, conventions C5)."
                                      },
                                      "storeyId": {
                                        "type": "string",
                                        "minLength": 1
                                      }
                                    },
                                    "required": ["kind", "modelId", "storeyId"],
                                    "additionalProperties": false
                                  }
                                ]
                              }
                            },
                            "required": ["documentId", "page", "key", "source"],
                            "additionalProperties": false
                          }
                        },
                        "ambiguousSamples": {
                          "maxItems": 10,
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "key": { "type": "string" },
                              "documentIds": {
                                "minItems": 2,
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                  "description": "A doc identifier (TypeID, conventions C5)."
                                }
                              }
                            },
                            "required": ["key", "documentIds"],
                            "additionalProperties": false
                          }
                        }
                      },
                      "required": [
                        "strategy",
                        "ruleDraft",
                        "score",
                        "coverage",
                        "matched",
                        "ambiguous",
                        "unmatchedDocuments",
                        "unmatchedElements",
                        "sampleMatches",
                        "ambiguousSamples"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "recommended": {
                    "type": "array",
                    "items": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "panels": {
                    "type": "object",
                    "properties": {
                      "total": {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 9007199254740991
                      },
                      "linkable": {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 9007199254740991
                      }
                    },
                    "required": ["total", "linkable"],
                    "additionalProperties": false
                  },
                  "skipped": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "strategy": {
                          "type": "string",
                          "enum": [
                            "file_name",
                            "layout_name",
                            "title_block_attribute",
                            "sheet_text",
                            "model_property",
                            "sheet_number"
                          ]
                        },
                        "reason": {
                          "type": "string",
                          "enum": ["model_index_missing", "no_keys"]
                        }
                      },
                      "required": ["strategy", "reason"],
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "evaluatedDocuments",
                  "evaluatedElements",
                  "strategies",
                  "recommended"
                ],
                "additionalProperties": false
              },
              "acceptedAt": {
                "type": "string",
                "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))$"
              },
              "acceptedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              },
              "acceptedRuleIds": {
                "type": "array",
                "items": {
                  "type": "string",
                  "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A lkr identifier (TypeID, conventions C5)."
                }
              },
              "acceptRunIds": {
                "type": "array",
                "items": {
                  "type": "string",
                  "pattern": "^lrr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A lrr identifier (TypeID, conventions C5)."
                }
              },
              "error": {
                "type": "object",
                "properties": {
                  "code": {
                    "type": "string",
                    "enum": ["discovery_timeout", "discovery_failed"]
                  },
                  "message": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "message"],
                "additionalProperties": false
              },
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              },
              "completedAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": [
              "schemaVersion",
              "id",
              "organizationId",
              "projectId",
              "status",
              "trigger",
              "scope",
              "requestedAt",
              "requestedBy"
            ],
            "additionalProperties": false
          },
          "rules": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A lkr identifier (TypeID, conventions C5)."
                },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "projectId": {
                  "type": "string",
                  "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A prj identifier (TypeID, conventions C5)."
                },
                "name": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 100,
                  "description": "Rule name, 1-100 chars after trimming."
                },
                "enabled": { "type": "boolean" },
                "priority": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 1000
                },
                "matchModel": {
                  "type": "object",
                  "properties": {
                    "field": {
                      "type": "string",
                      "enum": [
                        "tag",
                        "assemblyMark",
                        "storeyName",
                        "name",
                        "property"
                      ]
                    },
                    "property": {
                      "type": "object",
                      "properties": {
                        "set": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 128,
                          "description": "Property set, e.g. Pset_Panel."
                        },
                        "name": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 128,
                          "description": "Property name, e.g. Drawing."
                        }
                      },
                      "required": ["set", "name"],
                      "additionalProperties": false
                    }
                  },
                  "required": ["field"],
                  "additionalProperties": false
                },
                "matchDocument": {
                  "type": "object",
                  "properties": {
                    "field": {
                      "type": "string",
                      "enum": [
                        "fileName",
                        "sheetNumber",
                        "outlineTitle",
                        "titleBlock",
                        "layoutName",
                        "blockAttribute",
                        "sheetText"
                      ]
                    },
                    "attributeTag": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "required": ["field"],
                  "additionalProperties": false
                },
                "normalization": {
                  "type": "object",
                  "properties": {
                    "caseInsensitive": { "type": "boolean" },
                    "stripWhitespace": { "type": "boolean" },
                    "stripLeadingZeros": { "type": "boolean" },
                    "regex": {
                      "type": "string",
                      "description": "Regular expression applied to both sides after the other normalisation steps: a value that does not match is ignored, otherwise the match (or its named group `key`) is the value compared, e.g. W-\\d{3} (max 200 chars; no backreferences or nested repeats)."
                    }
                  },
                  "required": [
                    "caseInsensitive",
                    "stripWhitespace",
                    "stripLeadingZeros"
                  ],
                  "additionalProperties": false
                },
                "autoApply": { "type": "boolean" },
                "discoveryRunId": {
                  "type": "string",
                  "pattern": "^ldr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A ldr identifier (TypeID, conventions C5)."
                },
                "ambiguousDocumentIds": {
                  "maxItems": 500,
                  "type": "array",
                  "items": {
                    "type": "string",
                    "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A doc identifier (TypeID, conventions C5)."
                  }
                },
                "schemaVersion": { "type": "number", "const": 1 },
                "createdAt": {
                  "type": "string",
                  "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))$"
                },
                "updatedAt": {
                  "type": "string",
                  "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))$"
                },
                "revision": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "createdBy": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                }
              },
              "required": [
                "id",
                "organizationId",
                "projectId",
                "name",
                "enabled",
                "priority",
                "matchModel",
                "matchDocument",
                "normalization",
                "schemaVersion",
                "createdAt",
                "updatedAt",
                "revision",
                "createdBy"
              ],
              "additionalProperties": false
            },
            "description": "The created rules, in priority order."
          },
          "applyRuns": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "schemaVersion": { "type": "number", "const": 1 },
                "id": {
                  "type": "string",
                  "pattern": "^lrr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A lrr identifier (TypeID, conventions C5)."
                },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "projectId": {
                  "type": "string",
                  "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A prj identifier (TypeID, conventions C5)."
                },
                "ruleId": {
                  "type": "string",
                  "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A lkr identifier (TypeID, conventions C5)."
                },
                "dryRun": { "type": "boolean" },
                "status": {
                  "type": "string",
                  "enum": ["running", "done", "failed"]
                },
                "result": {
                  "type": "object",
                  "properties": {
                    "candidates": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "source": {
                            "oneOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "kind": {
                                    "type": "string",
                                    "const": "element"
                                  },
                                  "modelId": {
                                    "type": "string",
                                    "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                    "description": "A mdl identifier (TypeID, conventions C5)."
                                  },
                                  "globalId": {
                                    "type": "string",
                                    "minLength": 1
                                  }
                                },
                                "required": ["kind", "modelId", "globalId"],
                                "additionalProperties": false
                              },
                              {
                                "type": "object",
                                "properties": {
                                  "kind": {
                                    "type": "string",
                                    "const": "assembly"
                                  },
                                  "modelId": {
                                    "type": "string",
                                    "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                    "description": "A mdl identifier (TypeID, conventions C5)."
                                  },
                                  "assemblyMark": {
                                    "type": "string",
                                    "minLength": 1
                                  }
                                },
                                "required": ["kind", "modelId", "assemblyMark"],
                                "additionalProperties": false
                              },
                              {
                                "type": "object",
                                "properties": {
                                  "kind": {
                                    "type": "string",
                                    "const": "storey"
                                  },
                                  "modelId": {
                                    "type": "string",
                                    "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                    "description": "A mdl identifier (TypeID, conventions C5)."
                                  },
                                  "storeyId": {
                                    "type": "string",
                                    "minLength": 1
                                  }
                                },
                                "required": ["kind", "modelId", "storeyId"],
                                "additionalProperties": false
                              }
                            ]
                          },
                          "target": {
                            "type": "object",
                            "properties": {
                              "documentId": {
                                "type": "string",
                                "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                "description": "A doc identifier (TypeID, conventions C5)."
                              },
                              "page": {
                                "type": "integer",
                                "exclusiveMinimum": 0,
                                "maximum": 9007199254740991
                              },
                              "layoutName": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 255
                              }
                            },
                            "required": ["documentId", "page"],
                            "additionalProperties": false
                          },
                          "key": { "type": "string" },
                          "confidence": {
                            "type": "number",
                            "minimum": 0,
                            "maximum": 1
                          },
                          "ruleId": {
                            "type": "string",
                            "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                            "description": "A lkr identifier (TypeID, conventions C5)."
                          },
                          "ambiguous": { "type": "boolean" }
                        },
                        "required": [
                          "source",
                          "target",
                          "key",
                          "confidence",
                          "ruleId",
                          "ambiguous"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "wouldCreate": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "ambiguous": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "unmatched": {
                      "type": "object",
                      "properties": {
                        "model": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "document": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        }
                      },
                      "required": ["model", "document"],
                      "additionalProperties": false
                    },
                    "truncated": { "type": "boolean" },
                    "warnings": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "code": {
                            "type": "string",
                            "enum": [
                              "links_index_unavailable",
                              "spatial_tree_unavailable",
                              "text_layer_unavailable",
                              "link_keys_unavailable"
                            ]
                          },
                          "modelId": {
                            "type": "string",
                            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                            "description": "A mdl identifier (TypeID, conventions C5)."
                          },
                          "documentId": {
                            "type": "string",
                            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                            "description": "A doc identifier (TypeID, conventions C5)."
                          },
                          "page": {
                            "type": "integer",
                            "exclusiveMinimum": 0,
                            "maximum": 9007199254740991
                          }
                        },
                        "required": ["code"],
                        "additionalProperties": false
                      }
                    },
                    "skipped": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "reason": {
                            "type": "string",
                            "enum": ["model_index_missing"]
                          },
                          "modelId": {
                            "type": "string",
                            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                            "description": "A mdl identifier (TypeID, conventions C5)."
                          }
                        },
                        "required": ["reason", "modelId"],
                        "additionalProperties": false
                      }
                    },
                    "applied": {
                      "type": "object",
                      "properties": {
                        "created": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "updated": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "unchanged": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "manual": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "remaining": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        }
                      },
                      "required": [
                        "created",
                        "updated",
                        "unchanged",
                        "manual",
                        "remaining"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "candidates",
                    "wouldCreate",
                    "ambiguous",
                    "unmatched",
                    "truncated",
                    "warnings"
                  ],
                  "additionalProperties": false
                },
                "requestedAt": {
                  "type": "string",
                  "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))$"
                },
                "requestedBy": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                },
                "completedAt": {
                  "type": "string",
                  "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))$"
                }
              },
              "required": [
                "schemaVersion",
                "id",
                "organizationId",
                "projectId",
                "ruleId",
                "dryRun",
                "status",
                "requestedAt",
                "requestedBy"
              ],
              "additionalProperties": false
            },
            "description": "One applying run per rule; `result.applied.remaining` > 0 means the rule links more on its next run."
          }
        },
        "required": ["run", "rules", "applyRuns"],
        "additionalProperties": false
      },
      "acceptMyInvitationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "invitationId": {
            "type": "string",
            "pattern": "^inv_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "The invitation's id, as `listMyInvitations` returned it."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "The organisation the invitation belongs to."
          }
        },
        "required": ["invitationId", "organizationId"],
        "additionalProperties": false
      },
      "acceptMyInvitationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^inv_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A inv identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "kind": { "type": "string", "enum": ["email", "link"] },
          "role": {
            "type": "string",
            "enum": ["admin", "publisher", "member", "guest"]
          },
          "projectIds": {
            "maxItems": 10,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          "email": {
            "type": "string",
            "maxLength": 254,
            "format": "email",
            "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
          },
          "status": {
            "type": "string",
            "enum": ["pending", "accepted", "revoked", "expired", "exhausted"]
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "maxUses": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 250
          },
          "useCount": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "resendCount": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "lastSentAt": {
            "type": "string",
            "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))$"
          },
          "locale": { "type": "string", "enum": ["nl", "en", "fr"] },
          "acceptedBy": {
            "maxItems": 250,
            "type": "array",
            "items": { "type": "string", "minLength": 1 }
          },
          "acceptedAt": {
            "type": "string",
            "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))$"
          },
          "acceptedEmail": { "type": "string" },
          "revokedBy": { "type": "string", "minLength": 1 },
          "revokedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "alreadyMember": {
            "type": "boolean",
            "description": "True when the caller was already an active member: nothing was created and no seat used."
          }
        },
        "required": [
          "id",
          "organizationId",
          "kind",
          "role",
          "projectIds",
          "status",
          "expiresAt",
          "useCount",
          "resendCount",
          "locale",
          "acceptedBy",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy",
          "alreadyMember"
        ],
        "additionalProperties": false
      },
      "addProjectMemberInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "uid": {
            "description": "The member's uid (from `listMembers`), or a workstation's. Give this or `email`.",
            "type": "string",
            "minLength": 1
          },
          "email": {
            "description": "The member's e-mail address, resolved server-side. Give this or `uid`.",
            "type": "string",
            "maxLength": 254,
            "format": "email",
            "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
          }
        },
        "required": ["organizationId", "projectId"],
        "additionalProperties": false
      },
      "addProjectMemberOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "addedAt": {
            "type": "string",
            "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))$"
          },
          "addedBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "id": {
            "type": "string",
            "minLength": 1,
            "description": "The member's uid (user or workstation) -- also this row's Firestore id."
          }
        },
        "required": ["projectId", "organizationId", "addedAt", "addedBy", "id"],
        "additionalProperties": false
      },
      "addTryoutDrawingsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "The tryout's one project (createTryout's projectId)."
          },
          "drawings": {
            "minItems": 1,
            "maxItems": 20,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "fileName": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 255,
                  "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                },
                "sizeBytes": {
                  "type": "integer",
                  "minimum": 1,
                  "maximum": 1073741824,
                  "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                },
                "contentType": {
                  "type": "string",
                  "minLength": 1,
                  "description": "The drawing's MIME type: application/pdf, or whatever the browser reports for a DXF or DWG."
                }
              },
              "required": ["fileName", "sizeBytes", "contentType"],
              "additionalProperties": false
            },
            "description": "The drawings (PDF, DXF or DWG), up to the tryout plan's maxDocumentsPerProject."
          }
        },
        "required": ["organizationId", "projectId", "drawings"],
        "additionalProperties": false
      },
      "addTryoutDrawingsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "drawings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "documentId": {
                  "type": "string",
                  "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A doc identifier (TypeID, conventions C5)."
                },
                "versionId": {
                  "type": "string",
                  "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A dvr identifier (TypeID, conventions C5)."
                },
                "upload": {
                  "type": "object",
                  "properties": {
                    "method": { "type": "string", "const": "PUT" },
                    "url": { "type": "string" },
                    "headers": {
                      "type": "object",
                      "propertyNames": { "type": "string" },
                      "additionalProperties": { "type": "string" }
                    },
                    "expiresAt": {
                      "type": "string",
                      "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))$"
                    },
                    "maxBytes": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    },
                    "resumable": { "type": "boolean", "const": true },
                    "chunkSizeBytes": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": [
                    "method",
                    "url",
                    "headers",
                    "expiresAt",
                    "maxBytes",
                    "resumable",
                    "chunkSizeBytes"
                  ],
                  "additionalProperties": false
                }
              },
              "required": ["documentId", "versionId", "upload"],
              "additionalProperties": false
            }
          }
        },
        "required": ["drawings"],
        "additionalProperties": false
      },
      "applyLayerTemplateInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "templateId": {
            "type": "string",
            "pattern": "^ltp_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ltp identifier (TypeID, conventions C5)."
          },
          "applyTo": {
            "type": "string",
            "enum": ["all", "chosen"],
            "description": "`all`: every active project, and every project published later; `chosen`: the projects in projectIds."
          },
          "projectIds": {
            "description": "With applyTo chosen: the projects (at most 400).",
            "minItems": 1,
            "maxItems": 400,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        },
        "required": ["organizationId", "templateId", "applyTo"],
        "additionalProperties": false
      },
      "applyLayerTemplateOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "template": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "pattern": "^ltp_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A ltp identifier (TypeID, conventions C5)."
              },
              "organizationId": {
                "type": "string",
                "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A org identifier (TypeID, conventions C5)."
              },
              "name": { "type": "string", "minLength": 1, "maxLength": 60 },
              "layers": {
                "maxItems": 50,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "id": {
                      "type": "string",
                      "pattern": "^[a-z0-9][a-z0-9-]{0,39}$"
                    },
                    "displayName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 60
                    },
                    "colorHex": {
                      "type": "string",
                      "pattern": "^#[0-9a-f]{6}$"
                    },
                    "rule": {
                      "type": "object",
                      "properties": {
                        "source": {
                          "type": "string",
                          "enum": [
                            "property",
                            "name",
                            "material",
                            "ifcClass",
                            "panel"
                          ]
                        },
                        "psetName": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 255
                        },
                        "propName": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 255
                        },
                        "op": {
                          "type": "string",
                          "enum": ["eq", "neq", "contains"]
                        },
                        "value": { "type": "string", "maxLength": 1000 }
                      },
                      "required": ["op", "value"],
                      "additionalProperties": false
                    },
                    "defaultOn": { "type": "boolean" },
                    "hiddenFromField": { "type": "boolean" },
                    "locked": { "type": "boolean" }
                  },
                  "required": [
                    "id",
                    "displayName",
                    "rule",
                    "defaultOn",
                    "hiddenFromField",
                    "locked"
                  ],
                  "additionalProperties": false
                }
              },
              "applyTo": { "type": "string", "enum": ["all", "chosen"] },
              "projectIds": {
                "minItems": 1,
                "maxItems": 400,
                "type": "array",
                "items": {
                  "type": "string",
                  "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A prj identifier (TypeID, conventions C5)."
                }
              },
              "appliedAt": {
                "type": "string",
                "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))$"
              },
              "schemaVersion": { "type": "number", "const": 1 },
              "createdAt": {
                "type": "string",
                "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))$"
              },
              "updatedAt": {
                "type": "string",
                "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))$"
              },
              "revision": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "createdBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              }
            },
            "required": [
              "id",
              "organizationId",
              "name",
              "layers",
              "schemaVersion",
              "createdAt",
              "updatedAt",
              "revision",
              "createdBy"
            ],
            "additionalProperties": false
          },
          "projectCount": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "Projects asked to take the template (each syncs in the background)."
          }
        },
        "required": ["template", "projectCount"],
        "additionalProperties": false
      },
      "applyPriceToSubscriptionsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "planId": {
            "type": "string",
            "enum": ["free", "team", "enterprise", "internal", "tryout"]
          },
          "interval": {
            "type": "string",
            "enum": ["monthly", "yearly", "both"],
            "description": "Which subscriptions: monthly, yearly or both."
          },
          "target": {
            "oneOf": [
              {
                "type": "object",
                "properties": { "kind": { "type": "string", "const": "all" } },
                "required": ["kind"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "organizations" },
                  "organizationIds": {
                    "minItems": 1,
                    "maxItems": 100,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A org identifier (TypeID, conventions C5)."
                    }
                  }
                },
                "required": ["kind", "organizationIds"],
                "additionalProperties": false
              }
            ],
            "description": "Every organisation with a running subscription on the plan (`all`), or the organisations named (at most 100)."
          },
          "notBefore": {
            "description": "The new price applies from each subscription's first renewal on or after this moment (RFC 3339 UTC). Default: now + 90 days; earlier needs `force`.",
            "type": "string",
            "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))$"
          },
          "indexPercent": {
            "description": "Index each subscription's own current price by this percentage (rounded to whole cents) instead of applying the list price. The list price is left alone.",
            "type": "number",
            "exclusiveMinimum": 0,
            "maximum": 100
          },
          "note": {
            "description": "Why; kept on the platform log. Required with `force`.",
            "type": "string",
            "minLength": 1,
            "maxLength": 500
          },
          "dryRun": {
            "default": true,
            "description": "Only list what would change (the default). `false` applies it.",
            "type": "boolean"
          },
          "force": {
            "description": "Allow less than 90 days' notice (a platform override); needs a `note`.",
            "type": "boolean"
          }
        },
        "required": ["planId", "interval", "target", "dryRun"],
        "additionalProperties": false
      },
      "applyPriceToSubscriptionsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "dryRun": { "type": "boolean" },
          "notBefore": {
            "type": "string",
            "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))$"
          },
          "organizations": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "interval": { "type": "string", "enum": ["month", "year"] },
                "currentCents": {
                  "description": "The subscription's price now, EUR cents excl. VAT.",
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "newCents": {
                  "description": "The new price before its discount, whole EUR cents excl. VAT.",
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "newCurrentCents": {
                  "description": "What the organisation pays from effectiveAt: the new price with its discount (the lowest-price rule).",
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "effectiveAt": {
                  "description": "The first renewal on or after notBefore.",
                  "type": "string",
                  "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))$"
                },
                "discount": {
                  "description": "The organisation's discount, which stays on the new price.",
                  "type": "object",
                  "properties": { "name": { "type": "string" } },
                  "required": ["name"],
                  "additionalProperties": false
                },
                "status": {
                  "type": "string",
                  "enum": ["preview", "scheduled", "unchanged", "skipped"]
                },
                "reason": {
                  "type": "string",
                  "enum": [
                    "noSubscription",
                    "otherPlan",
                    "otherInterval",
                    "endsAtPeriodEnd",
                    "noProviderPrice"
                  ]
                }
              },
              "required": ["organizationId", "status"],
              "additionalProperties": false
            }
          }
        },
        "required": ["dryRun", "notBefore", "organizations"],
        "additionalProperties": false
      },
      "approveOAuthAuthorizationRequestInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "requestId": {
            "type": "string",
            "pattern": "^oar_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A oar identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "accessLevel": {
            "type": "string",
            "enum": ["fv.read", "fv.write", "fv.full"]
          }
        },
        "required": ["requestId", "organizationId", "accessLevel"],
        "additionalProperties": false
      },
      "approveOAuthAuthorizationRequestOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": { "redirectUrl": { "type": "string", "format": "uri" } },
        "required": ["redirectUrl"],
        "additionalProperties": false
      },
      "approveSupportAccessRequestInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "uid": {
            "type": "string",
            "minLength": 1,
            "maxLength": 128,
            "description": "The platform admin whose request it is (the request's uid)."
          }
        },
        "required": ["organizationId", "uid"],
        "additionalProperties": false
      },
      "approveSupportAccessRequestOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": { "type": "string", "minLength": 1 },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "uid": {
            "type": "string",
            "minLength": 1,
            "description": "The platform admin's user id."
          },
          "reason": { "type": "string" },
          "durationMinutes": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": ["pending", "approved", "denied", "used", "expired"]
          },
          "requestedAt": {
            "type": "string",
            "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))$"
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "decidedAt": {
            "type": "string",
            "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))$"
          }
        },
        "required": [
          "id",
          "organizationId",
          "uid",
          "reason",
          "durationMinutes",
          "status",
          "requestedAt",
          "expiresAt"
        ],
        "additionalProperties": false
      },
      "archiveDocumentInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "documentId"],
        "additionalProperties": false
      },
      "archiveDocumentOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "title": {
            "type": "string",
            "minLength": 1,
            "maxLength": 200,
            "description": "Document display title (1-200 chars after trimming)."
          },
          "status": {
            "type": "string",
            "enum": ["active", "archived", "deleted"]
          },
          "nextVersionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "format": { "type": "string", "enum": ["pdf", "dxf", "dwg"] },
          "published": {
            "type": "object",
            "properties": {
              "versionId": {
                "type": "string",
                "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A dvr identifier (TypeID, conventions C5)."
              },
              "publishedAt": {
                "type": "string",
                "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))$"
              },
              "publishedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              },
              "publishSeq": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "versionId",
              "publishedAt",
              "publishedBy",
              "publishSeq"
            ],
            "additionalProperties": false
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "deletedAt": {
            "type": "string",
            "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))$"
          },
          "purgeAfter": {
            "type": "string",
            "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))$"
          },
          "statusBeforeDeletion": {
            "type": "string",
            "enum": ["active", "archived"]
          },
          "purgeStartedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "status",
          "nextVersionNumber",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "archiveModelVersionInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "modelId", "versionId"],
        "additionalProperties": false
      },
      "archiveModelVersionOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": [
              "uploading",
              "uploaded",
              "processing",
              "ready",
              "failed",
              "archived",
              "cancelled"
            ]
          },
          "publication": {
            "type": "string",
            "enum": ["draft", "published", "superseded"]
          },
          "fieldVisible": { "type": "boolean" },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "upload" },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "fileName", "sizeBytes", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "copy" },
                  "sourceVersionId": {
                    "type": "string",
                    "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A ver identifier (TypeID, conventions C5)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": [
                  "kind",
                  "sourceVersionId",
                  "fileName",
                  "sizeBytes",
                  "contentType"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "url" },
                  "url": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 2048,
                    "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "url", "fileName", "contentType"],
                "additionalProperties": false
              }
            ]
          },
          "upload": {
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "cancelReason": { "type": "string", "enum": ["user", "expired"] },
          "pipelineVersion": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": { "type": "string" },
                "blocking": { "type": "boolean" },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": {}
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": { "type": "string", "minLength": 1 },
              "retryable": { "type": "boolean" },
              "params": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": {}
              },
              "messageKey": { "type": "string", "minLength": 1 },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "retryable"],
            "additionalProperties": false
          },
          "processing": {
            "type": "object",
            "properties": {
              "sizeClass": { "type": "string", "enum": ["s", "m", "l", "xl"] },
              "executionName": { "type": "string", "minLength": 1 },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "queuedAt": {
                "type": "string",
                "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))$"
              },
              "queuedTraceparent": {
                "type": "string",
                "pattern": "^(?!ff)[0-9a-f]{2}-(?!0{32})[0-9a-f]{32}-(?!0{16})[0-9a-f]{16}-[0-9a-f]{2}$"
              },
              "queuedEscalation": {
                "type": "object",
                "properties": {
                  "sizeClass": {
                    "type": "string",
                    "enum": ["s", "m", "l", "xl"]
                  },
                  "attempt": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["sizeClass", "attempt"],
                "additionalProperties": false
              },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "progressReportedAt": {
                "type": "string",
                "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))$"
              },
              "requestId": { "type": "string", "minLength": 1 }
            },
            "additionalProperties": false
          },
          "progress": {
            "type": "object",
            "properties": {
              "stage": { "type": "string", "minLength": 1 },
              "percent": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["stage", "percent"],
            "additionalProperties": false
          },
          "reprocessing": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "reason": {
                "type": "string",
                "enum": ["retry", "pipeline_upgrade"]
              },
              "targetPipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "state": {
                "type": "string",
                "enum": [
                  "requested",
                  "deferred",
                  "awaiting_rollout",
                  "done",
                  "failed"
                ]
              },
              "completedAt": {
                "type": "string",
                "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))$"
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1 },
                  "retryable": { "type": "boolean" },
                  "params": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": {}
                  },
                  "messageKey": { "type": "string", "minLength": 1 },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "retryable"],
                "additionalProperties": false
              }
            },
            "required": ["requestedAt", "requestedBy", "attempt"],
            "additionalProperties": false
          },
          "releasedAt": {
            "type": "string",
            "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))$"
          },
          "releasedBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "supersededAt": {
            "type": "string",
            "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))$"
          },
          "activeArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "nextArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "stats": {
            "type": "object",
            "properties": {
              "elementCount": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "boundsMm": {
                "type": "object",
                "properties": {
                  "min": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3
                  },
                  "max": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3
                  }
                },
                "required": ["min", "max"],
                "additionalProperties": false
              },
              "coveragePct": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["elementCount", "boundsMm"],
            "additionalProperties": false
          },
          "churn": {
            "type": "object",
            "properties": {
              "ratio": { "type": "number", "minimum": 0, "maximum": 1 },
              "added": { "type": "array", "items": { "type": "string" } },
              "removed": { "type": "array", "items": { "type": "string" } },
              "moved": { "type": "array", "items": { "type": "string" } },
              "recreated": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "from": { "type": "string" },
                    "to": { "type": "string" }
                  },
                  "required": ["from", "to"],
                  "additionalProperties": false
                }
              }
            },
            "required": ["ratio", "added", "removed", "moved", "recreated"],
            "additionalProperties": false
          },
          "label": {
            "type": "string",
            "minLength": 1,
            "maxLength": 40,
            "description": "Short version name, e.g. \"Roof fix\" (1-40 chars after trimming, BR-10)."
          },
          "notes": {
            "type": "string",
            "maxLength": 2000,
            "description": "Free-form notes for the crew (max 2000 chars, BR-10)."
          },
          "detailsEditedAt": {
            "type": "string",
            "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))$"
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "publishOnReady": {
            "description": "Publish this version automatically, in the same write that marks it ready (FV-383).",
            "type": "boolean"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "modelId",
          "versionNumber",
          "status",
          "publication",
          "fieldVisible",
          "source",
          "pipelineVersion",
          "warnings",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "archiveProjectInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId"],
        "additionalProperties": false
      },
      "archiveProjectOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "Project display name (1-80 chars after trimming, BR-2)."
          },
          "reference": {
            "type": "string",
            "minLength": 1,
            "maxLength": 40,
            "description": "Free-form job/reference code, e.g. \"2026-041\" (BR-2)."
          },
          "description": {
            "type": "string",
            "maxLength": 500,
            "description": "Free-form project description (BR-2)."
          },
          "status": {
            "type": "string",
            "enum": ["active", "archived", "deleted"]
          },
          "access": { "type": "string", "enum": ["org", "restricted"] },
          "memberIds": {
            "maxItems": 500,
            "type": "array",
            "items": { "type": "string", "minLength": 1 }
          },
          "fieldVersionIds": {
            "maxItems": 500,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ver identifier (TypeID, conventions C5)."
            }
          },
          "publishSeq": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "lastPublishedAt": {
            "type": "string",
            "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))$"
          },
          "isSample": { "type": "boolean", "const": true },
          "demoSlug": {
            "type": "string",
            "enum": [
              "landhuis_hulstveld",
              "landhuis_hulstveld_hsb",
              "woning_lindehof",
              "villa_berkenhaag",
              "hal_noorderkempen",
              "paneelset_werkplaats"
            ]
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "deletedAt": {
            "type": "string",
            "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))$"
          },
          "purgeAfter": {
            "type": "string",
            "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))$"
          },
          "statusBeforeDeletion": {
            "type": "string",
            "enum": ["active", "archived"]
          },
          "purgeStartedAt": {
            "type": "string",
            "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))$"
          },
          "sheetMetadata": {
            "type": "object",
            "properties": {
              "fileNamePattern": {
                "type": "string",
                "description": "Regular expression matched against the file name without its .pdf extension, with named groups sheetNumber and/or discipline, e.g. ^(?<discipline>[A-Z])-(?<sheetNumber>\\d+) (max 200 chars; no backreferences or nested repeats)."
              },
              "disciplineMap": {
                "type": "object",
                "propertyNames": {
                  "type": "string",
                  "pattern": "^[A-Za-z0-9]{1,8}$"
                },
                "additionalProperties": {
                  "type": "string",
                  "enum": [
                    "architecture",
                    "structure",
                    "mechanical",
                    "electrical",
                    "plumbing",
                    "fire_protection",
                    "civil",
                    "landscape",
                    "general"
                  ]
                }
              }
            },
            "additionalProperties": false,
            "description": "How this project's PDF file names map to sheet number and discipline (BR-11). Without a fileNamePattern the file-name stem is the sheet number."
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "name",
          "status",
          "access",
          "memberIds",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "assignWorkstationPresetInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "workstationId": {
            "type": "string",
            "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A wks identifier (TypeID, conventions C5)."
          },
          "mode": {
            "type": "string",
            "enum": ["fixed", "crew"],
            "description": "`fixed`: one project (`projectId`). `crew`: several (`projectIds`), all among the workstation's own projects; the screen opens on the first."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "projectIds": {
            "minItems": 1,
            "maxItems": 20,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          "modelPolicy": {
            "description": "Which model version the screen shows. `latest_published` (the default) is the only option.",
            "type": "string",
            "const": "latest_published"
          },
          "viewId": {
            "description": "A shared view of the project the screen opens on; without one it opens on the project's default view.",
            "type": "string",
            "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
          },
          "toolbarConfig": {
            "description": "Up to 7 toolbar ids, in the order they show (e.g. `measure`, `section`, `layers`). An id a screen does not know is skipped there. Without it the screen shows its usual toolbar.",
            "maxItems": 7,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^[a-z][a-zA-Z0-9-]{0,39}$"
            }
          },
          "lockedSettings": {
            "description": "Defaults: no project switching, no sharing, the device's own theme, back to the preset view after 10 idle minutes.",
            "type": "object",
            "properties": {
              "allowProjectSwitch": { "type": "boolean" },
              "allowShare": { "type": "boolean" },
              "theme": { "type": "string", "enum": ["sunlight", "dim"] },
              "idleResetMinutes": {
                "type": "integer",
                "minimum": 1,
                "maximum": 120
              }
            },
            "additionalProperties": false
          }
        },
        "required": ["organizationId", "workstationId", "mode"],
        "additionalProperties": false
      },
      "assignWorkstationPresetOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A wks identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": { "type": "string", "minLength": 1 },
          "assignedProjectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "projectIds": {
            "default": [],
            "maxItems": 20,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          "status": {
            "type": "string",
            "enum": ["unpaired", "active", "revoked"]
          },
          "blocked": { "type": "boolean" },
          "pairedAt": {
            "type": "string",
            "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))$"
          },
          "lastSeenAt": {
            "type": "string",
            "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))$"
          },
          "revokedAt": {
            "type": "string",
            "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))$"
          },
          "revokedBy": { "type": "string", "minLength": 1 },
          "preset": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "mode": { "type": "string", "const": "fixed" },
                  "projectId": {
                    "type": "string",
                    "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A prj identifier (TypeID, conventions C5)."
                  },
                  "modelPolicy": {
                    "type": "string",
                    "const": "latest_published"
                  },
                  "viewId": {
                    "type": "string",
                    "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A vw identifier (TypeID, conventions C5)."
                  },
                  "toolbarConfig": {
                    "maxItems": 7,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^[a-z][a-zA-Z0-9-]{0,39}$"
                    }
                  },
                  "lockedSettings": {
                    "type": "object",
                    "properties": {
                      "allowProjectSwitch": { "type": "boolean" },
                      "allowShare": { "type": "boolean" },
                      "theme": {
                        "type": "string",
                        "enum": ["sunlight", "dim"]
                      },
                      "idleResetMinutes": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 120
                      }
                    },
                    "required": [
                      "allowProjectSwitch",
                      "allowShare",
                      "idleResetMinutes"
                    ],
                    "additionalProperties": false
                  }
                },
                "required": [
                  "mode",
                  "projectId",
                  "modelPolicy",
                  "lockedSettings"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "mode": { "type": "string", "const": "crew" },
                  "projectIds": {
                    "minItems": 1,
                    "maxItems": 20,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A prj identifier (TypeID, conventions C5)."
                    }
                  },
                  "modelPolicy": {
                    "type": "string",
                    "const": "latest_published"
                  },
                  "viewId": {
                    "type": "string",
                    "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A vw identifier (TypeID, conventions C5)."
                  },
                  "toolbarConfig": {
                    "maxItems": 7,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^[a-z][a-zA-Z0-9-]{0,39}$"
                    }
                  },
                  "lockedSettings": {
                    "type": "object",
                    "properties": {
                      "allowProjectSwitch": { "type": "boolean" },
                      "allowShare": { "type": "boolean" },
                      "theme": {
                        "type": "string",
                        "enum": ["sunlight", "dim"]
                      },
                      "idleResetMinutes": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 120
                      }
                    },
                    "required": [
                      "allowProjectSwitch",
                      "allowShare",
                      "idleResetMinutes"
                    ],
                    "additionalProperties": false
                  }
                },
                "required": [
                  "mode",
                  "projectIds",
                  "modelPolicy",
                  "lockedSettings"
                ],
                "additionalProperties": false
              }
            ]
          },
          "runtime": {
            "type": "object",
            "properties": {
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "currentProjectId": {
                "type": "string",
                "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A prj identifier (TypeID, conventions C5)."
              },
              "appVersion": {
                "type": "string",
                "minLength": 1,
                "maxLength": 64
              },
              "state": { "type": "string", "enum": ["ready", "error"] }
            },
            "required": ["heartbeatAt"],
            "additionalProperties": false
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "name",
          "projectIds",
          "status",
          "blocked",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "cancelDocumentVersionUploadInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dvr identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "documentId", "versionId"],
        "additionalProperties": false
      },
      "cancelDocumentVersionUploadOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dvr identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": [
              "uploading",
              "uploaded",
              "processing",
              "ready",
              "failed",
              "archived",
              "cancelled"
            ]
          },
          "publication": {
            "type": "string",
            "enum": ["draft", "published", "superseded"]
          },
          "fieldVisible": { "type": "boolean" },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "upload" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "fileName", "sizeBytes", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "url" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "url": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 2048,
                    "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "url", "fileName", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "copy" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "sourceVersionId": {
                    "type": "string",
                    "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A dvr identifier (TypeID, conventions C5)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": [
                  "kind",
                  "sourceVersionId",
                  "fileName",
                  "sizeBytes",
                  "contentType"
                ],
                "additionalProperties": false
              }
            ]
          },
          "upload": {
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          },
          "cancelReason": { "type": "string", "enum": ["user"] },
          "pipelineVersion": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": { "type": "string" },
                "blocking": { "type": "boolean" },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": {}
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "progress": {
            "type": "object",
            "properties": {
              "stage": { "type": "string", "minLength": 1 },
              "percent": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["stage", "percent"],
            "additionalProperties": false
          },
          "processing": {
            "type": "object",
            "properties": {
              "sizeClass": { "type": "string", "enum": ["s", "m", "l", "xl"] },
              "executionName": { "type": "string", "minLength": 1 },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "queuedAt": {
                "type": "string",
                "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))$"
              },
              "queuedTraceparent": {
                "type": "string",
                "pattern": "^(?!ff)[0-9a-f]{2}-(?!0{32})[0-9a-f]{32}-(?!0{16})[0-9a-f]{16}-[0-9a-f]{2}$"
              },
              "queuedEscalation": {
                "type": "object",
                "properties": {
                  "sizeClass": {
                    "type": "string",
                    "enum": ["s", "m", "l", "xl"]
                  },
                  "attempt": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["sizeClass", "attempt"],
                "additionalProperties": false
              },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "progressReportedAt": {
                "type": "string",
                "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))$"
              },
              "requestId": { "type": "string", "minLength": 1 }
            },
            "additionalProperties": false
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": { "type": "string", "minLength": 1 },
              "retryable": { "type": "boolean" },
              "params": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": {}
              },
              "messageKey": { "type": "string", "minLength": 1 },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "retryable"],
            "additionalProperties": false
          },
          "activeArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "reprocessing": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "reason": {
                "type": "string",
                "enum": ["retry", "pipeline_upgrade"]
              },
              "targetPipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "state": {
                "type": "string",
                "enum": [
                  "requested",
                  "deferred",
                  "awaiting_rollout",
                  "done",
                  "failed"
                ]
              },
              "completedAt": {
                "type": "string",
                "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))$"
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1 },
                  "retryable": { "type": "boolean" },
                  "params": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": {}
                  },
                  "messageKey": { "type": "string", "minLength": 1 },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "retryable"],
                "additionalProperties": false
              }
            },
            "required": ["requestedAt", "requestedBy", "attempt"],
            "additionalProperties": false
          },
          "pageCount": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "pages": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "pageNumber": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "scanned": { "type": "boolean" },
                "sheetNumber": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 100,
                  "description": "Sheet number, e.g. \"W-101\" (BR-11)."
                },
                "title": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 200,
                  "description": "Sheet title, e.g. from the PDF outline (BR-11)."
                },
                "discipline": {
                  "type": "string",
                  "enum": [
                    "architecture",
                    "structure",
                    "mechanical",
                    "electrical",
                    "plumbing",
                    "fire_protection",
                    "civil",
                    "landscape",
                    "general"
                  ]
                },
                "storeyId": { "type": "string", "minLength": 1 },
                "overridden": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "enum": ["sheetNumber", "title", "discipline"]
                  }
                },
                "layout": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "kind": { "type": "string", "enum": ["model", "paper"] }
                  },
                  "required": ["name", "kind"],
                  "additionalProperties": false
                },
                "titleBlock": {
                  "type": "object",
                  "propertyNames": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 64
                  },
                  "additionalProperties": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "description": "FV-490 (E13 §4.4): a CAD page's primary title block, attribute tag -> value (<= 32 entries, values <= 200 chars)."
                },
                "scale": {
                  "type": "object",
                  "properties": {
                    "factor": {
                      "type": "number",
                      "exclusiveMinimum": 0,
                      "maximum": 10000,
                      "description": "Real millimetres per paper millimetre (1:50 is 50)."
                    },
                    "source": {
                      "type": "string",
                      "enum": ["calibration", "label"],
                      "description": "calibration: two points and a known length; label: the title-block scale, confirmed."
                    },
                    "basis": {
                      "description": "For a calibration: the two points (fractions of the page) and the real length in mm.",
                      "type": "object",
                      "properties": {
                        "a": {
                          "type": "object",
                          "properties": {
                            "xPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            },
                            "yPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            }
                          },
                          "required": ["xPct", "yPct"],
                          "additionalProperties": false
                        },
                        "b": {
                          "type": "object",
                          "properties": {
                            "xPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            },
                            "yPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            }
                          },
                          "required": ["xPct", "yPct"],
                          "additionalProperties": false
                        },
                        "lengthMm": { "type": "number", "exclusiveMinimum": 0 }
                      },
                      "required": ["a", "b", "lengthMm"],
                      "additionalProperties": false
                    },
                    "setBy": { "type": "string", "minLength": 1 },
                    "setAt": {
                      "type": "string",
                      "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))$"
                    }
                  },
                  "required": ["factor", "source", "setBy", "setAt"],
                  "additionalProperties": false
                }
              },
              "required": ["pageNumber", "scanned"],
              "additionalProperties": false
            }
          },
          "cad": {
            "type": "object",
            "properties": {
              "insunits": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "unitToMm": {
                "anyOf": [
                  { "type": "number", "exclusiveMinimum": 0 },
                  { "type": "null" }
                ]
              },
              "unitsOverride": {
                "type": "string",
                "enum": ["mm", "cm", "m", "in", "ft"],
                "description": "The drawing's units, set by a publisher because the file declares none: mm, cm, m, in or ft."
              },
              "defaultLayersOff": {
                "maxItems": 256,
                "type": "array",
                "items": { "type": "string", "minLength": 1, "maxLength": 255 },
                "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
              },
              "parser": { "type": "string", "const": "acad-ts" },
              "parserVersion": { "type": "string", "minLength": 1 },
              "version": { "type": "string", "minLength": 1 },
              "layoutCount": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "insunits",
              "unitToMm",
              "parser",
              "parserVersion",
              "version",
              "layoutCount"
            ],
            "additionalProperties": false
          },
          "layerDefault": {
            "type": "object",
            "properties": {
              "off": {
                "maxItems": 256,
                "type": "array",
                "items": { "type": "string", "minLength": 1, "maxLength": 255 },
                "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
              }
            },
            "required": ["off"],
            "additionalProperties": false,
            "description": "The layers off by default for everyone who opens this drawing (CAD layers or PDF optional content groups, by name). A person's own choice on their device still wins."
          },
          "publishOnReady": {
            "description": "Publish this version automatically, in the same write that marks it ready (FV-745).",
            "type": "boolean"
          },
          "releasedAt": {
            "type": "string",
            "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))$"
          },
          "supersededAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "documentId",
          "versionNumber",
          "status",
          "publication",
          "fieldVisible",
          "source",
          "pipelineVersion",
          "warnings",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "cancelModelVersionUploadInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "modelId", "versionId"],
        "additionalProperties": false
      },
      "cancelModelVersionUploadOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": [
              "uploading",
              "uploaded",
              "processing",
              "ready",
              "failed",
              "archived",
              "cancelled"
            ]
          },
          "publication": {
            "type": "string",
            "enum": ["draft", "published", "superseded"]
          },
          "fieldVisible": { "type": "boolean" },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "upload" },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "fileName", "sizeBytes", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "copy" },
                  "sourceVersionId": {
                    "type": "string",
                    "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A ver identifier (TypeID, conventions C5)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": [
                  "kind",
                  "sourceVersionId",
                  "fileName",
                  "sizeBytes",
                  "contentType"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "url" },
                  "url": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 2048,
                    "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "url", "fileName", "contentType"],
                "additionalProperties": false
              }
            ]
          },
          "upload": {
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "cancelReason": { "type": "string", "enum": ["user", "expired"] },
          "pipelineVersion": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": { "type": "string" },
                "blocking": { "type": "boolean" },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": {}
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": { "type": "string", "minLength": 1 },
              "retryable": { "type": "boolean" },
              "params": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": {}
              },
              "messageKey": { "type": "string", "minLength": 1 },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "retryable"],
            "additionalProperties": false
          },
          "processing": {
            "type": "object",
            "properties": {
              "sizeClass": { "type": "string", "enum": ["s", "m", "l", "xl"] },
              "executionName": { "type": "string", "minLength": 1 },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "queuedAt": {
                "type": "string",
                "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))$"
              },
              "queuedTraceparent": {
                "type": "string",
                "pattern": "^(?!ff)[0-9a-f]{2}-(?!0{32})[0-9a-f]{32}-(?!0{16})[0-9a-f]{16}-[0-9a-f]{2}$"
              },
              "queuedEscalation": {
                "type": "object",
                "properties": {
                  "sizeClass": {
                    "type": "string",
                    "enum": ["s", "m", "l", "xl"]
                  },
                  "attempt": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["sizeClass", "attempt"],
                "additionalProperties": false
              },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "progressReportedAt": {
                "type": "string",
                "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))$"
              },
              "requestId": { "type": "string", "minLength": 1 }
            },
            "additionalProperties": false
          },
          "progress": {
            "type": "object",
            "properties": {
              "stage": { "type": "string", "minLength": 1 },
              "percent": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["stage", "percent"],
            "additionalProperties": false
          },
          "reprocessing": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "reason": {
                "type": "string",
                "enum": ["retry", "pipeline_upgrade"]
              },
              "targetPipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "state": {
                "type": "string",
                "enum": [
                  "requested",
                  "deferred",
                  "awaiting_rollout",
                  "done",
                  "failed"
                ]
              },
              "completedAt": {
                "type": "string",
                "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))$"
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1 },
                  "retryable": { "type": "boolean" },
                  "params": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": {}
                  },
                  "messageKey": { "type": "string", "minLength": 1 },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "retryable"],
                "additionalProperties": false
              }
            },
            "required": ["requestedAt", "requestedBy", "attempt"],
            "additionalProperties": false
          },
          "releasedAt": {
            "type": "string",
            "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))$"
          },
          "releasedBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "supersededAt": {
            "type": "string",
            "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))$"
          },
          "activeArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "nextArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "stats": {
            "type": "object",
            "properties": {
              "elementCount": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "boundsMm": {
                "type": "object",
                "properties": {
                  "min": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3
                  },
                  "max": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3
                  }
                },
                "required": ["min", "max"],
                "additionalProperties": false
              },
              "coveragePct": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["elementCount", "boundsMm"],
            "additionalProperties": false
          },
          "churn": {
            "type": "object",
            "properties": {
              "ratio": { "type": "number", "minimum": 0, "maximum": 1 },
              "added": { "type": "array", "items": { "type": "string" } },
              "removed": { "type": "array", "items": { "type": "string" } },
              "moved": { "type": "array", "items": { "type": "string" } },
              "recreated": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "from": { "type": "string" },
                    "to": { "type": "string" }
                  },
                  "required": ["from", "to"],
                  "additionalProperties": false
                }
              }
            },
            "required": ["ratio", "added", "removed", "moved", "recreated"],
            "additionalProperties": false
          },
          "label": {
            "type": "string",
            "minLength": 1,
            "maxLength": 40,
            "description": "Short version name, e.g. \"Roof fix\" (1-40 chars after trimming, BR-10)."
          },
          "notes": {
            "type": "string",
            "maxLength": 2000,
            "description": "Free-form notes for the crew (max 2000 chars, BR-10)."
          },
          "detailsEditedAt": {
            "type": "string",
            "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))$"
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "publishOnReady": {
            "description": "Publish this version automatically, in the same write that marks it ready (FV-383).",
            "type": "boolean"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "modelId",
          "versionNumber",
          "status",
          "publication",
          "fieldVisible",
          "source",
          "pipelineVersion",
          "warnings",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "cancelOrganizationDeletionInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "cancelOrganizationDeletionOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 2,
            "maxLength": 80,
            "description": "Organisation display name (2-80 chars after trimming, BR-10)."
          },
          "defaultLocale": {
            "type": "string",
            "enum": ["nl", "en", "fr"],
            "description": "The organisation's default UI locale, one of nl | en | fr."
          },
          "status": {
            "type": "string",
            "enum": ["active", "pending_deletion"]
          },
          "deletion": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "purgeAfter": {
                "type": "string",
                "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))$"
              },
              "cancelledAt": {
                "type": "string",
                "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))$"
              },
              "purgeStartedAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["requestedAt", "requestedBy", "purgeAfter"],
            "additionalProperties": false
          },
          "supportAccess": {
            "description": "Whether Field-Viewer support may open a read-only support session: allowed (default when absent; owners are e-mailed) or ask (an owner approves each request first).",
            "type": "string",
            "enum": ["allowed", "ask"]
          },
          "settings": {
            "type": "object",
            "properties": {
              "analytics": {
                "type": "object",
                "properties": {
                  "mode": {
                    "type": "string",
                    "enum": ["enabled", "disabled"],
                    "description": "Product analytics for every member: enabled (the default) or disabled. Disabled, no usage event is recorded for anyone in the organisation."
                  }
                },
                "required": ["mode"],
                "additionalProperties": false
              },
              "cad": {
                "type": "object",
                "properties": {
                  "producerDetailTags": {
                    "type": "object",
                    "properties": {
                      "scale": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's scale text (1:n)."
                      },
                      "xFactor": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's x factor (1/n)."
                      },
                      "yFactor": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's y factor (1/n)."
                      },
                      "xMin": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's minimum x."
                      },
                      "yMin": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's minimum y."
                      },
                      "xMax": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's maximum x."
                      },
                      "yMax": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's maximum y."
                      }
                    },
                    "required": [
                      "scale",
                      "xFactor",
                      "yFactor",
                      "xMin",
                      "yMin",
                      "xMax",
                      "yMax"
                    ],
                    "additionalProperties": false,
                    "description": "The CAD producer's detail attribute tags: all seven, each the tag (not the value) of one block attribute. With them, scaled details in model space measure in real millimetres at their own scale; without them they read 'scale unknown'."
                  }
                },
                "additionalProperties": false
              }
            },
            "additionalProperties": false
          },
          "legal": {
            "type": "object",
            "properties": {
              "termsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "privacyVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "dpaVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "subprocessorsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "acceptedAt": {
                "type": "string",
                "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))$"
              },
              "acceptedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              }
            },
            "required": [
              "termsVersion",
              "privacyVersion",
              "dpaVersion",
              "subprocessorsVersion",
              "acceptedAt",
              "acceptedBy"
            ],
            "additionalProperties": false,
            "description": "The terms, privacy notice, DPA and sub-processor list versions an owner accepted for the organisation."
          },
          "kind": {
            "description": "standard (default when absent) or tryout: an anonymous visitor's 7-day try-it organisation.",
            "type": "string",
            "enum": ["standard", "tryout"]
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "logoUrl": {
            "type": "object",
            "properties": {
              "url": { "type": "string" },
              "expiresAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["url", "expiresAt"],
            "additionalProperties": false,
            "description": "Signed URL of the organisation's logo (15 minutes). Absent when it has no logo."
          },
          "reacceptanceRequired": {
            "description": "True when an owner must accept a newer material version of the terms, the DPA or the sub-processor list (or never accepted them).",
            "type": "boolean"
          }
        },
        "required": [
          "id",
          "name",
          "defaultLocale",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "cancelScheduledPriceChangesInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "target": {
            "oneOf": [
              {
                "type": "object",
                "properties": { "kind": { "type": "string", "const": "all" } },
                "required": ["kind"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "organizations" },
                  "organizationIds": {
                    "minItems": 1,
                    "maxItems": 100,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A org identifier (TypeID, conventions C5)."
                    }
                  }
                },
                "required": ["kind", "organizationIds"],
                "additionalProperties": false
              }
            ],
            "description": "Every organisation with a running subscription on the plan (`all`), or the organisations named (at most 100)."
          },
          "note": { "type": "string", "minLength": 1, "maxLength": 500 }
        },
        "required": ["target"],
        "additionalProperties": false
      },
      "cancelScheduledPriceChangesOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "canceled": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "amountCents": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "effectiveAt": {
                  "type": "string",
                  "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))$"
                }
              },
              "required": ["organizationId", "amountCents", "effectiveAt"],
              "additionalProperties": false
            }
          }
        },
        "required": ["canceled"],
        "additionalProperties": false
      },
      "cancelSubscriptionInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "cancelSubscriptionOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "cancelAtPeriodEnd": { "type": "boolean", "const": true },
          "currentPeriodEnd": {
            "type": "string",
            "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))$",
            "description": "The last day of the paid period; the organisation moves to the free plan after it."
          }
        },
        "required": ["cancelAtPeriodEnd", "currentPeriodEnd"],
        "additionalProperties": false
      },
      "claimTryoutInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "claimToken": {
            "type": "string",
            "pattern": "^[0-9a-f]{64}$",
            "description": "The claim token `createTryout` returned. Sent as the `X-Tryout-Claim-Token` header."
          },
          "organizationName": {
            "type": "string",
            "minLength": 2,
            "maxLength": 80,
            "description": "Organisation display name (2-80 chars after trimming, BR-10)."
          },
          "locale": {
            "type": "string",
            "enum": ["nl", "en", "fr"],
            "description": "The organisation's default language (nl, en or fr)."
          },
          "legalAcceptance": {
            "type": "object",
            "properties": {
              "termsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "privacyVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "dpaVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "subprocessorsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              }
            },
            "required": [
              "termsVersion",
              "privacyVersion",
              "dpaVersion",
              "subprocessorsVersion"
            ],
            "additionalProperties": false,
            "description": "The current terms, privacy notice, DPA and sub-processor list versions the caller accepts for the organisation (from the legal documents list). Required."
          }
        },
        "required": [
          "organizationId",
          "claimToken",
          "organizationName",
          "locale",
          "legalAcceptance"
        ],
        "additionalProperties": false
      },
      "claimTryoutOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 2,
            "maxLength": 80,
            "description": "Organisation display name (2-80 chars after trimming, BR-10)."
          },
          "defaultLocale": {
            "type": "string",
            "enum": ["nl", "en", "fr"],
            "description": "The organisation's default UI locale, one of nl | en | fr."
          },
          "status": {
            "type": "string",
            "enum": ["active", "pending_deletion"]
          },
          "deletion": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "purgeAfter": {
                "type": "string",
                "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))$"
              },
              "cancelledAt": {
                "type": "string",
                "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))$"
              },
              "purgeStartedAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["requestedAt", "requestedBy", "purgeAfter"],
            "additionalProperties": false
          },
          "supportAccess": {
            "description": "Whether Field-Viewer support may open a read-only support session: allowed (default when absent; owners are e-mailed) or ask (an owner approves each request first).",
            "type": "string",
            "enum": ["allowed", "ask"]
          },
          "settings": {
            "type": "object",
            "properties": {
              "analytics": {
                "type": "object",
                "properties": {
                  "mode": {
                    "type": "string",
                    "enum": ["enabled", "disabled"],
                    "description": "Product analytics for every member: enabled (the default) or disabled. Disabled, no usage event is recorded for anyone in the organisation."
                  }
                },
                "required": ["mode"],
                "additionalProperties": false
              },
              "cad": {
                "type": "object",
                "properties": {
                  "producerDetailTags": {
                    "type": "object",
                    "properties": {
                      "scale": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's scale text (1:n)."
                      },
                      "xFactor": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's x factor (1/n)."
                      },
                      "yFactor": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's y factor (1/n)."
                      },
                      "xMin": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's minimum x."
                      },
                      "yMin": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's minimum y."
                      },
                      "xMax": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's maximum x."
                      },
                      "yMax": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's maximum y."
                      }
                    },
                    "required": [
                      "scale",
                      "xFactor",
                      "yFactor",
                      "xMin",
                      "yMin",
                      "xMax",
                      "yMax"
                    ],
                    "additionalProperties": false,
                    "description": "The CAD producer's detail attribute tags: all seven, each the tag (not the value) of one block attribute. With them, scaled details in model space measure in real millimetres at their own scale; without them they read 'scale unknown'."
                  }
                },
                "additionalProperties": false
              }
            },
            "additionalProperties": false
          },
          "legal": {
            "type": "object",
            "properties": {
              "termsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "privacyVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "dpaVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "subprocessorsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "acceptedAt": {
                "type": "string",
                "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))$"
              },
              "acceptedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              }
            },
            "required": [
              "termsVersion",
              "privacyVersion",
              "dpaVersion",
              "subprocessorsVersion",
              "acceptedAt",
              "acceptedBy"
            ],
            "additionalProperties": false,
            "description": "The terms, privacy notice, DPA and sub-processor list versions an owner accepted for the organisation."
          },
          "kind": {
            "description": "standard (default when absent) or tryout: an anonymous visitor's 7-day try-it organisation.",
            "type": "string",
            "enum": ["standard", "tryout"]
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "logoUrl": {
            "type": "object",
            "properties": {
              "url": { "type": "string" },
              "expiresAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["url", "expiresAt"],
            "additionalProperties": false,
            "description": "Signed URL of the organisation's logo (15 minutes). Absent when it has no logo."
          },
          "reacceptanceRequired": {
            "description": "True when an owner must accept a newer material version of the terms, the DPA or the sub-processor list (or never accepted them).",
            "type": "boolean"
          }
        },
        "required": [
          "id",
          "name",
          "defaultLocale",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "claimWorkstationPairingInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "code": { "type": "string", "minLength": 1, "maxLength": 32 }
        },
        "required": ["code"],
        "additionalProperties": false
      },
      "claimWorkstationPairingOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "customToken": { "type": "string", "minLength": 1 },
          "workstationId": {
            "type": "string",
            "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A wks identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": { "type": "string", "minLength": 1 }
        },
        "required": ["customToken", "workstationId", "organizationId", "name"],
        "additionalProperties": false
      },
      "completeDocumentVersionUploadInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dvr identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "documentId", "versionId"],
        "additionalProperties": false
      },
      "completeDocumentVersionUploadOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dvr identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": [
              "uploading",
              "uploaded",
              "processing",
              "ready",
              "failed",
              "archived",
              "cancelled"
            ]
          },
          "publication": {
            "type": "string",
            "enum": ["draft", "published", "superseded"]
          },
          "fieldVisible": { "type": "boolean" },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "upload" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "fileName", "sizeBytes", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "url" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "url": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 2048,
                    "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "url", "fileName", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "copy" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "sourceVersionId": {
                    "type": "string",
                    "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A dvr identifier (TypeID, conventions C5)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": [
                  "kind",
                  "sourceVersionId",
                  "fileName",
                  "sizeBytes",
                  "contentType"
                ],
                "additionalProperties": false
              }
            ]
          },
          "upload": {
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          },
          "cancelReason": { "type": "string", "enum": ["user"] },
          "pipelineVersion": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": { "type": "string" },
                "blocking": { "type": "boolean" },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": {}
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "progress": {
            "type": "object",
            "properties": {
              "stage": { "type": "string", "minLength": 1 },
              "percent": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["stage", "percent"],
            "additionalProperties": false
          },
          "processing": {
            "type": "object",
            "properties": {
              "sizeClass": { "type": "string", "enum": ["s", "m", "l", "xl"] },
              "executionName": { "type": "string", "minLength": 1 },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "queuedAt": {
                "type": "string",
                "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))$"
              },
              "queuedTraceparent": {
                "type": "string",
                "pattern": "^(?!ff)[0-9a-f]{2}-(?!0{32})[0-9a-f]{32}-(?!0{16})[0-9a-f]{16}-[0-9a-f]{2}$"
              },
              "queuedEscalation": {
                "type": "object",
                "properties": {
                  "sizeClass": {
                    "type": "string",
                    "enum": ["s", "m", "l", "xl"]
                  },
                  "attempt": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["sizeClass", "attempt"],
                "additionalProperties": false
              },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "progressReportedAt": {
                "type": "string",
                "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))$"
              },
              "requestId": { "type": "string", "minLength": 1 }
            },
            "additionalProperties": false
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": { "type": "string", "minLength": 1 },
              "retryable": { "type": "boolean" },
              "params": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": {}
              },
              "messageKey": { "type": "string", "minLength": 1 },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "retryable"],
            "additionalProperties": false
          },
          "activeArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "reprocessing": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "reason": {
                "type": "string",
                "enum": ["retry", "pipeline_upgrade"]
              },
              "targetPipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "state": {
                "type": "string",
                "enum": [
                  "requested",
                  "deferred",
                  "awaiting_rollout",
                  "done",
                  "failed"
                ]
              },
              "completedAt": {
                "type": "string",
                "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))$"
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1 },
                  "retryable": { "type": "boolean" },
                  "params": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": {}
                  },
                  "messageKey": { "type": "string", "minLength": 1 },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "retryable"],
                "additionalProperties": false
              }
            },
            "required": ["requestedAt", "requestedBy", "attempt"],
            "additionalProperties": false
          },
          "pageCount": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "pages": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "pageNumber": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "scanned": { "type": "boolean" },
                "sheetNumber": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 100,
                  "description": "Sheet number, e.g. \"W-101\" (BR-11)."
                },
                "title": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 200,
                  "description": "Sheet title, e.g. from the PDF outline (BR-11)."
                },
                "discipline": {
                  "type": "string",
                  "enum": [
                    "architecture",
                    "structure",
                    "mechanical",
                    "electrical",
                    "plumbing",
                    "fire_protection",
                    "civil",
                    "landscape",
                    "general"
                  ]
                },
                "storeyId": { "type": "string", "minLength": 1 },
                "overridden": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "enum": ["sheetNumber", "title", "discipline"]
                  }
                },
                "layout": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "kind": { "type": "string", "enum": ["model", "paper"] }
                  },
                  "required": ["name", "kind"],
                  "additionalProperties": false
                },
                "titleBlock": {
                  "type": "object",
                  "propertyNames": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 64
                  },
                  "additionalProperties": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "description": "FV-490 (E13 §4.4): a CAD page's primary title block, attribute tag -> value (<= 32 entries, values <= 200 chars)."
                },
                "scale": {
                  "type": "object",
                  "properties": {
                    "factor": {
                      "type": "number",
                      "exclusiveMinimum": 0,
                      "maximum": 10000,
                      "description": "Real millimetres per paper millimetre (1:50 is 50)."
                    },
                    "source": {
                      "type": "string",
                      "enum": ["calibration", "label"],
                      "description": "calibration: two points and a known length; label: the title-block scale, confirmed."
                    },
                    "basis": {
                      "description": "For a calibration: the two points (fractions of the page) and the real length in mm.",
                      "type": "object",
                      "properties": {
                        "a": {
                          "type": "object",
                          "properties": {
                            "xPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            },
                            "yPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            }
                          },
                          "required": ["xPct", "yPct"],
                          "additionalProperties": false
                        },
                        "b": {
                          "type": "object",
                          "properties": {
                            "xPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            },
                            "yPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            }
                          },
                          "required": ["xPct", "yPct"],
                          "additionalProperties": false
                        },
                        "lengthMm": { "type": "number", "exclusiveMinimum": 0 }
                      },
                      "required": ["a", "b", "lengthMm"],
                      "additionalProperties": false
                    },
                    "setBy": { "type": "string", "minLength": 1 },
                    "setAt": {
                      "type": "string",
                      "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))$"
                    }
                  },
                  "required": ["factor", "source", "setBy", "setAt"],
                  "additionalProperties": false
                }
              },
              "required": ["pageNumber", "scanned"],
              "additionalProperties": false
            }
          },
          "cad": {
            "type": "object",
            "properties": {
              "insunits": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "unitToMm": {
                "anyOf": [
                  { "type": "number", "exclusiveMinimum": 0 },
                  { "type": "null" }
                ]
              },
              "unitsOverride": {
                "type": "string",
                "enum": ["mm", "cm", "m", "in", "ft"],
                "description": "The drawing's units, set by a publisher because the file declares none: mm, cm, m, in or ft."
              },
              "defaultLayersOff": {
                "maxItems": 256,
                "type": "array",
                "items": { "type": "string", "minLength": 1, "maxLength": 255 },
                "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
              },
              "parser": { "type": "string", "const": "acad-ts" },
              "parserVersion": { "type": "string", "minLength": 1 },
              "version": { "type": "string", "minLength": 1 },
              "layoutCount": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "insunits",
              "unitToMm",
              "parser",
              "parserVersion",
              "version",
              "layoutCount"
            ],
            "additionalProperties": false
          },
          "layerDefault": {
            "type": "object",
            "properties": {
              "off": {
                "maxItems": 256,
                "type": "array",
                "items": { "type": "string", "minLength": 1, "maxLength": 255 },
                "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
              }
            },
            "required": ["off"],
            "additionalProperties": false,
            "description": "The layers off by default for everyone who opens this drawing (CAD layers or PDF optional content groups, by name). A person's own choice on their device still wins."
          },
          "publishOnReady": {
            "description": "Publish this version automatically, in the same write that marks it ready (FV-745).",
            "type": "boolean"
          },
          "releasedAt": {
            "type": "string",
            "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))$"
          },
          "supersededAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "documentId",
          "versionNumber",
          "status",
          "publication",
          "fieldVisible",
          "source",
          "pipelineVersion",
          "warnings",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "completeModelVersionUploadInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "modelId", "versionId"],
        "additionalProperties": false
      },
      "completeModelVersionUploadOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": [
              "uploading",
              "uploaded",
              "processing",
              "ready",
              "failed",
              "archived",
              "cancelled"
            ]
          },
          "publication": {
            "type": "string",
            "enum": ["draft", "published", "superseded"]
          },
          "fieldVisible": { "type": "boolean" },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "upload" },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "fileName", "sizeBytes", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "copy" },
                  "sourceVersionId": {
                    "type": "string",
                    "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A ver identifier (TypeID, conventions C5)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": [
                  "kind",
                  "sourceVersionId",
                  "fileName",
                  "sizeBytes",
                  "contentType"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "url" },
                  "url": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 2048,
                    "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "url", "fileName", "contentType"],
                "additionalProperties": false
              }
            ]
          },
          "upload": {
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "cancelReason": { "type": "string", "enum": ["user", "expired"] },
          "pipelineVersion": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": { "type": "string" },
                "blocking": { "type": "boolean" },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": {}
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": { "type": "string", "minLength": 1 },
              "retryable": { "type": "boolean" },
              "params": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": {}
              },
              "messageKey": { "type": "string", "minLength": 1 },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "retryable"],
            "additionalProperties": false
          },
          "processing": {
            "type": "object",
            "properties": {
              "sizeClass": { "type": "string", "enum": ["s", "m", "l", "xl"] },
              "executionName": { "type": "string", "minLength": 1 },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "queuedAt": {
                "type": "string",
                "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))$"
              },
              "queuedTraceparent": {
                "type": "string",
                "pattern": "^(?!ff)[0-9a-f]{2}-(?!0{32})[0-9a-f]{32}-(?!0{16})[0-9a-f]{16}-[0-9a-f]{2}$"
              },
              "queuedEscalation": {
                "type": "object",
                "properties": {
                  "sizeClass": {
                    "type": "string",
                    "enum": ["s", "m", "l", "xl"]
                  },
                  "attempt": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["sizeClass", "attempt"],
                "additionalProperties": false
              },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "progressReportedAt": {
                "type": "string",
                "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))$"
              },
              "requestId": { "type": "string", "minLength": 1 }
            },
            "additionalProperties": false
          },
          "progress": {
            "type": "object",
            "properties": {
              "stage": { "type": "string", "minLength": 1 },
              "percent": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["stage", "percent"],
            "additionalProperties": false
          },
          "reprocessing": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "reason": {
                "type": "string",
                "enum": ["retry", "pipeline_upgrade"]
              },
              "targetPipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "state": {
                "type": "string",
                "enum": [
                  "requested",
                  "deferred",
                  "awaiting_rollout",
                  "done",
                  "failed"
                ]
              },
              "completedAt": {
                "type": "string",
                "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))$"
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1 },
                  "retryable": { "type": "boolean" },
                  "params": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": {}
                  },
                  "messageKey": { "type": "string", "minLength": 1 },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "retryable"],
                "additionalProperties": false
              }
            },
            "required": ["requestedAt", "requestedBy", "attempt"],
            "additionalProperties": false
          },
          "releasedAt": {
            "type": "string",
            "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))$"
          },
          "releasedBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "supersededAt": {
            "type": "string",
            "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))$"
          },
          "activeArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "nextArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "stats": {
            "type": "object",
            "properties": {
              "elementCount": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "boundsMm": {
                "type": "object",
                "properties": {
                  "min": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3
                  },
                  "max": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3
                  }
                },
                "required": ["min", "max"],
                "additionalProperties": false
              },
              "coveragePct": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["elementCount", "boundsMm"],
            "additionalProperties": false
          },
          "churn": {
            "type": "object",
            "properties": {
              "ratio": { "type": "number", "minimum": 0, "maximum": 1 },
              "added": { "type": "array", "items": { "type": "string" } },
              "removed": { "type": "array", "items": { "type": "string" } },
              "moved": { "type": "array", "items": { "type": "string" } },
              "recreated": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "from": { "type": "string" },
                    "to": { "type": "string" }
                  },
                  "required": ["from", "to"],
                  "additionalProperties": false
                }
              }
            },
            "required": ["ratio", "added", "removed", "moved", "recreated"],
            "additionalProperties": false
          },
          "label": {
            "type": "string",
            "minLength": 1,
            "maxLength": 40,
            "description": "Short version name, e.g. \"Roof fix\" (1-40 chars after trimming, BR-10)."
          },
          "notes": {
            "type": "string",
            "maxLength": 2000,
            "description": "Free-form notes for the crew (max 2000 chars, BR-10)."
          },
          "detailsEditedAt": {
            "type": "string",
            "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))$"
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "publishOnReady": {
            "description": "Publish this version automatically, in the same write that marks it ready (FV-383).",
            "type": "boolean"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "modelId",
          "versionNumber",
          "status",
          "publication",
          "fieldVisible",
          "source",
          "pipelineVersion",
          "warnings",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "convertTryoutInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "organizationName": {
            "type": "string",
            "minLength": 2,
            "maxLength": 80,
            "description": "Organisation display name (2-80 chars after trimming, BR-10)."
          },
          "locale": {
            "type": "string",
            "enum": ["nl", "en", "fr"],
            "description": "The organisation's default language (nl, en or fr)."
          },
          "legalAcceptance": {
            "type": "object",
            "properties": {
              "termsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "privacyVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "dpaVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "subprocessorsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              }
            },
            "required": [
              "termsVersion",
              "privacyVersion",
              "dpaVersion",
              "subprocessorsVersion"
            ],
            "additionalProperties": false,
            "description": "The current terms, privacy notice, DPA and sub-processor list versions the caller accepts for the organisation (from the legal documents list). Required."
          }
        },
        "required": [
          "organizationId",
          "organizationName",
          "locale",
          "legalAcceptance"
        ],
        "additionalProperties": false
      },
      "convertTryoutOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 2,
            "maxLength": 80,
            "description": "Organisation display name (2-80 chars after trimming, BR-10)."
          },
          "defaultLocale": {
            "type": "string",
            "enum": ["nl", "en", "fr"],
            "description": "The organisation's default UI locale, one of nl | en | fr."
          },
          "status": {
            "type": "string",
            "enum": ["active", "pending_deletion"]
          },
          "deletion": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "purgeAfter": {
                "type": "string",
                "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))$"
              },
              "cancelledAt": {
                "type": "string",
                "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))$"
              },
              "purgeStartedAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["requestedAt", "requestedBy", "purgeAfter"],
            "additionalProperties": false
          },
          "supportAccess": {
            "description": "Whether Field-Viewer support may open a read-only support session: allowed (default when absent; owners are e-mailed) or ask (an owner approves each request first).",
            "type": "string",
            "enum": ["allowed", "ask"]
          },
          "settings": {
            "type": "object",
            "properties": {
              "analytics": {
                "type": "object",
                "properties": {
                  "mode": {
                    "type": "string",
                    "enum": ["enabled", "disabled"],
                    "description": "Product analytics for every member: enabled (the default) or disabled. Disabled, no usage event is recorded for anyone in the organisation."
                  }
                },
                "required": ["mode"],
                "additionalProperties": false
              },
              "cad": {
                "type": "object",
                "properties": {
                  "producerDetailTags": {
                    "type": "object",
                    "properties": {
                      "scale": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's scale text (1:n)."
                      },
                      "xFactor": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's x factor (1/n)."
                      },
                      "yFactor": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's y factor (1/n)."
                      },
                      "xMin": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's minimum x."
                      },
                      "yMin": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's minimum y."
                      },
                      "xMax": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's maximum x."
                      },
                      "yMax": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's maximum y."
                      }
                    },
                    "required": [
                      "scale",
                      "xFactor",
                      "yFactor",
                      "xMin",
                      "yMin",
                      "xMax",
                      "yMax"
                    ],
                    "additionalProperties": false,
                    "description": "The CAD producer's detail attribute tags: all seven, each the tag (not the value) of one block attribute. With them, scaled details in model space measure in real millimetres at their own scale; without them they read 'scale unknown'."
                  }
                },
                "additionalProperties": false
              }
            },
            "additionalProperties": false
          },
          "legal": {
            "type": "object",
            "properties": {
              "termsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "privacyVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "dpaVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "subprocessorsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "acceptedAt": {
                "type": "string",
                "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))$"
              },
              "acceptedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              }
            },
            "required": [
              "termsVersion",
              "privacyVersion",
              "dpaVersion",
              "subprocessorsVersion",
              "acceptedAt",
              "acceptedBy"
            ],
            "additionalProperties": false,
            "description": "The terms, privacy notice, DPA and sub-processor list versions an owner accepted for the organisation."
          },
          "kind": {
            "description": "standard (default when absent) or tryout: an anonymous visitor's 7-day try-it organisation.",
            "type": "string",
            "enum": ["standard", "tryout"]
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "logoUrl": {
            "type": "object",
            "properties": {
              "url": { "type": "string" },
              "expiresAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["url", "expiresAt"],
            "additionalProperties": false,
            "description": "Signed URL of the organisation's logo (15 minutes). Absent when it has no logo."
          },
          "reacceptanceRequired": {
            "description": "True when an owner must accept a newer material version of the terms, the DPA or the sub-processor list (or never accepted them).",
            "type": "boolean"
          }
        },
        "required": [
          "id",
          "name",
          "defaultLocale",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "createAnnotationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "id": {
            "description": "Optional client-generated ann_ id (C11, offline outbox). Omit to let the server generate one.",
            "type": "string",
            "pattern": "^ann_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
          },
          "subtype": {
            "type": "string",
            "enum": ["measurement"],
            "description": "Annotation subtype; only 'measurement' exists today."
          },
          "visibility": {
            "description": "personal (only you) or shared (everyone in the project). Default personal; shared for a workstation.",
            "type": "string",
            "enum": ["personal", "shared"]
          },
          "measurement": {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "distance",
                  "edgeLength",
                  "angle",
                  "areaFace",
                  "perpendicularPointFace",
                  "perpendicularFaceFace",
                  "areaPolygon",
                  "overallDimensions"
                ]
              },
              "anchors": {
                "minItems": 1,
                "maxItems": 100,
                "type": "array",
                "items": {
                  "oneOf": [
                    {
                      "type": "object",
                      "properties": {
                        "kind": { "type": "string", "const": "element" },
                        "globalId": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 64,
                          "description": "IFC GlobalId of the anchored element."
                        },
                        "modelId": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        },
                        "versionId": {
                          "type": "string",
                          "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A ver identifier (TypeID, conventions C5)."
                        },
                        "localPointMm": {
                          "type": "object",
                          "properties": {
                            "x": { "type": "number" },
                            "y": { "type": "number" },
                            "z": { "type": "number" }
                          },
                          "required": ["x", "y", "z"],
                          "additionalProperties": false,
                          "description": "Snapped point in the version's coordinates, millimetres."
                        },
                        "edgeDirection": {
                          "description": "For an angle taken off an edge: the edge's unit direction in the version's coordinates.",
                          "type": "object",
                          "properties": {
                            "x": { "type": "number" },
                            "y": { "type": "number" },
                            "z": { "type": "number" }
                          },
                          "required": ["x", "y", "z"],
                          "additionalProperties": false
                        },
                        "faceNormal": {
                          "description": "For an angle or a face area taken off a face: the face's unit normal in the version's coordinates.",
                          "type": "object",
                          "properties": {
                            "x": { "type": "number" },
                            "y": { "type": "number" },
                            "z": { "type": "number" }
                          },
                          "required": ["x", "y", "z"],
                          "additionalProperties": false
                        }
                      },
                      "required": ["globalId", "versionId", "localPointMm"],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "kind": { "type": "string", "const": "document" },
                        "documentId": {
                          "type": "string",
                          "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A doc identifier (TypeID, conventions C5)."
                        },
                        "documentVersionId": {
                          "type": "string",
                          "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A dvr identifier (TypeID, conventions C5)."
                        },
                        "page": {
                          "type": "integer",
                          "minimum": 1,
                          "maximum": 9007199254740991,
                          "description": "1-based page (sheet) number."
                        },
                        "point": {
                          "type": "object",
                          "properties": {
                            "x": { "type": "number" },
                            "y": { "type": "number" }
                          },
                          "required": ["x", "y"],
                          "additionalProperties": false,
                          "description": "The point on the page, in the page's drawing units."
                        },
                        "entityHandle": {
                          "description": "The CAD entity handle the point snapped to.",
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 32
                        },
                        "snapKind": {
                          "description": "How the point snapped; absent for a free point.",
                          "type": "string",
                          "enum": [
                            "endpoint",
                            "intersection",
                            "midpoint",
                            "centre",
                            "quadrant",
                            "perpendicular",
                            "nearest"
                          ]
                        }
                      },
                      "required": [
                        "kind",
                        "documentId",
                        "documentVersionId",
                        "page",
                        "point"
                      ],
                      "additionalProperties": false
                    }
                  ]
                }
              },
              "valueMm": { "type": "number", "minimum": 0 },
              "valueDeg": { "type": "number", "minimum": 0, "maximum": 180 },
              "valueM2": { "type": "number", "minimum": 0 },
              "axisComponentsMm": {
                "type": "object",
                "properties": {
                  "dx": { "type": "number" },
                  "dy": { "type": "number" },
                  "dz": { "type": "number" }
                },
                "required": ["dx", "dy", "dz"],
                "additionalProperties": false
              },
              "vertexIndex": {
                "description": "For a three-point angle: the index of the anchor the angle is measured at (its vertex).",
                "type": "integer",
                "minimum": 0,
                "maximum": 2
              },
              "slopeReference": {
                "description": "For a slope (an angle with one anchor): what its edge or face is measured against.",
                "type": "string",
                "enum": ["horizontal", "vertical"]
              },
              "dimensions": {
                "minItems": 1,
                "maxItems": 3,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": {
                      "type": "string",
                      "enum": ["length", "width", "height", "thickness"]
                    },
                    "valueMm": { "type": "number", "minimum": 0 },
                    "axis": {
                      "type": "object",
                      "properties": {
                        "x": { "type": "number" },
                        "y": { "type": "number" },
                        "z": { "type": "number" }
                      },
                      "required": ["x", "y", "z"],
                      "additionalProperties": false
                    }
                  },
                  "required": ["name", "valueMm", "axis"],
                  "additionalProperties": false
                }
              },
              "tessellated": { "type": "boolean" },
              "inPlane": {
                "description": "For a distance, edge length or angle measured in a view: the view's normal and the value in its plane.",
                "type": "object",
                "properties": {
                  "normal": {
                    "type": "object",
                    "properties": {
                      "x": { "type": "number" },
                      "y": { "type": "number" },
                      "z": { "type": "number" }
                    },
                    "required": ["x", "y", "z"],
                    "additionalProperties": false,
                    "description": "The view's unit normal (towards the viewer) in the version's coordinates."
                  },
                  "valueMm": {
                    "description": "A distance's length in the view plane, millimetres.",
                    "type": "number",
                    "minimum": 0
                  },
                  "valueDeg": {
                    "description": "An angle as the view showed it, degrees.",
                    "type": "number",
                    "minimum": 0,
                    "maximum": 180
                  }
                },
                "required": ["normal"],
                "additionalProperties": false
              },
              "basis": {
                "description": "For a drawing measurement: real (read at the drawing's scale) or paper (millimetres on the sheet, no scale). Absent means real.",
                "type": "string",
                "enum": ["real", "paper"]
              }
            },
            "required": ["kind", "anchors", "tessellated"],
            "additionalProperties": false,
            "description": "kind, anchors (2 for distance/edgeLength/angle/perpendicular*, 1 for areaFace, 3-100 for areaPolygon), the kind's value (valueMm, valueDeg or valueM2) and tessellated. Anchors are on model elements, or (kind: 'document') all on one page of one drawing version."
          },
          "label": {
            "type": "string",
            "minLength": 1,
            "maxLength": 60,
            "description": "User-given name, 1-60 chars after trimming."
          },
          "viewpoint": {
            "description": "What to restore when the measurement is reopened: the camera, or for a drawing measurement the sheet's view (document: page, centre, scale).",
            "type": "object",
            "properties": {
              "camera": {
                "type": "object",
                "properties": {
                  "position": {
                    "type": "object",
                    "properties": {
                      "x": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "y": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "z": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      }
                    },
                    "required": ["x", "y", "z"],
                    "additionalProperties": false
                  },
                  "target": {
                    "type": "object",
                    "properties": {
                      "x": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "y": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "z": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      }
                    },
                    "required": ["x", "y", "z"],
                    "additionalProperties": false
                  },
                  "up": { "type": "string", "const": "z" },
                  "fovDeg": { "type": "number", "minimum": 20, "maximum": 90 },
                  "orthoHeightM": { "type": "number", "exclusiveMinimum": 0 }
                },
                "additionalProperties": false
              },
              "document": {
                "type": "object",
                "properties": {
                  "page": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 9007199254740991
                  },
                  "cad": {
                    "type": "object",
                    "properties": {
                      "center": {
                        "type": "object",
                        "properties": {
                          "x": { "type": "number" },
                          "y": { "type": "number" }
                        },
                        "required": ["x", "y"],
                        "additionalProperties": false
                      },
                      "scale": { "type": "number", "exclusiveMinimum": 0 }
                    },
                    "required": ["center", "scale"],
                    "additionalProperties": false
                  }
                },
                "required": ["page", "cad"],
                "additionalProperties": false
              }
            },
            "additionalProperties": false
          }
        },
        "required": ["organizationId", "projectId", "subtype", "measurement"],
        "additionalProperties": false
      },
      "createAnnotationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ann_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ann identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "subtype": { "type": "string", "enum": ["measurement"] },
          "visibility": { "type": "string", "enum": ["personal", "shared"] },
          "measurement": {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "distance",
                  "edgeLength",
                  "angle",
                  "areaFace",
                  "perpendicularPointFace",
                  "perpendicularFaceFace",
                  "areaPolygon",
                  "overallDimensions"
                ]
              },
              "anchors": {
                "minItems": 1,
                "maxItems": 100,
                "type": "array",
                "items": {
                  "oneOf": [
                    {
                      "type": "object",
                      "properties": {
                        "kind": { "type": "string", "const": "element" },
                        "globalId": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 64,
                          "description": "IFC GlobalId of the anchored element."
                        },
                        "modelId": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        },
                        "versionId": {
                          "type": "string",
                          "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A ver identifier (TypeID, conventions C5)."
                        },
                        "localPointMm": {
                          "type": "object",
                          "properties": {
                            "x": { "type": "number" },
                            "y": { "type": "number" },
                            "z": { "type": "number" }
                          },
                          "required": ["x", "y", "z"],
                          "additionalProperties": false,
                          "description": "Snapped point in the version's coordinates, millimetres."
                        },
                        "edgeDirection": {
                          "description": "For an angle taken off an edge: the edge's unit direction in the version's coordinates.",
                          "type": "object",
                          "properties": {
                            "x": { "type": "number" },
                            "y": { "type": "number" },
                            "z": { "type": "number" }
                          },
                          "required": ["x", "y", "z"],
                          "additionalProperties": false
                        },
                        "faceNormal": {
                          "description": "For an angle or a face area taken off a face: the face's unit normal in the version's coordinates.",
                          "type": "object",
                          "properties": {
                            "x": { "type": "number" },
                            "y": { "type": "number" },
                            "z": { "type": "number" }
                          },
                          "required": ["x", "y", "z"],
                          "additionalProperties": false
                        }
                      },
                      "required": ["globalId", "versionId", "localPointMm"],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "kind": { "type": "string", "const": "document" },
                        "documentId": {
                          "type": "string",
                          "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A doc identifier (TypeID, conventions C5)."
                        },
                        "documentVersionId": {
                          "type": "string",
                          "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A dvr identifier (TypeID, conventions C5)."
                        },
                        "page": {
                          "type": "integer",
                          "minimum": 1,
                          "maximum": 9007199254740991,
                          "description": "1-based page (sheet) number."
                        },
                        "point": {
                          "type": "object",
                          "properties": {
                            "x": { "type": "number" },
                            "y": { "type": "number" }
                          },
                          "required": ["x", "y"],
                          "additionalProperties": false,
                          "description": "The point on the page, in the page's drawing units."
                        },
                        "entityHandle": {
                          "description": "The CAD entity handle the point snapped to.",
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 32
                        },
                        "snapKind": {
                          "description": "How the point snapped; absent for a free point.",
                          "type": "string",
                          "enum": [
                            "endpoint",
                            "intersection",
                            "midpoint",
                            "centre",
                            "quadrant",
                            "perpendicular",
                            "nearest"
                          ]
                        }
                      },
                      "required": [
                        "kind",
                        "documentId",
                        "documentVersionId",
                        "page",
                        "point"
                      ],
                      "additionalProperties": false
                    }
                  ]
                }
              },
              "valueMm": { "type": "number", "minimum": 0 },
              "valueDeg": { "type": "number", "minimum": 0, "maximum": 180 },
              "valueM2": { "type": "number", "minimum": 0 },
              "axisComponentsMm": {
                "type": "object",
                "properties": {
                  "dx": { "type": "number" },
                  "dy": { "type": "number" },
                  "dz": { "type": "number" }
                },
                "required": ["dx", "dy", "dz"],
                "additionalProperties": false
              },
              "vertexIndex": {
                "description": "For a three-point angle: the index of the anchor the angle is measured at (its vertex).",
                "type": "integer",
                "minimum": 0,
                "maximum": 2
              },
              "slopeReference": {
                "description": "For a slope (an angle with one anchor): what its edge or face is measured against.",
                "type": "string",
                "enum": ["horizontal", "vertical"]
              },
              "dimensions": {
                "minItems": 1,
                "maxItems": 3,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": {
                      "type": "string",
                      "enum": ["length", "width", "height", "thickness"]
                    },
                    "valueMm": { "type": "number", "minimum": 0 },
                    "axis": {
                      "type": "object",
                      "properties": {
                        "x": { "type": "number" },
                        "y": { "type": "number" },
                        "z": { "type": "number" }
                      },
                      "required": ["x", "y", "z"],
                      "additionalProperties": false
                    }
                  },
                  "required": ["name", "valueMm", "axis"],
                  "additionalProperties": false
                }
              },
              "tessellated": { "type": "boolean" },
              "inPlane": {
                "description": "For a distance, edge length or angle measured in a view: the view's normal and the value in its plane.",
                "type": "object",
                "properties": {
                  "normal": {
                    "type": "object",
                    "properties": {
                      "x": { "type": "number" },
                      "y": { "type": "number" },
                      "z": { "type": "number" }
                    },
                    "required": ["x", "y", "z"],
                    "additionalProperties": false,
                    "description": "The view's unit normal (towards the viewer) in the version's coordinates."
                  },
                  "valueMm": {
                    "description": "A distance's length in the view plane, millimetres.",
                    "type": "number",
                    "minimum": 0
                  },
                  "valueDeg": {
                    "description": "An angle as the view showed it, degrees.",
                    "type": "number",
                    "minimum": 0,
                    "maximum": 180
                  }
                },
                "required": ["normal"],
                "additionalProperties": false
              },
              "basis": {
                "description": "For a drawing measurement: real (read at the drawing's scale) or paper (millimetres on the sheet, no scale). Absent means real.",
                "type": "string",
                "enum": ["real", "paper"]
              }
            },
            "required": ["kind", "anchors", "tessellated"],
            "additionalProperties": false
          },
          "label": {
            "type": "string",
            "minLength": 1,
            "maxLength": 60,
            "description": "User-given name, 1-60 chars after trimming."
          },
          "needsCheck": {
            "type": "object",
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "geometry_changed",
                  "element_missing",
                  "drawing_changed"
                ]
              },
              "since": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["reason", "since"],
            "additionalProperties": false
          },
          "viewpoint": {
            "type": "object",
            "properties": {
              "camera": {
                "type": "object",
                "properties": {
                  "position": {
                    "type": "object",
                    "properties": {
                      "x": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "y": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "z": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      }
                    },
                    "required": ["x", "y", "z"],
                    "additionalProperties": false
                  },
                  "target": {
                    "type": "object",
                    "properties": {
                      "x": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "y": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "z": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      }
                    },
                    "required": ["x", "y", "z"],
                    "additionalProperties": false
                  },
                  "up": { "type": "string", "const": "z" },
                  "fovDeg": { "type": "number", "minimum": 20, "maximum": 90 },
                  "orthoHeightM": { "type": "number", "exclusiveMinimum": 0 }
                },
                "additionalProperties": false
              },
              "document": {
                "type": "object",
                "properties": {
                  "page": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 9007199254740991
                  },
                  "cad": {
                    "type": "object",
                    "properties": {
                      "center": {
                        "type": "object",
                        "properties": {
                          "x": { "type": "number" },
                          "y": { "type": "number" }
                        },
                        "required": ["x", "y"],
                        "additionalProperties": false
                      },
                      "scale": { "type": "number", "exclusiveMinimum": 0 }
                    },
                    "required": ["center", "scale"],
                    "additionalProperties": false
                  }
                },
                "required": ["page", "cad"],
                "additionalProperties": false
              }
            },
            "additionalProperties": false
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "subtype",
          "visibility",
          "measurement",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "createApiTokenInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": { "type": "string", "minLength": 1, "maxLength": 100 },
          "scopes": {
            "minItems": 1,
            "type": "array",
            "items": {
              "type": "string",
              "minLength": 1,
              "description": "A capability id (e.g. \"project.read\") or bundle: fv.read | fv.write | fv.full."
            }
          },
          "expiresInDays": {
            "description": "1-365 days (BR-9). Defaults to 90.",
            "type": "integer",
            "minimum": 1,
            "maximum": 365
          },
          "id": {
            "description": "Optional client-generated id (C11). Omit to let the server generate one.",
            "type": "string",
            "pattern": "^tok_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
          }
        },
        "required": ["organizationId", "name", "scopes"],
        "additionalProperties": false
      },
      "createApiTokenOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^tok_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A tok identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": { "type": "string", "minLength": 1 },
          "ownerUid": { "type": "string", "minLength": 1 },
          "scopes": {
            "type": "array",
            "items": { "type": "string", "minLength": 1 }
          },
          "status": { "type": "string", "enum": ["active", "revoked"] },
          "tokenPrefix": { "type": "string", "minLength": 1 },
          "previousSecretGraceUntil": {
            "type": "string",
            "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))$"
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "lastUsedAt": {
            "type": "string",
            "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))$"
          },
          "revokedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "secret": {
            "type": "string",
            "description": "The raw bearer secret -- shown here ONCE (AC-1). Never retrievable again; lost means rotate."
          }
        },
        "required": [
          "id",
          "organizationId",
          "name",
          "scopes",
          "status",
          "tokenPrefix",
          "expiresAt",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy",
          "secret"
        ],
        "additionalProperties": false
      },
      "createBetaAccessCodeInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "boundEmail": {
            "type": "string",
            "format": "email",
            "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$",
            "description": "The reviewed lead's e-mail address (case-insensitive)."
          },
          "maxRedemptions": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991,
            "description": "How many organisations this code may be redeemed into."
          },
          "expiresInDays": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 365,
            "description": "Days from now until the code expires."
          }
        },
        "required": ["boundEmail", "maxRedemptions", "expiresInDays"],
        "additionalProperties": false
      },
      "createBetaAccessCodeOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "description": "The bac_ TypeID of the new code."
          },
          "code": {
            "type": "string",
            "pattern": "^[23456789ABCDEFGHJKLMNPQRSTUVWXYZ]{10}$",
            "description": "10-character opaque code, unambiguous alphabet (no 0/O/1/I)."
          },
          "boundEmail": {
            "type": "string",
            "format": "email",
            "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
          },
          "maxRedemptions": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "redeemedCount": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": ["active", "revoked", "exhausted"]
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "createdAt": {
            "type": "string",
            "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))$"
          }
        },
        "required": [
          "id",
          "code",
          "boundEmail",
          "maxRedemptions",
          "redeemedCount",
          "status",
          "expiresAt",
          "createdAt"
        ],
        "additionalProperties": false
      },
      "createBillingPortalSessionInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "flow": {
            "description": "Opens one task directly: change the payment method, cancel, or switch the interval.",
            "type": "string",
            "enum": [
              "payment_method_update",
              "subscription_cancel",
              "subscription_update"
            ]
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "createBillingPortalSessionOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "url": {
            "type": "string",
            "format": "uri",
            "description": "The provider's Customer Portal; the browser navigates there (never a frame). Single use, valid for a few minutes."
          }
        },
        "required": ["url"],
        "additionalProperties": false
      },
      "createCheckoutSessionInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "interval": { "type": "string", "enum": ["month", "year"] },
          "expectedPriceRevision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991,
            "description": "The `price.revision` the screen showed (`getBillingAccount`); an older one is `409 billing.price_changed`."
          }
        },
        "required": ["organizationId", "interval", "expectedPriceRevision"],
        "additionalProperties": false
      },
      "createCheckoutSessionOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "url": {
            "type": "string",
            "format": "uri",
            "description": "The provider's hosted payment page; the browser navigates there (never a frame)."
          },
          "expiresAt": {
            "type": "string",
            "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))$",
            "description": "When the payment page stops working."
          }
        },
        "required": ["url", "expiresAt"],
        "additionalProperties": false
      },
      "createDocumentInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "title": {
            "type": "string",
            "minLength": 1,
            "maxLength": 200,
            "description": "Document display title (1-200 chars after trimming)."
          },
          "id": {
            "description": "Optional client-generated id (C11). Omit to let the server generate one.",
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
          }
        },
        "required": ["organizationId", "projectId"],
        "additionalProperties": false
      },
      "createDocumentOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "title": {
            "type": "string",
            "minLength": 1,
            "maxLength": 200,
            "description": "Document display title (1-200 chars after trimming)."
          },
          "status": {
            "type": "string",
            "enum": ["active", "archived", "deleted"]
          },
          "nextVersionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "format": { "type": "string", "enum": ["pdf", "dxf", "dwg"] },
          "published": {
            "type": "object",
            "properties": {
              "versionId": {
                "type": "string",
                "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A dvr identifier (TypeID, conventions C5)."
              },
              "publishedAt": {
                "type": "string",
                "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))$"
              },
              "publishedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              },
              "publishSeq": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "versionId",
              "publishedAt",
              "publishedBy",
              "publishSeq"
            ],
            "additionalProperties": false
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "deletedAt": {
            "type": "string",
            "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))$"
          },
          "purgeAfter": {
            "type": "string",
            "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))$"
          },
          "statusBeforeDeletion": {
            "type": "string",
            "enum": ["active", "archived"]
          },
          "purgeStartedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "status",
          "nextVersionNumber",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "createDocumentVersionInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "fileName": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
          },
          "sizeBytes": {
            "description": "The file's size in bytes (BR-3). Required for an upload; leave out with source.kind url.",
            "type": "integer",
            "minimum": 1,
            "maximum": 1073741824
          },
          "contentType": {
            "type": "string",
            "minLength": 1,
            "description": "The source file's MIME type: application/pdf for a PDF; for a DXF or DWG whatever the browser reports (often application/octet-stream)."
          },
          "sha256": {
            "type": "string",
            "pattern": "^[0-9a-f]{64}$",
            "description": "Optional SHA-256 of the source file, 64 hex chars."
          },
          "id": {
            "description": "Optional client-generated id (C11). Omit to let the server generate one.",
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
          },
          "source": {
            "type": "object",
            "properties": {
              "kind": { "type": "string", "const": "url" },
              "url": {
                "type": "string",
                "minLength": 1,
                "maxLength": 2048,
                "description": "Where to download the file: a public HTTPS URL (at most 2,048 characters, no user:password@), e.g. a signed CDN or cloud-storage link. It must stay valid for 25 minutes. Only its scheme, host and path are stored; the query string is not."
              },
              "sha256": {
                "description": "Optional SHA-256 of the file (64 hex). A download that does not match fails with import.checksum_mismatch.",
                "type": "string",
                "pattern": "^[0-9a-f]{64}$"
              }
            },
            "required": ["kind", "url"],
            "additionalProperties": false,
            "description": "Import the file from a URL instead of uploading it: the server downloads it and the response carries no `upload` ticket. Leave out sizeBytes and the top-level sha256."
          }
        },
        "required": [
          "organizationId",
          "projectId",
          "documentId",
          "fileName",
          "contentType"
        ],
        "additionalProperties": false
      },
      "createDocumentVersionOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dvr identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": [
              "uploading",
              "uploaded",
              "processing",
              "ready",
              "failed",
              "archived",
              "cancelled"
            ]
          },
          "publication": {
            "type": "string",
            "enum": ["draft", "published", "superseded"]
          },
          "fieldVisible": { "type": "boolean" },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "upload" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "fileName", "sizeBytes", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "url" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "url": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 2048,
                    "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "url", "fileName", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "copy" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "sourceVersionId": {
                    "type": "string",
                    "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A dvr identifier (TypeID, conventions C5)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": [
                  "kind",
                  "sourceVersionId",
                  "fileName",
                  "sizeBytes",
                  "contentType"
                ],
                "additionalProperties": false
              }
            ]
          },
          "upload": {
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          },
          "cancelReason": { "type": "string", "enum": ["user"] },
          "pipelineVersion": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": { "type": "string" },
                "blocking": { "type": "boolean" },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": {}
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "progress": {
            "type": "object",
            "properties": {
              "stage": { "type": "string", "minLength": 1 },
              "percent": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["stage", "percent"],
            "additionalProperties": false
          },
          "processing": {
            "type": "object",
            "properties": {
              "sizeClass": { "type": "string", "enum": ["s", "m", "l", "xl"] },
              "executionName": { "type": "string", "minLength": 1 },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "queuedAt": {
                "type": "string",
                "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))$"
              },
              "queuedTraceparent": {
                "type": "string",
                "pattern": "^(?!ff)[0-9a-f]{2}-(?!0{32})[0-9a-f]{32}-(?!0{16})[0-9a-f]{16}-[0-9a-f]{2}$"
              },
              "queuedEscalation": {
                "type": "object",
                "properties": {
                  "sizeClass": {
                    "type": "string",
                    "enum": ["s", "m", "l", "xl"]
                  },
                  "attempt": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["sizeClass", "attempt"],
                "additionalProperties": false
              },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "progressReportedAt": {
                "type": "string",
                "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))$"
              },
              "requestId": { "type": "string", "minLength": 1 }
            },
            "additionalProperties": false
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": { "type": "string", "minLength": 1 },
              "retryable": { "type": "boolean" },
              "params": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": {}
              },
              "messageKey": { "type": "string", "minLength": 1 },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "retryable"],
            "additionalProperties": false
          },
          "activeArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "reprocessing": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "reason": {
                "type": "string",
                "enum": ["retry", "pipeline_upgrade"]
              },
              "targetPipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "state": {
                "type": "string",
                "enum": [
                  "requested",
                  "deferred",
                  "awaiting_rollout",
                  "done",
                  "failed"
                ]
              },
              "completedAt": {
                "type": "string",
                "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))$"
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1 },
                  "retryable": { "type": "boolean" },
                  "params": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": {}
                  },
                  "messageKey": { "type": "string", "minLength": 1 },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "retryable"],
                "additionalProperties": false
              }
            },
            "required": ["requestedAt", "requestedBy", "attempt"],
            "additionalProperties": false
          },
          "pageCount": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "pages": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "pageNumber": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "scanned": { "type": "boolean" },
                "sheetNumber": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 100,
                  "description": "Sheet number, e.g. \"W-101\" (BR-11)."
                },
                "title": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 200,
                  "description": "Sheet title, e.g. from the PDF outline (BR-11)."
                },
                "discipline": {
                  "type": "string",
                  "enum": [
                    "architecture",
                    "structure",
                    "mechanical",
                    "electrical",
                    "plumbing",
                    "fire_protection",
                    "civil",
                    "landscape",
                    "general"
                  ]
                },
                "storeyId": { "type": "string", "minLength": 1 },
                "overridden": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "enum": ["sheetNumber", "title", "discipline"]
                  }
                },
                "layout": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "kind": { "type": "string", "enum": ["model", "paper"] }
                  },
                  "required": ["name", "kind"],
                  "additionalProperties": false
                },
                "titleBlock": {
                  "type": "object",
                  "propertyNames": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 64
                  },
                  "additionalProperties": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "description": "FV-490 (E13 §4.4): a CAD page's primary title block, attribute tag -> value (<= 32 entries, values <= 200 chars)."
                },
                "scale": {
                  "type": "object",
                  "properties": {
                    "factor": {
                      "type": "number",
                      "exclusiveMinimum": 0,
                      "maximum": 10000,
                      "description": "Real millimetres per paper millimetre (1:50 is 50)."
                    },
                    "source": {
                      "type": "string",
                      "enum": ["calibration", "label"],
                      "description": "calibration: two points and a known length; label: the title-block scale, confirmed."
                    },
                    "basis": {
                      "description": "For a calibration: the two points (fractions of the page) and the real length in mm.",
                      "type": "object",
                      "properties": {
                        "a": {
                          "type": "object",
                          "properties": {
                            "xPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            },
                            "yPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            }
                          },
                          "required": ["xPct", "yPct"],
                          "additionalProperties": false
                        },
                        "b": {
                          "type": "object",
                          "properties": {
                            "xPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            },
                            "yPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            }
                          },
                          "required": ["xPct", "yPct"],
                          "additionalProperties": false
                        },
                        "lengthMm": { "type": "number", "exclusiveMinimum": 0 }
                      },
                      "required": ["a", "b", "lengthMm"],
                      "additionalProperties": false
                    },
                    "setBy": { "type": "string", "minLength": 1 },
                    "setAt": {
                      "type": "string",
                      "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))$"
                    }
                  },
                  "required": ["factor", "source", "setBy", "setAt"],
                  "additionalProperties": false
                }
              },
              "required": ["pageNumber", "scanned"],
              "additionalProperties": false
            }
          },
          "cad": {
            "type": "object",
            "properties": {
              "insunits": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "unitToMm": {
                "anyOf": [
                  { "type": "number", "exclusiveMinimum": 0 },
                  { "type": "null" }
                ]
              },
              "unitsOverride": {
                "type": "string",
                "enum": ["mm", "cm", "m", "in", "ft"],
                "description": "The drawing's units, set by a publisher because the file declares none: mm, cm, m, in or ft."
              },
              "defaultLayersOff": {
                "maxItems": 256,
                "type": "array",
                "items": { "type": "string", "minLength": 1, "maxLength": 255 },
                "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
              },
              "parser": { "type": "string", "const": "acad-ts" },
              "parserVersion": { "type": "string", "minLength": 1 },
              "version": { "type": "string", "minLength": 1 },
              "layoutCount": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "insunits",
              "unitToMm",
              "parser",
              "parserVersion",
              "version",
              "layoutCount"
            ],
            "additionalProperties": false
          },
          "layerDefault": {
            "type": "object",
            "properties": {
              "off": {
                "maxItems": 256,
                "type": "array",
                "items": { "type": "string", "minLength": 1, "maxLength": 255 },
                "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
              }
            },
            "required": ["off"],
            "additionalProperties": false,
            "description": "The layers off by default for everyone who opens this drawing (CAD layers or PDF optional content groups, by name). A person's own choice on their device still wins."
          },
          "publishOnReady": {
            "description": "Publish this version automatically, in the same write that marks it ready (FV-745).",
            "type": "boolean"
          },
          "releasedAt": {
            "type": "string",
            "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))$"
          },
          "supersededAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "documentId",
          "versionNumber",
          "status",
          "publication",
          "fieldVisible",
          "source",
          "pipelineVersion",
          "warnings",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "createFeedbackInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "id": {
            "description": "Optional client-generated fbk_ id (C11, offline outbox). Omit to let the server generate one.",
            "type": "string",
            "pattern": "^fbk_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
          },
          "text": {
            "type": "string",
            "maxLength": 2000,
            "description": "What went wrong, in the reporter's own words (1-2000 chars)."
          },
          "category": {
            "description": "problem (the default when omitted) or support.",
            "type": "string",
            "enum": ["problem", "support"]
          },
          "screenshot": {
            "description": "Declare a screenshot to get an upload ticket for it; omit for a text-only report.",
            "type": "object",
            "properties": {
              "contentType": {
                "type": "string",
                "enum": ["image/png", "image/jpeg", "image/webp"],
                "description": "image/png, image/jpeg or image/webp."
              },
              "sizeBytes": {
                "type": "integer",
                "minimum": 1,
                "maximum": 5242880,
                "description": "The image size in bytes (max 5242880)."
              }
            },
            "required": ["contentType", "sizeBytes"],
            "additionalProperties": false
          },
          "context": {
            "type": "object",
            "properties": {
              "projectId": {
                "description": "The project open when the report was made, if any.",
                "type": "string",
                "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
              },
              "modelVersionId": {
                "description": "The model version open in the viewer, if any.",
                "type": "string",
                "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
              },
              "viewState": {
                "description": "A viewer deep link (E05-S16 format: ?c=camera&s=selection) reproducing the reporter's view.",
                "type": "string",
                "maxLength": 2048,
                "format": "uri"
              },
              "appVersion": {
                "type": "string",
                "minLength": 1,
                "maxLength": 64,
                "description": "The app build the report came from."
              },
              "locale": {
                "type": "string",
                "enum": ["nl", "en", "fr"],
                "description": "The app language at the time (nl, en or fr)."
              },
              "url": {
                "type": "string",
                "maxLength": 2048,
                "format": "uri",
                "description": "The page the report was made on."
              }
            },
            "required": ["appVersion", "locale", "url"],
            "additionalProperties": false,
            "description": "Captured by the app: projectId?, modelVersionId?, viewState? (deep link), appVersion, locale, url."
          }
        },
        "required": ["organizationId", "text", "context"],
        "additionalProperties": false
      },
      "createFeedbackOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^fbk_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A fbk identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "text": { "type": "string", "minLength": 1, "maxLength": 2000 },
          "category": { "type": "string", "enum": ["problem", "support"] },
          "screenshot": {
            "type": "object",
            "properties": {
              "contentType": {
                "type": "string",
                "enum": ["image/png", "image/jpeg", "image/webp"],
                "description": "image/png, image/jpeg or image/webp."
              },
              "sizeBytes": {
                "type": "integer",
                "minimum": 1,
                "maximum": 5242880,
                "description": "The image size in bytes (max 5242880)."
              },
              "objectPath": { "type": "string", "minLength": 1 }
            },
            "required": ["contentType", "sizeBytes", "objectPath"],
            "additionalProperties": false
          },
          "context": {
            "type": "object",
            "properties": {
              "projectId": {
                "description": "The project open when the report was made, if any.",
                "type": "string",
                "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
              },
              "modelVersionId": {
                "description": "The model version open in the viewer, if any.",
                "type": "string",
                "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
              },
              "viewState": {
                "description": "A viewer deep link (E05-S16 format: ?c=camera&s=selection) reproducing the reporter's view.",
                "type": "string",
                "maxLength": 2048,
                "format": "uri"
              },
              "appVersion": {
                "type": "string",
                "minLength": 1,
                "maxLength": 64,
                "description": "The app build the report came from."
              },
              "locale": {
                "type": "string",
                "enum": ["nl", "en", "fr"],
                "description": "The app language at the time (nl, en or fr)."
              },
              "url": {
                "type": "string",
                "maxLength": 2048,
                "format": "uri",
                "description": "The page the report was made on."
              }
            },
            "required": ["appVersion", "locale", "url"],
            "additionalProperties": false
          },
          "status": { "type": "string", "enum": ["new"] },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "upload": {
            "description": "Present when a screenshot was declared: PUT the image bytes to upload.url (C13).",
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "text",
          "context",
          "status",
          "schemaVersion",
          "createdAt",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "createInvitationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "email": {
            "type": "string",
            "maxLength": 254,
            "format": "email",
            "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$",
            "description": "The invitee's e-mail address (case-insensitive, BR-20)."
          },
          "role": {
            "type": "string",
            "enum": ["admin", "publisher", "member", "guest"],
            "description": "The invited role: admin | publisher | member | guest (BR-20 -- never owner)."
          },
          "projectIds": {
            "default": [],
            "description": "Required (>= 1) when role is guest (BR-26); every project must exist in this organisation and be manageable by the inviter.",
            "maxItems": 10,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          "locale": {
            "type": "string",
            "enum": ["nl", "en", "fr"],
            "description": "The invitation e-mail's locale."
          },
          "continueUrl": {
            "type": "string",
            "format": "uri",
            "description": "URL of the web app's accept-invitation page. Only its path and query are used: the e-mailed link always uses this environment's own web app origin. The handler adds the token as the `#t=...` fragment."
          }
        },
        "required": [
          "organizationId",
          "email",
          "role",
          "projectIds",
          "locale",
          "continueUrl"
        ],
        "additionalProperties": false
      },
      "createInvitationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^inv_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A inv identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "kind": { "type": "string", "enum": ["email", "link"] },
          "role": {
            "type": "string",
            "enum": ["admin", "publisher", "member", "guest"]
          },
          "projectIds": {
            "maxItems": 10,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          "email": {
            "type": "string",
            "maxLength": 254,
            "format": "email",
            "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
          },
          "status": {
            "type": "string",
            "enum": ["pending", "accepted", "revoked", "expired", "exhausted"]
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "maxUses": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 250
          },
          "useCount": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "resendCount": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "lastSentAt": {
            "type": "string",
            "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))$"
          },
          "locale": { "type": "string", "enum": ["nl", "en", "fr"] },
          "acceptedBy": {
            "maxItems": 250,
            "type": "array",
            "items": { "type": "string", "minLength": 1 }
          },
          "acceptedAt": {
            "type": "string",
            "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))$"
          },
          "acceptedEmail": { "type": "string" },
          "revokedBy": { "type": "string", "minLength": 1 },
          "revokedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "kind",
          "role",
          "projectIds",
          "status",
          "expiresAt",
          "useCount",
          "resendCount",
          "locale",
          "acceptedBy",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "createJoinLinkInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "role": {
            "type": "string",
            "enum": ["member", "guest"],
            "description": "member | guest (BR-24 -- never admin, publisher or owner)."
          },
          "projectIds": {
            "default": [],
            "description": "Guest links only: 1-10 projects the joiner gets access to. Must be empty for a member link.",
            "maxItems": 10,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          "expiresInHours": {
            "default": 168,
            "description": "Hours until the link expires: 1-720, default 168 (7 days).",
            "type": "integer",
            "minimum": 1,
            "maximum": 720
          },
          "maxUses": {
            "default": 25,
            "description": "How many people can join through the link: 1-250, default 25.",
            "type": "integer",
            "minimum": 1,
            "maximum": 250
          },
          "locale": {
            "type": "string",
            "enum": ["nl", "en", "fr"],
            "description": "Locale of the owner/admin notice sent on every join."
          },
          "continueUrl": {
            "type": "string",
            "format": "uri",
            "description": "Base URL of the web app's join page; the response's `url` is this with the token in the `#t=...` fragment."
          }
        },
        "required": [
          "organizationId",
          "role",
          "projectIds",
          "expiresInHours",
          "maxUses",
          "locale",
          "continueUrl"
        ],
        "additionalProperties": false
      },
      "createJoinLinkOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^inv_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A inv identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "kind": { "type": "string", "enum": ["email", "link"] },
          "role": {
            "type": "string",
            "enum": ["admin", "publisher", "member", "guest"]
          },
          "projectIds": {
            "maxItems": 10,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          "email": {
            "type": "string",
            "maxLength": 254,
            "format": "email",
            "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
          },
          "status": {
            "type": "string",
            "enum": ["pending", "accepted", "revoked", "expired", "exhausted"]
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "maxUses": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 250
          },
          "useCount": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "resendCount": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "lastSentAt": {
            "type": "string",
            "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))$"
          },
          "locale": { "type": "string", "enum": ["nl", "en", "fr"] },
          "acceptedBy": {
            "maxItems": 250,
            "type": "array",
            "items": { "type": "string", "minLength": 1 }
          },
          "acceptedAt": {
            "type": "string",
            "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))$"
          },
          "acceptedEmail": { "type": "string" },
          "revokedBy": { "type": "string", "minLength": 1 },
          "revokedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "token": {
            "type": "string",
            "minLength": 1,
            "description": "The raw join token. Returned only here, once; only its SHA-256 is stored."
          },
          "url": {
            "type": "string",
            "format": "uri",
            "description": "The shareable join URL (the QR code's content)."
          }
        },
        "required": [
          "id",
          "organizationId",
          "kind",
          "role",
          "projectIds",
          "status",
          "expiresAt",
          "useCount",
          "resendCount",
          "locale",
          "acceptedBy",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy",
          "token",
          "url"
        ],
        "additionalProperties": false
      },
      "createLayerTemplateInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "id": {
            "type": "string",
            "pattern": "^ltp_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ltp identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 60,
            "description": "Name of the template, 1-60 characters."
          },
          "layers": {
            "description": "The template's layers (at most 50).",
            "maxItems": 50,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^[a-z0-9][a-z0-9-]{0,39}$",
                  "description": "Stable id of the layer within the template (lower-case letters, digits, hyphens; at most 40). Projects match the layer by it, so keep it when you rename the layer."
                },
                "displayName": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 60,
                  "description": "Name, 1-60 characters."
                },
                "colorHex": {
                  "description": "Colour as #rgb or #rrggbb.",
                  "type": "string",
                  "pattern": "^#(?:[0-9a-fA-F]{3}|[0-9a-fA-F]{6})$"
                },
                "rule": {
                  "type": "object",
                  "properties": {
                    "source": {
                      "description": "What the rule tests: `property` (the default) a property value (`psetName`, `propName`); `name` the element name, `material` its material, `ifcClass` its IFC class, `panel` the name or tag of the panel (`IfcElementAssembly`) it is part of -- these four take no psetName/propName, are counted on the device and work offline.",
                      "type": "string",
                      "enum": [
                        "property",
                        "name",
                        "material",
                        "ifcClass",
                        "panel"
                      ]
                    },
                    "psetName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255,
                      "description": "Property (or quantity) set name exactly as in the model, e.g. `Pset_WallCommon`. Property rules only."
                    },
                    "propName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255,
                      "description": "Property name exactly as in the model, e.g. `IsExternal`. Property rules only."
                    },
                    "op": {
                      "type": "string",
                      "enum": ["eq", "neq", "contains"],
                      "description": "`eq` equals, `neq` differs from (elements without the property never match), `contains` contains the value."
                    },
                    "value": {
                      "type": "string",
                      "maxLength": 1000,
                      "description": "Text to compare; case, accents and surrounding spaces are ignored. Booleans read `true`/`false`; a number also matches numerically (`0,24` = `0.24`). For name, material, ifcClass and panel rules several values may be separated by commas (any matches), and an empty value with eq/contains matches every element that has one (e.g. part of any panel)."
                    }
                  },
                  "required": ["op", "value"],
                  "additionalProperties": false
                },
                "defaultOn": {
                  "description": "On when a project opens. Default true.",
                  "type": "boolean"
                },
                "hiddenFromField": {
                  "description": "Hidden from the field panel. Default false.",
                  "type": "boolean"
                },
                "locked": {
                  "description": "Locked: every project keeps the template's name, colour and default-on. Unlocked (the default): a project may change them. Default false.",
                  "type": "boolean"
                }
              },
              "required": ["id", "displayName", "rule"],
              "additionalProperties": false
            }
          },
          "fromPreset": {
            "description": "Start from a discipline preset: `timberFrame`, `finishing` or `services` (layers named in the request's language).",
            "type": "string",
            "enum": ["timberFrame", "finishing", "services"]
          },
          "fromProjectId": {
            "description": "Start from this project's rule layers (name, material, IFC class, panel and property rules) with their names, colours and visibility.",
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
          }
        },
        "required": ["organizationId", "name"],
        "additionalProperties": false
      },
      "createLayerTemplateOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ltp_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ltp identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": { "type": "string", "minLength": 1, "maxLength": 60 },
          "layers": {
            "maxItems": 50,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^[a-z0-9][a-z0-9-]{0,39}$"
                },
                "displayName": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 60
                },
                "colorHex": { "type": "string", "pattern": "^#[0-9a-f]{6}$" },
                "rule": {
                  "type": "object",
                  "properties": {
                    "source": {
                      "type": "string",
                      "enum": [
                        "property",
                        "name",
                        "material",
                        "ifcClass",
                        "panel"
                      ]
                    },
                    "psetName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255
                    },
                    "propName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255
                    },
                    "op": {
                      "type": "string",
                      "enum": ["eq", "neq", "contains"]
                    },
                    "value": { "type": "string", "maxLength": 1000 }
                  },
                  "required": ["op", "value"],
                  "additionalProperties": false
                },
                "defaultOn": { "type": "boolean" },
                "hiddenFromField": { "type": "boolean" },
                "locked": { "type": "boolean" }
              },
              "required": [
                "id",
                "displayName",
                "rule",
                "defaultOn",
                "hiddenFromField",
                "locked"
              ],
              "additionalProperties": false
            }
          },
          "applyTo": { "type": "string", "enum": ["all", "chosen"] },
          "projectIds": {
            "minItems": 1,
            "maxItems": 400,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          "appliedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "name",
          "layers",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "createLinkDiscoveryRunInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "trigger": {
            "description": "manual (default): started from the links settings; upload_batch: started after a bulk upload.",
            "type": "string",
            "enum": ["manual", "upload_batch"]
          },
          "scope": {
            "description": "Only these published drawings (<= 500) and models (<= 4); default: every published one.",
            "type": "object",
            "properties": {
              "documentIds": {
                "minItems": 1,
                "maxItems": 500,
                "type": "array",
                "items": {
                  "type": "string",
                  "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A doc identifier (TypeID, conventions C5)."
                }
              },
              "modelIds": {
                "minItems": 1,
                "maxItems": 4,
                "type": "array",
                "items": {
                  "type": "string",
                  "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A mdl identifier (TypeID, conventions C5)."
                }
              }
            },
            "additionalProperties": false
          }
        },
        "required": ["organizationId", "projectId"],
        "additionalProperties": false
      },
      "createLinkDiscoveryRunOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "schemaVersion": { "type": "number", "const": 1 },
          "id": {
            "type": "string",
            "pattern": "^ldr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ldr identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "status": { "type": "string", "enum": ["running", "done", "failed"] },
          "trigger": { "type": "string", "enum": ["manual", "upload_batch"] },
          "scope": {
            "type": "object",
            "properties": {
              "documentIds": {
                "minItems": 1,
                "maxItems": 500,
                "type": "array",
                "items": {
                  "type": "string",
                  "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A doc identifier (TypeID, conventions C5)."
                }
              },
              "modelIds": {
                "minItems": 1,
                "maxItems": 4,
                "type": "array",
                "items": {
                  "type": "string",
                  "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A mdl identifier (TypeID, conventions C5)."
                }
              }
            },
            "additionalProperties": false
          },
          "result": {
            "type": "object",
            "properties": {
              "evaluatedDocuments": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "evaluatedElements": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "truncated": { "type": "boolean" },
              "strategies": {
                "maxItems": 20,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "strategy": {
                      "type": "string",
                      "enum": [
                        "file_name",
                        "layout_name",
                        "title_block_attribute",
                        "sheet_text",
                        "model_property",
                        "sheet_number"
                      ]
                    },
                    "ruleDraft": {
                      "type": "object",
                      "properties": {
                        "matchModel": {
                          "type": "object",
                          "properties": {
                            "field": {
                              "type": "string",
                              "enum": [
                                "tag",
                                "assemblyMark",
                                "storeyName",
                                "name",
                                "property"
                              ]
                            },
                            "property": {
                              "type": "object",
                              "properties": {
                                "set": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 128,
                                  "description": "Property set, e.g. Pset_Panel."
                                },
                                "name": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 128,
                                  "description": "Property name, e.g. Drawing."
                                }
                              },
                              "required": ["set", "name"],
                              "additionalProperties": false
                            }
                          },
                          "required": ["field"],
                          "additionalProperties": false
                        },
                        "matchDocument": {
                          "type": "object",
                          "properties": {
                            "field": {
                              "type": "string",
                              "enum": [
                                "fileName",
                                "sheetNumber",
                                "outlineTitle",
                                "titleBlock",
                                "layoutName",
                                "blockAttribute",
                                "sheetText"
                              ]
                            },
                            "attributeTag": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 128
                            }
                          },
                          "required": ["field"],
                          "additionalProperties": false
                        },
                        "normalization": {
                          "type": "object",
                          "properties": {
                            "caseInsensitive": { "type": "boolean" },
                            "stripWhitespace": { "type": "boolean" },
                            "stripLeadingZeros": { "type": "boolean" },
                            "regex": {
                              "type": "string",
                              "description": "Regular expression applied to both sides after the other normalisation steps: a value that does not match is ignored, otherwise the match (or its named group `key`) is the value compared, e.g. W-\\d{3} (max 200 chars; no backreferences or nested repeats)."
                            }
                          },
                          "required": [
                            "caseInsensitive",
                            "stripWhitespace",
                            "stripLeadingZeros"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "required": [
                        "matchModel",
                        "matchDocument",
                        "normalization"
                      ],
                      "additionalProperties": false
                    },
                    "score": { "type": "number", "minimum": 0, "maximum": 1 },
                    "coverage": {
                      "type": "number",
                      "minimum": 0,
                      "maximum": 1
                    },
                    "matched": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "ambiguous": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "unmatchedDocuments": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "unmatchedElements": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "sampleMatches": {
                      "maxItems": 10,
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "documentId": {
                            "type": "string",
                            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                            "description": "A doc identifier (TypeID, conventions C5)."
                          },
                          "page": {
                            "type": "integer",
                            "exclusiveMinimum": 0,
                            "maximum": 9007199254740991
                          },
                          "key": { "type": "string" },
                          "source": {
                            "oneOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "kind": {
                                    "type": "string",
                                    "const": "element"
                                  },
                                  "modelId": {
                                    "type": "string",
                                    "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                    "description": "A mdl identifier (TypeID, conventions C5)."
                                  },
                                  "globalId": {
                                    "type": "string",
                                    "minLength": 1
                                  }
                                },
                                "required": ["kind", "modelId", "globalId"],
                                "additionalProperties": false
                              },
                              {
                                "type": "object",
                                "properties": {
                                  "kind": {
                                    "type": "string",
                                    "const": "assembly"
                                  },
                                  "modelId": {
                                    "type": "string",
                                    "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                    "description": "A mdl identifier (TypeID, conventions C5)."
                                  },
                                  "assemblyMark": {
                                    "type": "string",
                                    "minLength": 1
                                  }
                                },
                                "required": ["kind", "modelId", "assemblyMark"],
                                "additionalProperties": false
                              },
                              {
                                "type": "object",
                                "properties": {
                                  "kind": {
                                    "type": "string",
                                    "const": "storey"
                                  },
                                  "modelId": {
                                    "type": "string",
                                    "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                    "description": "A mdl identifier (TypeID, conventions C5)."
                                  },
                                  "storeyId": {
                                    "type": "string",
                                    "minLength": 1
                                  }
                                },
                                "required": ["kind", "modelId", "storeyId"],
                                "additionalProperties": false
                              }
                            ]
                          }
                        },
                        "required": ["documentId", "page", "key", "source"],
                        "additionalProperties": false
                      }
                    },
                    "ambiguousSamples": {
                      "maxItems": 10,
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "key": { "type": "string" },
                          "documentIds": {
                            "minItems": 2,
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                              "description": "A doc identifier (TypeID, conventions C5)."
                            }
                          }
                        },
                        "required": ["key", "documentIds"],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "strategy",
                    "ruleDraft",
                    "score",
                    "coverage",
                    "matched",
                    "ambiguous",
                    "unmatchedDocuments",
                    "unmatchedElements",
                    "sampleMatches",
                    "ambiguousSamples"
                  ],
                  "additionalProperties": false
                }
              },
              "recommended": {
                "type": "array",
                "items": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                }
              },
              "panels": {
                "type": "object",
                "properties": {
                  "total": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "linkable": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["total", "linkable"],
                "additionalProperties": false
              },
              "skipped": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "strategy": {
                      "type": "string",
                      "enum": [
                        "file_name",
                        "layout_name",
                        "title_block_attribute",
                        "sheet_text",
                        "model_property",
                        "sheet_number"
                      ]
                    },
                    "reason": {
                      "type": "string",
                      "enum": ["model_index_missing", "no_keys"]
                    }
                  },
                  "required": ["strategy", "reason"],
                  "additionalProperties": false
                }
              }
            },
            "required": [
              "evaluatedDocuments",
              "evaluatedElements",
              "strategies",
              "recommended"
            ],
            "additionalProperties": false
          },
          "acceptedAt": {
            "type": "string",
            "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))$"
          },
          "acceptedBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "acceptedRuleIds": {
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A lkr identifier (TypeID, conventions C5)."
            }
          },
          "acceptRunIds": {
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^lrr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A lrr identifier (TypeID, conventions C5)."
            }
          },
          "error": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "enum": ["discovery_timeout", "discovery_failed"]
              },
              "message": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "message"],
            "additionalProperties": false
          },
          "requestedAt": {
            "type": "string",
            "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))$"
          },
          "requestedBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "completedAt": {
            "type": "string",
            "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))$"
          }
        },
        "required": [
          "schemaVersion",
          "id",
          "organizationId",
          "projectId",
          "status",
          "trigger",
          "scope",
          "requestedAt",
          "requestedBy"
        ],
        "additionalProperties": false
      },
      "createLinkImportInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "fileName": {
            "type": "string",
            "minLength": 5,
            "maxLength": 255,
            "description": "The CSV's file name, ending .csv (max 255 chars)."
          },
          "sizeBytes": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991,
            "description": "The CSV's size in bytes; over 2097152 is 422 import.csv_too_large."
          },
          "rowCount": {
            "description": "Optional: the CSV's data rows (header not counted); over 5000 is 422 import.csv_too_large.",
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "id": {
            "description": "Optional client-generated id (C11). Omit to let the server generate one.",
            "type": "string",
            "pattern": "^lim_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
          }
        },
        "required": ["organizationId", "projectId", "fileName", "sizeBytes"],
        "additionalProperties": false
      },
      "createLinkImportOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^lim_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lim identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "fileName": {
            "type": "string",
            "minLength": 5,
            "maxLength": 255,
            "description": "The CSV's file name, ending .csv (max 255 chars)."
          },
          "sizeBytes": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 2097152
          },
          "status": {
            "type": "string",
            "enum": ["uploading", "processing", "done", "failed"]
          },
          "progress": {
            "type": "object",
            "properties": {
              "rowsProcessed": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "rowsTotal": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": ["rowsProcessed", "rowsTotal"],
            "additionalProperties": false
          },
          "result": {
            "type": "object",
            "properties": {
              "rows": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "created": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "skipped": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "errors": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "row": {
                      "type": "integer",
                      "minimum": 2,
                      "maximum": 9007199254740991
                    },
                    "code": {
                      "type": "string",
                      "enum": [
                        "element_not_found",
                        "ambiguous_element",
                        "sheet_not_found",
                        "sheet_not_ready",
                        "ambiguous_sheet",
                        "page_out_of_range",
                        "invalid_page",
                        "invalid_region",
                        "missing_value"
                      ]
                    }
                  },
                  "required": ["row", "code"],
                  "additionalProperties": false
                }
              }
            },
            "required": ["rows", "created", "skipped", "errors"],
            "additionalProperties": false
          },
          "error": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "enum": [
                  "csv_too_large",
                  "csv_empty",
                  "csv_encoding",
                  "csv_malformed",
                  "csv_missing_column",
                  "csv_unknown_column",
                  "upload_missing",
                  "project_not_active"
                ]
              },
              "detail": { "type": "string", "maxLength": 500 }
            },
            "required": ["code", "detail"],
            "additionalProperties": false
          },
          "completedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "upload": {
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false,
            "description": "PUT the CSV bytes to upload.url (C13), never through this API."
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "fileName",
          "sizeBytes",
          "status",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy",
          "upload"
        ],
        "additionalProperties": false
      },
      "createLinkInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "sources": {
            "minItems": 1,
            "maxItems": 50,
            "type": "array",
            "items": {
              "oneOf": [
                {
                  "type": "object",
                  "properties": {
                    "kind": { "type": "string", "const": "element" },
                    "modelId": {
                      "type": "string",
                      "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A mdl identifier (TypeID, conventions C5)."
                    },
                    "globalId": { "type": "string", "minLength": 1 }
                  },
                  "required": ["kind", "modelId", "globalId"],
                  "additionalProperties": false
                },
                {
                  "type": "object",
                  "properties": {
                    "kind": { "type": "string", "const": "assembly" },
                    "modelId": {
                      "type": "string",
                      "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A mdl identifier (TypeID, conventions C5)."
                    },
                    "assemblyMark": { "type": "string", "minLength": 1 }
                  },
                  "required": ["kind", "modelId", "assemblyMark"],
                  "additionalProperties": false
                },
                {
                  "type": "object",
                  "properties": {
                    "kind": { "type": "string", "const": "storey" },
                    "modelId": {
                      "type": "string",
                      "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A mdl identifier (TypeID, conventions C5)."
                    },
                    "storeyId": { "type": "string", "minLength": 1 }
                  },
                  "required": ["kind", "modelId", "storeyId"],
                  "additionalProperties": false
                }
              ]
            },
            "description": "What to link: 1-50 sources, each an element (modelId + globalId), an assembly (modelId + assemblyMark) or a storey (modelId + storeyId)."
          },
          "target": {
            "type": "object",
            "properties": {
              "documentId": {
                "type": "string",
                "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A doc identifier (TypeID, conventions C5)."
              },
              "page": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "region": {
                "description": "Part of the page as fractions (0-1) of its width and height (D-8: never pixels, so it holds at any zoom); omitted: the whole page.",
                "type": "object",
                "properties": {
                  "xPct": { "type": "number", "minimum": 0, "maximum": 1 },
                  "yPct": { "type": "number", "minimum": 0, "maximum": 1 },
                  "wPct": { "type": "number", "minimum": 0, "maximum": 1 },
                  "hPct": { "type": "number", "minimum": 0, "maximum": 1 }
                },
                "required": ["xPct", "yPct", "wPct", "hPct"],
                "additionalProperties": false
              },
              "cadRegion": {
                "description": "CAD drawings: part of the page in drawing units ({x, y, w, h} with w, h > 0) and the space it is drawn in (model or paper). Not together with region or textRef.",
                "type": "object",
                "properties": {
                  "x": { "type": "number" },
                  "y": { "type": "number" },
                  "w": { "type": "number", "exclusiveMinimum": 0 },
                  "h": { "type": "number", "exclusiveMinimum": 0 },
                  "space": { "type": "string", "enum": ["model", "paper"] }
                },
                "required": ["x", "y", "w", "h", "space"],
                "additionalProperties": false
              },
              "textRef": {
                "description": "CAD drawings: one text of the page -- its index in the page's text layer and its content, which heals the link when the text moves. The text must be a word of that page (422 validation.failed, pointer /target/textRef, otherwise); the index is a hint: when it names another word, the occurrence nearest to it is stored. Not together with region or cadRegion.",
                "type": "object",
                "properties": {
                  "textIndex": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "text": { "type": "string", "minLength": 1, "maxLength": 200 }
                },
                "required": ["textIndex", "text"],
                "additionalProperties": false
              },
              "layoutName": {
                "description": "CAD drawings: the page's layout name. When a later version moves that layout to another page, the link follows it.",
                "type": "string",
                "minLength": 1,
                "maxLength": 255
              }
            },
            "required": ["documentId", "page"],
            "additionalProperties": false,
            "description": "A page of a published drawing of this project."
          }
        },
        "required": ["organizationId", "projectId", "sources", "target"],
        "additionalProperties": false
      },
      "createLinkOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "links": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^lnk_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A lnk identifier (TypeID, conventions C5)."
                },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "projectId": {
                  "type": "string",
                  "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A prj identifier (TypeID, conventions C5)."
                },
                "source": {
                  "oneOf": [
                    {
                      "type": "object",
                      "properties": {
                        "kind": { "type": "string", "const": "element" },
                        "modelId": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        },
                        "globalId": { "type": "string", "minLength": 1 }
                      },
                      "required": ["kind", "modelId", "globalId"],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "kind": { "type": "string", "const": "assembly" },
                        "modelId": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        },
                        "assemblyMark": { "type": "string", "minLength": 1 }
                      },
                      "required": ["kind", "modelId", "assemblyMark"],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "kind": { "type": "string", "const": "storey" },
                        "modelId": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        },
                        "storeyId": { "type": "string", "minLength": 1 }
                      },
                      "required": ["kind", "modelId", "storeyId"],
                      "additionalProperties": false
                    }
                  ]
                },
                "target": {
                  "type": "object",
                  "properties": {
                    "documentId": {
                      "type": "string",
                      "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A doc identifier (TypeID, conventions C5)."
                    },
                    "page": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    },
                    "layoutName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255
                    },
                    "region": {
                      "type": "object",
                      "properties": {
                        "xPct": {
                          "type": "number",
                          "minimum": 0,
                          "maximum": 1
                        },
                        "yPct": {
                          "type": "number",
                          "minimum": 0,
                          "maximum": 1
                        },
                        "wPct": {
                          "type": "number",
                          "minimum": 0,
                          "maximum": 1
                        },
                        "hPct": { "type": "number", "minimum": 0, "maximum": 1 }
                      },
                      "required": ["xPct", "yPct", "wPct", "hPct"],
                      "additionalProperties": false
                    },
                    "cadRegion": {
                      "type": "object",
                      "properties": {
                        "x": { "type": "number" },
                        "y": { "type": "number" },
                        "w": { "type": "number", "exclusiveMinimum": 0 },
                        "h": { "type": "number", "exclusiveMinimum": 0 },
                        "space": {
                          "type": "string",
                          "enum": ["model", "paper"]
                        }
                      },
                      "required": ["x", "y", "w", "h", "space"],
                      "additionalProperties": false
                    },
                    "textRef": {
                      "type": "object",
                      "properties": {
                        "textIndex": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "text": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 200
                        }
                      },
                      "required": ["textIndex", "text"],
                      "additionalProperties": false
                    }
                  },
                  "required": ["documentId", "page"],
                  "additionalProperties": false
                },
                "origin": {
                  "type": "string",
                  "enum": ["rule", "manual", "connector"]
                },
                "ruleId": {
                  "type": "string",
                  "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A lkr identifier (TypeID, conventions C5)."
                },
                "confidence": { "type": "number", "minimum": 0, "maximum": 1 },
                "key": { "type": "string", "minLength": 1 },
                "status": { "type": "string", "enum": ["active", "stale"] },
                "staleSince": {
                  "type": "string",
                  "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))$"
                },
                "staleReason": { "type": "string", "enum": ["page_removed"] },
                "schemaVersion": { "type": "number", "const": 1 },
                "createdAt": {
                  "type": "string",
                  "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))$"
                },
                "updatedAt": {
                  "type": "string",
                  "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))$"
                },
                "revision": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "createdBy": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                }
              },
              "required": [
                "id",
                "organizationId",
                "projectId",
                "source",
                "target",
                "origin",
                "status",
                "schemaVersion",
                "createdAt",
                "updatedAt",
                "revision",
                "createdBy"
              ],
              "additionalProperties": false
            },
            "description": "One link per distinct source, in request order: the new link, or the identical one that already existed."
          },
          "created": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "How many of `links` this call created."
          }
        },
        "required": ["links", "created"],
        "additionalProperties": false
      },
      "createLinkRuleInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "description": "Rule name, 1-100 chars after trimming."
          },
          "enabled": { "type": "boolean" },
          "priority": {
            "type": "integer",
            "minimum": 0,
            "maximum": 1000,
            "description": "0-1000; lower runs first when rules run together."
          },
          "matchModel": {
            "type": "object",
            "properties": {
              "field": {
                "type": "string",
                "enum": [
                  "tag",
                  "assemblyMark",
                  "storeyName",
                  "name",
                  "property"
                ]
              },
              "property": {
                "type": "object",
                "properties": {
                  "set": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 128,
                    "description": "Property set, e.g. Pset_Panel."
                  },
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 128,
                    "description": "Property name, e.g. Drawing."
                  }
                },
                "required": ["set", "name"],
                "additionalProperties": false
              }
            },
            "required": ["field"],
            "additionalProperties": false
          },
          "matchDocument": {
            "type": "object",
            "properties": {
              "field": {
                "type": "string",
                "enum": [
                  "fileName",
                  "sheetNumber",
                  "outlineTitle",
                  "titleBlock",
                  "layoutName",
                  "blockAttribute",
                  "sheetText"
                ]
              },
              "attributeTag": {
                "type": "string",
                "minLength": 1,
                "maxLength": 128
              }
            },
            "required": ["field"],
            "additionalProperties": false
          },
          "normalization": {
            "type": "object",
            "properties": {
              "caseInsensitive": { "type": "boolean" },
              "stripWhitespace": { "type": "boolean" },
              "stripLeadingZeros": { "type": "boolean" },
              "regex": {
                "type": "string",
                "description": "Regular expression applied to both sides after the other normalisation steps: a value that does not match is ignored, otherwise the match (or its named group `key`) is the value compared, e.g. W-\\d{3} (max 200 chars; no backreferences or nested repeats)."
              }
            },
            "additionalProperties": false
          },
          "autoApply": {
            "description": "Run this rule on every newly published drawing version and after each model publish (default false).",
            "type": "boolean"
          }
        },
        "required": [
          "organizationId",
          "projectId",
          "name",
          "matchModel",
          "matchDocument"
        ],
        "additionalProperties": false
      },
      "createLinkRuleOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lkr identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "description": "Rule name, 1-100 chars after trimming."
          },
          "enabled": { "type": "boolean" },
          "priority": { "type": "integer", "minimum": 0, "maximum": 1000 },
          "matchModel": {
            "type": "object",
            "properties": {
              "field": {
                "type": "string",
                "enum": [
                  "tag",
                  "assemblyMark",
                  "storeyName",
                  "name",
                  "property"
                ]
              },
              "property": {
                "type": "object",
                "properties": {
                  "set": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 128,
                    "description": "Property set, e.g. Pset_Panel."
                  },
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 128,
                    "description": "Property name, e.g. Drawing."
                  }
                },
                "required": ["set", "name"],
                "additionalProperties": false
              }
            },
            "required": ["field"],
            "additionalProperties": false
          },
          "matchDocument": {
            "type": "object",
            "properties": {
              "field": {
                "type": "string",
                "enum": [
                  "fileName",
                  "sheetNumber",
                  "outlineTitle",
                  "titleBlock",
                  "layoutName",
                  "blockAttribute",
                  "sheetText"
                ]
              },
              "attributeTag": {
                "type": "string",
                "minLength": 1,
                "maxLength": 128
              }
            },
            "required": ["field"],
            "additionalProperties": false
          },
          "normalization": {
            "type": "object",
            "properties": {
              "caseInsensitive": { "type": "boolean" },
              "stripWhitespace": { "type": "boolean" },
              "stripLeadingZeros": { "type": "boolean" },
              "regex": {
                "type": "string",
                "description": "Regular expression applied to both sides after the other normalisation steps: a value that does not match is ignored, otherwise the match (or its named group `key`) is the value compared, e.g. W-\\d{3} (max 200 chars; no backreferences or nested repeats)."
              }
            },
            "required": [
              "caseInsensitive",
              "stripWhitespace",
              "stripLeadingZeros"
            ],
            "additionalProperties": false
          },
          "autoApply": { "type": "boolean" },
          "discoveryRunId": {
            "type": "string",
            "pattern": "^ldr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ldr identifier (TypeID, conventions C5)."
          },
          "ambiguousDocumentIds": {
            "maxItems": 500,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "name",
          "enabled",
          "priority",
          "matchModel",
          "matchDocument",
          "normalization",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "createLinkRuleRunInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "ruleId": {
            "type": "string",
            "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lkr identifier (TypeID, conventions C5)."
          },
          "dryRun": {
            "description": "`true` (the default): preview only, nothing is linked. `false`: apply -- create the unambiguous links (at most 128 per run; run again while `result.applied.remaining` > 0).",
            "type": "boolean"
          }
        },
        "required": ["organizationId", "projectId", "ruleId"],
        "additionalProperties": false
      },
      "createLinkRuleRunOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "schemaVersion": { "type": "number", "const": 1 },
          "id": {
            "type": "string",
            "pattern": "^lrr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lrr identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "ruleId": {
            "type": "string",
            "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lkr identifier (TypeID, conventions C5)."
          },
          "dryRun": { "type": "boolean" },
          "status": { "type": "string", "enum": ["running", "done", "failed"] },
          "result": {
            "type": "object",
            "properties": {
              "candidates": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "source": {
                      "oneOf": [
                        {
                          "type": "object",
                          "properties": {
                            "kind": { "type": "string", "const": "element" },
                            "modelId": {
                              "type": "string",
                              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                              "description": "A mdl identifier (TypeID, conventions C5)."
                            },
                            "globalId": { "type": "string", "minLength": 1 }
                          },
                          "required": ["kind", "modelId", "globalId"],
                          "additionalProperties": false
                        },
                        {
                          "type": "object",
                          "properties": {
                            "kind": { "type": "string", "const": "assembly" },
                            "modelId": {
                              "type": "string",
                              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                              "description": "A mdl identifier (TypeID, conventions C5)."
                            },
                            "assemblyMark": { "type": "string", "minLength": 1 }
                          },
                          "required": ["kind", "modelId", "assemblyMark"],
                          "additionalProperties": false
                        },
                        {
                          "type": "object",
                          "properties": {
                            "kind": { "type": "string", "const": "storey" },
                            "modelId": {
                              "type": "string",
                              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                              "description": "A mdl identifier (TypeID, conventions C5)."
                            },
                            "storeyId": { "type": "string", "minLength": 1 }
                          },
                          "required": ["kind", "modelId", "storeyId"],
                          "additionalProperties": false
                        }
                      ]
                    },
                    "target": {
                      "type": "object",
                      "properties": {
                        "documentId": {
                          "type": "string",
                          "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A doc identifier (TypeID, conventions C5)."
                        },
                        "page": {
                          "type": "integer",
                          "exclusiveMinimum": 0,
                          "maximum": 9007199254740991
                        },
                        "layoutName": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 255
                        }
                      },
                      "required": ["documentId", "page"],
                      "additionalProperties": false
                    },
                    "key": { "type": "string" },
                    "confidence": {
                      "type": "number",
                      "minimum": 0,
                      "maximum": 1
                    },
                    "ruleId": {
                      "type": "string",
                      "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A lkr identifier (TypeID, conventions C5)."
                    },
                    "ambiguous": { "type": "boolean" }
                  },
                  "required": [
                    "source",
                    "target",
                    "key",
                    "confidence",
                    "ruleId",
                    "ambiguous"
                  ],
                  "additionalProperties": false
                }
              },
              "wouldCreate": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "ambiguous": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "unmatched": {
                "type": "object",
                "properties": {
                  "model": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "document": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["model", "document"],
                "additionalProperties": false
              },
              "truncated": { "type": "boolean" },
              "warnings": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "code": {
                      "type": "string",
                      "enum": [
                        "links_index_unavailable",
                        "spatial_tree_unavailable",
                        "text_layer_unavailable",
                        "link_keys_unavailable"
                      ]
                    },
                    "modelId": {
                      "type": "string",
                      "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A mdl identifier (TypeID, conventions C5)."
                    },
                    "documentId": {
                      "type": "string",
                      "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A doc identifier (TypeID, conventions C5)."
                    },
                    "page": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["code"],
                  "additionalProperties": false
                }
              },
              "skipped": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "reason": {
                      "type": "string",
                      "enum": ["model_index_missing"]
                    },
                    "modelId": {
                      "type": "string",
                      "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A mdl identifier (TypeID, conventions C5)."
                    }
                  },
                  "required": ["reason", "modelId"],
                  "additionalProperties": false
                }
              },
              "applied": {
                "type": "object",
                "properties": {
                  "created": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "updated": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "unchanged": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "manual": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "remaining": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": [
                  "created",
                  "updated",
                  "unchanged",
                  "manual",
                  "remaining"
                ],
                "additionalProperties": false
              }
            },
            "required": [
              "candidates",
              "wouldCreate",
              "ambiguous",
              "unmatched",
              "truncated",
              "warnings"
            ],
            "additionalProperties": false
          },
          "requestedAt": {
            "type": "string",
            "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))$"
          },
          "requestedBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "completedAt": {
            "type": "string",
            "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))$"
          }
        },
        "required": [
          "schemaVersion",
          "id",
          "organizationId",
          "projectId",
          "ruleId",
          "dryRun",
          "status",
          "requestedAt",
          "requestedBy"
        ],
        "additionalProperties": false
      },
      "createOrganizationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "minLength": 2,
            "maxLength": 80,
            "description": "Organisation display name (2-80 chars after trimming, BR-10)."
          },
          "defaultLocale": { "type": "string", "enum": ["nl", "en", "fr"] },
          "id": {
            "description": "Optional client-generated id (C11). Omit to let the server generate one.",
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
          },
          "legalAcceptance": {
            "type": "object",
            "properties": {
              "termsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "privacyVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "dpaVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "subprocessorsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              }
            },
            "required": [
              "termsVersion",
              "privacyVersion",
              "dpaVersion",
              "subprocessorsVersion"
            ],
            "additionalProperties": false,
            "description": "The current terms, privacy notice, DPA and sub-processor list versions the caller accepts for the organisation (from getLegalDocumentVersions). Required."
          }
        },
        "required": ["name", "defaultLocale", "legalAcceptance"],
        "additionalProperties": false
      },
      "createOrganizationLogoUploadInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "contentType": {
            "type": "string",
            "enum": ["image/png", "image/jpeg", "image/webp"],
            "description": "image/png, image/jpeg or image/webp."
          },
          "sizeBytes": {
            "type": "integer",
            "minimum": 1,
            "maximum": 2097152,
            "description": "The image size in bytes (max 2097152, 2 MB)."
          }
        },
        "required": ["organizationId", "contentType", "sizeBytes"],
        "additionalProperties": false
      },
      "createOrganizationLogoUploadOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "uploadId": {
            "type": "string",
            "pattern": "^upl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "Names this upload: send it with its contentType as updateOrganization's logo once the PUT finished."
          },
          "upload": {
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false,
            "description": "PUT the image bytes to upload.url (C13)."
          }
        },
        "required": ["uploadId", "upload"],
        "additionalProperties": false
      },
      "createOrganizationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 2,
            "maxLength": 80,
            "description": "Organisation display name (2-80 chars after trimming, BR-10)."
          },
          "defaultLocale": {
            "type": "string",
            "enum": ["nl", "en", "fr"],
            "description": "The organisation's default UI locale, one of nl | en | fr."
          },
          "status": {
            "type": "string",
            "enum": ["active", "pending_deletion"]
          },
          "deletion": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "purgeAfter": {
                "type": "string",
                "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))$"
              },
              "cancelledAt": {
                "type": "string",
                "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))$"
              },
              "purgeStartedAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["requestedAt", "requestedBy", "purgeAfter"],
            "additionalProperties": false
          },
          "supportAccess": {
            "description": "Whether Field-Viewer support may open a read-only support session: allowed (default when absent; owners are e-mailed) or ask (an owner approves each request first).",
            "type": "string",
            "enum": ["allowed", "ask"]
          },
          "settings": {
            "type": "object",
            "properties": {
              "analytics": {
                "type": "object",
                "properties": {
                  "mode": {
                    "type": "string",
                    "enum": ["enabled", "disabled"],
                    "description": "Product analytics for every member: enabled (the default) or disabled. Disabled, no usage event is recorded for anyone in the organisation."
                  }
                },
                "required": ["mode"],
                "additionalProperties": false
              },
              "cad": {
                "type": "object",
                "properties": {
                  "producerDetailTags": {
                    "type": "object",
                    "properties": {
                      "scale": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's scale text (1:n)."
                      },
                      "xFactor": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's x factor (1/n)."
                      },
                      "yFactor": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's y factor (1/n)."
                      },
                      "xMin": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's minimum x."
                      },
                      "yMin": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's minimum y."
                      },
                      "xMax": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's maximum x."
                      },
                      "yMax": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's maximum y."
                      }
                    },
                    "required": [
                      "scale",
                      "xFactor",
                      "yFactor",
                      "xMin",
                      "yMin",
                      "xMax",
                      "yMax"
                    ],
                    "additionalProperties": false,
                    "description": "The CAD producer's detail attribute tags: all seven, each the tag (not the value) of one block attribute. With them, scaled details in model space measure in real millimetres at their own scale; without them they read 'scale unknown'."
                  }
                },
                "additionalProperties": false
              }
            },
            "additionalProperties": false
          },
          "legal": {
            "type": "object",
            "properties": {
              "termsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "privacyVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "dpaVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "subprocessorsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "acceptedAt": {
                "type": "string",
                "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))$"
              },
              "acceptedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              }
            },
            "required": [
              "termsVersion",
              "privacyVersion",
              "dpaVersion",
              "subprocessorsVersion",
              "acceptedAt",
              "acceptedBy"
            ],
            "additionalProperties": false,
            "description": "The terms, privacy notice, DPA and sub-processor list versions an owner accepted for the organisation."
          },
          "kind": {
            "description": "standard (default when absent) or tryout: an anonymous visitor's 7-day try-it organisation.",
            "type": "string",
            "enum": ["standard", "tryout"]
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "logoUrl": {
            "type": "object",
            "properties": {
              "url": { "type": "string" },
              "expiresAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["url", "expiresAt"],
            "additionalProperties": false,
            "description": "Signed URL of the organisation's logo (15 minutes). Absent when it has no logo."
          },
          "reacceptanceRequired": {
            "description": "True when an owner must accept a newer material version of the terms, the DPA or the sub-processor list (or never accepted them).",
            "type": "boolean"
          }
        },
        "required": [
          "id",
          "name",
          "defaultLocale",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "createProjectInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "Project display name (1-80 chars after trimming, BR-2)."
          },
          "reference": {
            "type": "string",
            "minLength": 1,
            "maxLength": 40,
            "description": "Free-form job/reference code, e.g. \"2026-041\" (BR-2)."
          },
          "description": {
            "type": "string",
            "maxLength": 500,
            "description": "Free-form project description (BR-2)."
          },
          "id": {
            "description": "Optional client-generated id (C11). Omit to let the server generate one.",
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
          }
        },
        "required": ["organizationId", "name"],
        "additionalProperties": false
      },
      "createProjectOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "Project display name (1-80 chars after trimming, BR-2)."
          },
          "reference": {
            "type": "string",
            "minLength": 1,
            "maxLength": 40,
            "description": "Free-form job/reference code, e.g. \"2026-041\" (BR-2)."
          },
          "description": {
            "type": "string",
            "maxLength": 500,
            "description": "Free-form project description (BR-2)."
          },
          "status": {
            "type": "string",
            "enum": ["active", "archived", "deleted"]
          },
          "access": { "type": "string", "enum": ["org", "restricted"] },
          "memberIds": {
            "maxItems": 500,
            "type": "array",
            "items": { "type": "string", "minLength": 1 }
          },
          "fieldVersionIds": {
            "maxItems": 500,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ver identifier (TypeID, conventions C5)."
            }
          },
          "publishSeq": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "lastPublishedAt": {
            "type": "string",
            "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))$"
          },
          "isSample": { "type": "boolean", "const": true },
          "demoSlug": {
            "type": "string",
            "enum": [
              "landhuis_hulstveld",
              "landhuis_hulstveld_hsb",
              "woning_lindehof",
              "villa_berkenhaag",
              "hal_noorderkempen",
              "paneelset_werkplaats"
            ]
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "deletedAt": {
            "type": "string",
            "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))$"
          },
          "purgeAfter": {
            "type": "string",
            "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))$"
          },
          "statusBeforeDeletion": {
            "type": "string",
            "enum": ["active", "archived"]
          },
          "purgeStartedAt": {
            "type": "string",
            "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))$"
          },
          "sheetMetadata": {
            "type": "object",
            "properties": {
              "fileNamePattern": {
                "type": "string",
                "description": "Regular expression matched against the file name without its .pdf extension, with named groups sheetNumber and/or discipline, e.g. ^(?<discipline>[A-Z])-(?<sheetNumber>\\d+) (max 200 chars; no backreferences or nested repeats)."
              },
              "disciplineMap": {
                "type": "object",
                "propertyNames": {
                  "type": "string",
                  "pattern": "^[A-Za-z0-9]{1,8}$"
                },
                "additionalProperties": {
                  "type": "string",
                  "enum": [
                    "architecture",
                    "structure",
                    "mechanical",
                    "electrical",
                    "plumbing",
                    "fire_protection",
                    "civil",
                    "landscape",
                    "general"
                  ]
                }
              }
            },
            "additionalProperties": false,
            "description": "How this project's PDF file names map to sheet number and discipline (BR-11). Without a fileNamePattern the file-name stem is the sheet number."
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "quotaWarning": {
            "type": "object",
            "properties": {
              "resource": {
                "type": "string",
                "enum": [
                  "seats",
                  "guests",
                  "workstations",
                  "projects",
                  "storageBytes",
                  "maxModelFileBytes",
                  "maxModelsPerProject",
                  "processingMinutesPerMonth",
                  "apiTokens",
                  "maxDocumentFileBytes",
                  "maxDocumentsPerProject"
                ]
              },
              "used": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "limit": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": ["resource", "used", "limit"],
            "additionalProperties": false,
            "description": "Set when this write pushed the organisation past 80% of a plan limit. `used` includes this write."
          }
        },
        "required": [
          "id",
          "organizationId",
          "name",
          "status",
          "access",
          "memberIds",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "createProjectRevisionInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "fileName": {
            "type": "string",
            "minLength": 1,
            "maxLength": 255,
            "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
          },
          "sizeBytes": {
            "description": "The file's size in bytes (BR-24). Required for an upload; leave out with source.kind url.",
            "type": "integer",
            "minimum": 1,
            "maximum": 1073741824
          },
          "contentType": {
            "type": "string",
            "minLength": 1,
            "description": "The source file's MIME type, e.g. application/octet-stream."
          },
          "sha256": {
            "type": "string",
            "pattern": "^[0-9a-f]{64}$",
            "description": "Optional SHA-256 of the source file, 64 hex chars."
          },
          "id": {
            "description": "Optional client-generated id (C11). Omit to let the server generate one.",
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
          },
          "publishOnReady": {
            "description": "Publish this revision automatically as soon as processing marks it ready (FV-383). Default false: publish with publishProjectRevision.",
            "type": "boolean"
          },
          "source": {
            "type": "object",
            "properties": {
              "kind": { "type": "string", "const": "url" },
              "url": {
                "type": "string",
                "minLength": 1,
                "maxLength": 2048,
                "description": "Where to download the file: a public HTTPS URL (at most 2,048 characters, no user:password@), e.g. a signed CDN or cloud-storage link. It must stay valid for 25 minutes. Only its scheme, host and path are stored; the query string is not."
              },
              "sha256": {
                "description": "Optional SHA-256 of the file (64 hex). A download that does not match fails with import.checksum_mismatch.",
                "type": "string",
                "pattern": "^[0-9a-f]{64}$"
              }
            },
            "required": ["kind", "url"],
            "additionalProperties": false,
            "description": "Import the file from a URL instead of uploading it: the server downloads it and the response carries no `upload` ticket. Leave out sizeBytes and the top-level sha256."
          }
        },
        "required": ["organizationId", "projectId", "fileName", "contentType"],
        "additionalProperties": false
      },
      "createProjectRevisionOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": [
              "uploading",
              "uploaded",
              "processing",
              "ready",
              "failed",
              "archived",
              "cancelled"
            ]
          },
          "publication": {
            "type": "string",
            "enum": ["draft", "published", "superseded"]
          },
          "fieldVisible": { "type": "boolean" },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "upload" },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "fileName", "sizeBytes", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "copy" },
                  "sourceVersionId": {
                    "type": "string",
                    "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A ver identifier (TypeID, conventions C5)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": [
                  "kind",
                  "sourceVersionId",
                  "fileName",
                  "sizeBytes",
                  "contentType"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "url" },
                  "url": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 2048,
                    "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "url", "fileName", "contentType"],
                "additionalProperties": false
              }
            ]
          },
          "upload": {
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "cancelReason": { "type": "string", "enum": ["user", "expired"] },
          "pipelineVersion": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": { "type": "string" },
                "blocking": { "type": "boolean" },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": {}
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": { "type": "string", "minLength": 1 },
              "retryable": { "type": "boolean" },
              "params": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": {}
              },
              "messageKey": { "type": "string", "minLength": 1 },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "retryable"],
            "additionalProperties": false
          },
          "processing": {
            "type": "object",
            "properties": {
              "sizeClass": { "type": "string", "enum": ["s", "m", "l", "xl"] },
              "executionName": { "type": "string", "minLength": 1 },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "queuedAt": {
                "type": "string",
                "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))$"
              },
              "queuedTraceparent": {
                "type": "string",
                "pattern": "^(?!ff)[0-9a-f]{2}-(?!0{32})[0-9a-f]{32}-(?!0{16})[0-9a-f]{16}-[0-9a-f]{2}$"
              },
              "queuedEscalation": {
                "type": "object",
                "properties": {
                  "sizeClass": {
                    "type": "string",
                    "enum": ["s", "m", "l", "xl"]
                  },
                  "attempt": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["sizeClass", "attempt"],
                "additionalProperties": false
              },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "progressReportedAt": {
                "type": "string",
                "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))$"
              },
              "requestId": { "type": "string", "minLength": 1 }
            },
            "additionalProperties": false
          },
          "progress": {
            "type": "object",
            "properties": {
              "stage": { "type": "string", "minLength": 1 },
              "percent": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["stage", "percent"],
            "additionalProperties": false
          },
          "reprocessing": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "reason": {
                "type": "string",
                "enum": ["retry", "pipeline_upgrade"]
              },
              "targetPipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "state": {
                "type": "string",
                "enum": [
                  "requested",
                  "deferred",
                  "awaiting_rollout",
                  "done",
                  "failed"
                ]
              },
              "completedAt": {
                "type": "string",
                "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))$"
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1 },
                  "retryable": { "type": "boolean" },
                  "params": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": {}
                  },
                  "messageKey": { "type": "string", "minLength": 1 },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "retryable"],
                "additionalProperties": false
              }
            },
            "required": ["requestedAt", "requestedBy", "attempt"],
            "additionalProperties": false
          },
          "releasedAt": {
            "type": "string",
            "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))$"
          },
          "releasedBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "supersededAt": {
            "type": "string",
            "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))$"
          },
          "activeArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "nextArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "stats": {
            "type": "object",
            "properties": {
              "elementCount": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "boundsMm": {
                "type": "object",
                "properties": {
                  "min": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3
                  },
                  "max": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3
                  }
                },
                "required": ["min", "max"],
                "additionalProperties": false
              },
              "coveragePct": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["elementCount", "boundsMm"],
            "additionalProperties": false
          },
          "churn": {
            "type": "object",
            "properties": {
              "ratio": { "type": "number", "minimum": 0, "maximum": 1 },
              "added": { "type": "array", "items": { "type": "string" } },
              "removed": { "type": "array", "items": { "type": "string" } },
              "moved": { "type": "array", "items": { "type": "string" } },
              "recreated": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "from": { "type": "string" },
                    "to": { "type": "string" }
                  },
                  "required": ["from", "to"],
                  "additionalProperties": false
                }
              }
            },
            "required": ["ratio", "added", "removed", "moved", "recreated"],
            "additionalProperties": false
          },
          "label": {
            "type": "string",
            "minLength": 1,
            "maxLength": 40,
            "description": "Short version name, e.g. \"Roof fix\" (1-40 chars after trimming, BR-10)."
          },
          "notes": {
            "type": "string",
            "maxLength": 2000,
            "description": "Free-form notes for the crew (max 2000 chars, BR-10)."
          },
          "detailsEditedAt": {
            "type": "string",
            "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))$"
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "publishOnReady": {
            "description": "Publish this version automatically, in the same write that marks it ready (FV-383).",
            "type": "boolean"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "number": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991,
            "description": "The revision number within the project (1, 2, 3...)."
          },
          "current": {
            "type": "boolean",
            "description": "Whether this is the revision the field sees now."
          },
          "publishedAt": {
            "description": "When this revision was (last) published; absent for a revision never published.",
            "type": "string",
            "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))$"
          },
          "publishedBy": {
            "description": "Who published it; absent for a revision never published, or published before FV-384 and no longer current.",
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "publishedByName": {
            "description": "The publisher's display name, when they are a member.",
            "type": "string",
            "minLength": 1
          },
          "quotaWarning": {
            "type": "object",
            "properties": {
              "resource": {
                "type": "string",
                "enum": [
                  "seats",
                  "guests",
                  "workstations",
                  "projects",
                  "storageBytes",
                  "maxModelFileBytes",
                  "maxModelsPerProject",
                  "processingMinutesPerMonth",
                  "apiTokens",
                  "maxDocumentFileBytes",
                  "maxDocumentsPerProject"
                ]
              },
              "used": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "limit": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": ["resource", "used", "limit"],
            "additionalProperties": false,
            "description": "Set when this write pushed the organisation past 80% of a plan limit. `used` includes this write."
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "modelId",
          "versionNumber",
          "status",
          "publication",
          "fieldVisible",
          "source",
          "pipelineVersion",
          "warnings",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy",
          "number",
          "current"
        ],
        "additionalProperties": false
      },
      "createSavedViewInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "id": {
            "description": "Optional client-generated vw_ id (C11, offline outbox). Omit to let the server generate one.",
            "type": "string",
            "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "The view's name, 1-80 characters."
          },
          "description": {
            "type": "string",
            "maxLength": 280,
            "description": "Optional note, max 280 characters."
          },
          "scope": {
            "description": "personal (only you see it, the default) or shared (everyone in the project; needs view.manage).",
            "type": "string",
            "enum": ["personal", "shared"]
          },
          "isProjectDefault": {
            "description": "true: the project's default view -- the one people land on when they open the project (scope shared; needs view.manage). Clears the previous default in the same write.",
            "type": "boolean"
          },
          "state": {
            "type": "object",
            "properties": {
              "schemaVersion": { "type": "number", "const": 1 },
              "camera": {
                "type": "object",
                "properties": {
                  "position": {
                    "type": "object",
                    "properties": {
                      "x": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "y": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "z": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      }
                    },
                    "required": ["x", "y", "z"],
                    "additionalProperties": false
                  },
                  "target": {
                    "type": "object",
                    "properties": {
                      "x": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "y": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "z": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      }
                    },
                    "required": ["x", "y", "z"],
                    "additionalProperties": false
                  },
                  "up": { "type": "string", "const": "z" },
                  "fovDeg": { "type": "number", "minimum": 20, "maximum": 90 },
                  "orthoHeightM": { "type": "number", "exclusiveMinimum": 0 }
                },
                "required": ["position", "target", "up"],
                "additionalProperties": false
              },
              "visibility": {
                "type": "object",
                "properties": {
                  "hiddenRefs": {
                    "maxItems": 5000,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "globalId": { "type": "string", "minLength": 1 },
                        "modelId": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        }
                      },
                      "required": ["globalId"],
                      "additionalProperties": false
                    }
                  },
                  "isolateRefs": {
                    "maxItems": 5000,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "globalId": { "type": "string", "minLength": 1 },
                        "modelId": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        }
                      },
                      "required": ["globalId"],
                      "additionalProperties": false
                    }
                  },
                  "ghost": { "type": "boolean" },
                  "isolateSource": { "type": "string", "const": "storey" }
                },
                "required": ["hiddenRefs", "isolateRefs", "ghost"],
                "additionalProperties": false
              },
              "section": {
                "type": "object",
                "properties": {
                  "axis": { "type": "string", "enum": ["x", "y", "z"] },
                  "offsetMm": { "type": "number" },
                  "flipped": { "type": "boolean" }
                },
                "required": ["axis", "offsetMm", "flipped"],
                "additionalProperties": false
              },
              "layerSetRef": {
                "type": "object",
                "properties": {
                  "layerSetId": {
                    "type": "string",
                    "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A lys identifier (TypeID, conventions C5)."
                  },
                  "overrides": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": { "type": "boolean" }
                  }
                },
                "required": ["layerSetId", "overrides"],
                "additionalProperties": false
              },
              "selection": {
                "maxItems": 50,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "globalId": { "type": "string", "minLength": 1 },
                    "modelId": {
                      "type": "string",
                      "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A mdl identifier (TypeID, conventions C5)."
                    }
                  },
                  "required": ["globalId"],
                  "additionalProperties": false
                }
              },
              "activeTool": { "type": "string", "minLength": 1 },
              "theme": { "type": "string", "enum": ["sunlight", "dim"] },
              "storeyFocusId": { "type": "string" },
              "splitView": {
                "type": "object",
                "properties": {
                  "active": { "type": "boolean" },
                  "ratio": { "type": "number", "minimum": 0.1, "maximum": 0.9 },
                  "primaryPane": {
                    "type": "string",
                    "enum": ["model", "document"]
                  },
                  "document": {
                    "type": "object",
                    "properties": {
                      "documentId": {
                        "type": "string",
                        "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                        "description": "A doc identifier (TypeID, conventions C5)."
                      },
                      "page": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 9007199254740991
                      },
                      "zoom": { "type": "number", "exclusiveMinimum": 0 },
                      "panPct": {
                        "type": "object",
                        "properties": {
                          "x": { "type": "number" },
                          "y": { "type": "number" }
                        },
                        "required": ["x", "y"],
                        "additionalProperties": false
                      },
                      "cad": {
                        "description": "FV-497: a CAD sheet's view -- the drawing point at the pane's centre (drawing units) and the scale in CSS px per drawing unit.",
                        "type": "object",
                        "properties": {
                          "center": {
                            "type": "object",
                            "properties": {
                              "x": { "type": "number" },
                              "y": { "type": "number" }
                            },
                            "required": ["x", "y"],
                            "additionalProperties": false
                          },
                          "scale": { "type": "number", "exclusiveMinimum": 0 }
                        },
                        "required": ["center", "scale"],
                        "additionalProperties": false
                      }
                    },
                    "required": ["documentId", "page"],
                    "additionalProperties": false
                  },
                  "fullscreenPane": {
                    "type": "string",
                    "enum": ["model", "document"]
                  }
                },
                "required": ["active", "ratio", "primaryPane"],
                "additionalProperties": false
              },
              "filter": {
                "description": "FV-473: the filter terms behind the hidden and isolate sets, and the built-in layers (panels, loose parts) that are off.",
                "type": "object",
                "properties": {
                  "terms": {
                    "maxItems": 20,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "mode": { "type": "string", "enum": ["only", "hide"] },
                        "key": {
                          "type": "string",
                          "enum": [
                            "search",
                            "class",
                            "type",
                            "material",
                            "layer",
                            "panel",
                            "storey",
                            "property",
                            "elements"
                          ]
                        },
                        "value": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 500
                        },
                        "name": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 200
                        },
                        "set": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 200
                        }
                      },
                      "required": ["mode", "key", "value"],
                      "additionalProperties": false
                    }
                  },
                  "builtInOff": {
                    "maxItems": 2,
                    "type": "array",
                    "items": { "type": "string", "enum": ["panels", "loose"] }
                  }
                },
                "required": ["terms"],
                "additionalProperties": false
              }
            },
            "required": [
              "schemaVersion",
              "camera",
              "visibility",
              "selection",
              "activeTool",
              "theme"
            ],
            "additionalProperties": false,
            "description": "A full ViewState v1 (E05 §4.2): camera, visibility, section, layerSetRef, selection, activeTool, theme, storeyFocusId, splitView, filter."
          },
          "originOffsetMm": {
            "type": "array",
            "prefixItems": [
              { "type": "number" },
              { "type": "number" },
              { "type": "number" }
            ],
            "items": false,
            "minItems": 3,
            "maxItems": 3,
            "description": "The scene's origin offset in millimetres the state's camera and section are relative to."
          },
          "thumbnail": {
            "description": "Declare a thumbnail to get an upload ticket for it; omit for a view without a picture.",
            "type": "object",
            "properties": {
              "contentType": {
                "type": "string",
                "enum": ["image/webp", "image/png"],
                "description": "image/webp or image/png."
              },
              "sizeBytes": {
                "type": "integer",
                "minimum": 1,
                "maximum": 1048576,
                "description": "The image size in bytes (max 1048576)."
              }
            },
            "required": ["contentType", "sizeBytes"],
            "additionalProperties": false
          }
        },
        "required": ["organizationId", "projectId", "name", "state"],
        "additionalProperties": false
      },
      "createSavedViewOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A vw identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "The view's name, 1-80 characters."
          },
          "description": {
            "type": "string",
            "maxLength": 280,
            "description": "Optional note, max 280 characters."
          },
          "scope": { "type": "string", "enum": ["personal", "shared"] },
          "ownerUid": { "type": "string", "minLength": 1 },
          "isProjectDefault": {
            "description": "true on the project's default view (at most one shared view per project); absent otherwise.",
            "type": "boolean",
            "const": true
          },
          "order": {
            "description": "A shared view's place in the project's list (0 first); absent until the list is reordered.",
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "state": {
            "type": "object",
            "properties": {
              "schemaVersion": { "type": "number", "const": 1 },
              "camera": {
                "type": "object",
                "properties": {
                  "position": {
                    "type": "object",
                    "properties": {
                      "x": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "y": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "z": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      }
                    },
                    "required": ["x", "y", "z"],
                    "additionalProperties": false
                  },
                  "target": {
                    "type": "object",
                    "properties": {
                      "x": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "y": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "z": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      }
                    },
                    "required": ["x", "y", "z"],
                    "additionalProperties": false
                  },
                  "up": { "type": "string", "const": "z" },
                  "fovDeg": { "type": "number", "minimum": 20, "maximum": 90 },
                  "orthoHeightM": { "type": "number", "exclusiveMinimum": 0 }
                },
                "required": ["position", "target", "up"],
                "additionalProperties": false
              },
              "visibility": {
                "type": "object",
                "properties": {
                  "hiddenRefs": {
                    "maxItems": 5000,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "globalId": { "type": "string", "minLength": 1 },
                        "modelId": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        }
                      },
                      "required": ["globalId"],
                      "additionalProperties": false
                    }
                  },
                  "isolateRefs": {
                    "maxItems": 5000,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "globalId": { "type": "string", "minLength": 1 },
                        "modelId": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        }
                      },
                      "required": ["globalId"],
                      "additionalProperties": false
                    }
                  },
                  "ghost": { "type": "boolean" },
                  "isolateSource": { "type": "string", "const": "storey" }
                },
                "required": ["hiddenRefs", "isolateRefs", "ghost"],
                "additionalProperties": false
              },
              "section": {
                "type": "object",
                "properties": {
                  "axis": { "type": "string", "enum": ["x", "y", "z"] },
                  "offsetMm": { "type": "number" },
                  "flipped": { "type": "boolean" }
                },
                "required": ["axis", "offsetMm", "flipped"],
                "additionalProperties": false
              },
              "layerSetRef": {
                "type": "object",
                "properties": {
                  "layerSetId": {
                    "type": "string",
                    "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A lys identifier (TypeID, conventions C5)."
                  },
                  "overrides": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": { "type": "boolean" }
                  }
                },
                "required": ["layerSetId", "overrides"],
                "additionalProperties": false
              },
              "selection": {
                "maxItems": 50,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "globalId": { "type": "string", "minLength": 1 },
                    "modelId": {
                      "type": "string",
                      "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A mdl identifier (TypeID, conventions C5)."
                    }
                  },
                  "required": ["globalId"],
                  "additionalProperties": false
                }
              },
              "activeTool": { "type": "string", "minLength": 1 },
              "theme": { "type": "string", "enum": ["sunlight", "dim"] },
              "storeyFocusId": { "type": "string" },
              "splitView": {
                "type": "object",
                "properties": {
                  "active": { "type": "boolean" },
                  "ratio": { "type": "number", "minimum": 0.1, "maximum": 0.9 },
                  "primaryPane": {
                    "type": "string",
                    "enum": ["model", "document"]
                  },
                  "document": {
                    "type": "object",
                    "properties": {
                      "documentId": {
                        "type": "string",
                        "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                        "description": "A doc identifier (TypeID, conventions C5)."
                      },
                      "page": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 9007199254740991
                      },
                      "zoom": { "type": "number", "exclusiveMinimum": 0 },
                      "panPct": {
                        "type": "object",
                        "properties": {
                          "x": { "type": "number" },
                          "y": { "type": "number" }
                        },
                        "required": ["x", "y"],
                        "additionalProperties": false
                      },
                      "cad": {
                        "description": "FV-497: a CAD sheet's view -- the drawing point at the pane's centre (drawing units) and the scale in CSS px per drawing unit.",
                        "type": "object",
                        "properties": {
                          "center": {
                            "type": "object",
                            "properties": {
                              "x": { "type": "number" },
                              "y": { "type": "number" }
                            },
                            "required": ["x", "y"],
                            "additionalProperties": false
                          },
                          "scale": { "type": "number", "exclusiveMinimum": 0 }
                        },
                        "required": ["center", "scale"],
                        "additionalProperties": false
                      }
                    },
                    "required": ["documentId", "page"],
                    "additionalProperties": false
                  },
                  "fullscreenPane": {
                    "type": "string",
                    "enum": ["model", "document"]
                  }
                },
                "required": ["active", "ratio", "primaryPane"],
                "additionalProperties": false
              },
              "filter": {
                "description": "FV-473: the filter terms behind the hidden and isolate sets, and the built-in layers (panels, loose parts) that are off.",
                "type": "object",
                "properties": {
                  "terms": {
                    "maxItems": 20,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "mode": { "type": "string", "enum": ["only", "hide"] },
                        "key": {
                          "type": "string",
                          "enum": [
                            "search",
                            "class",
                            "type",
                            "material",
                            "layer",
                            "panel",
                            "storey",
                            "property",
                            "elements"
                          ]
                        },
                        "value": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 500
                        },
                        "name": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 200
                        },
                        "set": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 200
                        }
                      },
                      "required": ["mode", "key", "value"],
                      "additionalProperties": false
                    }
                  },
                  "builtInOff": {
                    "maxItems": 2,
                    "type": "array",
                    "items": { "type": "string", "enum": ["panels", "loose"] }
                  }
                },
                "required": ["terms"],
                "additionalProperties": false
              }
            },
            "required": [
              "schemaVersion",
              "camera",
              "visibility",
              "selection",
              "activeTool",
              "theme"
            ],
            "additionalProperties": false,
            "description": "A full ViewState v1 (E05 §4.2): camera, visibility, section, layerSetRef, selection, activeTool, theme, storeyFocusId, splitView, filter."
          },
          "originOffsetMm": {
            "type": "array",
            "prefixItems": [
              { "type": "number" },
              { "type": "number" },
              { "type": "number" }
            ],
            "items": false,
            "minItems": 3,
            "maxItems": 3,
            "description": "The scene's origin offset in millimetres the state's camera and section are relative to."
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "thumbnail": {
            "type": "object",
            "properties": {
              "contentType": {
                "type": "string",
                "enum": ["image/webp", "image/png"],
                "description": "image/webp or image/png."
              },
              "sizeBytes": {
                "type": "integer",
                "minimum": 1,
                "maximum": 1048576,
                "description": "The image size in bytes (max 1048576)."
              }
            },
            "required": ["contentType", "sizeBytes"],
            "additionalProperties": false
          },
          "thumbnailUrl": {
            "description": "Signed URL of the thumbnail (15 minutes). Absent while the image has not been uploaded.",
            "type": "object",
            "properties": {
              "url": { "type": "string" },
              "expiresAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["url", "expiresAt"],
            "additionalProperties": false
          },
          "upload": {
            "description": "Present when a thumbnail was declared: PUT the image bytes to upload.url (C13).",
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "name",
          "scope",
          "state",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "createSurveyResponseInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "wave": {
            "type": "string",
            "pattern": "^m[0-9]{1,2}$",
            "description": "The survey wave: a milestone, lower case (m3, m4)."
          },
          "kind": {
            "type": "string",
            "enum": ["sus", "nps"],
            "description": "sus (ten 1-5 answers) or nps (one 0-10 score)."
          },
          "answers": {
            "description": "SUS only: the ten answers, 1-5, in questionnaire order.",
            "minItems": 10,
            "maxItems": 10,
            "type": "array",
            "items": { "type": "integer", "minimum": 1, "maximum": 5 }
          },
          "score": {
            "description": "NPS only: the 0-10 score.",
            "type": "integer",
            "minimum": 0,
            "maximum": 10
          },
          "comment": {
            "type": "string",
            "maxLength": 1000,
            "description": "An optional remark in the person's own words (at most 1000 chars)."
          }
        },
        "required": ["organizationId", "wave", "kind"],
        "additionalProperties": false
      },
      "createSurveyResponseOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "minLength": 1,
            "description": "{organizationId}_{userId}_{wave}: one response per person per wave."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "userId": { "type": "string", "minLength": 1 },
          "wave": {
            "type": "string",
            "pattern": "^m[0-9]{1,2}$",
            "description": "The survey wave: a milestone, lower case (m3, m4)."
          },
          "kind": { "type": "string", "enum": ["sus", "nps"] },
          "answers": {
            "minItems": 10,
            "maxItems": 10,
            "type": "array",
            "items": { "type": "integer", "minimum": 1, "maximum": 5 },
            "description": "The ten SUS answers in questionnaire order, each 1 (strongly disagree) to 5 (strongly agree)."
          },
          "score": {
            "type": "integer",
            "minimum": 0,
            "maximum": 10,
            "description": "How likely the person is to recommend the app, 0-10."
          },
          "comment": {
            "type": "string",
            "maxLength": 1000,
            "description": "An optional remark in the person's own words (at most 1000 chars)."
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "submittedAt": {
            "type": "string",
            "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))$"
          }
        },
        "required": [
          "id",
          "organizationId",
          "userId",
          "wave",
          "kind",
          "schemaVersion",
          "submittedAt"
        ],
        "additionalProperties": false
      },
      "createTelemetryBatchInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "events": {
            "minItems": 1,
            "type": "array",
            "items": {
              "oneOf": [
                {
                  "type": "object",
                  "properties": {
                    "kind": { "type": "string", "const": "log" },
                    "at": {
                      "type": "string",
                      "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))$"
                    },
                    "level": {
                      "type": "string",
                      "enum": ["debug", "info", "warn", "error"]
                    },
                    "event": {
                      "type": "string",
                      "maxLength": 80,
                      "pattern": "^[a-z][a-z0-9_]*(\\.[a-z0-9_]+)*$"
                    },
                    "message": { "type": "string", "maxLength": 500 },
                    "route": { "type": "string", "maxLength": 200 },
                    "attributes": {
                      "description": "Flat facts about the event (ids, codes, counts). Denylisted keys are redacted server-side.",
                      "type": "object",
                      "propertyNames": { "type": "string", "maxLength": 64 },
                      "additionalProperties": {
                        "anyOf": [
                          { "type": "string", "maxLength": 200 },
                          { "type": "number" },
                          { "type": "boolean" },
                          { "type": "null" }
                        ]
                      }
                    }
                  },
                  "required": ["kind", "at", "level", "event"],
                  "additionalProperties": false
                },
                {
                  "type": "object",
                  "properties": {
                    "kind": { "type": "string", "const": "web_vital" },
                    "at": {
                      "type": "string",
                      "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))$"
                    },
                    "name": { "type": "string", "enum": ["CLS", "LCP", "INP"] },
                    "value": { "type": "number", "minimum": 0 },
                    "rating": {
                      "type": "string",
                      "enum": ["good", "needs-improvement", "poor"]
                    },
                    "route": { "type": "string", "maxLength": 200 }
                  },
                  "required": ["kind", "at", "name", "value", "rating"],
                  "additionalProperties": false
                },
                {
                  "type": "object",
                  "properties": {
                    "kind": { "type": "string", "const": "error" },
                    "at": {
                      "type": "string",
                      "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))$"
                    },
                    "name": { "type": "string", "maxLength": 100 },
                    "message": { "type": "string", "maxLength": 500 },
                    "stack": { "type": "string", "maxLength": 4000 },
                    "route": { "type": "string", "maxLength": 200 }
                  },
                  "required": ["kind", "at", "name", "message"],
                  "additionalProperties": false
                }
              ]
            }
          },
          "appVersion": {
            "description": "The web build's git sha, when known.",
            "type": "string",
            "maxLength": 64
          }
        },
        "required": ["events"],
        "additionalProperties": false
      },
      "createTelemetryBatchOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "accepted": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "How many events became log lines."
          }
        },
        "required": ["accepted"],
        "additionalProperties": false
      },
      "createTrialInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "createTrialOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "status": { "type": "string", "const": "trialing" },
          "trialEndsAt": {
            "type": "string",
            "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))$",
            "description": "When the trial ends; the organisation then returns to the free plan unless it paid."
          }
        },
        "required": ["status", "trialEndsAt"],
        "additionalProperties": false
      },
      "createTryoutInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "fileName": {
            "description": "The IFC's file name (.ifc or .ifczip). Omit, with sizeBytes and contentType, for a tryout of drawings only.",
            "type": "string",
            "minLength": 1,
            "maxLength": 255
          },
          "sizeBytes": {
            "type": "integer",
            "minimum": 1,
            "maximum": 1073741824,
            "description": "Declared file size in bytes (BR-24)."
          },
          "contentType": {
            "description": "The IFC file's MIME type, e.g. application/octet-stream.",
            "type": "string",
            "minLength": 1
          },
          "drawings": {
            "maxItems": 20,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "fileName": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 255,
                  "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                },
                "sizeBytes": {
                  "type": "integer",
                  "minimum": 1,
                  "maximum": 1073741824,
                  "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                },
                "contentType": {
                  "type": "string",
                  "minLength": 1,
                  "description": "The drawing's MIME type: application/pdf, or whatever the browser reports for a DXF or DWG."
                }
              },
              "required": ["fileName", "sizeBytes", "contentType"],
              "additionalProperties": false
            },
            "description": "The drawings (PDF, DXF or DWG), up to the tryout plan's maxDocumentsPerProject."
          },
          "locale": {
            "type": "string",
            "enum": ["nl", "en", "fr"],
            "description": "The visitor's language (nl, en or fr)."
          },
          "source": {
            "type": "object",
            "properties": {
              "page": {
                "type": "string",
                "enum": ["site_try", "direct", "mail"],
                "description": "Where the visitor started: site_try (the try page on field-viewer.com), direct (/try opened directly) or mail."
              },
              "utm": {
                "description": "The campaign parameters of the try page, if any.",
                "type": "object",
                "properties": {
                  "source": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 100
                  },
                  "medium": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 100
                  },
                  "campaign": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 100
                  },
                  "term": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 100
                  },
                  "content": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 100
                  }
                },
                "additionalProperties": false
              }
            },
            "required": ["page"],
            "additionalProperties": false
          }
        },
        "required": ["locale", "source"],
        "additionalProperties": false
      },
      "createTryoutOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "tryout": {
            "type": "object",
            "properties": {
              "organizationId": {
                "type": "string",
                "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A org identifier (TypeID, conventions C5)."
              },
              "projectId": {
                "type": "string",
                "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A prj identifier (TypeID, conventions C5)."
              },
              "modelId": {
                "type": "string",
                "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A mdl identifier (TypeID, conventions C5)."
              },
              "versionId": {
                "description": "The IFC's revision; absent for a tryout of drawings only.",
                "type": "string",
                "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
              },
              "revisionNumber": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "claimToken": {
                "type": "string",
                "pattern": "^[0-9a-f]{64}$",
                "description": "The single-use claim token that keeps this model in an account later. Returned only here; Field-Viewer stores only its hash."
              }
            },
            "required": [
              "organizationId",
              "projectId",
              "modelId",
              "expiresAt",
              "claimToken"
            ],
            "additionalProperties": false
          },
          "upload": {
            "description": "The IFC's upload ticket; absent for a tryout of drawings only.",
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          },
          "drawings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "documentId": {
                  "type": "string",
                  "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A doc identifier (TypeID, conventions C5)."
                },
                "versionId": {
                  "type": "string",
                  "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A dvr identifier (TypeID, conventions C5)."
                },
                "upload": {
                  "type": "object",
                  "properties": {
                    "method": { "type": "string", "const": "PUT" },
                    "url": { "type": "string" },
                    "headers": {
                      "type": "object",
                      "propertyNames": { "type": "string" },
                      "additionalProperties": { "type": "string" }
                    },
                    "expiresAt": {
                      "type": "string",
                      "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))$"
                    },
                    "maxBytes": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    },
                    "resumable": { "type": "boolean", "const": true },
                    "chunkSizeBytes": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": [
                    "method",
                    "url",
                    "headers",
                    "expiresAt",
                    "maxBytes",
                    "resumable",
                    "chunkSizeBytes"
                  ],
                  "additionalProperties": false
                }
              },
              "required": ["documentId", "versionId", "upload"],
              "additionalProperties": false
            },
            "description": "One per drawing sent, in the same order (FV-745)."
          }
        },
        "required": ["tryout", "drawings"],
        "additionalProperties": false
      },
      "createWorkstationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "id": {
            "type": "string",
            "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A wks identifier (TypeID, conventions C5)."
          },
          "name": { "type": "string", "minLength": 1, "maxLength": 60 },
          "projectIds": {
            "maxItems": 20,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        },
        "required": ["organizationId", "name"],
        "additionalProperties": false
      },
      "createWorkstationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A wks identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": { "type": "string", "minLength": 1 },
          "assignedProjectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "projectIds": {
            "default": [],
            "maxItems": 20,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          "status": {
            "type": "string",
            "enum": ["unpaired", "active", "revoked"]
          },
          "blocked": { "type": "boolean" },
          "pairedAt": {
            "type": "string",
            "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))$"
          },
          "lastSeenAt": {
            "type": "string",
            "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))$"
          },
          "revokedAt": {
            "type": "string",
            "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))$"
          },
          "revokedBy": { "type": "string", "minLength": 1 },
          "preset": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "mode": { "type": "string", "const": "fixed" },
                  "projectId": {
                    "type": "string",
                    "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A prj identifier (TypeID, conventions C5)."
                  },
                  "modelPolicy": {
                    "type": "string",
                    "const": "latest_published"
                  },
                  "viewId": {
                    "type": "string",
                    "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A vw identifier (TypeID, conventions C5)."
                  },
                  "toolbarConfig": {
                    "maxItems": 7,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^[a-z][a-zA-Z0-9-]{0,39}$"
                    }
                  },
                  "lockedSettings": {
                    "type": "object",
                    "properties": {
                      "allowProjectSwitch": { "type": "boolean" },
                      "allowShare": { "type": "boolean" },
                      "theme": {
                        "type": "string",
                        "enum": ["sunlight", "dim"]
                      },
                      "idleResetMinutes": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 120
                      }
                    },
                    "required": [
                      "allowProjectSwitch",
                      "allowShare",
                      "idleResetMinutes"
                    ],
                    "additionalProperties": false
                  }
                },
                "required": [
                  "mode",
                  "projectId",
                  "modelPolicy",
                  "lockedSettings"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "mode": { "type": "string", "const": "crew" },
                  "projectIds": {
                    "minItems": 1,
                    "maxItems": 20,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A prj identifier (TypeID, conventions C5)."
                    }
                  },
                  "modelPolicy": {
                    "type": "string",
                    "const": "latest_published"
                  },
                  "viewId": {
                    "type": "string",
                    "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A vw identifier (TypeID, conventions C5)."
                  },
                  "toolbarConfig": {
                    "maxItems": 7,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^[a-z][a-zA-Z0-9-]{0,39}$"
                    }
                  },
                  "lockedSettings": {
                    "type": "object",
                    "properties": {
                      "allowProjectSwitch": { "type": "boolean" },
                      "allowShare": { "type": "boolean" },
                      "theme": {
                        "type": "string",
                        "enum": ["sunlight", "dim"]
                      },
                      "idleResetMinutes": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 120
                      }
                    },
                    "required": [
                      "allowProjectSwitch",
                      "allowShare",
                      "idleResetMinutes"
                    ],
                    "additionalProperties": false
                  }
                },
                "required": [
                  "mode",
                  "projectIds",
                  "modelPolicy",
                  "lockedSettings"
                ],
                "additionalProperties": false
              }
            ]
          },
          "runtime": {
            "type": "object",
            "properties": {
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "currentProjectId": {
                "type": "string",
                "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A prj identifier (TypeID, conventions C5)."
              },
              "appVersion": {
                "type": "string",
                "minLength": 1,
                "maxLength": 64
              },
              "state": { "type": "string", "enum": ["ready", "error"] }
            },
            "required": ["heartbeatAt"],
            "additionalProperties": false
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "name",
          "projectIds",
          "status",
          "blocked",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "createWorkstationPairingCodeInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "workstationId": {
            "type": "string",
            "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A wks identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "workstationId"],
        "additionalProperties": false
      },
      "createWorkstationPairingCodeOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "code": {
            "type": "string",
            "pattern": "^[0-9A-HJKMNP-TV-Z]{4}-[0-9A-HJKMNP-TV-Z]{4}$"
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "workstation": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A wks identifier (TypeID, conventions C5)."
              },
              "organizationId": {
                "type": "string",
                "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A org identifier (TypeID, conventions C5)."
              },
              "name": { "type": "string", "minLength": 1 },
              "assignedProjectId": {
                "type": "string",
                "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A prj identifier (TypeID, conventions C5)."
              },
              "projectIds": {
                "default": [],
                "maxItems": 20,
                "type": "array",
                "items": {
                  "type": "string",
                  "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A prj identifier (TypeID, conventions C5)."
                }
              },
              "status": {
                "type": "string",
                "enum": ["unpaired", "active", "revoked"]
              },
              "blocked": { "type": "boolean" },
              "pairedAt": {
                "type": "string",
                "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))$"
              },
              "lastSeenAt": {
                "type": "string",
                "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))$"
              },
              "revokedAt": {
                "type": "string",
                "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))$"
              },
              "revokedBy": { "type": "string", "minLength": 1 },
              "preset": {
                "oneOf": [
                  {
                    "type": "object",
                    "properties": {
                      "mode": { "type": "string", "const": "fixed" },
                      "projectId": {
                        "type": "string",
                        "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                        "description": "A prj identifier (TypeID, conventions C5)."
                      },
                      "modelPolicy": {
                        "type": "string",
                        "const": "latest_published"
                      },
                      "viewId": {
                        "type": "string",
                        "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                        "description": "A vw identifier (TypeID, conventions C5)."
                      },
                      "toolbarConfig": {
                        "maxItems": 7,
                        "type": "array",
                        "items": {
                          "type": "string",
                          "pattern": "^[a-z][a-zA-Z0-9-]{0,39}$"
                        }
                      },
                      "lockedSettings": {
                        "type": "object",
                        "properties": {
                          "allowProjectSwitch": { "type": "boolean" },
                          "allowShare": { "type": "boolean" },
                          "theme": {
                            "type": "string",
                            "enum": ["sunlight", "dim"]
                          },
                          "idleResetMinutes": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 120
                          }
                        },
                        "required": [
                          "allowProjectSwitch",
                          "allowShare",
                          "idleResetMinutes"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "required": [
                      "mode",
                      "projectId",
                      "modelPolicy",
                      "lockedSettings"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "mode": { "type": "string", "const": "crew" },
                      "projectIds": {
                        "minItems": 1,
                        "maxItems": 20,
                        "type": "array",
                        "items": {
                          "type": "string",
                          "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A prj identifier (TypeID, conventions C5)."
                        }
                      },
                      "modelPolicy": {
                        "type": "string",
                        "const": "latest_published"
                      },
                      "viewId": {
                        "type": "string",
                        "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                        "description": "A vw identifier (TypeID, conventions C5)."
                      },
                      "toolbarConfig": {
                        "maxItems": 7,
                        "type": "array",
                        "items": {
                          "type": "string",
                          "pattern": "^[a-z][a-zA-Z0-9-]{0,39}$"
                        }
                      },
                      "lockedSettings": {
                        "type": "object",
                        "properties": {
                          "allowProjectSwitch": { "type": "boolean" },
                          "allowShare": { "type": "boolean" },
                          "theme": {
                            "type": "string",
                            "enum": ["sunlight", "dim"]
                          },
                          "idleResetMinutes": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 120
                          }
                        },
                        "required": [
                          "allowProjectSwitch",
                          "allowShare",
                          "idleResetMinutes"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "required": [
                      "mode",
                      "projectIds",
                      "modelPolicy",
                      "lockedSettings"
                    ],
                    "additionalProperties": false
                  }
                ]
              },
              "runtime": {
                "type": "object",
                "properties": {
                  "heartbeatAt": {
                    "type": "string",
                    "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))$"
                  },
                  "currentProjectId": {
                    "type": "string",
                    "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A prj identifier (TypeID, conventions C5)."
                  },
                  "appVersion": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 64
                  },
                  "state": { "type": "string", "enum": ["ready", "error"] }
                },
                "required": ["heartbeatAt"],
                "additionalProperties": false
              },
              "schemaVersion": { "type": "number", "const": 1 },
              "createdAt": {
                "type": "string",
                "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))$"
              },
              "updatedAt": {
                "type": "string",
                "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))$"
              },
              "revision": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "createdBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              }
            },
            "required": [
              "id",
              "organizationId",
              "name",
              "projectIds",
              "status",
              "blocked",
              "schemaVersion",
              "createdAt",
              "updatedAt",
              "revision",
              "createdBy"
            ],
            "additionalProperties": false
          }
        },
        "required": ["code", "expiresAt", "workstation"],
        "additionalProperties": false
      },
      "deleteAnnotationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "annotationId": {
            "type": "string",
            "pattern": "^ann_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ann identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "annotationId"],
        "additionalProperties": false
      },
      "deleteAnnotationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ann_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ann identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          }
        },
        "required": ["id", "organizationId", "projectId"],
        "additionalProperties": false
      },
      "deleteDocumentInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "documentId"],
        "additionalProperties": false
      },
      "deleteDocumentOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "title": {
            "type": "string",
            "minLength": 1,
            "maxLength": 200,
            "description": "Document display title (1-200 chars after trimming)."
          },
          "status": {
            "type": "string",
            "enum": ["active", "archived", "deleted"]
          },
          "nextVersionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "format": { "type": "string", "enum": ["pdf", "dxf", "dwg"] },
          "published": {
            "type": "object",
            "properties": {
              "versionId": {
                "type": "string",
                "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A dvr identifier (TypeID, conventions C5)."
              },
              "publishedAt": {
                "type": "string",
                "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))$"
              },
              "publishedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              },
              "publishSeq": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "versionId",
              "publishedAt",
              "publishedBy",
              "publishSeq"
            ],
            "additionalProperties": false
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "deletedAt": {
            "type": "string",
            "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))$"
          },
          "purgeAfter": {
            "type": "string",
            "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))$"
          },
          "statusBeforeDeletion": {
            "type": "string",
            "enum": ["active", "archived"]
          },
          "purgeStartedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "status",
          "nextVersionNumber",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "deleteLayerTemplateInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "templateId": {
            "type": "string",
            "pattern": "^ltp_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ltp identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "templateId"],
        "additionalProperties": false
      },
      "deleteLayerTemplateOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ltp_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ltp identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": { "type": "string", "minLength": 1, "maxLength": 60 },
          "layers": {
            "maxItems": 50,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^[a-z0-9][a-z0-9-]{0,39}$"
                },
                "displayName": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 60
                },
                "colorHex": { "type": "string", "pattern": "^#[0-9a-f]{6}$" },
                "rule": {
                  "type": "object",
                  "properties": {
                    "source": {
                      "type": "string",
                      "enum": [
                        "property",
                        "name",
                        "material",
                        "ifcClass",
                        "panel"
                      ]
                    },
                    "psetName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255
                    },
                    "propName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255
                    },
                    "op": {
                      "type": "string",
                      "enum": ["eq", "neq", "contains"]
                    },
                    "value": { "type": "string", "maxLength": 1000 }
                  },
                  "required": ["op", "value"],
                  "additionalProperties": false
                },
                "defaultOn": { "type": "boolean" },
                "hiddenFromField": { "type": "boolean" },
                "locked": { "type": "boolean" }
              },
              "required": [
                "id",
                "displayName",
                "rule",
                "defaultOn",
                "hiddenFromField",
                "locked"
              ],
              "additionalProperties": false
            }
          },
          "applyTo": { "type": "string", "enum": ["all", "chosen"] },
          "projectIds": {
            "minItems": 1,
            "maxItems": 400,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          "appliedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "name",
          "layers",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "deleteLinkInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "linkId": {
            "type": "string",
            "pattern": "^lnk_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lnk identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "linkId"],
        "additionalProperties": false
      },
      "deleteLinkOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^lnk_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lnk identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "element" },
                  "modelId": {
                    "type": "string",
                    "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A mdl identifier (TypeID, conventions C5)."
                  },
                  "globalId": { "type": "string", "minLength": 1 }
                },
                "required": ["kind", "modelId", "globalId"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "assembly" },
                  "modelId": {
                    "type": "string",
                    "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A mdl identifier (TypeID, conventions C5)."
                  },
                  "assemblyMark": { "type": "string", "minLength": 1 }
                },
                "required": ["kind", "modelId", "assemblyMark"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "storey" },
                  "modelId": {
                    "type": "string",
                    "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A mdl identifier (TypeID, conventions C5)."
                  },
                  "storeyId": { "type": "string", "minLength": 1 }
                },
                "required": ["kind", "modelId", "storeyId"],
                "additionalProperties": false
              }
            ]
          },
          "target": {
            "type": "object",
            "properties": {
              "documentId": {
                "type": "string",
                "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A doc identifier (TypeID, conventions C5)."
              },
              "page": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "layoutName": {
                "type": "string",
                "minLength": 1,
                "maxLength": 255
              },
              "region": {
                "type": "object",
                "properties": {
                  "xPct": { "type": "number", "minimum": 0, "maximum": 1 },
                  "yPct": { "type": "number", "minimum": 0, "maximum": 1 },
                  "wPct": { "type": "number", "minimum": 0, "maximum": 1 },
                  "hPct": { "type": "number", "minimum": 0, "maximum": 1 }
                },
                "required": ["xPct", "yPct", "wPct", "hPct"],
                "additionalProperties": false
              },
              "cadRegion": {
                "type": "object",
                "properties": {
                  "x": { "type": "number" },
                  "y": { "type": "number" },
                  "w": { "type": "number", "exclusiveMinimum": 0 },
                  "h": { "type": "number", "exclusiveMinimum": 0 },
                  "space": { "type": "string", "enum": ["model", "paper"] }
                },
                "required": ["x", "y", "w", "h", "space"],
                "additionalProperties": false
              },
              "textRef": {
                "type": "object",
                "properties": {
                  "textIndex": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "text": { "type": "string", "minLength": 1, "maxLength": 200 }
                },
                "required": ["textIndex", "text"],
                "additionalProperties": false
              }
            },
            "required": ["documentId", "page"],
            "additionalProperties": false
          },
          "origin": {
            "type": "string",
            "enum": ["rule", "manual", "connector"]
          },
          "ruleId": {
            "type": "string",
            "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lkr identifier (TypeID, conventions C5)."
          },
          "confidence": { "type": "number", "minimum": 0, "maximum": 1 },
          "key": { "type": "string", "minLength": 1 },
          "status": { "type": "string", "enum": ["active", "stale"] },
          "staleSince": {
            "type": "string",
            "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))$"
          },
          "staleReason": { "type": "string", "enum": ["page_removed"] },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "source",
          "target",
          "origin",
          "status",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "deleteLinkRuleInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "ruleId": {
            "type": "string",
            "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lkr identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "ruleId"],
        "additionalProperties": false
      },
      "deleteLinkRuleOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lkr identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "description": "Rule name, 1-100 chars after trimming."
          },
          "enabled": { "type": "boolean" },
          "priority": { "type": "integer", "minimum": 0, "maximum": 1000 },
          "matchModel": {
            "type": "object",
            "properties": {
              "field": {
                "type": "string",
                "enum": [
                  "tag",
                  "assemblyMark",
                  "storeyName",
                  "name",
                  "property"
                ]
              },
              "property": {
                "type": "object",
                "properties": {
                  "set": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 128,
                    "description": "Property set, e.g. Pset_Panel."
                  },
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 128,
                    "description": "Property name, e.g. Drawing."
                  }
                },
                "required": ["set", "name"],
                "additionalProperties": false
              }
            },
            "required": ["field"],
            "additionalProperties": false
          },
          "matchDocument": {
            "type": "object",
            "properties": {
              "field": {
                "type": "string",
                "enum": [
                  "fileName",
                  "sheetNumber",
                  "outlineTitle",
                  "titleBlock",
                  "layoutName",
                  "blockAttribute",
                  "sheetText"
                ]
              },
              "attributeTag": {
                "type": "string",
                "minLength": 1,
                "maxLength": 128
              }
            },
            "required": ["field"],
            "additionalProperties": false
          },
          "normalization": {
            "type": "object",
            "properties": {
              "caseInsensitive": { "type": "boolean" },
              "stripWhitespace": { "type": "boolean" },
              "stripLeadingZeros": { "type": "boolean" },
              "regex": {
                "type": "string",
                "description": "Regular expression applied to both sides after the other normalisation steps: a value that does not match is ignored, otherwise the match (or its named group `key`) is the value compared, e.g. W-\\d{3} (max 200 chars; no backreferences or nested repeats)."
              }
            },
            "required": [
              "caseInsensitive",
              "stripWhitespace",
              "stripLeadingZeros"
            ],
            "additionalProperties": false
          },
          "autoApply": { "type": "boolean" },
          "discoveryRunId": {
            "type": "string",
            "pattern": "^ldr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ldr identifier (TypeID, conventions C5)."
          },
          "ambiguousDocumentIds": {
            "maxItems": 500,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "name",
          "enabled",
          "priority",
          "matchModel",
          "matchDocument",
          "normalization",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "deleteModelVersionInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "modelId", "versionId"],
        "additionalProperties": false
      },
      "deleteModelVersionOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "objectsRemovedAfter": {
            "type": "string",
            "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))$",
            "description": "When the version's stored files (source and artefacts) are physically removed (24 h after the delete)."
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "modelId",
          "versionNumber",
          "objectsRemovedAfter"
        ],
        "additionalProperties": false
      },
      "deleteMyAccountInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {},
        "additionalProperties": false
      },
      "deleteMyAccountOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^usr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A usr identifier (TypeID, conventions C5)."
          },
          "deletedAt": {
            "type": "string",
            "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))$"
          },
          "organizationIds": {
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            },
            "description": "Organisations whose membership was removed by this call."
          }
        },
        "required": ["id", "deletedAt", "organizationIds"],
        "additionalProperties": false
      },
      "deleteProjectInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId"],
        "additionalProperties": false
      },
      "deleteProjectOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "Project display name (1-80 chars after trimming, BR-2)."
          },
          "reference": {
            "type": "string",
            "minLength": 1,
            "maxLength": 40,
            "description": "Free-form job/reference code, e.g. \"2026-041\" (BR-2)."
          },
          "description": {
            "type": "string",
            "maxLength": 500,
            "description": "Free-form project description (BR-2)."
          },
          "status": {
            "type": "string",
            "enum": ["active", "archived", "deleted"]
          },
          "access": { "type": "string", "enum": ["org", "restricted"] },
          "memberIds": {
            "maxItems": 500,
            "type": "array",
            "items": { "type": "string", "minLength": 1 }
          },
          "fieldVersionIds": {
            "maxItems": 500,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ver identifier (TypeID, conventions C5)."
            }
          },
          "publishSeq": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "lastPublishedAt": {
            "type": "string",
            "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))$"
          },
          "isSample": { "type": "boolean", "const": true },
          "demoSlug": {
            "type": "string",
            "enum": [
              "landhuis_hulstveld",
              "landhuis_hulstveld_hsb",
              "woning_lindehof",
              "villa_berkenhaag",
              "hal_noorderkempen",
              "paneelset_werkplaats"
            ]
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "deletedAt": {
            "type": "string",
            "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))$"
          },
          "purgeAfter": {
            "type": "string",
            "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))$"
          },
          "statusBeforeDeletion": {
            "type": "string",
            "enum": ["active", "archived"]
          },
          "purgeStartedAt": {
            "type": "string",
            "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))$"
          },
          "sheetMetadata": {
            "type": "object",
            "properties": {
              "fileNamePattern": {
                "type": "string",
                "description": "Regular expression matched against the file name without its .pdf extension, with named groups sheetNumber and/or discipline, e.g. ^(?<discipline>[A-Z])-(?<sheetNumber>\\d+) (max 200 chars; no backreferences or nested repeats)."
              },
              "disciplineMap": {
                "type": "object",
                "propertyNames": {
                  "type": "string",
                  "pattern": "^[A-Za-z0-9]{1,8}$"
                },
                "additionalProperties": {
                  "type": "string",
                  "enum": [
                    "architecture",
                    "structure",
                    "mechanical",
                    "electrical",
                    "plumbing",
                    "fire_protection",
                    "civil",
                    "landscape",
                    "general"
                  ]
                }
              }
            },
            "additionalProperties": false,
            "description": "How this project's PDF file names map to sheet number and discipline (BR-11). Without a fileNamePattern the file-name stem is the sheet number."
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "name",
          "status",
          "access",
          "memberIds",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "deleteSavedViewInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "viewId": {
            "type": "string",
            "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A vw identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "viewId"],
        "additionalProperties": false
      },
      "deleteSavedViewOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A vw identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          }
        },
        "required": ["id", "organizationId", "projectId"],
        "additionalProperties": false
      },
      "deleteTryoutInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "deleteTryoutOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 2,
            "maxLength": 80,
            "description": "Organisation display name (2-80 chars after trimming, BR-10)."
          },
          "defaultLocale": {
            "type": "string",
            "enum": ["nl", "en", "fr"],
            "description": "The organisation's default UI locale, one of nl | en | fr."
          },
          "status": {
            "type": "string",
            "enum": ["active", "pending_deletion"]
          },
          "deletion": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "purgeAfter": {
                "type": "string",
                "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))$"
              },
              "cancelledAt": {
                "type": "string",
                "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))$"
              },
              "purgeStartedAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["requestedAt", "requestedBy", "purgeAfter"],
            "additionalProperties": false
          },
          "supportAccess": {
            "description": "Whether Field-Viewer support may open a read-only support session: allowed (default when absent; owners are e-mailed) or ask (an owner approves each request first).",
            "type": "string",
            "enum": ["allowed", "ask"]
          },
          "settings": {
            "type": "object",
            "properties": {
              "analytics": {
                "type": "object",
                "properties": {
                  "mode": {
                    "type": "string",
                    "enum": ["enabled", "disabled"],
                    "description": "Product analytics for every member: enabled (the default) or disabled. Disabled, no usage event is recorded for anyone in the organisation."
                  }
                },
                "required": ["mode"],
                "additionalProperties": false
              },
              "cad": {
                "type": "object",
                "properties": {
                  "producerDetailTags": {
                    "type": "object",
                    "properties": {
                      "scale": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's scale text (1:n)."
                      },
                      "xFactor": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's x factor (1/n)."
                      },
                      "yFactor": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's y factor (1/n)."
                      },
                      "xMin": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's minimum x."
                      },
                      "yMin": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's minimum y."
                      },
                      "xMax": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's maximum x."
                      },
                      "yMax": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's maximum y."
                      }
                    },
                    "required": [
                      "scale",
                      "xFactor",
                      "yFactor",
                      "xMin",
                      "yMin",
                      "xMax",
                      "yMax"
                    ],
                    "additionalProperties": false,
                    "description": "The CAD producer's detail attribute tags: all seven, each the tag (not the value) of one block attribute. With them, scaled details in model space measure in real millimetres at their own scale; without them they read 'scale unknown'."
                  }
                },
                "additionalProperties": false
              }
            },
            "additionalProperties": false
          },
          "legal": {
            "type": "object",
            "properties": {
              "termsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "privacyVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "dpaVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "subprocessorsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "acceptedAt": {
                "type": "string",
                "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))$"
              },
              "acceptedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              }
            },
            "required": [
              "termsVersion",
              "privacyVersion",
              "dpaVersion",
              "subprocessorsVersion",
              "acceptedAt",
              "acceptedBy"
            ],
            "additionalProperties": false,
            "description": "The terms, privacy notice, DPA and sub-processor list versions an owner accepted for the organisation."
          },
          "kind": {
            "description": "standard (default when absent) or tryout: an anonymous visitor's 7-day try-it organisation.",
            "type": "string",
            "enum": ["standard", "tryout"]
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "logoUrl": {
            "type": "object",
            "properties": {
              "url": { "type": "string" },
              "expiresAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["url", "expiresAt"],
            "additionalProperties": false,
            "description": "Signed URL of the organisation's logo (15 minutes). Absent when it has no logo."
          },
          "reacceptanceRequired": {
            "description": "True when an owner must accept a newer material version of the terms, the DPA or the sub-processor list (or never accepted them).",
            "type": "boolean"
          }
        },
        "required": [
          "id",
          "name",
          "defaultLocale",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "deleteWorkstationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "workstationId": {
            "type": "string",
            "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A wks identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "workstationId"],
        "additionalProperties": false
      },
      "deleteWorkstationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A wks identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["id", "organizationId"],
        "additionalProperties": false
      },
      "denyOAuthAuthorizationRequestInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "requestId": {
            "type": "string",
            "pattern": "^oar_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A oar identifier (TypeID, conventions C5)."
          }
        },
        "required": ["requestId"],
        "additionalProperties": false
      },
      "denyOAuthAuthorizationRequestOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": { "redirectUrl": { "type": "string", "format": "uri" } },
        "required": ["redirectUrl"],
        "additionalProperties": false
      },
      "denySupportAccessRequestInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "uid": {
            "type": "string",
            "minLength": 1,
            "maxLength": 128,
            "description": "The platform admin whose request it is (the request's uid)."
          }
        },
        "required": ["organizationId", "uid"],
        "additionalProperties": false
      },
      "denySupportAccessRequestOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": { "type": "string", "minLength": 1 },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "uid": {
            "type": "string",
            "minLength": 1,
            "description": "The platform admin's user id."
          },
          "reason": { "type": "string" },
          "durationMinutes": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": ["pending", "approved", "denied", "used", "expired"]
          },
          "requestedAt": {
            "type": "string",
            "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))$"
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "decidedAt": {
            "type": "string",
            "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))$"
          }
        },
        "required": [
          "id",
          "organizationId",
          "uid",
          "reason",
          "durationMinutes",
          "status",
          "requestedAt",
          "expiresAt"
        ],
        "additionalProperties": false
      },
      "endSupportAccessInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "endSupportAccessOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": { "type": "string", "minLength": 1 },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "uid": {
            "type": "string",
            "minLength": 1,
            "description": "The platform admin's user id."
          },
          "reason": { "type": "string" },
          "status": {
            "type": "string",
            "enum": ["active", "ended", "expired"]
          },
          "startedAt": {
            "type": "string",
            "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))$"
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "endedAt": {
            "type": "string",
            "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))$"
          }
        },
        "required": [
          "id",
          "organizationId",
          "uid",
          "reason",
          "status",
          "startedAt",
          "expiresAt"
        ],
        "additionalProperties": false
      },
      "getAnnotationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "annotationId": {
            "type": "string",
            "pattern": "^ann_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ann identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "annotationId"],
        "additionalProperties": false
      },
      "getAnnotationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ann_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ann identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "subtype": { "type": "string", "enum": ["measurement"] },
          "visibility": { "type": "string", "enum": ["personal", "shared"] },
          "measurement": {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "distance",
                  "edgeLength",
                  "angle",
                  "areaFace",
                  "perpendicularPointFace",
                  "perpendicularFaceFace",
                  "areaPolygon",
                  "overallDimensions"
                ]
              },
              "anchors": {
                "minItems": 1,
                "maxItems": 100,
                "type": "array",
                "items": {
                  "oneOf": [
                    {
                      "type": "object",
                      "properties": {
                        "kind": { "type": "string", "const": "element" },
                        "globalId": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 64,
                          "description": "IFC GlobalId of the anchored element."
                        },
                        "modelId": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        },
                        "versionId": {
                          "type": "string",
                          "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A ver identifier (TypeID, conventions C5)."
                        },
                        "localPointMm": {
                          "type": "object",
                          "properties": {
                            "x": { "type": "number" },
                            "y": { "type": "number" },
                            "z": { "type": "number" }
                          },
                          "required": ["x", "y", "z"],
                          "additionalProperties": false,
                          "description": "Snapped point in the version's coordinates, millimetres."
                        },
                        "edgeDirection": {
                          "description": "For an angle taken off an edge: the edge's unit direction in the version's coordinates.",
                          "type": "object",
                          "properties": {
                            "x": { "type": "number" },
                            "y": { "type": "number" },
                            "z": { "type": "number" }
                          },
                          "required": ["x", "y", "z"],
                          "additionalProperties": false
                        },
                        "faceNormal": {
                          "description": "For an angle or a face area taken off a face: the face's unit normal in the version's coordinates.",
                          "type": "object",
                          "properties": {
                            "x": { "type": "number" },
                            "y": { "type": "number" },
                            "z": { "type": "number" }
                          },
                          "required": ["x", "y", "z"],
                          "additionalProperties": false
                        }
                      },
                      "required": ["globalId", "versionId", "localPointMm"],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "kind": { "type": "string", "const": "document" },
                        "documentId": {
                          "type": "string",
                          "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A doc identifier (TypeID, conventions C5)."
                        },
                        "documentVersionId": {
                          "type": "string",
                          "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A dvr identifier (TypeID, conventions C5)."
                        },
                        "page": {
                          "type": "integer",
                          "minimum": 1,
                          "maximum": 9007199254740991,
                          "description": "1-based page (sheet) number."
                        },
                        "point": {
                          "type": "object",
                          "properties": {
                            "x": { "type": "number" },
                            "y": { "type": "number" }
                          },
                          "required": ["x", "y"],
                          "additionalProperties": false,
                          "description": "The point on the page, in the page's drawing units."
                        },
                        "entityHandle": {
                          "description": "The CAD entity handle the point snapped to.",
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 32
                        },
                        "snapKind": {
                          "description": "How the point snapped; absent for a free point.",
                          "type": "string",
                          "enum": [
                            "endpoint",
                            "intersection",
                            "midpoint",
                            "centre",
                            "quadrant",
                            "perpendicular",
                            "nearest"
                          ]
                        }
                      },
                      "required": [
                        "kind",
                        "documentId",
                        "documentVersionId",
                        "page",
                        "point"
                      ],
                      "additionalProperties": false
                    }
                  ]
                }
              },
              "valueMm": { "type": "number", "minimum": 0 },
              "valueDeg": { "type": "number", "minimum": 0, "maximum": 180 },
              "valueM2": { "type": "number", "minimum": 0 },
              "axisComponentsMm": {
                "type": "object",
                "properties": {
                  "dx": { "type": "number" },
                  "dy": { "type": "number" },
                  "dz": { "type": "number" }
                },
                "required": ["dx", "dy", "dz"],
                "additionalProperties": false
              },
              "vertexIndex": {
                "description": "For a three-point angle: the index of the anchor the angle is measured at (its vertex).",
                "type": "integer",
                "minimum": 0,
                "maximum": 2
              },
              "slopeReference": {
                "description": "For a slope (an angle with one anchor): what its edge or face is measured against.",
                "type": "string",
                "enum": ["horizontal", "vertical"]
              },
              "dimensions": {
                "minItems": 1,
                "maxItems": 3,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": {
                      "type": "string",
                      "enum": ["length", "width", "height", "thickness"]
                    },
                    "valueMm": { "type": "number", "minimum": 0 },
                    "axis": {
                      "type": "object",
                      "properties": {
                        "x": { "type": "number" },
                        "y": { "type": "number" },
                        "z": { "type": "number" }
                      },
                      "required": ["x", "y", "z"],
                      "additionalProperties": false
                    }
                  },
                  "required": ["name", "valueMm", "axis"],
                  "additionalProperties": false
                }
              },
              "tessellated": { "type": "boolean" },
              "inPlane": {
                "description": "For a distance, edge length or angle measured in a view: the view's normal and the value in its plane.",
                "type": "object",
                "properties": {
                  "normal": {
                    "type": "object",
                    "properties": {
                      "x": { "type": "number" },
                      "y": { "type": "number" },
                      "z": { "type": "number" }
                    },
                    "required": ["x", "y", "z"],
                    "additionalProperties": false,
                    "description": "The view's unit normal (towards the viewer) in the version's coordinates."
                  },
                  "valueMm": {
                    "description": "A distance's length in the view plane, millimetres.",
                    "type": "number",
                    "minimum": 0
                  },
                  "valueDeg": {
                    "description": "An angle as the view showed it, degrees.",
                    "type": "number",
                    "minimum": 0,
                    "maximum": 180
                  }
                },
                "required": ["normal"],
                "additionalProperties": false
              },
              "basis": {
                "description": "For a drawing measurement: real (read at the drawing's scale) or paper (millimetres on the sheet, no scale). Absent means real.",
                "type": "string",
                "enum": ["real", "paper"]
              }
            },
            "required": ["kind", "anchors", "tessellated"],
            "additionalProperties": false
          },
          "label": {
            "type": "string",
            "minLength": 1,
            "maxLength": 60,
            "description": "User-given name, 1-60 chars after trimming."
          },
          "needsCheck": {
            "type": "object",
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "geometry_changed",
                  "element_missing",
                  "drawing_changed"
                ]
              },
              "since": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["reason", "since"],
            "additionalProperties": false
          },
          "viewpoint": {
            "type": "object",
            "properties": {
              "camera": {
                "type": "object",
                "properties": {
                  "position": {
                    "type": "object",
                    "properties": {
                      "x": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "y": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "z": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      }
                    },
                    "required": ["x", "y", "z"],
                    "additionalProperties": false
                  },
                  "target": {
                    "type": "object",
                    "properties": {
                      "x": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "y": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "z": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      }
                    },
                    "required": ["x", "y", "z"],
                    "additionalProperties": false
                  },
                  "up": { "type": "string", "const": "z" },
                  "fovDeg": { "type": "number", "minimum": 20, "maximum": 90 },
                  "orthoHeightM": { "type": "number", "exclusiveMinimum": 0 }
                },
                "additionalProperties": false
              },
              "document": {
                "type": "object",
                "properties": {
                  "page": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 9007199254740991
                  },
                  "cad": {
                    "type": "object",
                    "properties": {
                      "center": {
                        "type": "object",
                        "properties": {
                          "x": { "type": "number" },
                          "y": { "type": "number" }
                        },
                        "required": ["x", "y"],
                        "additionalProperties": false
                      },
                      "scale": { "type": "number", "exclusiveMinimum": 0 }
                    },
                    "required": ["center", "scale"],
                    "additionalProperties": false
                  }
                },
                "required": ["page", "cad"],
                "additionalProperties": false
              }
            },
            "additionalProperties": false
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "subtype",
          "visibility",
          "measurement",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "getApiContextInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {},
        "additionalProperties": false
      },
      "getApiContextOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "principal": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": ["user", "apiToken", "oauth", "workstation"],
                "description": "What the credential resolved to: `apiToken` (Bearer fvt_...), `oauth` (a connected app such as claude.ai), `user` (a signed-in person) or `workstation` (a shared device)."
              },
              "id": {
                "type": "string",
                "description": "The principal's own id: the `tok_` token id, the `grt_` grant id, the user's id or the `wks_` workstation id."
              },
              "name": {
                "description": "The credential's own name, when it has one: the API token's name (e.g. \"ERP sync\") or the connected app's client name (e.g. \"claude.ai\").",
                "type": "string"
              }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "organizationId": {
            "description": "The organisation an org-bound credential (API token, OAuth grant, workstation) is bound to. Absent for a signed-in user, who may belong to several.",
            "type": "string"
          },
          "scopes": {
            "type": "array",
            "items": { "type": "string" },
            "description": "The credential's scopes (`fv.read`, `fv.write`, `fv.full`). Empty for a signed-in user or a workstation, whose access is their role alone."
          },
          "mcpUrl": {
            "type": "string",
            "description": "This environment's MCP server URL (Streamable HTTP)."
          },
          "docsUrl": {
            "type": "string",
            "description": "This environment's hosted API reference (`/docs/`): every operation with a try-it panel, the quickstart and the error catalogue. The OpenAPI document is at `/docs/openapi.json`."
          }
        },
        "required": ["principal", "scopes", "mcpUrl", "docsUrl"],
        "additionalProperties": false
      },
      "getApiTokenInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "apiTokenId": {
            "type": "string",
            "pattern": "^tok_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A tok identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "apiTokenId"],
        "additionalProperties": false
      },
      "getApiTokenOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^tok_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A tok identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": { "type": "string", "minLength": 1 },
          "ownerUid": { "type": "string", "minLength": 1 },
          "scopes": {
            "type": "array",
            "items": { "type": "string", "minLength": 1 }
          },
          "status": { "type": "string", "enum": ["active", "revoked"] },
          "tokenPrefix": { "type": "string", "minLength": 1 },
          "previousSecretGraceUntil": {
            "type": "string",
            "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))$"
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "lastUsedAt": {
            "type": "string",
            "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))$"
          },
          "revokedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "name",
          "scopes",
          "status",
          "tokenPrefix",
          "expiresAt",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "getAuditLogExportInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "exportId": {
            "type": "string",
            "pattern": "^alx_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A alx identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "exportId"],
        "additionalProperties": false
      },
      "getAuditLogExportOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^alx_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A alx identifier (TypeID, conventions C5)."
          },
          "status": {
            "type": "string",
            "enum": ["pending", "ready", "failed", "expired"],
            "description": "pending (being built) | ready (downloadable until expiresAt) | failed (request a new one; see error) | expired (past its 24 h window)."
          },
          "requestedAt": {
            "type": "string",
            "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))$"
          },
          "filters": {
            "type": "object",
            "properties": {
              "types": {
                "type": "array",
                "items": { "type": "string", "minLength": 1 }
              },
              "actor": { "type": "string", "minLength": 1 },
              "occurredAfter": {
                "type": "string",
                "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))$"
              },
              "occurredBefore": {
                "type": "string",
                "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))$"
              }
            },
            "additionalProperties": false,
            "description": "The filters the export was requested with."
          },
          "readyAt": {
            "type": "string",
            "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))$"
          },
          "expiresAt": {
            "description": "End of the 24 h download window.",
            "type": "string",
            "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))$"
          },
          "rowCount": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "sizeBytes": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "error": {
            "description": "Only on a failed export. too_many_rows: more than 50,000 events match -- narrow the date range.",
            "type": "string",
            "enum": ["build_failed", "too_many_rows"]
          },
          "download": {
            "description": "Present only while status is ready: a CSV (one row per event, every field except metadata) behind a signed URL valid for 15 minutes (C13). Call getAuditLogExport again for a fresh one until expiresAt.",
            "type": "object",
            "properties": {
              "url": { "type": "string", "format": "uri" },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "contentType": { "type": "string", "minLength": 1 },
              "sizeBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": ["url", "expiresAt", "contentType", "sizeBytes"],
            "additionalProperties": false
          }
        },
        "required": ["id", "status", "requestedAt", "filters"],
        "additionalProperties": false
      },
      "getBillingAccountInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "getBillingAccountOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "status": {
            "type": "string",
            "enum": ["none", "trialing", "active", "past_due", "canceled"]
          },
          "provider": { "type": "string", "enum": ["none", "stripe"] },
          "interval": { "type": "string", "enum": ["month", "year"] },
          "collection": {
            "type": "string",
            "enum": ["charge_automatically", "send_invoice"]
          },
          "cancelAtPeriodEnd": { "type": "boolean" },
          "currentPeriodEnd": {
            "type": "string",
            "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))$"
          },
          "trialEndsAt": {
            "anyOf": [
              {
                "type": "string",
                "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))$"
              },
              { "type": "null" }
            ]
          },
          "trialUsedAt": {
            "type": "string",
            "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))$"
          },
          "trialReason": { "type": "string", "enum": ["standard", "beta"] },
          "firstFailedAt": {
            "type": "string",
            "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))$"
          },
          "graceUntil": {
            "type": "string",
            "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))$"
          },
          "graceExpiredAt": {
            "type": "string",
            "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))$"
          },
          "cancellationEndedAt": {
            "type": "string",
            "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))$"
          },
          "discount": {
            "type": "object",
            "properties": {
              "discountId": { "type": "string" },
              "endsAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["discountId"],
            "additionalProperties": false
          },
          "paymentMethod": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": ["card", "sepa_debit", "bancontact", "ideal", "other"]
              },
              "brand": { "type": "string" },
              "last4": { "type": "string", "pattern": "^\\d{4}$" },
              "expMonth": { "type": "integer", "minimum": 1, "maximum": 12 },
              "expYear": {
                "type": "integer",
                "minimum": -9007199254740991,
                "maximum": 9007199254740991
              }
            },
            "required": ["type"],
            "additionalProperties": false
          },
          "pendingPriceChange": {
            "type": "object",
            "properties": {
              "amountCents": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991,
                "description": "What the organisation pays from effectiveAt, EUR cents excl. VAT, its discount applied."
              },
              "effectiveAt": {
                "type": "string",
                "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))$",
                "description": "The renewal from which the new price applies, RFC 3339 UTC."
              },
              "revision": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991,
                "description": "The plan price document's revision the change came from."
              }
            },
            "required": ["amountCents", "effectiveAt", "revision"],
            "additionalProperties": false
          },
          "duplicateCheckout": {
            "type": "object",
            "properties": {
              "sessionHash": { "type": "string", "pattern": "^[0-9a-f]{16}$" },
              "at": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["sessionHash", "at"],
            "additionalProperties": false
          },
          "vatIdStatus": {
            "type": "string",
            "enum": ["pending", "verified", "unverified", "invalid"]
          },
          "plan": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "enum": [
                  "beta",
                  "free",
                  "team",
                  "enterprise",
                  "internal",
                  "tryout"
                ]
              },
              "name": {
                "description": "The plan's name per language, from the plan catalogue. Absent for the legacy beta plan.",
                "type": "object",
                "properties": {
                  "nl": { "type": "string", "minLength": 1 },
                  "en": { "type": "string", "minLength": 1 },
                  "fr": { "type": "string", "minLength": 1 }
                },
                "required": ["nl", "en", "fr"],
                "additionalProperties": false
              }
            },
            "required": ["id"],
            "additionalProperties": false
          },
          "price": {
            "description": "The Team price for this organisation (its own discount applied), excl. VAT. Absent while no Team price exists.",
            "type": "object",
            "properties": {
              "currency": { "type": "string", "const": "EUR" },
              "list": {
                "type": "object",
                "properties": {
                  "monthlyCents": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "yearlyCents": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["monthlyCents", "yearlyCents"],
                "additionalProperties": false,
                "description": "The list price, excl. VAT."
              },
              "current": {
                "type": "object",
                "properties": {
                  "monthlyCents": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "yearlyCents": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["monthlyCents", "yearlyCents"],
                "additionalProperties": false,
                "description": "What this caller pays now, excl. VAT: the list price, or the list price after its organisation's discount."
              },
              "discount": {
                "description": "The discount behind `current`; never sent to an anonymous caller.",
                "type": "object",
                "properties": {
                  "id": { "type": "string" },
                  "name": { "type": "string" },
                  "endsAt": {
                    "type": "string",
                    "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))$"
                  }
                },
                "required": ["id", "name"],
                "additionalProperties": false
              },
              "revision": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": ["currency", "list", "current", "revision"],
            "additionalProperties": false
          },
          "paymentsAvailable": {
            "type": "boolean",
            "description": "Whether this deployment takes payments for the Team plan: a payment provider is configured and holds the Team price. While false, Checkout, the Customer Portal and cancelling answer an error; the trial works either way."
          }
        },
        "required": ["status", "provider", "plan", "paymentsAvailable"],
        "additionalProperties": false
      },
      "getDocumentVersionArtifactsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dvr identifier (TypeID, conventions C5)."
          },
          "paths": {
            "type": "string",
            "minLength": 1,
            "maxLength": 3072,
            "description": "Comma-separated artefact-set-relative paths to sign, e.g. `manifest.json,pages/1/tiles.json,pages/1/text.json.gz`."
          }
        },
        "required": [
          "organizationId",
          "projectId",
          "documentId",
          "versionId",
          "paths"
        ],
        "additionalProperties": false
      },
      "getDocumentVersionArtifactsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "documentVersionId": {
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dvr identifier (TypeID, conventions C5)."
          },
          "status": {
            "type": "string",
            "enum": [
              "uploading",
              "uploaded",
              "processing",
              "ready",
              "failed",
              "archived",
              "cancelled"
            ]
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "publication": {
            "type": "string",
            "enum": ["draft", "published", "superseded"]
          },
          "releasedAt": {
            "type": "string",
            "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))$"
          },
          "pipelineVersion": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "files": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "path": { "type": "string" },
                "url": { "type": "string" }
              },
              "required": ["path", "url"],
              "additionalProperties": false
            }
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "pages": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "pageNumber": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "sheetNumber": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 100,
                  "description": "Sheet number, e.g. \"W-101\" (BR-11)."
                },
                "title": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 200,
                  "description": "Sheet title, e.g. from the PDF outline (BR-11)."
                },
                "discipline": {
                  "type": "string",
                  "enum": [
                    "architecture",
                    "structure",
                    "mechanical",
                    "electrical",
                    "plumbing",
                    "fire_protection",
                    "civil",
                    "landscape",
                    "general"
                  ]
                },
                "titleBlock": {
                  "type": "object",
                  "propertyNames": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 64
                  },
                  "additionalProperties": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "description": "FV-490 (E13 §4.4): a CAD page's primary title block, attribute tag -> value (<= 32 entries, values <= 200 chars)."
                },
                "scale": {
                  "type": "object",
                  "properties": {
                    "factor": {
                      "type": "number",
                      "exclusiveMinimum": 0,
                      "maximum": 10000,
                      "description": "Real millimetres per paper millimetre (1:50 is 50)."
                    },
                    "source": {
                      "type": "string",
                      "enum": ["calibration", "label"],
                      "description": "calibration: two points and a known length; label: the title-block scale, confirmed."
                    },
                    "basis": {
                      "description": "For a calibration: the two points (fractions of the page) and the real length in mm.",
                      "type": "object",
                      "properties": {
                        "a": {
                          "type": "object",
                          "properties": {
                            "xPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            },
                            "yPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            }
                          },
                          "required": ["xPct", "yPct"],
                          "additionalProperties": false
                        },
                        "b": {
                          "type": "object",
                          "properties": {
                            "xPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            },
                            "yPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            }
                          },
                          "required": ["xPct", "yPct"],
                          "additionalProperties": false
                        },
                        "lengthMm": { "type": "number", "exclusiveMinimum": 0 }
                      },
                      "required": ["a", "b", "lengthMm"],
                      "additionalProperties": false
                    },
                    "setBy": { "type": "string", "minLength": 1 },
                    "setAt": {
                      "type": "string",
                      "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))$"
                    }
                  },
                  "required": ["factor", "source", "setBy", "setAt"],
                  "additionalProperties": false
                }
              },
              "required": ["pageNumber"],
              "additionalProperties": false
            }
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": { "type": "string", "minLength": 1 },
              "messageKey": { "type": "string", "minLength": 1 },
              "retryable": { "type": "boolean" },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "messageKey", "retryable"],
            "additionalProperties": false
          },
          "cad": {
            "type": "object",
            "properties": {
              "unitsOverride": {
                "type": "string",
                "enum": ["mm", "cm", "m", "in", "ft"],
                "description": "The drawing's units, set by a publisher because the file declares none: mm, cm, m, in or ft."
              }
            },
            "required": ["unitsOverride"],
            "additionalProperties": false
          },
          "cadDefaultLayersOff": {
            "maxItems": 256,
            "type": "array",
            "items": { "type": "string", "minLength": 1, "maxLength": 255 },
            "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
          },
          "layerDefaultOff": {
            "maxItems": 256,
            "type": "array",
            "items": { "type": "string", "minLength": 1, "maxLength": 255 },
            "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
          }
        },
        "required": [
          "documentVersionId",
          "status",
          "versionNumber",
          "publication",
          "files"
        ],
        "additionalProperties": false
      },
      "getDocumentVersionInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dvr identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "documentId", "versionId"],
        "additionalProperties": false
      },
      "getDocumentVersionOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dvr identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": [
              "uploading",
              "uploaded",
              "processing",
              "ready",
              "failed",
              "archived",
              "cancelled"
            ]
          },
          "publication": {
            "type": "string",
            "enum": ["draft", "published", "superseded"]
          },
          "fieldVisible": { "type": "boolean" },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "upload" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "fileName", "sizeBytes", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "url" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "url": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 2048,
                    "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "url", "fileName", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "copy" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "sourceVersionId": {
                    "type": "string",
                    "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A dvr identifier (TypeID, conventions C5)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": [
                  "kind",
                  "sourceVersionId",
                  "fileName",
                  "sizeBytes",
                  "contentType"
                ],
                "additionalProperties": false
              }
            ]
          },
          "upload": {
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          },
          "cancelReason": { "type": "string", "enum": ["user"] },
          "pipelineVersion": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": { "type": "string" },
                "blocking": { "type": "boolean" },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": {}
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "progress": {
            "type": "object",
            "properties": {
              "stage": { "type": "string", "minLength": 1 },
              "percent": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["stage", "percent"],
            "additionalProperties": false
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": { "type": "string", "minLength": 1 },
              "retryable": { "type": "boolean" },
              "params": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": {}
              },
              "messageKey": { "type": "string", "minLength": 1 },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "retryable"],
            "additionalProperties": false
          },
          "activeArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "reprocessing": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "reason": {
                "type": "string",
                "enum": ["retry", "pipeline_upgrade"]
              },
              "targetPipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "state": {
                "type": "string",
                "enum": [
                  "requested",
                  "deferred",
                  "awaiting_rollout",
                  "done",
                  "failed"
                ]
              },
              "completedAt": {
                "type": "string",
                "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))$"
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1 },
                  "retryable": { "type": "boolean" },
                  "params": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": {}
                  },
                  "messageKey": { "type": "string", "minLength": 1 },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "retryable"],
                "additionalProperties": false
              }
            },
            "required": ["requestedAt", "requestedBy", "attempt"],
            "additionalProperties": false
          },
          "pageCount": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "pages": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "pageNumber": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "scanned": { "type": "boolean" },
                "sheetNumber": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 100,
                  "description": "Sheet number, e.g. \"W-101\" (BR-11)."
                },
                "title": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 200,
                  "description": "Sheet title, e.g. from the PDF outline (BR-11)."
                },
                "discipline": {
                  "type": "string",
                  "enum": [
                    "architecture",
                    "structure",
                    "mechanical",
                    "electrical",
                    "plumbing",
                    "fire_protection",
                    "civil",
                    "landscape",
                    "general"
                  ]
                },
                "storeyId": { "type": "string", "minLength": 1 },
                "overridden": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "enum": ["sheetNumber", "title", "discipline"]
                  }
                },
                "layout": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "kind": { "type": "string", "enum": ["model", "paper"] }
                  },
                  "required": ["name", "kind"],
                  "additionalProperties": false
                },
                "titleBlock": {
                  "type": "object",
                  "propertyNames": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 64
                  },
                  "additionalProperties": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "description": "FV-490 (E13 §4.4): a CAD page's primary title block, attribute tag -> value (<= 32 entries, values <= 200 chars)."
                },
                "scale": {
                  "type": "object",
                  "properties": {
                    "factor": {
                      "type": "number",
                      "exclusiveMinimum": 0,
                      "maximum": 10000,
                      "description": "Real millimetres per paper millimetre (1:50 is 50)."
                    },
                    "source": {
                      "type": "string",
                      "enum": ["calibration", "label"],
                      "description": "calibration: two points and a known length; label: the title-block scale, confirmed."
                    },
                    "basis": {
                      "description": "For a calibration: the two points (fractions of the page) and the real length in mm.",
                      "type": "object",
                      "properties": {
                        "a": {
                          "type": "object",
                          "properties": {
                            "xPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            },
                            "yPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            }
                          },
                          "required": ["xPct", "yPct"],
                          "additionalProperties": false
                        },
                        "b": {
                          "type": "object",
                          "properties": {
                            "xPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            },
                            "yPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            }
                          },
                          "required": ["xPct", "yPct"],
                          "additionalProperties": false
                        },
                        "lengthMm": { "type": "number", "exclusiveMinimum": 0 }
                      },
                      "required": ["a", "b", "lengthMm"],
                      "additionalProperties": false
                    },
                    "setBy": { "type": "string", "minLength": 1 },
                    "setAt": {
                      "type": "string",
                      "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))$"
                    }
                  },
                  "required": ["factor", "source", "setBy", "setAt"],
                  "additionalProperties": false
                }
              },
              "required": ["pageNumber", "scanned"],
              "additionalProperties": false
            }
          },
          "cad": {
            "type": "object",
            "properties": {
              "insunits": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "unitToMm": {
                "anyOf": [
                  { "type": "number", "exclusiveMinimum": 0 },
                  { "type": "null" }
                ]
              },
              "unitsOverride": {
                "type": "string",
                "enum": ["mm", "cm", "m", "in", "ft"],
                "description": "The drawing's units, set by a publisher because the file declares none: mm, cm, m, in or ft."
              },
              "defaultLayersOff": {
                "maxItems": 256,
                "type": "array",
                "items": { "type": "string", "minLength": 1, "maxLength": 255 },
                "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
              },
              "parser": { "type": "string", "const": "acad-ts" },
              "parserVersion": { "type": "string", "minLength": 1 },
              "version": { "type": "string", "minLength": 1 },
              "layoutCount": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "insunits",
              "unitToMm",
              "parser",
              "parserVersion",
              "version",
              "layoutCount"
            ],
            "additionalProperties": false
          },
          "layerDefault": {
            "type": "object",
            "properties": {
              "off": {
                "maxItems": 256,
                "type": "array",
                "items": { "type": "string", "minLength": 1, "maxLength": 255 },
                "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
              }
            },
            "required": ["off"],
            "additionalProperties": false,
            "description": "The layers off by default for everyone who opens this drawing (CAD layers or PDF optional content groups, by name). A person's own choice on their device still wins."
          },
          "publishOnReady": {
            "description": "Publish this version automatically, in the same write that marks it ready (FV-745).",
            "type": "boolean"
          },
          "releasedAt": {
            "type": "string",
            "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))$"
          },
          "supersededAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "documentId",
          "versionNumber",
          "status",
          "publication",
          "fieldVisible",
          "source",
          "pipelineVersion",
          "warnings",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "getDocumentVersionSourceInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dvr identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "documentId", "versionId"],
        "additionalProperties": false
      },
      "getDocumentVersionSourceOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "url": {
            "type": "string",
            "description": "Signed GET URL; it saves the file under `fileName`."
          },
          "expiresAt": {
            "type": "string",
            "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))$",
            "description": "When `url` stops working (15 minutes after issue, C13)."
          },
          "contentType": { "type": "string", "minLength": 1 },
          "sizeBytes": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "sha256": {
            "description": "SHA-256 of the file, when the upload declared one.",
            "type": "string",
            "pattern": "^[0-9a-f]{64}$"
          },
          "fileName": {
            "type": "string",
            "minLength": 1,
            "description": "The file's original name, as it was uploaded."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "format": {
            "type": "string",
            "enum": ["pdf", "dxf", "dwg"],
            "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
          }
        },
        "required": [
          "url",
          "expiresAt",
          "contentType",
          "sizeBytes",
          "fileName",
          "versionNumber",
          "format"
        ],
        "additionalProperties": false
      },
      "getEntitlementsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "getEntitlementsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "planId": {
            "type": "string",
            "enum": ["beta", "free", "team", "enterprise", "internal", "tryout"]
          },
          "cohort": { "type": "string", "minLength": 1 },
          "orgStatus": { "type": "string", "enum": ["active", "suspended"] },
          "limits": {
            "type": "object",
            "properties": {
              "seats": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "guests": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "workstations": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "projects": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "storageBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "maxModelFileBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 1073741824,
                "description": "Largest single model file, in bytes, for direct upload and URL import. Never above 1 GiB (BR-10)."
              },
              "maxModelsPerProject": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "processingMinutesPerMonth": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "apiTokens": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "maxDocumentFileBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991,
                "description": "Largest single drawing file (PDF, DXF, DWG), in bytes. The format's own ceiling still applies on top."
              },
              "maxDocumentsPerProject": {
                "description": "Most drawings (documents) in one project. Absent: no limit.",
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "seats",
              "guests",
              "workstations",
              "projects",
              "storageBytes",
              "maxModelFileBytes",
              "maxModelsPerProject",
              "processingMinutesPerMonth",
              "apiTokens",
              "maxDocumentFileBytes"
            ],
            "additionalProperties": false
          },
          "features": {
            "type": "object",
            "properties": {
              "autoDimensions": { "type": "boolean" },
              "workstationMode": { "type": "boolean" },
              "auditLogExport": {
                "type": "boolean",
                "description": "Whether the activity log can be exported as CSV (`requestAuditLogExport`)."
              },
              "sso": {
                "type": "boolean",
                "description": "Reserved for single sign-on. Not in use yet."
              }
            },
            "required": [
              "autoDimensions",
              "workstationMode",
              "auditLogExport",
              "sso"
            ],
            "additionalProperties": false
          },
          "overrides": {
            "type": "object",
            "properties": {
              "limits": {
                "type": "object",
                "properties": {
                  "seats": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "guests": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "workstations": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "projects": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "storageBytes": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "maxModelFileBytes": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 1073741824,
                    "description": "Largest single model file, in bytes, for direct upload and URL import. Never above 1 GiB (BR-10)."
                  },
                  "maxModelsPerProject": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "processingMinutesPerMonth": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "apiTokens": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "maxDocumentFileBytes": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991,
                    "description": "Largest single drawing file (PDF, DXF, DWG), in bytes. The format's own ceiling still applies on top."
                  },
                  "maxDocumentsPerProject": {
                    "description": "Most drawings (documents) in one project. Absent: no limit.",
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "additionalProperties": false
              },
              "features": {
                "type": "object",
                "properties": {
                  "autoDimensions": { "type": "boolean" },
                  "workstationMode": { "type": "boolean" },
                  "auditLogExport": {
                    "type": "boolean",
                    "description": "Whether the activity log can be exported as CSV (`requestAuditLogExport`)."
                  },
                  "sso": {
                    "type": "boolean",
                    "description": "Reserved for single sign-on. Not in use yet."
                  }
                },
                "additionalProperties": false
              },
              "reason": { "type": "string", "minLength": 1 },
              "appliedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              },
              "appliedAt": {
                "type": "string",
                "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))$"
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["reason", "appliedBy", "appliedAt"],
            "additionalProperties": false
          },
          "plan": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "enum": [
                  "beta",
                  "free",
                  "team",
                  "enterprise",
                  "internal",
                  "tryout"
                ]
              },
              "name": {
                "description": "The plan's name per language, from the plan catalogue. Absent for the legacy beta plan.",
                "type": "object",
                "properties": {
                  "nl": { "type": "string", "minLength": 1 },
                  "en": { "type": "string", "minLength": 1 },
                  "fr": { "type": "string", "minLength": 1 }
                },
                "required": ["nl", "en", "fr"],
                "additionalProperties": false
              }
            },
            "required": ["id"],
            "additionalProperties": false
          },
          "planSource": {
            "type": "string",
            "enum": ["default", "billing", "platform", "migration"],
            "description": "Who last set the plan: default (the plan a new organisation starts on), billing, platform or migration."
          }
        },
        "required": [
          "planId",
          "orgStatus",
          "limits",
          "features",
          "plan",
          "planSource"
        ],
        "additionalProperties": false
      },
      "getInvitationPreviewInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "token": {
            "type": "string",
            "minLength": 1,
            "description": "The raw accept token from the invitation link. Sent as the `X-Invitation-Token` header."
          }
        },
        "required": ["token"],
        "additionalProperties": false
      },
      "getInvitationPreviewOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "kind": { "type": "string", "enum": ["email", "link"] },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "organizationName": { "type": "string", "minLength": 1 },
          "role": {
            "type": "string",
            "enum": ["admin", "publisher", "member", "guest"]
          },
          "projectIds": {
            "maxItems": 10,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          "inviterDisplayName": { "type": "string", "minLength": 1 }
        },
        "required": [
          "kind",
          "organizationId",
          "organizationName",
          "role",
          "projectIds"
        ],
        "additionalProperties": false
      },
      "getLayerSetInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "layerSetId": {
            "type": "string",
            "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lys identifier (TypeID, conventions C5)."
          },
          "view": {
            "description": "`field` (default): without the entries hidden from the field. `all`: every entry, for curation.",
            "type": "string",
            "enum": ["field", "all"]
          }
        },
        "required": ["organizationId", "projectId", "layerSetId"],
        "additionalProperties": false
      },
      "getLayerSetOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lys identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "status": {
            "type": "string",
            "enum": ["ready", "materializing", "failed"]
          },
          "materializingSince": {
            "type": "string",
            "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))$"
          },
          "materializeAttempts": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "enum": ["layer_rule_materialization_failed"]
              },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "supportRef"],
            "additionalProperties": false
          },
          "derivationSource": {
            "type": "string",
            "enum": [
              "assignment",
              "type",
              "classification",
              "name-role",
              "material",
              "object-type"
            ]
          },
          "grouping": {
            "minItems": 1,
            "maxItems": 2,
            "type": "array",
            "items": {
              "type": "string",
              "enum": ["classification", "name-role", "material", "object-type"]
            }
          },
          "sourceCoveragePct": {
            "type": "number",
            "minimum": 0,
            "maximum": 100
          },
          "sources": {
            "maxItems": 100,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "modelId": {
                  "type": "string",
                  "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A mdl identifier (TypeID, conventions C5)."
                },
                "versionId": {
                  "type": "string",
                  "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A ver identifier (TypeID, conventions C5)."
                }
              },
              "required": ["modelId", "versionId"],
              "additionalProperties": false
            }
          },
          "generatedFromVersionId": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          },
          "derivedAtPublishSeq": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "generatedAt": {
            "type": "string",
            "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))$"
          },
          "warnings": {
            "maxItems": 100,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": {
                  "type": "string",
                  "enum": [
                    "layers_index_failed",
                    "layer_source_unavailable",
                    "layer_source_invalid",
                    "layer_assignment_skipped",
                    "layer_entries_truncated",
                    "layer_rule_truncated",
                    "layer_template_truncated"
                  ]
                },
                "modelId": {
                  "type": "string",
                  "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A mdl identifier (TypeID, conventions C5)."
                },
                "versionId": {
                  "type": "string",
                  "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A ver identifier (TypeID, conventions C5)."
                },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": { "type": ["string", "number"] }
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "entries": {
            "maxItems": 100,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^[a-z0-9][a-z0-9-]{0,63}$"
                },
                "kind": {
                  "type": "string",
                  "enum": ["assignment", "type", "manual", "rule", "attribute"]
                },
                "derivationKeys": {
                  "maxItems": 100,
                  "type": "array",
                  "items": { "type": "string", "minLength": 1 }
                },
                "manualGlobalIds": {
                  "maxItems": 500,
                  "type": "array",
                  "items": { "type": "string", "minLength": 1 }
                },
                "rule": {
                  "type": "object",
                  "properties": {
                    "source": {
                      "type": "string",
                      "enum": [
                        "property",
                        "name",
                        "material",
                        "ifcClass",
                        "panel"
                      ]
                    },
                    "psetName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255
                    },
                    "propName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255
                    },
                    "op": {
                      "type": "string",
                      "enum": ["eq", "neq", "contains"]
                    },
                    "value": { "type": "string", "maxLength": 1000 }
                  },
                  "required": ["op", "value"],
                  "additionalProperties": false
                },
                "materializedGlobalIds": {
                  "maxItems": 20000,
                  "type": "array",
                  "items": { "type": "string", "minLength": 1 }
                },
                "elementCount": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "displayName": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 60
                },
                "colorHex": { "type": "string", "pattern": "^#[0-9a-f]{6}$" },
                "order": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "defaultOn": { "type": "boolean" },
                "hiddenFromField": { "type": "boolean" },
                "origin": { "type": "string", "enum": ["template", "project"] },
                "templateKey": {
                  "type": "string",
                  "pattern": "^template:ltp_[0-9a-z]{26}:[a-z0-9][a-z0-9-]{0,39}$"
                },
                "locked": { "type": "boolean" },
                "curated": { "type": "boolean" }
              },
              "required": [
                "id",
                "kind",
                "derivationKeys",
                "elementCount",
                "displayName",
                "order",
                "defaultOn",
                "hiddenFromField"
              ],
              "additionalProperties": false
            }
          },
          "template": {
            "type": "object",
            "properties": {
              "templateId": {
                "type": "string",
                "pattern": "^ltp_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A ltp identifier (TypeID, conventions C5)."
              },
              "revision": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": ["templateId", "revision"],
            "additionalProperties": false
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "status",
          "derivationSource",
          "sourceCoveragePct",
          "sources",
          "derivedAtPublishSeq",
          "generatedAt",
          "warnings",
          "entries",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "getLayerTemplateInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "templateId": {
            "type": "string",
            "pattern": "^ltp_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ltp identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "templateId"],
        "additionalProperties": false
      },
      "getLayerTemplateOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ltp_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ltp identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": { "type": "string", "minLength": 1, "maxLength": 60 },
          "layers": {
            "maxItems": 50,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^[a-z0-9][a-z0-9-]{0,39}$"
                },
                "displayName": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 60
                },
                "colorHex": { "type": "string", "pattern": "^#[0-9a-f]{6}$" },
                "rule": {
                  "type": "object",
                  "properties": {
                    "source": {
                      "type": "string",
                      "enum": [
                        "property",
                        "name",
                        "material",
                        "ifcClass",
                        "panel"
                      ]
                    },
                    "psetName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255
                    },
                    "propName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255
                    },
                    "op": {
                      "type": "string",
                      "enum": ["eq", "neq", "contains"]
                    },
                    "value": { "type": "string", "maxLength": 1000 }
                  },
                  "required": ["op", "value"],
                  "additionalProperties": false
                },
                "defaultOn": { "type": "boolean" },
                "hiddenFromField": { "type": "boolean" },
                "locked": { "type": "boolean" }
              },
              "required": [
                "id",
                "displayName",
                "rule",
                "defaultOn",
                "hiddenFromField",
                "locked"
              ],
              "additionalProperties": false
            }
          },
          "applyTo": { "type": "string", "enum": ["all", "chosen"] },
          "projectIds": {
            "minItems": 1,
            "maxItems": 400,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          "appliedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "name",
          "layers",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "getLegalDocumentVersionsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {},
        "additionalProperties": false
      },
      "getLegalDocumentVersionsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "documents": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "enum": [
                    "terms",
                    "privacy",
                    "dpa",
                    "subprocessors",
                    "cookies",
                    "security"
                  ],
                  "description": "terms, privacy, dpa, subprocessors, cookies or security."
                },
                "version": {
                  "type": "string",
                  "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                  "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
                },
                "publishedAt": {
                  "type": "string",
                  "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))$"
                },
                "material": {
                  "type": "boolean",
                  "description": "Whether the current version asks for a new acceptance."
                },
                "latestMaterialVersion": {
                  "type": "string",
                  "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                  "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
                },
                "path": {
                  "type": "string",
                  "description": "Where the web app shows the document, e.g. /legal/dpa."
                },
                "languages": {
                  "type": "array",
                  "items": { "type": "string", "enum": ["nl", "en"] },
                  "description": "The languages the text exists in; nl is the master text."
                },
                "changelog": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "version": {
                        "type": "string",
                        "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                        "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
                      },
                      "publishedAt": {
                        "type": "string",
                        "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))$"
                      },
                      "material": { "type": "boolean" },
                      "summary": {
                        "type": "object",
                        "properties": {
                          "nl": { "type": "string" },
                          "en": { "type": "string" }
                        },
                        "required": ["nl", "en"],
                        "additionalProperties": false
                      }
                    },
                    "required": [
                      "version",
                      "publishedAt",
                      "material",
                      "summary"
                    ],
                    "additionalProperties": false
                  },
                  "description": "Every published version, oldest first."
                }
              },
              "required": [
                "id",
                "version",
                "publishedAt",
                "material",
                "latestMaterialVersion",
                "path",
                "languages",
                "changelog"
              ],
              "additionalProperties": false
            },
            "description": "The terms of use, privacy notice, DPA, sub-processor list and cookie notice, each with its current version and changelog."
          }
        },
        "required": ["documents"],
        "additionalProperties": false
      },
      "getLinkCoverageInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId"],
        "additionalProperties": false
      },
      "getLinkCoverageOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "panels": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "linked": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "unlinked": {
            "maxItems": 200,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "modelId": {
                  "type": "string",
                  "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A mdl identifier (TypeID, conventions C5)."
                },
                "assemblyMark": { "type": "string", "minLength": 1 }
              },
              "required": ["modelId", "assemblyMark"],
              "additionalProperties": false
            }
          },
          "truncated": { "type": "boolean" }
        },
        "required": ["panels", "linked", "unlinked"],
        "additionalProperties": false
      },
      "getLinkDiscoveryRunInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "runId": {
            "type": "string",
            "pattern": "^ldr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ldr identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "runId"],
        "additionalProperties": false
      },
      "getLinkDiscoveryRunOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "schemaVersion": { "type": "number", "const": 1 },
          "id": {
            "type": "string",
            "pattern": "^ldr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ldr identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "status": { "type": "string", "enum": ["running", "done", "failed"] },
          "trigger": { "type": "string", "enum": ["manual", "upload_batch"] },
          "scope": {
            "type": "object",
            "properties": {
              "documentIds": {
                "minItems": 1,
                "maxItems": 500,
                "type": "array",
                "items": {
                  "type": "string",
                  "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A doc identifier (TypeID, conventions C5)."
                }
              },
              "modelIds": {
                "minItems": 1,
                "maxItems": 4,
                "type": "array",
                "items": {
                  "type": "string",
                  "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A mdl identifier (TypeID, conventions C5)."
                }
              }
            },
            "additionalProperties": false
          },
          "result": {
            "type": "object",
            "properties": {
              "evaluatedDocuments": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "evaluatedElements": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "truncated": { "type": "boolean" },
              "strategies": {
                "maxItems": 20,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "strategy": {
                      "type": "string",
                      "enum": [
                        "file_name",
                        "layout_name",
                        "title_block_attribute",
                        "sheet_text",
                        "model_property",
                        "sheet_number"
                      ]
                    },
                    "ruleDraft": {
                      "type": "object",
                      "properties": {
                        "matchModel": {
                          "type": "object",
                          "properties": {
                            "field": {
                              "type": "string",
                              "enum": [
                                "tag",
                                "assemblyMark",
                                "storeyName",
                                "name",
                                "property"
                              ]
                            },
                            "property": {
                              "type": "object",
                              "properties": {
                                "set": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 128,
                                  "description": "Property set, e.g. Pset_Panel."
                                },
                                "name": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 128,
                                  "description": "Property name, e.g. Drawing."
                                }
                              },
                              "required": ["set", "name"],
                              "additionalProperties": false
                            }
                          },
                          "required": ["field"],
                          "additionalProperties": false
                        },
                        "matchDocument": {
                          "type": "object",
                          "properties": {
                            "field": {
                              "type": "string",
                              "enum": [
                                "fileName",
                                "sheetNumber",
                                "outlineTitle",
                                "titleBlock",
                                "layoutName",
                                "blockAttribute",
                                "sheetText"
                              ]
                            },
                            "attributeTag": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 128
                            }
                          },
                          "required": ["field"],
                          "additionalProperties": false
                        },
                        "normalization": {
                          "type": "object",
                          "properties": {
                            "caseInsensitive": { "type": "boolean" },
                            "stripWhitespace": { "type": "boolean" },
                            "stripLeadingZeros": { "type": "boolean" },
                            "regex": {
                              "type": "string",
                              "description": "Regular expression applied to both sides after the other normalisation steps: a value that does not match is ignored, otherwise the match (or its named group `key`) is the value compared, e.g. W-\\d{3} (max 200 chars; no backreferences or nested repeats)."
                            }
                          },
                          "required": [
                            "caseInsensitive",
                            "stripWhitespace",
                            "stripLeadingZeros"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "required": [
                        "matchModel",
                        "matchDocument",
                        "normalization"
                      ],
                      "additionalProperties": false
                    },
                    "score": { "type": "number", "minimum": 0, "maximum": 1 },
                    "coverage": {
                      "type": "number",
                      "minimum": 0,
                      "maximum": 1
                    },
                    "matched": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "ambiguous": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "unmatchedDocuments": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "unmatchedElements": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "sampleMatches": {
                      "maxItems": 10,
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "documentId": {
                            "type": "string",
                            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                            "description": "A doc identifier (TypeID, conventions C5)."
                          },
                          "page": {
                            "type": "integer",
                            "exclusiveMinimum": 0,
                            "maximum": 9007199254740991
                          },
                          "key": { "type": "string" },
                          "source": {
                            "oneOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "kind": {
                                    "type": "string",
                                    "const": "element"
                                  },
                                  "modelId": {
                                    "type": "string",
                                    "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                    "description": "A mdl identifier (TypeID, conventions C5)."
                                  },
                                  "globalId": {
                                    "type": "string",
                                    "minLength": 1
                                  }
                                },
                                "required": ["kind", "modelId", "globalId"],
                                "additionalProperties": false
                              },
                              {
                                "type": "object",
                                "properties": {
                                  "kind": {
                                    "type": "string",
                                    "const": "assembly"
                                  },
                                  "modelId": {
                                    "type": "string",
                                    "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                    "description": "A mdl identifier (TypeID, conventions C5)."
                                  },
                                  "assemblyMark": {
                                    "type": "string",
                                    "minLength": 1
                                  }
                                },
                                "required": ["kind", "modelId", "assemblyMark"],
                                "additionalProperties": false
                              },
                              {
                                "type": "object",
                                "properties": {
                                  "kind": {
                                    "type": "string",
                                    "const": "storey"
                                  },
                                  "modelId": {
                                    "type": "string",
                                    "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                    "description": "A mdl identifier (TypeID, conventions C5)."
                                  },
                                  "storeyId": {
                                    "type": "string",
                                    "minLength": 1
                                  }
                                },
                                "required": ["kind", "modelId", "storeyId"],
                                "additionalProperties": false
                              }
                            ]
                          }
                        },
                        "required": ["documentId", "page", "key", "source"],
                        "additionalProperties": false
                      }
                    },
                    "ambiguousSamples": {
                      "maxItems": 10,
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "key": { "type": "string" },
                          "documentIds": {
                            "minItems": 2,
                            "type": "array",
                            "items": {
                              "type": "string",
                              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                              "description": "A doc identifier (TypeID, conventions C5)."
                            }
                          }
                        },
                        "required": ["key", "documentIds"],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "strategy",
                    "ruleDraft",
                    "score",
                    "coverage",
                    "matched",
                    "ambiguous",
                    "unmatchedDocuments",
                    "unmatchedElements",
                    "sampleMatches",
                    "ambiguousSamples"
                  ],
                  "additionalProperties": false
                }
              },
              "recommended": {
                "type": "array",
                "items": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                }
              },
              "panels": {
                "type": "object",
                "properties": {
                  "total": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "linkable": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["total", "linkable"],
                "additionalProperties": false
              },
              "skipped": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "strategy": {
                      "type": "string",
                      "enum": [
                        "file_name",
                        "layout_name",
                        "title_block_attribute",
                        "sheet_text",
                        "model_property",
                        "sheet_number"
                      ]
                    },
                    "reason": {
                      "type": "string",
                      "enum": ["model_index_missing", "no_keys"]
                    }
                  },
                  "required": ["strategy", "reason"],
                  "additionalProperties": false
                }
              }
            },
            "required": [
              "evaluatedDocuments",
              "evaluatedElements",
              "strategies",
              "recommended"
            ],
            "additionalProperties": false
          },
          "acceptedAt": {
            "type": "string",
            "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))$"
          },
          "acceptedBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "acceptedRuleIds": {
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A lkr identifier (TypeID, conventions C5)."
            }
          },
          "acceptRunIds": {
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^lrr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A lrr identifier (TypeID, conventions C5)."
            }
          },
          "error": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "enum": ["discovery_timeout", "discovery_failed"]
              },
              "message": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "message"],
            "additionalProperties": false
          },
          "requestedAt": {
            "type": "string",
            "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))$"
          },
          "requestedBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "completedAt": {
            "type": "string",
            "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))$"
          }
        },
        "required": [
          "schemaVersion",
          "id",
          "organizationId",
          "projectId",
          "status",
          "trigger",
          "scope",
          "requestedAt",
          "requestedBy"
        ],
        "additionalProperties": false
      },
      "getLinkImportInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "importId": {
            "type": "string",
            "pattern": "^lim_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lim identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "importId"],
        "additionalProperties": false
      },
      "getLinkImportOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^lim_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lim identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "fileName": {
            "type": "string",
            "minLength": 5,
            "maxLength": 255,
            "description": "The CSV's file name, ending .csv (max 255 chars)."
          },
          "sizeBytes": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 2097152
          },
          "status": {
            "type": "string",
            "enum": ["uploading", "processing", "done", "failed"]
          },
          "progress": {
            "type": "object",
            "properties": {
              "rowsProcessed": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "rowsTotal": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": ["rowsProcessed", "rowsTotal"],
            "additionalProperties": false
          },
          "result": {
            "type": "object",
            "properties": {
              "rows": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "created": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "skipped": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "errors": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "row": {
                      "type": "integer",
                      "minimum": 2,
                      "maximum": 9007199254740991
                    },
                    "code": {
                      "type": "string",
                      "enum": [
                        "element_not_found",
                        "ambiguous_element",
                        "sheet_not_found",
                        "sheet_not_ready",
                        "ambiguous_sheet",
                        "page_out_of_range",
                        "invalid_page",
                        "invalid_region",
                        "missing_value"
                      ]
                    }
                  },
                  "required": ["row", "code"],
                  "additionalProperties": false
                }
              }
            },
            "required": ["rows", "created", "skipped", "errors"],
            "additionalProperties": false
          },
          "error": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "enum": [
                  "csv_too_large",
                  "csv_empty",
                  "csv_encoding",
                  "csv_malformed",
                  "csv_missing_column",
                  "csv_unknown_column",
                  "upload_missing",
                  "project_not_active"
                ]
              },
              "detail": { "type": "string", "maxLength": 500 }
            },
            "required": ["code", "detail"],
            "additionalProperties": false
          },
          "completedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "fileName",
          "sizeBytes",
          "status",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "getLinkInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "linkId": {
            "type": "string",
            "pattern": "^lnk_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lnk identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "linkId"],
        "additionalProperties": false
      },
      "getLinkOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^lnk_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lnk identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "element" },
                  "modelId": {
                    "type": "string",
                    "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A mdl identifier (TypeID, conventions C5)."
                  },
                  "globalId": { "type": "string", "minLength": 1 }
                },
                "required": ["kind", "modelId", "globalId"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "assembly" },
                  "modelId": {
                    "type": "string",
                    "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A mdl identifier (TypeID, conventions C5)."
                  },
                  "assemblyMark": { "type": "string", "minLength": 1 }
                },
                "required": ["kind", "modelId", "assemblyMark"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "storey" },
                  "modelId": {
                    "type": "string",
                    "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A mdl identifier (TypeID, conventions C5)."
                  },
                  "storeyId": { "type": "string", "minLength": 1 }
                },
                "required": ["kind", "modelId", "storeyId"],
                "additionalProperties": false
              }
            ]
          },
          "target": {
            "type": "object",
            "properties": {
              "documentId": {
                "type": "string",
                "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A doc identifier (TypeID, conventions C5)."
              },
              "page": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "layoutName": {
                "type": "string",
                "minLength": 1,
                "maxLength": 255
              },
              "region": {
                "type": "object",
                "properties": {
                  "xPct": { "type": "number", "minimum": 0, "maximum": 1 },
                  "yPct": { "type": "number", "minimum": 0, "maximum": 1 },
                  "wPct": { "type": "number", "minimum": 0, "maximum": 1 },
                  "hPct": { "type": "number", "minimum": 0, "maximum": 1 }
                },
                "required": ["xPct", "yPct", "wPct", "hPct"],
                "additionalProperties": false
              },
              "cadRegion": {
                "type": "object",
                "properties": {
                  "x": { "type": "number" },
                  "y": { "type": "number" },
                  "w": { "type": "number", "exclusiveMinimum": 0 },
                  "h": { "type": "number", "exclusiveMinimum": 0 },
                  "space": { "type": "string", "enum": ["model", "paper"] }
                },
                "required": ["x", "y", "w", "h", "space"],
                "additionalProperties": false
              },
              "textRef": {
                "type": "object",
                "properties": {
                  "textIndex": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "text": { "type": "string", "minLength": 1, "maxLength": 200 }
                },
                "required": ["textIndex", "text"],
                "additionalProperties": false
              }
            },
            "required": ["documentId", "page"],
            "additionalProperties": false
          },
          "origin": {
            "type": "string",
            "enum": ["rule", "manual", "connector"]
          },
          "ruleId": {
            "type": "string",
            "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lkr identifier (TypeID, conventions C5)."
          },
          "confidence": { "type": "number", "minimum": 0, "maximum": 1 },
          "key": { "type": "string", "minLength": 1 },
          "status": { "type": "string", "enum": ["active", "stale"] },
          "staleSince": {
            "type": "string",
            "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))$"
          },
          "staleReason": { "type": "string", "enum": ["page_removed"] },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "source",
          "target",
          "origin",
          "status",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "getLinkRuleInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "ruleId": {
            "type": "string",
            "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lkr identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "ruleId"],
        "additionalProperties": false
      },
      "getLinkRuleOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lkr identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "description": "Rule name, 1-100 chars after trimming."
          },
          "enabled": { "type": "boolean" },
          "priority": { "type": "integer", "minimum": 0, "maximum": 1000 },
          "matchModel": {
            "type": "object",
            "properties": {
              "field": {
                "type": "string",
                "enum": [
                  "tag",
                  "assemblyMark",
                  "storeyName",
                  "name",
                  "property"
                ]
              },
              "property": {
                "type": "object",
                "properties": {
                  "set": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 128,
                    "description": "Property set, e.g. Pset_Panel."
                  },
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 128,
                    "description": "Property name, e.g. Drawing."
                  }
                },
                "required": ["set", "name"],
                "additionalProperties": false
              }
            },
            "required": ["field"],
            "additionalProperties": false
          },
          "matchDocument": {
            "type": "object",
            "properties": {
              "field": {
                "type": "string",
                "enum": [
                  "fileName",
                  "sheetNumber",
                  "outlineTitle",
                  "titleBlock",
                  "layoutName",
                  "blockAttribute",
                  "sheetText"
                ]
              },
              "attributeTag": {
                "type": "string",
                "minLength": 1,
                "maxLength": 128
              }
            },
            "required": ["field"],
            "additionalProperties": false
          },
          "normalization": {
            "type": "object",
            "properties": {
              "caseInsensitive": { "type": "boolean" },
              "stripWhitespace": { "type": "boolean" },
              "stripLeadingZeros": { "type": "boolean" },
              "regex": {
                "type": "string",
                "description": "Regular expression applied to both sides after the other normalisation steps: a value that does not match is ignored, otherwise the match (or its named group `key`) is the value compared, e.g. W-\\d{3} (max 200 chars; no backreferences or nested repeats)."
              }
            },
            "required": [
              "caseInsensitive",
              "stripWhitespace",
              "stripLeadingZeros"
            ],
            "additionalProperties": false
          },
          "autoApply": { "type": "boolean" },
          "discoveryRunId": {
            "type": "string",
            "pattern": "^ldr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ldr identifier (TypeID, conventions C5)."
          },
          "ambiguousDocumentIds": {
            "maxItems": 500,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "name",
          "enabled",
          "priority",
          "matchModel",
          "matchDocument",
          "normalization",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "getLinkRuleRunInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "runId": {
            "type": "string",
            "pattern": "^lrr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lrr identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "runId"],
        "additionalProperties": false
      },
      "getLinkRuleRunOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "schemaVersion": { "type": "number", "const": 1 },
          "id": {
            "type": "string",
            "pattern": "^lrr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lrr identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "ruleId": {
            "type": "string",
            "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lkr identifier (TypeID, conventions C5)."
          },
          "dryRun": { "type": "boolean" },
          "status": { "type": "string", "enum": ["running", "done", "failed"] },
          "result": {
            "type": "object",
            "properties": {
              "candidates": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "source": {
                      "oneOf": [
                        {
                          "type": "object",
                          "properties": {
                            "kind": { "type": "string", "const": "element" },
                            "modelId": {
                              "type": "string",
                              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                              "description": "A mdl identifier (TypeID, conventions C5)."
                            },
                            "globalId": { "type": "string", "minLength": 1 }
                          },
                          "required": ["kind", "modelId", "globalId"],
                          "additionalProperties": false
                        },
                        {
                          "type": "object",
                          "properties": {
                            "kind": { "type": "string", "const": "assembly" },
                            "modelId": {
                              "type": "string",
                              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                              "description": "A mdl identifier (TypeID, conventions C5)."
                            },
                            "assemblyMark": { "type": "string", "minLength": 1 }
                          },
                          "required": ["kind", "modelId", "assemblyMark"],
                          "additionalProperties": false
                        },
                        {
                          "type": "object",
                          "properties": {
                            "kind": { "type": "string", "const": "storey" },
                            "modelId": {
                              "type": "string",
                              "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                              "description": "A mdl identifier (TypeID, conventions C5)."
                            },
                            "storeyId": { "type": "string", "minLength": 1 }
                          },
                          "required": ["kind", "modelId", "storeyId"],
                          "additionalProperties": false
                        }
                      ]
                    },
                    "target": {
                      "type": "object",
                      "properties": {
                        "documentId": {
                          "type": "string",
                          "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A doc identifier (TypeID, conventions C5)."
                        },
                        "page": {
                          "type": "integer",
                          "exclusiveMinimum": 0,
                          "maximum": 9007199254740991
                        },
                        "layoutName": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 255
                        }
                      },
                      "required": ["documentId", "page"],
                      "additionalProperties": false
                    },
                    "key": { "type": "string" },
                    "confidence": {
                      "type": "number",
                      "minimum": 0,
                      "maximum": 1
                    },
                    "ruleId": {
                      "type": "string",
                      "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A lkr identifier (TypeID, conventions C5)."
                    },
                    "ambiguous": { "type": "boolean" }
                  },
                  "required": [
                    "source",
                    "target",
                    "key",
                    "confidence",
                    "ruleId",
                    "ambiguous"
                  ],
                  "additionalProperties": false
                }
              },
              "wouldCreate": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "ambiguous": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "unmatched": {
                "type": "object",
                "properties": {
                  "model": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "document": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["model", "document"],
                "additionalProperties": false
              },
              "truncated": { "type": "boolean" },
              "warnings": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "code": {
                      "type": "string",
                      "enum": [
                        "links_index_unavailable",
                        "spatial_tree_unavailable",
                        "text_layer_unavailable",
                        "link_keys_unavailable"
                      ]
                    },
                    "modelId": {
                      "type": "string",
                      "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A mdl identifier (TypeID, conventions C5)."
                    },
                    "documentId": {
                      "type": "string",
                      "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A doc identifier (TypeID, conventions C5)."
                    },
                    "page": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["code"],
                  "additionalProperties": false
                }
              },
              "skipped": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "reason": {
                      "type": "string",
                      "enum": ["model_index_missing"]
                    },
                    "modelId": {
                      "type": "string",
                      "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A mdl identifier (TypeID, conventions C5)."
                    }
                  },
                  "required": ["reason", "modelId"],
                  "additionalProperties": false
                }
              },
              "applied": {
                "type": "object",
                "properties": {
                  "created": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "updated": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "unchanged": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "manual": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "remaining": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": [
                  "created",
                  "updated",
                  "unchanged",
                  "manual",
                  "remaining"
                ],
                "additionalProperties": false
              }
            },
            "required": [
              "candidates",
              "wouldCreate",
              "ambiguous",
              "unmatched",
              "truncated",
              "warnings"
            ],
            "additionalProperties": false
          },
          "requestedAt": {
            "type": "string",
            "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))$"
          },
          "requestedBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "completedAt": {
            "type": "string",
            "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))$"
          }
        },
        "required": [
          "schemaVersion",
          "id",
          "organizationId",
          "projectId",
          "ruleId",
          "dryRun",
          "status",
          "requestedAt",
          "requestedBy"
        ],
        "additionalProperties": false
      },
      "getMeInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {},
        "additionalProperties": false
      },
      "getMeOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^usr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A usr identifier (TypeID, conventions C5)."
          },
          "displayName": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "Display name shown in the UI (1-80 chars, §5.4)."
          },
          "locale": {
            "type": "string",
            "enum": ["nl", "en", "fr"],
            "description": "BCP 47 UI locale, one of nl | en | fr."
          },
          "localeChosen": {
            "description": "Whether the user explicitly chose `locale` (profile screen); then every device follows it. Absent: false.",
            "type": "boolean"
          },
          "email": {
            "description": "The account's sign-in e-mail address, as last synced from the identity provider.",
            "type": "string",
            "maxLength": 254,
            "format": "email",
            "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
          },
          "security": {
            "type": "object",
            "properties": {
              "providers": {
                "type": "array",
                "items": { "type": "string" },
                "description": "Sign-in provider ids this user has used (e.g. password, google.com)."
              },
              "passwordSet": {
                "description": "Whether the account can sign in with a password (set by refreshMySecurityState).",
                "type": "boolean"
              },
              "mfaEnrolled": {
                "description": "Whether two-step verification is enrolled (set by refreshMySecurityState).",
                "type": "boolean"
              }
            },
            "required": ["providers"],
            "additionalProperties": false
          },
          "preferences": {
            "type": "object",
            "properties": {
              "lastOrgId": {
                "description": "The last organisation this user was active in, if any.",
                "type": "string",
                "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
              },
              "onboardingChecklistDismissed": {
                "description": "Whether the caller dismissed the get-started checklist panel (FV-208, per user).",
                "type": "boolean"
              },
              "gesturesCoached": {
                "description": "The viewer gesture coach-marks this account has been shown (orbit, zoom, select; FV-219).",
                "type": "array",
                "items": {
                  "type": "string",
                  "enum": ["orbit", "zoom", "select"]
                }
              },
              "lengthUnit": {
                "description": "Display unit for measured lengths: mm (default when absent), cm or m (FV-238). Display only; stored values stay mm.",
                "type": "string",
                "enum": ["mm", "cm", "m"]
              },
              "measureSnap": {
                "description": "Measure snap settings: the targets switched off and the snap radius (FV-433). Absent: all on, medium.",
                "type": "object",
                "properties": {
                  "off": {
                    "maxItems": 7,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "enum": [
                        "vertex",
                        "edgeIntersection",
                        "edgeMidpoint",
                        "circleCentre",
                        "perpendicular",
                        "edgePoint",
                        "facePoint"
                      ]
                    },
                    "description": "Snap targets switched off: vertex, edgeIntersection, edgeMidpoint, circleCentre, perpendicular, edgePoint, facePoint."
                  },
                  "radius": {
                    "type": "string",
                    "enum": ["small", "medium", "large"],
                    "description": "Snap radius: small, medium (default) or large."
                  }
                },
                "required": ["off", "radius"],
                "additionalProperties": false
              },
              "trackpadScroll": {
                "description": "What a two-finger trackpad scroll does in the 3D viewer: pan (default when absent) or zoom (FV-472). A pinch always zooms.",
                "type": "string",
                "enum": ["pan", "zoom"]
              },
              "modelColours": {
                "description": "How the 3D viewer colours a model: file (default when absent: the file's own colours, the Field-Viewer palette where it has none) or palette (always the Field-Viewer palette) (FV-515).",
                "type": "string",
                "enum": ["file", "palette"]
              },
              "layers": {
                "description": "Personal layer defaults (FV-513): byProject (a project's own on/off overrides, the 30 most recently saved) and mine (on/off by template layer or derivation key, across projects). Absent: none.",
                "type": "object",
                "properties": {
                  "byProject": {
                    "maxItems": 30,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "projectId": {
                          "type": "string",
                          "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A prj identifier (TypeID, conventions C5)."
                        },
                        "layerSetId": {
                          "type": "string",
                          "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A lys identifier (TypeID, conventions C5)."
                        },
                        "off": {
                          "maxItems": 100,
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "^[a-z0-9][a-z0-9-]{0,63}$"
                          },
                          "description": "Field layers switched off against the project's default."
                        },
                        "on": {
                          "maxItems": 100,
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "^[a-z0-9][a-z0-9-]{0,63}$"
                          },
                          "description": "Field layers switched on against the project's default."
                        },
                        "mode": {
                          "description": "project-default: this project opens on its own defaults, never on my default.",
                          "type": "string",
                          "enum": ["project-default"]
                        },
                        "updatedAt": {
                          "type": "string",
                          "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))$"
                        }
                      },
                      "required": [
                        "projectId",
                        "layerSetId",
                        "off",
                        "on",
                        "updatedAt"
                      ],
                      "additionalProperties": false
                    },
                    "description": "This person's own layer state per project, most recently saved first (at most 30)."
                  },
                  "mineOff": {
                    "maxItems": 200,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "maxLength": 120,
                      "pattern": "^(?:template:ltp_[0-9a-z]{26}:[a-z0-9][a-z0-9-]{0,39}|(?:assignment|type|attribute):\\S.*)$"
                    },
                    "description": "My default, off across projects: template:<template>:<layer> or <kind>:<derivation key>."
                  },
                  "mineOn": {
                    "maxItems": 200,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "maxLength": 120,
                      "pattern": "^(?:template:ltp_[0-9a-z]{26}:[a-z0-9][a-z0-9-]{0,39}|(?:assignment|type|attribute):\\S.*)$"
                    },
                    "description": "My default, on across projects (same keys)."
                  }
                },
                "required": ["byProject", "mineOff", "mineOn"],
                "additionalProperties": false
              },
              "analyticsOptOut": {
                "description": "Whether the caller switched off technical measurements (web vitals, client logs; FV-464). Absent: allowed.",
                "type": "boolean"
              }
            },
            "additionalProperties": false
          },
          "betaAccess": {
            "type": "object",
            "properties": {
              "codeId": {
                "type": "string",
                "pattern": "^bac_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A bac identifier (TypeID, conventions C5)."
              },
              "grantedAt": {
                "type": "string",
                "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))$"
              },
              "consumedAt": {
                "type": "string",
                "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))$"
              },
              "consumedOrgId": {
                "type": "string",
                "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A org identifier (TypeID, conventions C5)."
              }
            },
            "required": ["codeId", "grantedAt"],
            "additionalProperties": false
          },
          "legal": {
            "type": "object",
            "properties": {
              "privacyAcknowledgedVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "privacyAcknowledgedAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["privacyAcknowledgedVersion", "privacyAcknowledgedAt"],
            "additionalProperties": false,
            "description": "The privacy notice version the user acknowledged, and when."
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "displayName",
          "locale",
          "security",
          "preferences",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "getMemberInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "uid": {
            "type": "string",
            "minLength": 1,
            "description": "The member's Firebase Auth uid."
          }
        },
        "required": ["organizationId", "uid"],
        "additionalProperties": false
      },
      "getMemberOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "minLength": 1,
            "description": "Same value as `uid`."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "uid": {
            "type": "string",
            "minLength": 1,
            "description": "The member's Firebase Auth uid."
          },
          "role": {
            "type": "string",
            "enum": ["owner", "admin", "publisher", "member", "guest"]
          },
          "status": {
            "type": "string",
            "enum": ["active", "invited", "suspended", "removed"]
          },
          "blocked": { "type": "boolean" },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          }
        },
        "required": [
          "id",
          "organizationId",
          "uid",
          "role",
          "status",
          "blocked",
          "createdAt",
          "updatedAt",
          "revision"
        ],
        "additionalProperties": false
      },
      "getModelVersionSourceInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "modelId", "versionId"],
        "additionalProperties": false
      },
      "getModelVersionSourceOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "url": {
            "type": "string",
            "description": "Signed GET URL; it saves the file under `fileName`."
          },
          "expiresAt": {
            "type": "string",
            "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))$",
            "description": "When `url` stops working (15 minutes after issue, C13)."
          },
          "contentType": { "type": "string", "minLength": 1 },
          "sizeBytes": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "sha256": {
            "description": "SHA-256 of the file, when the upload declared one.",
            "type": "string",
            "pattern": "^[0-9a-f]{64}$"
          },
          "fileName": {
            "type": "string",
            "minLength": 1,
            "description": "The file's original name, as it was uploaded."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          }
        },
        "required": [
          "url",
          "expiresAt",
          "contentType",
          "sizeBytes",
          "fileName",
          "versionNumber"
        ],
        "additionalProperties": false
      },
      "getMyAccessInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "description": "Optional project id (Part B §2.5). When given, the returned capabilities are narrowed by that project's access mode/memberIds; when omitted, only org-scoped capabilities are returned.",
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "getMyAccessOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "capabilities": {
            "type": "array",
            "items": { "type": "string" },
            "description": "Every capability id (§2.3) the caller's role bundle grants them, narrowed by the named project's access when `projectId` was given (§2.5). Empty for no membership, an inactive/blocked membership, or a role §2.5 excludes from that project -- never an error."
          }
        },
        "required": ["capabilities"],
        "additionalProperties": false
      },
      "getMyDataExportInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "exportId": {
            "type": "string",
            "pattern": "^dex_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dex identifier (TypeID, conventions C5)."
          }
        },
        "required": ["exportId"],
        "additionalProperties": false
      },
      "getMyDataExportOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^dex_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dex identifier (TypeID, conventions C5)."
          },
          "status": {
            "type": "string",
            "enum": ["pending", "ready", "failed", "expired"],
            "description": "pending (being built) | ready (downloadable until expiresAt) | failed (request a new one) | expired (past its 24 h window)."
          },
          "requestedAt": {
            "type": "string",
            "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))$"
          },
          "readyAt": {
            "type": "string",
            "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))$"
          },
          "expiresAt": {
            "description": "End of the 24 h download window (BR-45).",
            "type": "string",
            "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))$"
          },
          "sizeBytes": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "download": {
            "description": "Present only while status is ready. The URL itself is valid for 15 minutes (C13); call getMyDataExport again for a fresh one until expiresAt.",
            "type": "object",
            "properties": {
              "url": { "type": "string", "format": "uri" },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "contentType": { "type": "string", "minLength": 1 },
              "sizeBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": ["url", "expiresAt", "contentType", "sizeBytes"],
            "additionalProperties": false
          }
        },
        "required": ["id", "status", "requestedAt"],
        "additionalProperties": false
      },
      "getOAuthAuthorizationRequestInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "requestId": {
            "type": "string",
            "pattern": "^oar_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A oar identifier (TypeID, conventions C5)."
          }
        },
        "required": ["requestId"],
        "additionalProperties": false
      },
      "getOAuthAuthorizationRequestOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "requestId": {
            "type": "string",
            "pattern": "^oar_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A oar identifier (TypeID, conventions C5)."
          },
          "clientHost": { "type": "string", "minLength": 1 },
          "clientName": { "type": "string" },
          "redirectHost": { "type": "string", "minLength": 1 },
          "isLoopback": { "type": "boolean" },
          "scopes": {
            "type": "array",
            "items": { "type": "string", "minLength": 1 }
          },
          "status": {
            "type": "string",
            "enum": ["pending", "approved", "denied", "redeemed", "expired"]
          }
        },
        "required": [
          "requestId",
          "clientHost",
          "redirectHost",
          "isLoopback",
          "scopes",
          "status"
        ],
        "additionalProperties": false
      },
      "getOnboardingStatusInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "getOnboardingStatusOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "ownModelPublished": {
            "type": "boolean",
            "description": "True once any project in the organisation has a published model version (\"Upload your own model\", AC-2). Org-wide, independent of the caller's own project visibility."
          },
          "crewInvited": {
            "type": "boolean",
            "description": "True once the organisation has at least 2 active members (\"Invite your crew\", AC-1)."
          },
          "sampleOpened": {
            "description": "Reserved for \"Open your sample project\". The sample project exists (FV-205); whether it was opened needs the model-opened signal (E03-S14), so this stays absent -- the checklist panel renders a step only when its field is present.",
            "type": "boolean"
          },
          "demoProjects": {
            "type": "object",
            "properties": {
              "state": {
                "type": "string",
                "enum": ["none", "pending", "preparing", "ready"],
                "description": "none: no demo projects are coming (none configured here, a tryout, the creator's per-user cap, or an organisation older than the wait with none started). pending: a new organisation (younger than 3 minutes) whose demo projects have not started yet. preparing: at least one is still being copied. ready: all of them are done (or no longer active)."
              },
              "total": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991,
                "description": "How many demo projects this environment provisions (0 when none are configured)."
              },
              "ready": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991,
                "description": "How many of them are ready to open."
              },
              "startedAt": {
                "description": "When the provisioning started: the first demo project's creation, or the organisation's creation while pending. Absent for none. A client shows a calm 'taking longer' message when this is long ago and the state is not ready.",
                "type": "string",
                "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))$"
              }
            },
            "required": ["state", "total", "ready"],
            "additionalProperties": false,
            "description": "The demo projects a new organisation starts with: whether they are coming, how many, and how many are ready. Poll this while pending or preparing."
          }
        },
        "required": ["ownModelPublished", "crewInvited", "demoProjects"],
        "additionalProperties": false
      },
      "getOrganizationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "getOrganizationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 2,
            "maxLength": 80,
            "description": "Organisation display name (2-80 chars after trimming, BR-10)."
          },
          "defaultLocale": {
            "type": "string",
            "enum": ["nl", "en", "fr"],
            "description": "The organisation's default UI locale, one of nl | en | fr."
          },
          "status": {
            "type": "string",
            "enum": ["active", "pending_deletion"]
          },
          "deletion": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "purgeAfter": {
                "type": "string",
                "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))$"
              },
              "cancelledAt": {
                "type": "string",
                "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))$"
              },
              "purgeStartedAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["requestedAt", "requestedBy", "purgeAfter"],
            "additionalProperties": false
          },
          "supportAccess": {
            "description": "Whether Field-Viewer support may open a read-only support session: allowed (default when absent; owners are e-mailed) or ask (an owner approves each request first).",
            "type": "string",
            "enum": ["allowed", "ask"]
          },
          "settings": {
            "type": "object",
            "properties": {
              "analytics": {
                "type": "object",
                "properties": {
                  "mode": {
                    "type": "string",
                    "enum": ["enabled", "disabled"],
                    "description": "Product analytics for every member: enabled (the default) or disabled. Disabled, no usage event is recorded for anyone in the organisation."
                  }
                },
                "required": ["mode"],
                "additionalProperties": false
              },
              "cad": {
                "type": "object",
                "properties": {
                  "producerDetailTags": {
                    "type": "object",
                    "properties": {
                      "scale": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's scale text (1:n)."
                      },
                      "xFactor": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's x factor (1/n)."
                      },
                      "yFactor": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's y factor (1/n)."
                      },
                      "xMin": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's minimum x."
                      },
                      "yMin": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's minimum y."
                      },
                      "xMax": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's maximum x."
                      },
                      "yMax": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's maximum y."
                      }
                    },
                    "required": [
                      "scale",
                      "xFactor",
                      "yFactor",
                      "xMin",
                      "yMin",
                      "xMax",
                      "yMax"
                    ],
                    "additionalProperties": false,
                    "description": "The CAD producer's detail attribute tags: all seven, each the tag (not the value) of one block attribute. With them, scaled details in model space measure in real millimetres at their own scale; without them they read 'scale unknown'."
                  }
                },
                "additionalProperties": false
              }
            },
            "additionalProperties": false
          },
          "legal": {
            "type": "object",
            "properties": {
              "termsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "privacyVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "dpaVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "subprocessorsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "acceptedAt": {
                "type": "string",
                "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))$"
              },
              "acceptedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              }
            },
            "required": [
              "termsVersion",
              "privacyVersion",
              "dpaVersion",
              "subprocessorsVersion",
              "acceptedAt",
              "acceptedBy"
            ],
            "additionalProperties": false,
            "description": "The terms, privacy notice, DPA and sub-processor list versions an owner accepted for the organisation."
          },
          "kind": {
            "description": "standard (default when absent) or tryout: an anonymous visitor's 7-day try-it organisation.",
            "type": "string",
            "enum": ["standard", "tryout"]
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "logoUrl": {
            "type": "object",
            "properties": {
              "url": { "type": "string" },
              "expiresAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["url", "expiresAt"],
            "additionalProperties": false,
            "description": "Signed URL of the organisation's logo (15 minutes). Absent when it has no logo."
          },
          "reacceptanceRequired": {
            "description": "True when an owner must accept a newer material version of the terms, the DPA or the sub-processor list (or never accepted them).",
            "type": "boolean"
          },
          "orgStatus": {
            "type": "string",
            "enum": ["active", "suspended"],
            "description": "`suspended` while Field-Viewer has paused the organisation: every change is refused `403 organization.suspended`, viewing still works (FV-215)."
          },
          "planId": {
            "description": "The organisation's plan, absent for an organisation without an entitlements document. The app sends it to Remote Config as a custom signal (FV-202).",
            "type": "string",
            "enum": ["beta", "free", "team", "enterprise", "internal", "tryout"]
          },
          "cohort": {
            "description": "The beta wave tag a platform admin set (e.g. `wave1`), absent when none is set. Feature flags target it (FV-202).",
            "type": "string",
            "minLength": 1
          }
        },
        "required": [
          "id",
          "name",
          "defaultLocale",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy",
          "orgStatus"
        ],
        "additionalProperties": false
      },
      "getPlatformFlagsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {},
        "additionalProperties": false
      },
      "getPlatformFlagsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "environment": {
            "type": "string",
            "minLength": 1,
            "description": "The environment the API runs in, whose templates these are."
          },
          "templates": {
            "type": "object",
            "properties": {
              "client": {
                "type": "object",
                "properties": {
                  "exists": {
                    "type": "boolean",
                    "description": "False while the environment has no template of this kind yet."
                  },
                  "etag": {
                    "type": "string",
                    "minLength": 1,
                    "description": "The template's ETag; send it back in `etags` on a change (`*` while none exists)."
                  },
                  "versionNumber": { "type": "string" },
                  "updateTime": { "type": "string" }
                },
                "required": ["exists", "etag"],
                "additionalProperties": false
              },
              "server": {
                "type": "object",
                "properties": {
                  "exists": {
                    "type": "boolean",
                    "description": "False while the environment has no template of this kind yet."
                  },
                  "etag": {
                    "type": "string",
                    "minLength": 1,
                    "description": "The template's ETag; send it back in `etags` on a change (`*` while none exists)."
                  },
                  "versionNumber": { "type": "string" },
                  "updateTime": { "type": "string" }
                },
                "required": ["exists", "etag"],
                "additionalProperties": false
              }
            },
            "required": ["client", "server"],
            "additionalProperties": false
          },
          "flags": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "key": {
                  "type": "string",
                  "pattern": "^ff_e\\d{2}_[a-z0-9]+(?:_[a-z0-9]+)*$",
                  "description": "A registered flag key, `ff_<epic>_<feature>` (docs/flags.md)."
                },
                "purpose": { "type": "string" },
                "owner": { "type": "string" },
                "templates": {
                  "minItems": 1,
                  "type": "array",
                  "items": { "type": "string", "enum": ["client", "server"] }
                },
                "repoDefault": {
                  "type": "boolean",
                  "description": "The repo template's default: what a new environment starts with."
                },
                "inSync": {
                  "type": "boolean",
                  "description": "A flag in both templates: whether its default and rules are the same in both. Always true for a flag in one template."
                },
                "client": {
                  "type": "object",
                  "properties": {
                    "present": {
                      "type": "boolean",
                      "description": "Whether the live template has the parameter (a new environment gets it at the next deploy)."
                    },
                    "defaultValue": {
                      "description": "The unconditional default; `null` when absent or when it uses the in-app default.",
                      "type": ["boolean", "null"]
                    },
                    "rules": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "condition": {
                            "type": "string",
                            "minLength": 1,
                            "description": "The Remote Config condition's name."
                          },
                          "group": {
                            "description": "The rollout group the condition matches; absent for a condition this screen cannot read (several terms, several values): shown, never written.",
                            "oneOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "kind": {
                                    "type": "string",
                                    "const": "cohort"
                                  },
                                  "cohort": {
                                    "type": "string",
                                    "pattern": "^[a-z0-9][a-z0-9_-]{0,39}$",
                                    "description": "The cohort tag, e.g. `wave1`."
                                  }
                                },
                                "required": ["kind", "cohort"],
                                "additionalProperties": false
                              },
                              {
                                "type": "object",
                                "properties": {
                                  "kind": { "type": "string", "const": "plan" },
                                  "planId": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 40,
                                    "description": "The plan id the condition matches (`planId` signal)."
                                  }
                                },
                                "required": ["kind", "planId"],
                                "additionalProperties": false
                              }
                            ]
                          },
                          "value": { "type": "boolean" }
                        },
                        "required": ["condition", "value"],
                        "additionalProperties": false
                      },
                      "description": "One rule per condition with a value, in the template's priority order."
                    }
                  },
                  "required": ["present", "defaultValue", "rules"],
                  "additionalProperties": false
                },
                "server": {
                  "type": "object",
                  "properties": {
                    "present": {
                      "type": "boolean",
                      "description": "Whether the live template has the parameter (a new environment gets it at the next deploy)."
                    },
                    "defaultValue": {
                      "description": "The unconditional default; `null` when absent or when it uses the in-app default.",
                      "type": ["boolean", "null"]
                    },
                    "rules": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "condition": {
                            "type": "string",
                            "minLength": 1,
                            "description": "The Remote Config condition's name."
                          },
                          "group": {
                            "description": "The rollout group the condition matches; absent for a condition this screen cannot read (several terms, several values): shown, never written.",
                            "oneOf": [
                              {
                                "type": "object",
                                "properties": {
                                  "kind": {
                                    "type": "string",
                                    "const": "cohort"
                                  },
                                  "cohort": {
                                    "type": "string",
                                    "pattern": "^[a-z0-9][a-z0-9_-]{0,39}$",
                                    "description": "The cohort tag, e.g. `wave1`."
                                  }
                                },
                                "required": ["kind", "cohort"],
                                "additionalProperties": false
                              },
                              {
                                "type": "object",
                                "properties": {
                                  "kind": { "type": "string", "const": "plan" },
                                  "planId": {
                                    "type": "string",
                                    "minLength": 1,
                                    "maxLength": 40,
                                    "description": "The plan id the condition matches (`planId` signal)."
                                  }
                                },
                                "required": ["kind", "planId"],
                                "additionalProperties": false
                              }
                            ]
                          },
                          "value": { "type": "boolean" }
                        },
                        "required": ["condition", "value"],
                        "additionalProperties": false
                      },
                      "description": "One rule per condition with a value, in the template's priority order."
                    }
                  },
                  "required": ["present", "defaultValue", "rules"],
                  "additionalProperties": false
                }
              },
              "required": [
                "key",
                "purpose",
                "owner",
                "templates",
                "repoDefault",
                "inSync"
              ],
              "additionalProperties": false
            }
          }
        },
        "required": ["environment", "templates", "flags"],
        "additionalProperties": false
      },
      "getPlatformOrganizationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "getPlatformOrganizationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 2,
            "maxLength": 80,
            "description": "Organisation display name (2-80 chars after trimming, BR-10)."
          },
          "planId": {
            "type": "string",
            "enum": ["beta", "free", "team", "enterprise", "internal", "tryout"]
          },
          "orgStatus": {
            "type": "string",
            "enum": ["active", "suspended"],
            "description": "`suspended` while a platform admin has paused the organisation's writes."
          },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "cohort": { "type": "string", "minLength": 1 },
          "plan": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "enum": [
                  "beta",
                  "free",
                  "team",
                  "enterprise",
                  "internal",
                  "tryout"
                ]
              },
              "name": {
                "description": "The plan's name per language, from the plan catalogue. Absent for the legacy beta plan.",
                "type": "object",
                "properties": {
                  "nl": { "type": "string", "minLength": 1 },
                  "en": { "type": "string", "minLength": 1 },
                  "fr": { "type": "string", "minLength": 1 }
                },
                "required": ["nl", "en", "fr"],
                "additionalProperties": false
              }
            },
            "required": ["id"],
            "additionalProperties": false
          },
          "planSource": {
            "type": "string",
            "enum": ["default", "billing", "platform", "migration"]
          },
          "planChange": {
            "description": "The newest plan change in the organisation's activity log: when, and who set it. Absent when the plan was never changed.",
            "type": "object",
            "properties": {
              "at": {
                "type": "string",
                "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))$"
              },
              "by": {
                "type": "string",
                "enum": ["default", "billing", "platform", "migration"]
              }
            },
            "required": ["at", "by"],
            "additionalProperties": false
          },
          "entitlementsRevision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991,
            "description": "The entitlements document's revision: send it as If-Match (expectedRevision) to updateOrganizationEntitlements."
          },
          "billing": {
            "type": "object",
            "properties": {
              "status": {
                "type": "string",
                "enum": ["none", "trialing", "active", "past_due", "canceled"]
              },
              "subscription": {
                "type": "boolean",
                "description": "True while the organisation has a live provider subscription (active, past due, or a trial with a card): a manual plan conflicts with it."
              }
            },
            "required": ["status", "subscription"],
            "additionalProperties": false
          },
          "limits": {
            "type": "object",
            "properties": {
              "seats": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "guests": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "workstations": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "projects": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "storageBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "maxModelFileBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 1073741824,
                "description": "Largest single model file, in bytes, for direct upload and URL import. Never above 1 GiB (BR-10)."
              },
              "maxModelsPerProject": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "processingMinutesPerMonth": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "apiTokens": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "maxDocumentFileBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991,
                "description": "Largest single drawing file (PDF, DXF, DWG), in bytes. The format's own ceiling still applies on top."
              },
              "maxDocumentsPerProject": {
                "description": "Most drawings (documents) in one project. Absent: no limit.",
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "seats",
              "guests",
              "workstations",
              "projects",
              "storageBytes",
              "maxModelFileBytes",
              "maxModelsPerProject",
              "processingMinutesPerMonth",
              "apiTokens",
              "maxDocumentFileBytes"
            ],
            "additionalProperties": false
          },
          "features": {
            "type": "object",
            "properties": {
              "autoDimensions": { "type": "boolean" },
              "workstationMode": { "type": "boolean" },
              "auditLogExport": {
                "type": "boolean",
                "description": "Whether the activity log can be exported as CSV (`requestAuditLogExport`)."
              },
              "sso": {
                "type": "boolean",
                "description": "Reserved for single sign-on. Not in use yet."
              }
            },
            "required": [
              "autoDimensions",
              "workstationMode",
              "auditLogExport",
              "sso"
            ],
            "additionalProperties": false
          },
          "overrides": {
            "type": "object",
            "properties": {
              "limits": {
                "type": "object",
                "properties": {
                  "seats": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "guests": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "workstations": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "projects": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "storageBytes": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "maxModelFileBytes": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 1073741824,
                    "description": "Largest single model file, in bytes, for direct upload and URL import. Never above 1 GiB (BR-10)."
                  },
                  "maxModelsPerProject": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "processingMinutesPerMonth": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "apiTokens": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "maxDocumentFileBytes": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991,
                    "description": "Largest single drawing file (PDF, DXF, DWG), in bytes. The format's own ceiling still applies on top."
                  },
                  "maxDocumentsPerProject": {
                    "description": "Most drawings (documents) in one project. Absent: no limit.",
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "additionalProperties": false
              },
              "features": {
                "type": "object",
                "properties": {
                  "autoDimensions": { "type": "boolean" },
                  "workstationMode": { "type": "boolean" },
                  "auditLogExport": {
                    "type": "boolean",
                    "description": "Whether the activity log can be exported as CSV (`requestAuditLogExport`)."
                  },
                  "sso": {
                    "type": "boolean",
                    "description": "Reserved for single sign-on. Not in use yet."
                  }
                },
                "additionalProperties": false
              },
              "reason": { "type": "string", "minLength": 1 },
              "appliedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              },
              "appliedAt": {
                "type": "string",
                "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))$"
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["reason", "appliedBy", "appliedAt"],
            "additionalProperties": false
          },
          "usage": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "resource": {
                  "type": "string",
                  "enum": [
                    "seats",
                    "guests",
                    "workstations",
                    "projects",
                    "storageBytes",
                    "processingMinutesPerMonth",
                    "apiTokens"
                  ]
                },
                "used": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991,
                  "description": "Current usage; 0 when nothing has been counted yet. Bytes for `storageBytes`, minutes this month for `processingMinutesPerMonth`."
                },
                "limit": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "resetsAt": {
                  "description": "Only for a monthly resource (`processingMinutesPerMonth`): when its usage resets, the 1st of next month at 00:00 UTC.",
                  "type": "string",
                  "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))$"
                }
              },
              "required": ["resource", "used", "limit"],
              "additionalProperties": false
            },
            "description": "Usage against each organisation-wide limit, the same numbers the owner's usage screen shows."
          },
          "membersCount": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "Active members of every role."
          },
          "lastActivityAt": {
            "description": "The newest change a member, token, app or workstation made, from the organisation's activity log. Absent when there is none.",
            "type": "string",
            "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))$"
          }
        },
        "required": [
          "id",
          "name",
          "planId",
          "orgStatus",
          "createdAt",
          "plan",
          "planSource",
          "entitlementsRevision",
          "billing",
          "limits",
          "features",
          "usage",
          "membersCount"
        ],
        "additionalProperties": false
      },
      "getPlatformTryoutStatsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {},
        "additionalProperties": false
      },
      "getPlatformTryoutStatsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "today": {
            "type": "object",
            "properties": {
              "created": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "capHits": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "converted": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "consented": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "estimatedCostEur": {
                "type": "number",
                "minimum": 0,
                "description": "`created` times the E15 §0.7 upper estimate per tryout."
              }
            },
            "required": [
              "created",
              "capHits",
              "converted",
              "consented",
              "estimatedCostEur"
            ],
            "additionalProperties": false
          },
          "last7Days": {
            "type": "object",
            "properties": {
              "created": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "capHits": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "converted": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "consented": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "estimatedCostEur": {
                "type": "number",
                "minimum": 0,
                "description": "`created` times the E15 §0.7 upper estimate per tryout."
              }
            },
            "required": [
              "created",
              "capHits",
              "converted",
              "consented",
              "estimatedCostEur"
            ],
            "additionalProperties": false
          },
          "tryoutsPaused": { "type": "boolean" }
        },
        "required": ["today", "last7Days", "tryoutsPaused"],
        "additionalProperties": false
      },
      "getPricingInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {},
        "additionalProperties": false
      },
      "getPricingOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "prices": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "planId": {
                  "type": "string",
                  "enum": ["free", "team", "enterprise", "internal", "tryout"]
                },
                "currency": { "type": "string", "const": "EUR" },
                "intervals": {
                  "type": "object",
                  "properties": {
                    "monthly": {
                      "type": "object",
                      "properties": {
                        "amountCents": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "validFrom": {
                          "type": "string",
                          "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))$"
                        }
                      },
                      "required": ["amountCents", "validFrom"],
                      "additionalProperties": false
                    },
                    "yearly": {
                      "type": "object",
                      "properties": {
                        "amountCents": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "validFrom": {
                          "type": "string",
                          "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))$"
                        }
                      },
                      "required": ["amountCents", "validFrom"],
                      "additionalProperties": false
                    }
                  },
                  "required": ["monthly", "yearly"],
                  "additionalProperties": false
                },
                "history": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "interval": {
                        "type": "string",
                        "enum": ["monthly", "yearly"]
                      },
                      "amountCents": {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 9007199254740991
                      },
                      "validFrom": {
                        "type": "string",
                        "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))$"
                      },
                      "validUntil": {
                        "type": "string",
                        "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))$"
                      },
                      "changedBy": {
                        "type": "object",
                        "properties": {
                          "type": {
                            "type": "string",
                            "enum": [
                              "user",
                              "apiToken",
                              "oauth",
                              "workstation",
                              "platformAdmin"
                            ]
                          },
                          "id": { "type": "string" }
                        },
                        "required": ["type", "id"],
                        "additionalProperties": false
                      },
                      "note": { "type": "string", "maxLength": 500 }
                    },
                    "required": [
                      "interval",
                      "amountCents",
                      "validFrom",
                      "validUntil"
                    ],
                    "additionalProperties": false
                  }
                },
                "atProvider": { "type": "boolean" },
                "updatedAt": {
                  "type": "string",
                  "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))$"
                },
                "updatedBy": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                },
                "revision": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                }
              },
              "required": [
                "planId",
                "currency",
                "intervals",
                "history",
                "atProvider",
                "updatedAt",
                "revision"
              ],
              "additionalProperties": false
            }
          },
          "discounts": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": { "type": "string", "minLength": 1 },
                "name": { "type": "string", "minLength": 1 },
                "kind": { "type": "string", "enum": ["organization", "code"] },
                "planIds": {
                  "minItems": 1,
                  "type": "array",
                  "items": {
                    "type": "string",
                    "enum": ["free", "team", "enterprise", "internal", "tryout"]
                  }
                },
                "discount": {
                  "oneOf": [
                    {
                      "type": "object",
                      "properties": {
                        "type": { "type": "string", "const": "percent" },
                        "value": {
                          "type": "number",
                          "exclusiveMinimum": 0,
                          "maximum": 100
                        }
                      },
                      "required": ["type", "value"],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "type": { "type": "string", "const": "amount_off" },
                        "cents": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        }
                      },
                      "required": ["type", "cents"],
                      "additionalProperties": false
                    }
                  ]
                },
                "duration": {
                  "anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "months": {
                          "type": "integer",
                          "exclusiveMinimum": 0,
                          "maximum": 9007199254740991
                        }
                      },
                      "required": ["months"],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "forever": { "type": "boolean", "const": true }
                      },
                      "required": ["forever"],
                      "additionalProperties": false
                    }
                  ]
                },
                "organizationId": { "type": "string", "minLength": 1 },
                "codePrefix": { "type": "string", "minLength": 1 },
                "status": { "type": "string", "enum": ["active", "ended"] },
                "startsAt": {
                  "type": "string",
                  "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))$"
                },
                "updatedAt": {
                  "type": "string",
                  "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))$"
                },
                "updatedBy": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                },
                "revision": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "endsAt": {
                  "type": "string",
                  "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))$"
                }
              },
              "required": [
                "id",
                "name",
                "kind",
                "planIds",
                "discount",
                "duration",
                "status",
                "startsAt",
                "updatedAt",
                "revision"
              ],
              "additionalProperties": false
            },
            "description": "Every active discount, newest first."
          },
          "marginalCostCents": {
            "anyOf": [
              {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              { "type": "null" }
            ],
            "description": "Our marginal cost per organisation per month, in EUR cents excl. VAT (the backoffice's margin hint); null while not set."
          }
        },
        "required": ["prices", "discounts", "marginalCostCents"],
        "additionalProperties": false
      },
      "getProjectInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId"],
        "additionalProperties": false
      },
      "getProjectOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "Project display name (1-80 chars after trimming, BR-2)."
          },
          "reference": {
            "type": "string",
            "minLength": 1,
            "maxLength": 40,
            "description": "Free-form job/reference code, e.g. \"2026-041\" (BR-2)."
          },
          "updatedAt": {
            "type": "string",
            "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))$",
            "description": "When this project was last updated (RFC 3339 UTC)."
          },
          "isSample": {
            "description": "Present (true) only on the organisation's onboarding sample project (FV-205) and its demo projects (FV-600).",
            "type": "boolean",
            "const": true
          },
          "demoSlug": {
            "description": "Present only on a demo project the organisation started with (FV-600): which one. Shown as an example project.",
            "type": "string",
            "enum": [
              "landhuis_hulstveld",
              "landhuis_hulstveld_hsb",
              "woning_lindehof",
              "villa_berkenhaag",
              "hal_noorderkempen",
              "paneelset_werkplaats"
            ]
          },
          "lastPublishedAt": {
            "description": "When a model in this project was last published; absent until the first publish.",
            "type": "string",
            "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))$"
          },
          "status": {
            "type": "string",
            "enum": ["active", "archived", "deleted"],
            "description": "Lifecycle status (FV-134): active, archived (read-only) or deleted (restorable until purgeAfter)."
          },
          "archivedAt": {
            "description": "When the project was archived; present while archived.",
            "type": "string",
            "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))$"
          },
          "deletedAt": {
            "description": "When the project was deleted; present while deleted.",
            "type": "string",
            "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))$"
          },
          "purgeAfter": {
            "description": "When a deleted project is purged for good; restoreProject works until then.",
            "type": "string",
            "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))$"
          },
          "access": {
            "type": "object",
            "properties": {
              "mode": {
                "type": "string",
                "enum": ["organisation", "restricted"],
                "description": "organisation: everyone in the organisation can open it; restricted: owners, admins and the project's own members only."
              },
              "memberCount": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991,
                "description": "People who can open the project right now (in organisation mode the org-wide count)."
              },
              "pendingInvitationCount": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991,
                "description": "Pending, unexpired e-mail invitations that would give access to this project."
              },
              "preview": {
                "description": "The first three people, owners and admins first. Absent for a guest caller.",
                "maxItems": 3,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "uid": { "type": "string", "minLength": 1 },
                    "displayName": { "type": "string", "minLength": 1 },
                    "initials": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 4,
                      "description": "One or two letters for an avatar without a picture."
                    },
                    "avatarUrl": { "type": "string", "format": "uri" }
                  },
                  "required": ["uid", "displayName", "initials"],
                  "additionalProperties": false
                }
              },
              "people": {
                "description": "Everyone who can open the project, owners and admins first; pending invitations only for an owner or admin caller. Absent for a guest caller.",
                "maxItems": 1000,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "id": {
                      "type": "string",
                      "minLength": 1,
                      "description": "The person's uid (status active) or the invitation's id (status invited)."
                    },
                    "displayName": { "type": "string", "minLength": 1 },
                    "initials": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 4
                    },
                    "avatarUrl": { "type": "string", "format": "uri" },
                    "role": {
                      "type": "string",
                      "enum": ["owner", "admin", "publisher", "member", "guest"]
                    },
                    "status": {
                      "type": "string",
                      "enum": ["active", "invited"]
                    }
                  },
                  "required": [
                    "id",
                    "displayName",
                    "initials",
                    "role",
                    "status"
                  ],
                  "additionalProperties": false
                }
              }
            },
            "required": ["mode", "memberCount", "pendingInvitationCount"],
            "additionalProperties": false,
            "description": "Who can open the project, everyone by name (FV-380)."
          },
          "currentRevision": {
            "type": "object",
            "properties": {
              "number": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "publishedAt": {
                "type": "string",
                "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))$"
              },
              "publishedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              },
              "publishedByName": {
                "description": "The publisher's display name, when they are a member.",
                "type": "string",
                "minLength": 1
              }
            },
            "required": ["number", "publishedAt", "publishedBy"],
            "additionalProperties": false,
            "description": "The project's current (published) revision; absent until the first publish (FV-384)."
          },
          "latestRevision": {
            "type": "object",
            "properties": {
              "number": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "status": {
                "type": "string",
                "enum": [
                  "uploading",
                  "uploaded",
                  "processing",
                  "ready",
                  "failed",
                  "archived",
                  "cancelled"
                ]
              }
            },
            "required": ["number", "status"],
            "additionalProperties": false,
            "description": "The project's newest revision and its processing status; absent with no revision yet (FV-384)."
          },
          "thumbnail": {
            "type": "object",
            "properties": {
              "url": {
                "type": "string",
                "format": "uri",
                "description": "Short-lived signed GET URL to the current revision's thumbnail (512 x 512 WebP)."
              },
              "expiresAt": {
                "type": "string",
                "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))$",
                "description": "When `url` stops working (RFC 3339 UTC)."
              },
              "cacheKey": {
                "type": "string",
                "minLength": 1,
                "description": "Stable identity of this exact image: it changes only when a new image is published, so a client may keep the bytes under it (offline)."
              },
              "dark": {
                "type": "object",
                "properties": {
                  "url": {
                    "type": "string",
                    "format": "uri",
                    "description": "Short-lived signed GET URL to the current revision's thumbnail (512 x 512 WebP)."
                  },
                  "expiresAt": {
                    "type": "string",
                    "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))$",
                    "description": "When `url` stops working (RFC 3339 UTC)."
                  },
                  "cacheKey": {
                    "type": "string",
                    "minLength": 1,
                    "description": "Stable identity of this exact image: it changes only when a new image is published, so a client may keep the bytes under it (offline)."
                  }
                },
                "required": ["url", "expiresAt", "cacheKey"],
                "additionalProperties": false,
                "description": "The same thumbnail drawn in the dim theme's colours; absent for revisions processed before it existed -- show the light image then (FV-436)."
              }
            },
            "required": ["url", "expiresAt", "cacheKey"],
            "additionalProperties": false,
            "description": "The project's current revision as a thumbnail; absent before the first publish, while it has no thumbnail (processing failed to draw one), or when it cannot be signed (FV-132)."
          },
          "drawingCount": {
            "description": "How many drawings (active documents with a published version) the field sees in the project (FV-771). Returned by listProjects; absent elsewhere, and when the count could not be read -- the list never fails for it.",
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          }
        },
        "required": ["id", "name", "updatedAt", "status", "access"],
        "additionalProperties": false
      },
      "getProjectRevisionInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "number": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991,
            "description": "The revision number within the project."
          }
        },
        "required": ["organizationId", "projectId", "number"],
        "additionalProperties": false
      },
      "getProjectRevisionOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": [
              "uploading",
              "uploaded",
              "processing",
              "ready",
              "failed",
              "archived",
              "cancelled"
            ]
          },
          "publication": {
            "type": "string",
            "enum": ["draft", "published", "superseded"]
          },
          "fieldVisible": { "type": "boolean" },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "upload" },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "fileName", "sizeBytes", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "copy" },
                  "sourceVersionId": {
                    "type": "string",
                    "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A ver identifier (TypeID, conventions C5)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": [
                  "kind",
                  "sourceVersionId",
                  "fileName",
                  "sizeBytes",
                  "contentType"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "url" },
                  "url": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 2048,
                    "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "url", "fileName", "contentType"],
                "additionalProperties": false
              }
            ]
          },
          "upload": {
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "cancelReason": { "type": "string", "enum": ["user", "expired"] },
          "pipelineVersion": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": { "type": "string" },
                "blocking": { "type": "boolean" },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": {}
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": { "type": "string", "minLength": 1 },
              "retryable": { "type": "boolean" },
              "params": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": {}
              },
              "messageKey": { "type": "string", "minLength": 1 },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "retryable"],
            "additionalProperties": false
          },
          "processing": {
            "type": "object",
            "properties": {
              "sizeClass": { "type": "string", "enum": ["s", "m", "l", "xl"] },
              "executionName": { "type": "string", "minLength": 1 },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "queuedAt": {
                "type": "string",
                "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))$"
              },
              "queuedTraceparent": {
                "type": "string",
                "pattern": "^(?!ff)[0-9a-f]{2}-(?!0{32})[0-9a-f]{32}-(?!0{16})[0-9a-f]{16}-[0-9a-f]{2}$"
              },
              "queuedEscalation": {
                "type": "object",
                "properties": {
                  "sizeClass": {
                    "type": "string",
                    "enum": ["s", "m", "l", "xl"]
                  },
                  "attempt": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["sizeClass", "attempt"],
                "additionalProperties": false
              },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "progressReportedAt": {
                "type": "string",
                "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))$"
              },
              "requestId": { "type": "string", "minLength": 1 }
            },
            "additionalProperties": false
          },
          "progress": {
            "type": "object",
            "properties": {
              "stage": { "type": "string", "minLength": 1 },
              "percent": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["stage", "percent"],
            "additionalProperties": false
          },
          "reprocessing": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "reason": {
                "type": "string",
                "enum": ["retry", "pipeline_upgrade"]
              },
              "targetPipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "state": {
                "type": "string",
                "enum": [
                  "requested",
                  "deferred",
                  "awaiting_rollout",
                  "done",
                  "failed"
                ]
              },
              "completedAt": {
                "type": "string",
                "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))$"
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1 },
                  "retryable": { "type": "boolean" },
                  "params": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": {}
                  },
                  "messageKey": { "type": "string", "minLength": 1 },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "retryable"],
                "additionalProperties": false
              }
            },
            "required": ["requestedAt", "requestedBy", "attempt"],
            "additionalProperties": false
          },
          "releasedAt": {
            "type": "string",
            "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))$"
          },
          "releasedBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "supersededAt": {
            "type": "string",
            "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))$"
          },
          "activeArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "nextArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "stats": {
            "type": "object",
            "properties": {
              "elementCount": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "boundsMm": {
                "type": "object",
                "properties": {
                  "min": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3
                  },
                  "max": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3
                  }
                },
                "required": ["min", "max"],
                "additionalProperties": false
              },
              "coveragePct": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["elementCount", "boundsMm"],
            "additionalProperties": false
          },
          "churn": {
            "type": "object",
            "properties": {
              "ratio": { "type": "number", "minimum": 0, "maximum": 1 },
              "added": { "type": "array", "items": { "type": "string" } },
              "removed": { "type": "array", "items": { "type": "string" } },
              "moved": { "type": "array", "items": { "type": "string" } },
              "recreated": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "from": { "type": "string" },
                    "to": { "type": "string" }
                  },
                  "required": ["from", "to"],
                  "additionalProperties": false
                }
              }
            },
            "required": ["ratio", "added", "removed", "moved", "recreated"],
            "additionalProperties": false
          },
          "label": {
            "type": "string",
            "minLength": 1,
            "maxLength": 40,
            "description": "Short version name, e.g. \"Roof fix\" (1-40 chars after trimming, BR-10)."
          },
          "notes": {
            "type": "string",
            "maxLength": 2000,
            "description": "Free-form notes for the crew (max 2000 chars, BR-10)."
          },
          "detailsEditedAt": {
            "type": "string",
            "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))$"
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "publishOnReady": {
            "description": "Publish this version automatically, in the same write that marks it ready (FV-383).",
            "type": "boolean"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "number": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991,
            "description": "The revision number within the project (1, 2, 3...)."
          },
          "current": {
            "type": "boolean",
            "description": "Whether this is the revision the field sees now."
          },
          "publishedAt": {
            "description": "When this revision was (last) published; absent for a revision never published.",
            "type": "string",
            "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))$"
          },
          "publishedBy": {
            "description": "Who published it; absent for a revision never published, or published before FV-384 and no longer current.",
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "publishedByName": {
            "description": "The publisher's display name, when they are a member.",
            "type": "string",
            "minLength": 1
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "modelId",
          "versionNumber",
          "status",
          "publication",
          "fieldVisible",
          "source",
          "pipelineVersion",
          "warnings",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy",
          "number",
          "current"
        ],
        "additionalProperties": false
      },
      "getProjectSceneInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId"],
        "additionalProperties": false
      },
      "getProjectSceneOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "models": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "modelId": {
                  "type": "string",
                  "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A mdl identifier (TypeID, conventions C5)."
                },
                "name": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 80,
                  "description": "Model display name (1-80 chars after trimming, BR-8)."
                },
                "versionId": {
                  "type": "string",
                  "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A ver identifier (TypeID, conventions C5)."
                },
                "versionNumber": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "publishedAt": {
                  "type": "string",
                  "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))$"
                },
                "artifacts": {
                  "type": "object",
                  "properties": {
                    "manifestUrl": { "type": "string" },
                    "geometryUrl": { "type": "string" },
                    "geometryBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "spatialTreeUrl": { "type": "string" },
                    "elementsUrl": { "type": "string" },
                    "layersUrl": { "type": "string" },
                    "openingsUrl": { "type": "string" },
                    "expiresAt": {
                      "type": "string",
                      "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))$"
                    }
                  },
                  "required": [
                    "manifestUrl",
                    "geometryUrl",
                    "geometryBytes",
                    "expiresAt"
                  ],
                  "additionalProperties": false
                }
              },
              "required": [
                "modelId",
                "name",
                "versionId",
                "versionNumber",
                "publishedAt",
                "artifacts"
              ],
              "additionalProperties": false
            }
          },
          "empty": { "type": "boolean" },
          "truncated": { "type": "boolean" }
        },
        "required": ["models", "empty"],
        "additionalProperties": false
      },
      "getResearchConsentInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "getResearchConsentOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "status": {
            "type": "string",
            "enum": ["not_asked", "declined", "consented", "withdrawn"]
          },
          "decidedAt": {
            "type": "string",
            "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))$"
          },
          "legalVersion": { "type": "string", "minLength": 1 },
          "withdrawnAt": {
            "type": "string",
            "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))$"
          },
          "copiedAt": {
            "type": "string",
            "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))$"
          },
          "objectPath": { "type": "string", "minLength": 1 }
        },
        "required": ["status"],
        "additionalProperties": false
      },
      "getSampleSceneInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "slug": {
            "type": "string",
            "pattern": "^[a-z0-9_]{1,64}$",
            "description": "The sample to open, e.g. `woning_lindehof` (as `listSamples` returns it)."
          },
          "locale": {
            "description": "The language of `name` and `audience` (nl, en or fr); the request's Accept-Language, else Dutch, when omitted.",
            "type": "string",
            "enum": ["nl", "en", "fr"]
          }
        },
        "required": ["slug"],
        "additionalProperties": false
      },
      "getSampleSceneOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "models": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "modelId": {
                  "type": "string",
                  "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A mdl identifier (TypeID, conventions C5)."
                },
                "name": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 80,
                  "description": "Model display name (1-80 chars after trimming, BR-8)."
                },
                "versionId": {
                  "type": "string",
                  "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A ver identifier (TypeID, conventions C5)."
                },
                "versionNumber": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "publishedAt": {
                  "type": "string",
                  "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))$"
                },
                "artifacts": {
                  "type": "object",
                  "properties": {
                    "manifestUrl": { "type": "string" },
                    "geometryUrl": { "type": "string" },
                    "geometryBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "spatialTreeUrl": { "type": "string" },
                    "elementsUrl": { "type": "string" },
                    "layersUrl": { "type": "string" },
                    "openingsUrl": { "type": "string" },
                    "expiresAt": {
                      "type": "string",
                      "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))$"
                    }
                  },
                  "required": [
                    "manifestUrl",
                    "geometryUrl",
                    "geometryBytes",
                    "expiresAt"
                  ],
                  "additionalProperties": false
                }
              },
              "required": [
                "modelId",
                "name",
                "versionId",
                "versionNumber",
                "publishedAt",
                "artifacts"
              ],
              "additionalProperties": false
            }
          },
          "empty": { "type": "boolean" },
          "truncated": { "type": "boolean" },
          "sample": {
            "type": "object",
            "properties": {
              "slug": {
                "type": "string",
                "enum": [
                  "landhuis_hulstveld",
                  "landhuis_hulstveld_hsb",
                  "woning_lindehof",
                  "villa_berkenhaag",
                  "hal_noorderkempen",
                  "paneelset_werkplaats"
                ],
                "description": "The sample's id, e.g. `woning_lindehof` (the demo project it is)."
              },
              "name": { "type": "string", "description": "The sample's name." },
              "audience": {
                "type": "string",
                "description": "One line on who it is for, in the asked language (e.g. timber frame)."
              },
              "thumbnailUrl": {
                "description": "A signed URL of the model's card image (WebP), valid for 24 hours; absent when the model has none.",
                "type": "string"
              }
            },
            "required": ["slug", "name", "audience"],
            "additionalProperties": false
          }
        },
        "required": ["models", "empty", "sample"],
        "additionalProperties": false
      },
      "getServiceStatusInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {},
        "additionalProperties": false
      },
      "getServiceStatusOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "status": {
            "type": "string",
            "const": "ok",
            "description": "Always \"ok\" when this call succeeds."
          },
          "buildId": {
            "type": "string",
            "description": "The build identifier currently serving this request (foundation A16)."
          },
          "reportedAt": {
            "type": "string",
            "description": "RFC 3339 UTC timestamp of this check."
          }
        },
        "required": ["status", "buildId", "reportedAt"],
        "additionalProperties": false
      },
      "getSignInMethodsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "email": {
            "type": "string",
            "format": "email",
            "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
          }
        },
        "required": ["email"],
        "additionalProperties": false
      },
      "getSignInMethodsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "methods": {
            "minItems": 1,
            "type": "array",
            "items": {
              "type": "string",
              "enum": ["google", "microsoft", "password", "emailLink"]
            }
          }
        },
        "required": ["methods"],
        "additionalProperties": false
      },
      "getSpatialTreeInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId"],
        "additionalProperties": false
      },
      "getSpatialTreeOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "nodes": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "globalId": { "type": "string" },
                "ifcClass": {
                  "type": "string",
                  "description": "e.g. `IfcSite`, `IfcBuildingStorey`."
                },
                "name": { "type": ["string", "null"] },
                "longName": { "type": "string" },
                "elevationMm": {
                  "description": "Storeys only, in mm.",
                  "type": "number"
                },
                "parentId": {
                  "description": "GlobalId of the node this one is decomposed from; null for the root.",
                  "type": ["string", "null"]
                }
              },
              "required": ["globalId", "ifcClass", "name", "parentId"],
              "additionalProperties": false
            },
            "description": "The spatial decomposition, depth first, parents before their children."
          },
          "levels": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "globalId": { "type": "string" },
                "name": { "type": ["string", "null"] },
                "elevationMm": { "type": ["number", "null"] },
                "elementCount": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991,
                  "description": "Elements on this storey (directly, through a space or an assembly)."
                }
              },
              "required": ["globalId", "name", "elevationMm", "elementCount"],
              "additionalProperties": false
            },
            "description": "Every storey by ascending elevation (one without an elevation last)."
          },
          "zones": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "globalId": { "type": "string" },
                "name": { "type": ["string", "null"] },
                "spaceIds": { "type": "array", "items": { "type": "string" } }
              },
              "required": ["globalId", "name", "spaceIds"],
              "additionalProperties": false
            }
          }
        },
        "required": ["nodes", "levels", "zones"],
        "additionalProperties": false
      },
      "getTryoutInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "getTryoutOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "source": {
            "type": "object",
            "properties": {
              "page": {
                "type": "string",
                "enum": ["site_try", "direct", "mail"],
                "description": "Where the visitor started: site_try (the try page on field-viewer.com), direct (/try opened directly) or mail."
              },
              "locale": { "type": "string", "enum": ["nl", "en", "fr"] },
              "utm": {
                "description": "The campaign parameters of the try page, if any.",
                "type": "object",
                "properties": {
                  "source": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 100
                  },
                  "medium": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 100
                  },
                  "campaign": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 100
                  },
                  "term": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 100
                  },
                  "content": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 100
                  }
                },
                "additionalProperties": false
              }
            },
            "required": ["page", "locale"],
            "additionalProperties": false
          },
          "research": {
            "type": "object",
            "properties": {
              "status": {
                "type": "string",
                "enum": ["not_asked", "declined", "consented", "withdrawn"]
              },
              "decidedAt": {
                "type": "string",
                "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))$"
              },
              "legalVersion": { "type": "string", "minLength": 1 },
              "withdrawnAt": {
                "type": "string",
                "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))$"
              },
              "copiedAt": {
                "type": "string",
                "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))$"
              },
              "objectPath": { "type": "string", "minLength": 1 }
            },
            "required": ["status"],
            "additionalProperties": false
          }
        },
        "required": ["organizationId", "expiresAt", "source", "research"],
        "additionalProperties": false
      },
      "getUsageSummaryInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "getUsageSummaryOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "planId": {
            "type": "string",
            "enum": ["beta", "free", "team", "enterprise", "internal", "tryout"]
          },
          "plan": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "enum": [
                  "beta",
                  "free",
                  "team",
                  "enterprise",
                  "internal",
                  "tryout"
                ]
              },
              "name": {
                "description": "The plan's name per language, from the plan catalogue. Absent for the legacy beta plan.",
                "type": "object",
                "properties": {
                  "nl": { "type": "string", "minLength": 1 },
                  "en": { "type": "string", "minLength": 1 },
                  "fr": { "type": "string", "minLength": 1 }
                },
                "required": ["nl", "en", "fr"],
                "additionalProperties": false
              }
            },
            "required": ["id"],
            "additionalProperties": false
          },
          "planSource": {
            "type": "string",
            "enum": ["default", "billing", "platform", "migration"],
            "description": "Who last set the plan: default (the plan a new organisation starts on), billing, platform or migration."
          },
          "resources": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "resource": {
                  "type": "string",
                  "enum": [
                    "seats",
                    "guests",
                    "workstations",
                    "projects",
                    "storageBytes",
                    "processingMinutesPerMonth",
                    "apiTokens"
                  ]
                },
                "used": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991,
                  "description": "Current usage; 0 when nothing has been counted yet. Bytes for `storageBytes`, minutes this month for `processingMinutesPerMonth`."
                },
                "limit": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "resetsAt": {
                  "description": "Only for a monthly resource (`processingMinutesPerMonth`): when its usage resets, the 1st of next month at 00:00 UTC.",
                  "type": "string",
                  "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))$"
                }
              },
              "required": ["resource", "used", "limit"],
              "additionalProperties": false
            },
            "description": "One row per organisation-wide limit whose usage is measured. A limit whose counter is not built yet is left out, and appears once it is counted."
          },
          "fileLimits": {
            "type": "object",
            "properties": {
              "maxModelFileBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 1073741824,
                "description": "Largest single model file, in bytes, for direct upload and URL import. Never above 1 GiB (BR-10)."
              },
              "maxDocumentFileBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991,
                "description": "Largest single drawing file (PDF, DXF, DWG), in bytes. The format's own ceiling still applies on top."
              },
              "maxModelsPerProject": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991,
                "description": "Most models (IFC) in one project."
              },
              "maxDocumentsPerProject": {
                "description": "Most drawings in one project. Absent: no limit.",
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "maxModelFileBytes",
              "maxDocumentFileBytes",
              "maxModelsPerProject"
            ],
            "additionalProperties": false,
            "description": "FV-718: the organisation's effective per-item limits (an active override applied)."
          },
          "owners": {
            "type": "array",
            "items": { "type": "string", "minLength": 1 },
            "description": "The organisation's active owners, by display name (their e-mail address when they have none), whom to ask for a larger plan."
          },
          "asOf": {
            "type": "string",
            "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))$",
            "description": "When these numbers were read."
          }
        },
        "required": [
          "planId",
          "plan",
          "planSource",
          "resources",
          "fileLimits",
          "owners",
          "asOf"
        ],
        "additionalProperties": false
      },
      "getViewInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "viewId": {
            "type": "string",
            "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A vw identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "viewId"],
        "additionalProperties": false
      },
      "getViewOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A vw identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "The view's name, 1-80 characters."
          },
          "description": {
            "type": "string",
            "maxLength": 280,
            "description": "Optional note, max 280 characters."
          },
          "scope": { "type": "string", "enum": ["personal", "shared"] },
          "ownerUid": { "type": "string", "minLength": 1 },
          "isProjectDefault": {
            "description": "true on the project's default view (at most one shared view per project); absent otherwise.",
            "type": "boolean",
            "const": true
          },
          "order": {
            "description": "A shared view's place in the project's list (0 first); absent until the list is reordered.",
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "state": {
            "type": "object",
            "properties": {
              "schemaVersion": { "type": "number", "const": 1 },
              "camera": {
                "type": "object",
                "properties": {
                  "position": {
                    "type": "object",
                    "properties": {
                      "x": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "y": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "z": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      }
                    },
                    "required": ["x", "y", "z"],
                    "additionalProperties": false
                  },
                  "target": {
                    "type": "object",
                    "properties": {
                      "x": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "y": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "z": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      }
                    },
                    "required": ["x", "y", "z"],
                    "additionalProperties": false
                  },
                  "up": { "type": "string", "const": "z" },
                  "fovDeg": { "type": "number", "minimum": 20, "maximum": 90 },
                  "orthoHeightM": { "type": "number", "exclusiveMinimum": 0 }
                },
                "required": ["position", "target", "up"],
                "additionalProperties": false
              },
              "visibility": {
                "type": "object",
                "properties": {
                  "hiddenRefs": {
                    "maxItems": 5000,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "globalId": { "type": "string", "minLength": 1 },
                        "modelId": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        }
                      },
                      "required": ["globalId"],
                      "additionalProperties": false
                    }
                  },
                  "isolateRefs": {
                    "maxItems": 5000,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "globalId": { "type": "string", "minLength": 1 },
                        "modelId": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        }
                      },
                      "required": ["globalId"],
                      "additionalProperties": false
                    }
                  },
                  "ghost": { "type": "boolean" },
                  "isolateSource": { "type": "string", "const": "storey" }
                },
                "required": ["hiddenRefs", "isolateRefs", "ghost"],
                "additionalProperties": false
              },
              "section": {
                "type": "object",
                "properties": {
                  "axis": { "type": "string", "enum": ["x", "y", "z"] },
                  "offsetMm": { "type": "number" },
                  "flipped": { "type": "boolean" }
                },
                "required": ["axis", "offsetMm", "flipped"],
                "additionalProperties": false
              },
              "layerSetRef": {
                "type": "object",
                "properties": {
                  "layerSetId": {
                    "type": "string",
                    "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A lys identifier (TypeID, conventions C5)."
                  },
                  "overrides": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": { "type": "boolean" }
                  }
                },
                "required": ["layerSetId", "overrides"],
                "additionalProperties": false
              },
              "selection": {
                "maxItems": 50,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "globalId": { "type": "string", "minLength": 1 },
                    "modelId": {
                      "type": "string",
                      "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A mdl identifier (TypeID, conventions C5)."
                    }
                  },
                  "required": ["globalId"],
                  "additionalProperties": false
                }
              },
              "activeTool": { "type": "string", "minLength": 1 },
              "theme": { "type": "string", "enum": ["sunlight", "dim"] },
              "storeyFocusId": { "type": "string" },
              "splitView": {
                "type": "object",
                "properties": {
                  "active": { "type": "boolean" },
                  "ratio": { "type": "number", "minimum": 0.1, "maximum": 0.9 },
                  "primaryPane": {
                    "type": "string",
                    "enum": ["model", "document"]
                  },
                  "document": {
                    "type": "object",
                    "properties": {
                      "documentId": {
                        "type": "string",
                        "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                        "description": "A doc identifier (TypeID, conventions C5)."
                      },
                      "page": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 9007199254740991
                      },
                      "zoom": { "type": "number", "exclusiveMinimum": 0 },
                      "panPct": {
                        "type": "object",
                        "properties": {
                          "x": { "type": "number" },
                          "y": { "type": "number" }
                        },
                        "required": ["x", "y"],
                        "additionalProperties": false
                      },
                      "cad": {
                        "description": "FV-497: a CAD sheet's view -- the drawing point at the pane's centre (drawing units) and the scale in CSS px per drawing unit.",
                        "type": "object",
                        "properties": {
                          "center": {
                            "type": "object",
                            "properties": {
                              "x": { "type": "number" },
                              "y": { "type": "number" }
                            },
                            "required": ["x", "y"],
                            "additionalProperties": false
                          },
                          "scale": { "type": "number", "exclusiveMinimum": 0 }
                        },
                        "required": ["center", "scale"],
                        "additionalProperties": false
                      }
                    },
                    "required": ["documentId", "page"],
                    "additionalProperties": false
                  },
                  "fullscreenPane": {
                    "type": "string",
                    "enum": ["model", "document"]
                  }
                },
                "required": ["active", "ratio", "primaryPane"],
                "additionalProperties": false
              },
              "filter": {
                "description": "FV-473: the filter terms behind the hidden and isolate sets, and the built-in layers (panels, loose parts) that are off.",
                "type": "object",
                "properties": {
                  "terms": {
                    "maxItems": 20,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "mode": { "type": "string", "enum": ["only", "hide"] },
                        "key": {
                          "type": "string",
                          "enum": [
                            "search",
                            "class",
                            "type",
                            "material",
                            "layer",
                            "panel",
                            "storey",
                            "property",
                            "elements"
                          ]
                        },
                        "value": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 500
                        },
                        "name": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 200
                        },
                        "set": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 200
                        }
                      },
                      "required": ["mode", "key", "value"],
                      "additionalProperties": false
                    }
                  },
                  "builtInOff": {
                    "maxItems": 2,
                    "type": "array",
                    "items": { "type": "string", "enum": ["panels", "loose"] }
                  }
                },
                "required": ["terms"],
                "additionalProperties": false
              }
            },
            "required": [
              "schemaVersion",
              "camera",
              "visibility",
              "selection",
              "activeTool",
              "theme"
            ],
            "additionalProperties": false,
            "description": "A full ViewState v1 (E05 §4.2): camera, visibility, section, layerSetRef, selection, activeTool, theme, storeyFocusId, splitView, filter."
          },
          "originOffsetMm": {
            "type": "array",
            "prefixItems": [
              { "type": "number" },
              { "type": "number" },
              { "type": "number" }
            ],
            "items": false,
            "minItems": 3,
            "maxItems": 3,
            "description": "The scene's origin offset in millimetres the state's camera and section are relative to."
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "thumbnail": {
            "type": "object",
            "properties": {
              "contentType": {
                "type": "string",
                "enum": ["image/webp", "image/png"],
                "description": "image/webp or image/png."
              },
              "sizeBytes": {
                "type": "integer",
                "minimum": 1,
                "maximum": 1048576,
                "description": "The image size in bytes (max 1048576)."
              }
            },
            "required": ["contentType", "sizeBytes"],
            "additionalProperties": false
          },
          "thumbnailUrl": {
            "description": "Signed URL of the thumbnail (15 minutes). Absent while the image has not been uploaded.",
            "type": "object",
            "properties": {
              "url": { "type": "string" },
              "expiresAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["url", "expiresAt"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "name",
          "scope",
          "state",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "getWorkstationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "workstationId": {
            "type": "string",
            "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A wks identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "workstationId"],
        "additionalProperties": false
      },
      "getWorkstationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A wks identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": { "type": "string", "minLength": 1 },
          "assignedProjectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "projectIds": {
            "default": [],
            "maxItems": 20,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          "status": {
            "type": "string",
            "enum": ["unpaired", "active", "revoked"]
          },
          "blocked": { "type": "boolean" },
          "pairedAt": {
            "type": "string",
            "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))$"
          },
          "lastSeenAt": {
            "type": "string",
            "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))$"
          },
          "revokedAt": {
            "type": "string",
            "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))$"
          },
          "revokedBy": { "type": "string", "minLength": 1 },
          "preset": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "mode": { "type": "string", "const": "fixed" },
                  "projectId": {
                    "type": "string",
                    "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A prj identifier (TypeID, conventions C5)."
                  },
                  "modelPolicy": {
                    "type": "string",
                    "const": "latest_published"
                  },
                  "viewId": {
                    "type": "string",
                    "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A vw identifier (TypeID, conventions C5)."
                  },
                  "toolbarConfig": {
                    "maxItems": 7,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^[a-z][a-zA-Z0-9-]{0,39}$"
                    }
                  },
                  "lockedSettings": {
                    "type": "object",
                    "properties": {
                      "allowProjectSwitch": { "type": "boolean" },
                      "allowShare": { "type": "boolean" },
                      "theme": {
                        "type": "string",
                        "enum": ["sunlight", "dim"]
                      },
                      "idleResetMinutes": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 120
                      }
                    },
                    "required": [
                      "allowProjectSwitch",
                      "allowShare",
                      "idleResetMinutes"
                    ],
                    "additionalProperties": false
                  }
                },
                "required": [
                  "mode",
                  "projectId",
                  "modelPolicy",
                  "lockedSettings"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "mode": { "type": "string", "const": "crew" },
                  "projectIds": {
                    "minItems": 1,
                    "maxItems": 20,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A prj identifier (TypeID, conventions C5)."
                    }
                  },
                  "modelPolicy": {
                    "type": "string",
                    "const": "latest_published"
                  },
                  "viewId": {
                    "type": "string",
                    "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A vw identifier (TypeID, conventions C5)."
                  },
                  "toolbarConfig": {
                    "maxItems": 7,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^[a-z][a-zA-Z0-9-]{0,39}$"
                    }
                  },
                  "lockedSettings": {
                    "type": "object",
                    "properties": {
                      "allowProjectSwitch": { "type": "boolean" },
                      "allowShare": { "type": "boolean" },
                      "theme": {
                        "type": "string",
                        "enum": ["sunlight", "dim"]
                      },
                      "idleResetMinutes": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 120
                      }
                    },
                    "required": [
                      "allowProjectSwitch",
                      "allowShare",
                      "idleResetMinutes"
                    ],
                    "additionalProperties": false
                  }
                },
                "required": [
                  "mode",
                  "projectIds",
                  "modelPolicy",
                  "lockedSettings"
                ],
                "additionalProperties": false
              }
            ]
          },
          "runtime": {
            "type": "object",
            "properties": {
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "currentProjectId": {
                "type": "string",
                "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A prj identifier (TypeID, conventions C5)."
              },
              "appVersion": {
                "type": "string",
                "minLength": 1,
                "maxLength": 64
              },
              "state": { "type": "string", "enum": ["ready", "error"] }
            },
            "required": ["heartbeatAt"],
            "additionalProperties": false
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "name",
          "projectIds",
          "status",
          "blocked",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "grantOrganizationDiscountInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "The discount's name, e.g. 'case study'. The organisation sees only the resulting price."
          },
          "discount": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "type": { "type": "string", "const": "percent" },
                  "value": {
                    "type": "number",
                    "exclusiveMinimum": 0,
                    "maximum": 100
                  }
                },
                "required": ["type", "value"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "type": { "type": "string", "const": "amount_off" },
                  "cents": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["type", "cents"],
                "additionalProperties": false
              }
            ]
          },
          "duration": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "months": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["months"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "forever": { "type": "boolean", "const": true }
                },
                "required": ["forever"],
                "additionalProperties": false
              }
            ]
          },
          "note": { "type": "string", "minLength": 1, "maxLength": 500 },
          "applyToCurrentSubscription": {
            "description": "Also put the discount on the organisation's running subscription now. Default: only new Checkouts get it.",
            "type": "boolean"
          }
        },
        "required": ["organizationId", "name", "discount", "duration"],
        "additionalProperties": false
      },
      "grantOrganizationDiscountOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "discount": {
            "type": "object",
            "properties": {
              "id": { "type": "string", "minLength": 1 },
              "name": { "type": "string", "minLength": 1 },
              "kind": { "type": "string", "enum": ["organization", "code"] },
              "planIds": {
                "minItems": 1,
                "type": "array",
                "items": {
                  "type": "string",
                  "enum": ["free", "team", "enterprise", "internal", "tryout"]
                }
              },
              "discount": {
                "oneOf": [
                  {
                    "type": "object",
                    "properties": {
                      "type": { "type": "string", "const": "percent" },
                      "value": {
                        "type": "number",
                        "exclusiveMinimum": 0,
                        "maximum": 100
                      }
                    },
                    "required": ["type", "value"],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "type": { "type": "string", "const": "amount_off" },
                      "cents": {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 9007199254740991
                      }
                    },
                    "required": ["type", "cents"],
                    "additionalProperties": false
                  }
                ]
              },
              "duration": {
                "anyOf": [
                  {
                    "type": "object",
                    "properties": {
                      "months": {
                        "type": "integer",
                        "exclusiveMinimum": 0,
                        "maximum": 9007199254740991
                      }
                    },
                    "required": ["months"],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "forever": { "type": "boolean", "const": true }
                    },
                    "required": ["forever"],
                    "additionalProperties": false
                  }
                ]
              },
              "organizationId": { "type": "string", "minLength": 1 },
              "codePrefix": { "type": "string", "minLength": 1 },
              "status": { "type": "string", "enum": ["active", "ended"] },
              "startsAt": {
                "type": "string",
                "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))$"
              },
              "updatedAt": {
                "type": "string",
                "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))$"
              },
              "updatedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              },
              "revision": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "endsAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": [
              "id",
              "name",
              "kind",
              "planIds",
              "discount",
              "duration",
              "status",
              "startsAt",
              "updatedAt",
              "revision"
            ],
            "additionalProperties": false
          },
          "price": {
            "description": "What the organisation now pays (the lowest of its active discounts; they never stack).",
            "type": "object",
            "properties": {
              "currency": { "type": "string", "const": "EUR" },
              "list": {
                "type": "object",
                "properties": {
                  "monthlyCents": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "yearlyCents": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["monthlyCents", "yearlyCents"],
                "additionalProperties": false,
                "description": "The list price, excl. VAT."
              },
              "current": {
                "type": "object",
                "properties": {
                  "monthlyCents": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "yearlyCents": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["monthlyCents", "yearlyCents"],
                "additionalProperties": false,
                "description": "What this caller pays now, excl. VAT: the list price, or the list price after its organisation's discount."
              },
              "discount": {
                "description": "The discount behind `current`; never sent to an anonymous caller.",
                "type": "object",
                "properties": {
                  "id": { "type": "string" },
                  "name": { "type": "string" },
                  "endsAt": {
                    "type": "string",
                    "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))$"
                  }
                },
                "required": ["id", "name"],
                "additionalProperties": false
              },
              "revision": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": ["currency", "list", "current", "revision"],
            "additionalProperties": false
          },
          "appliedToSubscription": { "type": "boolean" }
        },
        "required": ["discount", "appliedToSubscription"],
        "additionalProperties": false
      },
      "leaveOrganizationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "leaveOrganizationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "minLength": 1,
            "description": "Same value as `uid`."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "uid": {
            "type": "string",
            "minLength": 1,
            "description": "The member's Firebase Auth uid."
          },
          "role": {
            "type": "string",
            "enum": ["owner", "admin", "publisher", "member", "guest"]
          },
          "status": {
            "type": "string",
            "enum": ["active", "invited", "suspended", "removed"]
          },
          "blocked": { "type": "boolean" },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          }
        },
        "required": [
          "id",
          "organizationId",
          "uid",
          "role",
          "status",
          "blocked",
          "createdAt",
          "updatedAt",
          "revision"
        ],
        "additionalProperties": false
      },
      "listAnnotationsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: createdAt | -createdAt.",
            "type": "string",
            "enum": ["createdAt", "-createdAt"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "subtype": {
            "description": "Only annotations of this subtype.",
            "type": "string",
            "enum": ["measurement"]
          },
          "visibility": {
            "description": "Only personal (your own private ones) or only shared annotations.",
            "type": "string",
            "enum": ["personal", "shared"]
          },
          "documentId": {
            "description": "Only measurements taken on this drawing (document).",
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
          }
        },
        "required": ["organizationId", "projectId"],
        "additionalProperties": false
      },
      "listAnnotationsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^ann_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A ann identifier (TypeID, conventions C5)."
                },
                "subtype": { "type": "string", "enum": ["measurement"] },
                "visibility": {
                  "type": "string",
                  "enum": ["personal", "shared"]
                },
                "label": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 60,
                  "description": "User-given name, 1-60 chars after trimming."
                },
                "measurement": {
                  "type": "object",
                  "properties": {
                    "kind": {
                      "type": "string",
                      "enum": [
                        "distance",
                        "edgeLength",
                        "angle",
                        "areaFace",
                        "perpendicularPointFace",
                        "perpendicularFaceFace",
                        "areaPolygon",
                        "overallDimensions"
                      ]
                    },
                    "valueMm": { "type": "number", "minimum": 0 },
                    "valueDeg": {
                      "type": "number",
                      "minimum": 0,
                      "maximum": 180
                    },
                    "valueM2": { "type": "number", "minimum": 0 },
                    "tessellated": { "type": "boolean" },
                    "slopeReference": {
                      "description": "For a slope (an angle with one anchor): what its edge or face is measured against.",
                      "type": "string",
                      "enum": ["horizontal", "vertical"]
                    },
                    "inPlane": {
                      "description": "For a distance, edge length or angle measured in a view: the view's normal and the value in its plane.",
                      "type": "object",
                      "properties": {
                        "normal": {
                          "type": "object",
                          "properties": {
                            "x": { "type": "number" },
                            "y": { "type": "number" },
                            "z": { "type": "number" }
                          },
                          "required": ["x", "y", "z"],
                          "additionalProperties": false,
                          "description": "The view's unit normal (towards the viewer) in the version's coordinates."
                        },
                        "valueMm": {
                          "description": "A distance's length in the view plane, millimetres.",
                          "type": "number",
                          "minimum": 0
                        },
                        "valueDeg": {
                          "description": "An angle as the view showed it, degrees.",
                          "type": "number",
                          "minimum": 0,
                          "maximum": 180
                        }
                      },
                      "required": ["normal"],
                      "additionalProperties": false
                    },
                    "basis": {
                      "description": "For a drawing measurement: real (read at the drawing's scale) or paper (millimetres on the sheet, no scale). Absent means real.",
                      "type": "string",
                      "enum": ["real", "paper"]
                    },
                    "dimensions": {
                      "minItems": 1,
                      "maxItems": 3,
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "name": {
                            "type": "string",
                            "enum": ["length", "width", "height", "thickness"]
                          },
                          "valueMm": { "type": "number", "minimum": 0 }
                        },
                        "required": ["name", "valueMm"],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": ["kind", "tessellated"],
                  "additionalProperties": false
                },
                "needsCheck": {
                  "type": "object",
                  "properties": {
                    "reason": {
                      "type": "string",
                      "enum": [
                        "geometry_changed",
                        "element_missing",
                        "drawing_changed"
                      ]
                    },
                    "since": {
                      "type": "string",
                      "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))$"
                    }
                  },
                  "required": ["reason", "since"],
                  "additionalProperties": false
                },
                "drawing": {
                  "type": "object",
                  "properties": {
                    "documentId": {
                      "type": "string",
                      "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A doc identifier (TypeID, conventions C5)."
                    },
                    "documentVersionId": {
                      "type": "string",
                      "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A dvr identifier (TypeID, conventions C5)."
                    },
                    "page": {
                      "type": "integer",
                      "minimum": 1,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["documentId", "documentVersionId", "page"],
                  "additionalProperties": false
                },
                "createdBy": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                },
                "createdAt": {
                  "type": "string",
                  "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))$"
                },
                "updatedAt": {
                  "type": "string",
                  "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))$"
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listApiTokensInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: name | -name | createdAt | -createdAt.",
            "type": "string",
            "enum": ["name", "-name", "createdAt", "-createdAt"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "listApiTokensOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^tok_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A tok identifier (TypeID, conventions C5)."
                },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "name": { "type": "string", "minLength": 1 },
                "ownerUid": { "type": "string", "minLength": 1 },
                "scopes": {
                  "type": "array",
                  "items": { "type": "string", "minLength": 1 }
                },
                "status": { "type": "string", "enum": ["active", "revoked"] },
                "tokenPrefix": { "type": "string", "minLength": 1 },
                "previousSecretGraceUntil": {
                  "type": "string",
                  "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))$"
                },
                "expiresAt": {
                  "type": "string",
                  "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))$"
                },
                "lastUsedAt": {
                  "type": "string",
                  "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))$"
                },
                "revokedAt": {
                  "type": "string",
                  "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))$"
                },
                "schemaVersion": { "type": "number", "const": 1 },
                "createdAt": {
                  "type": "string",
                  "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))$"
                },
                "updatedAt": {
                  "type": "string",
                  "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))$"
                },
                "revision": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "createdBy": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listAuditEventsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: -occurredAt.",
            "type": "string",
            "enum": ["-occurredAt"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "type": {
            "description": "Only events of these types, comma-separated (max 10), e.g. `member.roleChanged,member.removed`. A denied attempt has the type `<type>.denied`.",
            "type": "string",
            "pattern": "^[a-zA-Z0-9._]+(,[a-zA-Z0-9._]+)*$"
          },
          "actor": {
            "description": "Only events by this actor id (a `usr_`/`tok_`/`wks_` id, as in `actor.id`).",
            "type": "string",
            "minLength": 1,
            "maxLength": 128
          },
          "occurredAfter": {
            "description": "Only events at or after this instant (RFC 3339).",
            "type": "string",
            "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))$"
          },
          "occurredBefore": {
            "description": "Only events before this instant (RFC 3339).",
            "type": "string",
            "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))$"
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "listAuditEventsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^adt_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A adt identifier (TypeID, conventions C5)."
                },
                "type": {
                  "type": "string",
                  "minLength": 1,
                  "description": "The business event, e.g. `project.created`; `<type>.denied` for a refused attempt."
                },
                "outcome": { "type": "string", "enum": ["success", "denied"] },
                "actor": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "minLength": 1,
                      "description": "user | apiToken | workstation | oauth | platformAdmin | service | anonymous."
                    },
                    "id": { "type": "string", "minLength": 1 },
                    "idHash": { "type": "string", "minLength": 1 }
                  },
                  "required": ["type"],
                  "additionalProperties": false
                },
                "target": {
                  "type": "object",
                  "properties": {
                    "type": { "type": "string", "minLength": 1 },
                    "id": { "type": "string", "minLength": 1 }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "occurredAt": {
                  "type": "string",
                  "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))$"
                },
                "requestId": { "type": "string", "minLength": 1 },
                "correlationId": { "type": "string", "minLength": 1 },
                "metadata": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": {},
                  "description": "Redacted facts about the command (ids only, at most 2 KB)."
                },
                "truncated": { "type": "boolean", "const": true }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listBetaAccessCodesInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: createdAt | -createdAt.",
            "type": "string",
            "enum": ["createdAt", "-createdAt"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          }
        },
        "additionalProperties": false
      },
      "listBetaAccessCodesOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": { "type": "string", "description": "The bac_ TypeID." },
                "boundEmail": {
                  "type": "string",
                  "format": "email",
                  "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
                },
                "maxRedemptions": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "redeemedCount": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "consumedOrgId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "status": {
                  "type": "string",
                  "enum": ["active", "revoked", "exhausted"]
                },
                "expiresAt": {
                  "type": "string",
                  "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))$"
                },
                "createdAt": {
                  "type": "string",
                  "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))$"
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listDocumentVersionsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: -versionNumber | versionNumber.",
            "type": "string",
            "enum": ["-versionNumber", "versionNumber"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "documentId"],
        "additionalProperties": false
      },
      "listDocumentVersionsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A dvr identifier (TypeID, conventions C5)."
                },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "projectId": {
                  "type": "string",
                  "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A prj identifier (TypeID, conventions C5)."
                },
                "documentId": {
                  "type": "string",
                  "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A doc identifier (TypeID, conventions C5)."
                },
                "versionNumber": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "uploading",
                    "uploaded",
                    "processing",
                    "ready",
                    "failed",
                    "archived",
                    "cancelled"
                  ]
                },
                "publication": {
                  "type": "string",
                  "enum": ["draft", "published", "superseded"]
                },
                "fieldVisible": { "type": "boolean" },
                "source": {
                  "oneOf": [
                    {
                      "type": "object",
                      "properties": {
                        "kind": { "type": "string", "const": "upload" },
                        "format": {
                          "type": "string",
                          "enum": ["pdf", "dxf", "dwg"],
                          "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                        },
                        "fileName": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 255,
                          "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                        },
                        "sizeBytes": {
                          "type": "integer",
                          "minimum": 1,
                          "maximum": 1073741824,
                          "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                        },
                        "contentType": { "type": "string", "minLength": 1 },
                        "sha256": {
                          "type": "string",
                          "pattern": "^[0-9a-f]{64}$",
                          "description": "Optional SHA-256 of the source file, 64 hex chars."
                        }
                      },
                      "required": [
                        "kind",
                        "fileName",
                        "sizeBytes",
                        "contentType"
                      ],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "kind": { "type": "string", "const": "url" },
                        "format": {
                          "type": "string",
                          "enum": ["pdf", "dxf", "dwg"],
                          "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                        },
                        "url": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 2048,
                          "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                        },
                        "fileName": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 255,
                          "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                        },
                        "sizeBytes": {
                          "type": "integer",
                          "minimum": 1,
                          "maximum": 1073741824,
                          "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                        },
                        "contentType": { "type": "string", "minLength": 1 },
                        "sha256": {
                          "type": "string",
                          "pattern": "^[0-9a-f]{64}$",
                          "description": "Optional SHA-256 of the source file, 64 hex chars."
                        }
                      },
                      "required": ["kind", "url", "fileName", "contentType"],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "kind": { "type": "string", "const": "copy" },
                        "format": {
                          "type": "string",
                          "enum": ["pdf", "dxf", "dwg"],
                          "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                        },
                        "sourceVersionId": {
                          "type": "string",
                          "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A dvr identifier (TypeID, conventions C5)."
                        },
                        "fileName": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 255,
                          "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                        },
                        "sizeBytes": {
                          "type": "integer",
                          "minimum": 1,
                          "maximum": 1073741824,
                          "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                        },
                        "contentType": { "type": "string", "minLength": 1 },
                        "sha256": {
                          "type": "string",
                          "pattern": "^[0-9a-f]{64}$",
                          "description": "Optional SHA-256 of the source file, 64 hex chars."
                        }
                      },
                      "required": [
                        "kind",
                        "sourceVersionId",
                        "fileName",
                        "sizeBytes",
                        "contentType"
                      ],
                      "additionalProperties": false
                    }
                  ]
                },
                "upload": {
                  "type": "object",
                  "properties": {
                    "method": { "type": "string", "const": "PUT" },
                    "url": { "type": "string" },
                    "headers": {
                      "type": "object",
                      "propertyNames": { "type": "string" },
                      "additionalProperties": { "type": "string" }
                    },
                    "expiresAt": {
                      "type": "string",
                      "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))$"
                    },
                    "maxBytes": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    },
                    "resumable": { "type": "boolean", "const": true },
                    "chunkSizeBytes": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": [
                    "method",
                    "url",
                    "headers",
                    "expiresAt",
                    "maxBytes",
                    "resumable",
                    "chunkSizeBytes"
                  ],
                  "additionalProperties": false
                },
                "cancelReason": { "type": "string", "enum": ["user"] },
                "pipelineVersion": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "warnings": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "code": { "type": "string" },
                      "blocking": { "type": "boolean" },
                      "params": {
                        "type": "object",
                        "propertyNames": { "type": "string" },
                        "additionalProperties": {}
                      }
                    },
                    "required": ["code"],
                    "additionalProperties": false
                  }
                },
                "progress": {
                  "type": "object",
                  "properties": {
                    "stage": { "type": "string", "minLength": 1 },
                    "percent": {
                      "type": "number",
                      "minimum": 0,
                      "maximum": 100
                    }
                  },
                  "required": ["stage", "percent"],
                  "additionalProperties": false
                },
                "failure": {
                  "type": "object",
                  "properties": {
                    "code": { "type": "string", "minLength": 1 },
                    "retryable": { "type": "boolean" },
                    "params": {
                      "type": "object",
                      "propertyNames": { "type": "string" },
                      "additionalProperties": {}
                    },
                    "messageKey": { "type": "string", "minLength": 1 },
                    "supportRef": { "type": "string", "minLength": 1 }
                  },
                  "required": ["code", "retryable"],
                  "additionalProperties": false
                },
                "activeArtifactSet": {
                  "type": "object",
                  "properties": {
                    "path": { "type": "string", "minLength": 1 },
                    "pipelineVersion": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    },
                    "startedAt": {
                      "type": "string",
                      "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))$"
                    },
                    "files": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "name": { "type": "string", "minLength": 1 },
                          "sizeBytes": {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          }
                        },
                        "required": ["name", "sizeBytes"],
                        "additionalProperties": false
                      }
                    },
                    "totalBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "contractVersion": {
                      "type": "string",
                      "pattern": "^\\d+\\.\\d+$"
                    }
                  },
                  "required": ["path", "pipelineVersion", "startedAt", "files"],
                  "additionalProperties": false
                },
                "reprocessing": {
                  "type": "object",
                  "properties": {
                    "requestedAt": {
                      "type": "string",
                      "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))$"
                    },
                    "requestedBy": { "type": "string", "minLength": 1 },
                    "attempt": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    },
                    "reason": {
                      "type": "string",
                      "enum": ["retry", "pipeline_upgrade"]
                    },
                    "targetPipelineVersion": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    },
                    "state": {
                      "type": "string",
                      "enum": [
                        "requested",
                        "deferred",
                        "awaiting_rollout",
                        "done",
                        "failed"
                      ]
                    },
                    "completedAt": {
                      "type": "string",
                      "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))$"
                    },
                    "failure": {
                      "type": "object",
                      "properties": {
                        "code": { "type": "string", "minLength": 1 },
                        "retryable": { "type": "boolean" },
                        "params": {
                          "type": "object",
                          "propertyNames": { "type": "string" },
                          "additionalProperties": {}
                        },
                        "messageKey": { "type": "string", "minLength": 1 },
                        "supportRef": { "type": "string", "minLength": 1 }
                      },
                      "required": ["code", "retryable"],
                      "additionalProperties": false
                    }
                  },
                  "required": ["requestedAt", "requestedBy", "attempt"],
                  "additionalProperties": false
                },
                "pageCount": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "pages": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "pageNumber": {
                        "type": "integer",
                        "exclusiveMinimum": 0,
                        "maximum": 9007199254740991
                      },
                      "scanned": { "type": "boolean" },
                      "sheetNumber": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 100,
                        "description": "Sheet number, e.g. \"W-101\" (BR-11)."
                      },
                      "title": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 200,
                        "description": "Sheet title, e.g. from the PDF outline (BR-11)."
                      },
                      "discipline": {
                        "type": "string",
                        "enum": [
                          "architecture",
                          "structure",
                          "mechanical",
                          "electrical",
                          "plumbing",
                          "fire_protection",
                          "civil",
                          "landscape",
                          "general"
                        ]
                      },
                      "storeyId": { "type": "string", "minLength": 1 },
                      "overridden": {
                        "type": "array",
                        "items": {
                          "type": "string",
                          "enum": ["sheetNumber", "title", "discipline"]
                        }
                      },
                      "layout": {
                        "type": "object",
                        "properties": {
                          "name": { "type": "string", "minLength": 1 },
                          "kind": {
                            "type": "string",
                            "enum": ["model", "paper"]
                          }
                        },
                        "required": ["name", "kind"],
                        "additionalProperties": false
                      },
                      "titleBlock": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 64
                        },
                        "additionalProperties": {
                          "type": "string",
                          "maxLength": 200
                        },
                        "description": "FV-490 (E13 §4.4): a CAD page's primary title block, attribute tag -> value (<= 32 entries, values <= 200 chars)."
                      },
                      "scale": {
                        "type": "object",
                        "properties": {
                          "factor": {
                            "type": "number",
                            "exclusiveMinimum": 0,
                            "maximum": 10000,
                            "description": "Real millimetres per paper millimetre (1:50 is 50)."
                          },
                          "source": {
                            "type": "string",
                            "enum": ["calibration", "label"],
                            "description": "calibration: two points and a known length; label: the title-block scale, confirmed."
                          },
                          "basis": {
                            "description": "For a calibration: the two points (fractions of the page) and the real length in mm.",
                            "type": "object",
                            "properties": {
                              "a": {
                                "type": "object",
                                "properties": {
                                  "xPct": {
                                    "type": "number",
                                    "minimum": 0,
                                    "maximum": 1
                                  },
                                  "yPct": {
                                    "type": "number",
                                    "minimum": 0,
                                    "maximum": 1
                                  }
                                },
                                "required": ["xPct", "yPct"],
                                "additionalProperties": false
                              },
                              "b": {
                                "type": "object",
                                "properties": {
                                  "xPct": {
                                    "type": "number",
                                    "minimum": 0,
                                    "maximum": 1
                                  },
                                  "yPct": {
                                    "type": "number",
                                    "minimum": 0,
                                    "maximum": 1
                                  }
                                },
                                "required": ["xPct", "yPct"],
                                "additionalProperties": false
                              },
                              "lengthMm": {
                                "type": "number",
                                "exclusiveMinimum": 0
                              }
                            },
                            "required": ["a", "b", "lengthMm"],
                            "additionalProperties": false
                          },
                          "setBy": { "type": "string", "minLength": 1 },
                          "setAt": {
                            "type": "string",
                            "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))$"
                          }
                        },
                        "required": ["factor", "source", "setBy", "setAt"],
                        "additionalProperties": false
                      }
                    },
                    "required": ["pageNumber", "scanned"],
                    "additionalProperties": false
                  }
                },
                "cad": {
                  "type": "object",
                  "properties": {
                    "insunits": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "unitToMm": {
                      "anyOf": [
                        { "type": "number", "exclusiveMinimum": 0 },
                        { "type": "null" }
                      ]
                    },
                    "unitsOverride": {
                      "type": "string",
                      "enum": ["mm", "cm", "m", "in", "ft"],
                      "description": "The drawing's units, set by a publisher because the file declares none: mm, cm, m, in or ft."
                    },
                    "defaultLayersOff": {
                      "maxItems": 256,
                      "type": "array",
                      "items": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 255
                      },
                      "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
                    },
                    "parser": { "type": "string", "const": "acad-ts" },
                    "parserVersion": { "type": "string", "minLength": 1 },
                    "version": { "type": "string", "minLength": 1 },
                    "layoutCount": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": [
                    "insunits",
                    "unitToMm",
                    "parser",
                    "parserVersion",
                    "version",
                    "layoutCount"
                  ],
                  "additionalProperties": false
                },
                "layerDefault": {
                  "type": "object",
                  "properties": {
                    "off": {
                      "maxItems": 256,
                      "type": "array",
                      "items": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 255
                      },
                      "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
                    }
                  },
                  "required": ["off"],
                  "additionalProperties": false,
                  "description": "The layers off by default for everyone who opens this drawing (CAD layers or PDF optional content groups, by name). A person's own choice on their device still wins."
                },
                "publishOnReady": {
                  "description": "Publish this version automatically, in the same write that marks it ready (FV-745).",
                  "type": "boolean"
                },
                "releasedAt": {
                  "type": "string",
                  "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))$"
                },
                "supersededAt": {
                  "type": "string",
                  "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))$"
                },
                "schemaVersion": { "type": "number", "const": 1 },
                "createdAt": {
                  "type": "string",
                  "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))$"
                },
                "updatedAt": {
                  "type": "string",
                  "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))$"
                },
                "revision": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "createdBy": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listDocumentsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: title | -title | updatedAt | -updatedAt.",
            "type": "string",
            "enum": ["title", "-title", "updatedAt", "-updatedAt"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "status": {
            "description": "Which documents to list: active (default, every field list), archived (needs document.upload) or deleted (the 'Recently deleted' view, needs document.delete).",
            "type": "string",
            "enum": ["active", "archived", "deleted"]
          },
          "format": {
            "description": "Only documents of this file format: pdf, dxf or dwg (FV-481). A document without a version yet has no format and is left out.",
            "type": "string",
            "enum": ["pdf", "dxf", "dwg"]
          }
        },
        "required": ["organizationId", "projectId"],
        "additionalProperties": false
      },
      "listDocumentsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A doc identifier (TypeID, conventions C5)."
                },
                "title": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 200,
                  "description": "Document display title (1-200 chars after trimming)."
                },
                "status": {
                  "type": "string",
                  "enum": ["active", "archived", "deleted"]
                },
                "format": { "type": "string", "enum": ["pdf", "dxf", "dwg"] },
                "published": { "type": "boolean" },
                "latestVersion": {
                  "type": "object",
                  "properties": {
                    "id": {
                      "type": "string",
                      "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A dvr identifier (TypeID, conventions C5)."
                    },
                    "number": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    },
                    "status": {
                      "type": "string",
                      "enum": [
                        "uploading",
                        "uploaded",
                        "processing",
                        "ready",
                        "failed",
                        "archived",
                        "cancelled"
                      ]
                    },
                    "publication": {
                      "type": "string",
                      "enum": ["draft", "published", "superseded"]
                    },
                    "pageCount": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    },
                    "sheetNumber": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 100,
                      "description": "Sheet number, e.g. \"W-101\" (BR-11)."
                    },
                    "sheetTitle": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 200,
                      "description": "Sheet title, e.g. from the PDF outline (BR-11)."
                    },
                    "thumbnail": {
                      "description": "Signed GET URL to page 1's thumbnail (webp), present once the version is processed.",
                      "type": "object",
                      "properties": {
                        "url": { "type": "string" },
                        "expiresAt": {
                          "type": "string",
                          "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))$"
                        }
                      },
                      "required": ["url", "expiresAt"],
                      "additionalProperties": false
                    },
                    "failure": {
                      "type": "object",
                      "properties": {
                        "code": { "type": "string", "minLength": 1 },
                        "messageKey": { "type": "string", "minLength": 1 },
                        "retryable": { "type": "boolean" },
                        "supportRef": { "type": "string", "minLength": 1 }
                      },
                      "required": ["code", "messageKey", "retryable"],
                      "additionalProperties": false
                    },
                    "warnings": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "code": { "type": "string", "minLength": 1 },
                          "params": {
                            "type": "object",
                            "propertyNames": { "type": "string" },
                            "additionalProperties": {}
                          }
                        },
                        "required": ["code"],
                        "additionalProperties": false
                      }
                    },
                    "updatedAt": {
                      "type": "string",
                      "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))$"
                    }
                  },
                  "required": ["id", "number", "status", "publication"],
                  "additionalProperties": false
                },
                "updatedAt": {
                  "type": "string",
                  "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))$"
                },
                "archivedAt": {
                  "type": "string",
                  "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))$"
                },
                "deletedAt": {
                  "type": "string",
                  "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))$"
                },
                "purgeAfter": {
                  "description": "When a deleted document is purged for good; restoreDocument works until then.",
                  "type": "string",
                  "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))$"
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listFailedModelVersionsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: -failedAt.",
            "type": "string",
            "enum": ["-failedAt"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "status": {
            "description": "Only `failed` (the default): the versions the pipeline gave up on.",
            "type": "string",
            "const": "failed"
          },
          "organizationId": {
            "description": "Only this organisation's failures.",
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
          }
        },
        "additionalProperties": false
      },
      "listFailedModelVersionsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "The version's id (the list item key, C10); same as `versionId`."
                },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "organizationName": {
                  "description": "Absent when the organisation document is gone.",
                  "type": "string",
                  "minLength": 2,
                  "maxLength": 80
                },
                "projectId": {
                  "type": "string",
                  "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A prj identifier (TypeID, conventions C5)."
                },
                "modelId": {
                  "type": "string",
                  "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A mdl identifier (TypeID, conventions C5)."
                },
                "versionId": {
                  "type": "string",
                  "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A ver identifier (TypeID, conventions C5)."
                },
                "versionNumber": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "sourceKind": {
                  "type": "string",
                  "enum": ["upload", "url", "copy"],
                  "description": "`upload` (PUT by the caller), `url` (imported from a link) or `copy` (sample project)."
                },
                "attempt": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991,
                  "description": "Which processing run failed: 1 for the upload's own run, one more for every reprocess."
                },
                "failedAt": {
                  "type": "string",
                  "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))$",
                  "description": "When the version was last updated, i.e. when it failed."
                },
                "failure": {
                  "type": "object",
                  "properties": {
                    "code": { "type": "string", "minLength": 1 },
                    "retryable": { "type": "boolean" },
                    "params": {
                      "type": "object",
                      "propertyNames": { "type": "string" },
                      "additionalProperties": {}
                    },
                    "messageKey": { "type": "string", "minLength": 1 },
                    "supportRef": { "type": "string", "minLength": 1 }
                  },
                  "required": ["code", "retryable"],
                  "additionalProperties": false
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listInvitationsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: createdAt | -createdAt.",
            "type": "string",
            "enum": ["createdAt", "-createdAt"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "kind": { "type": "string", "enum": ["email", "link"] },
          "status": {
            "type": "string",
            "enum": ["pending", "accepted", "revoked", "expired", "exhausted"]
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "listInvitationsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^inv_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A inv identifier (TypeID, conventions C5)."
                },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "kind": { "type": "string", "enum": ["email", "link"] },
                "role": {
                  "type": "string",
                  "enum": ["admin", "publisher", "member", "guest"]
                },
                "projectIds": {
                  "maxItems": 10,
                  "type": "array",
                  "items": {
                    "type": "string",
                    "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A prj identifier (TypeID, conventions C5)."
                  }
                },
                "email": {
                  "type": "string",
                  "maxLength": 254,
                  "format": "email",
                  "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "pending",
                    "accepted",
                    "revoked",
                    "expired",
                    "exhausted"
                  ]
                },
                "expiresAt": {
                  "type": "string",
                  "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))$"
                },
                "maxUses": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 250
                },
                "useCount": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "resendCount": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "lastSentAt": {
                  "type": "string",
                  "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))$"
                },
                "locale": { "type": "string", "enum": ["nl", "en", "fr"] },
                "acceptedBy": {
                  "maxItems": 250,
                  "type": "array",
                  "items": { "type": "string", "minLength": 1 }
                },
                "acceptedAt": {
                  "type": "string",
                  "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))$"
                },
                "acceptedEmail": { "type": "string" },
                "revokedBy": { "type": "string", "minLength": 1 },
                "revokedAt": {
                  "type": "string",
                  "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))$"
                },
                "schemaVersion": { "type": "number", "const": 1 },
                "createdAt": {
                  "type": "string",
                  "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))$"
                },
                "updatedAt": {
                  "type": "string",
                  "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))$"
                },
                "revision": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "createdBy": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listInvoicesInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: -createdAt.",
            "type": "string",
            "enum": ["-createdAt"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "listInvoicesOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The invoice's id at the provider."
                },
                "number": {
                  "description": "The invoice number printed on it (absent on a draft).",
                  "type": "string"
                },
                "status": {
                  "type": "string",
                  "enum": ["draft", "open", "paid", "uncollectible", "void"]
                },
                "amountDueCents": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "amountPaidCents": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "currency": {
                  "type": "string",
                  "pattern": "^[A-Z]{3}$",
                  "description": "ISO 4217, upper case (EUR)."
                },
                "periodStart": {
                  "type": "string",
                  "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))$"
                },
                "periodEnd": {
                  "type": "string",
                  "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))$"
                },
                "createdAt": {
                  "type": "string",
                  "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))$"
                },
                "hostedInvoiceUrl": {
                  "description": "The provider's page for this invoice (pay or download).",
                  "type": "string",
                  "format": "uri"
                },
                "pdfUrl": {
                  "description": "The invoice as a PDF.",
                  "type": "string",
                  "format": "uri"
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listLayerSetsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: updatedAt | -updatedAt.",
            "type": "string",
            "enum": ["updatedAt", "-updatedAt"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId"],
        "additionalProperties": false
      },
      "listLayerSetsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A lys identifier (TypeID, conventions C5)."
                },
                "status": {
                  "type": "string",
                  "enum": ["ready", "materializing", "failed"]
                },
                "derivationSource": {
                  "type": "string",
                  "enum": [
                    "assignment",
                    "type",
                    "classification",
                    "name-role",
                    "material",
                    "object-type"
                  ]
                },
                "entryCount": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "revision": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "updatedAt": {
                  "type": "string",
                  "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))$"
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listLayerTemplatesInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: name | -name | createdAt | -createdAt.",
            "type": "string",
            "enum": ["name", "-name", "createdAt", "-createdAt"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "listLayerTemplatesOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^ltp_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A ltp identifier (TypeID, conventions C5)."
                },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "name": { "type": "string", "minLength": 1, "maxLength": 60 },
                "layers": {
                  "maxItems": 50,
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "id": {
                        "type": "string",
                        "pattern": "^[a-z0-9][a-z0-9-]{0,39}$"
                      },
                      "displayName": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 60
                      },
                      "colorHex": {
                        "type": "string",
                        "pattern": "^#[0-9a-f]{6}$"
                      },
                      "rule": {
                        "type": "object",
                        "properties": {
                          "source": {
                            "type": "string",
                            "enum": [
                              "property",
                              "name",
                              "material",
                              "ifcClass",
                              "panel"
                            ]
                          },
                          "psetName": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 255
                          },
                          "propName": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 255
                          },
                          "op": {
                            "type": "string",
                            "enum": ["eq", "neq", "contains"]
                          },
                          "value": { "type": "string", "maxLength": 1000 }
                        },
                        "required": ["op", "value"],
                        "additionalProperties": false
                      },
                      "defaultOn": { "type": "boolean" },
                      "hiddenFromField": { "type": "boolean" },
                      "locked": { "type": "boolean" }
                    },
                    "required": [
                      "id",
                      "displayName",
                      "rule",
                      "defaultOn",
                      "hiddenFromField",
                      "locked"
                    ],
                    "additionalProperties": false
                  }
                },
                "applyTo": { "type": "string", "enum": ["all", "chosen"] },
                "projectIds": {
                  "minItems": 1,
                  "maxItems": 400,
                  "type": "array",
                  "items": {
                    "type": "string",
                    "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A prj identifier (TypeID, conventions C5)."
                  }
                },
                "appliedAt": {
                  "type": "string",
                  "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))$"
                },
                "schemaVersion": { "type": "number", "const": 1 },
                "createdAt": {
                  "type": "string",
                  "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))$"
                },
                "updatedAt": {
                  "type": "string",
                  "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))$"
                },
                "revision": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "createdBy": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listLinkRulesInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: priority | -priority | name | -name.",
            "type": "string",
            "enum": ["priority", "-priority", "name", "-name"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "autoApply": {
            "description": "Only rules that run on every new drawing version (true) or only those that do not (false).",
            "type": "string",
            "enum": ["true", "false"]
          }
        },
        "required": ["organizationId", "projectId"],
        "additionalProperties": false
      },
      "listLinkRulesOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A lkr identifier (TypeID, conventions C5)."
                },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "projectId": {
                  "type": "string",
                  "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A prj identifier (TypeID, conventions C5)."
                },
                "name": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 100,
                  "description": "Rule name, 1-100 chars after trimming."
                },
                "enabled": { "type": "boolean" },
                "priority": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 1000
                },
                "matchModel": {
                  "type": "object",
                  "properties": {
                    "field": {
                      "type": "string",
                      "enum": [
                        "tag",
                        "assemblyMark",
                        "storeyName",
                        "name",
                        "property"
                      ]
                    },
                    "property": {
                      "type": "object",
                      "properties": {
                        "set": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 128,
                          "description": "Property set, e.g. Pset_Panel."
                        },
                        "name": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 128,
                          "description": "Property name, e.g. Drawing."
                        }
                      },
                      "required": ["set", "name"],
                      "additionalProperties": false
                    }
                  },
                  "required": ["field"],
                  "additionalProperties": false
                },
                "matchDocument": {
                  "type": "object",
                  "properties": {
                    "field": {
                      "type": "string",
                      "enum": [
                        "fileName",
                        "sheetNumber",
                        "outlineTitle",
                        "titleBlock",
                        "layoutName",
                        "blockAttribute",
                        "sheetText"
                      ]
                    },
                    "attributeTag": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 128
                    }
                  },
                  "required": ["field"],
                  "additionalProperties": false
                },
                "normalization": {
                  "type": "object",
                  "properties": {
                    "caseInsensitive": { "type": "boolean" },
                    "stripWhitespace": { "type": "boolean" },
                    "stripLeadingZeros": { "type": "boolean" },
                    "regex": {
                      "type": "string",
                      "description": "Regular expression applied to both sides after the other normalisation steps: a value that does not match is ignored, otherwise the match (or its named group `key`) is the value compared, e.g. W-\\d{3} (max 200 chars; no backreferences or nested repeats)."
                    }
                  },
                  "required": [
                    "caseInsensitive",
                    "stripWhitespace",
                    "stripLeadingZeros"
                  ],
                  "additionalProperties": false
                },
                "autoApply": { "type": "boolean" },
                "discoveryRunId": {
                  "type": "string",
                  "pattern": "^ldr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A ldr identifier (TypeID, conventions C5)."
                },
                "ambiguousDocumentIds": {
                  "maxItems": 500,
                  "type": "array",
                  "items": {
                    "type": "string",
                    "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A doc identifier (TypeID, conventions C5)."
                  }
                },
                "schemaVersion": { "type": "number", "const": 1 },
                "createdAt": {
                  "type": "string",
                  "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))$"
                },
                "updatedAt": {
                  "type": "string",
                  "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))$"
                },
                "revision": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "createdBy": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listLinksInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: -createdAt | createdAt.",
            "type": "string",
            "enum": ["-createdAt", "createdAt"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "status": {
            "description": "Only active or only stale links.",
            "type": "string",
            "enum": ["active", "stale"]
          },
          "origin": {
            "description": "Only links created by a rule, by hand or by a connector.",
            "type": "string",
            "enum": ["rule", "manual", "connector"]
          },
          "modelId": {
            "description": "Only links from this model.",
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
          },
          "documentId": {
            "description": "Only links to this drawing.",
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
          }
        },
        "required": ["organizationId", "projectId"],
        "additionalProperties": false
      },
      "listLinksOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^lnk_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A lnk identifier (TypeID, conventions C5)."
                },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "projectId": {
                  "type": "string",
                  "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A prj identifier (TypeID, conventions C5)."
                },
                "source": {
                  "oneOf": [
                    {
                      "type": "object",
                      "properties": {
                        "kind": { "type": "string", "const": "element" },
                        "modelId": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        },
                        "globalId": { "type": "string", "minLength": 1 }
                      },
                      "required": ["kind", "modelId", "globalId"],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "kind": { "type": "string", "const": "assembly" },
                        "modelId": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        },
                        "assemblyMark": { "type": "string", "minLength": 1 }
                      },
                      "required": ["kind", "modelId", "assemblyMark"],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "kind": { "type": "string", "const": "storey" },
                        "modelId": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        },
                        "storeyId": { "type": "string", "minLength": 1 }
                      },
                      "required": ["kind", "modelId", "storeyId"],
                      "additionalProperties": false
                    }
                  ]
                },
                "target": {
                  "type": "object",
                  "properties": {
                    "documentId": {
                      "type": "string",
                      "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A doc identifier (TypeID, conventions C5)."
                    },
                    "page": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    },
                    "layoutName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255
                    },
                    "region": {
                      "type": "object",
                      "properties": {
                        "xPct": {
                          "type": "number",
                          "minimum": 0,
                          "maximum": 1
                        },
                        "yPct": {
                          "type": "number",
                          "minimum": 0,
                          "maximum": 1
                        },
                        "wPct": {
                          "type": "number",
                          "minimum": 0,
                          "maximum": 1
                        },
                        "hPct": { "type": "number", "minimum": 0, "maximum": 1 }
                      },
                      "required": ["xPct", "yPct", "wPct", "hPct"],
                      "additionalProperties": false
                    },
                    "cadRegion": {
                      "type": "object",
                      "properties": {
                        "x": { "type": "number" },
                        "y": { "type": "number" },
                        "w": { "type": "number", "exclusiveMinimum": 0 },
                        "h": { "type": "number", "exclusiveMinimum": 0 },
                        "space": {
                          "type": "string",
                          "enum": ["model", "paper"]
                        }
                      },
                      "required": ["x", "y", "w", "h", "space"],
                      "additionalProperties": false
                    },
                    "textRef": {
                      "type": "object",
                      "properties": {
                        "textIndex": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "text": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 200
                        }
                      },
                      "required": ["textIndex", "text"],
                      "additionalProperties": false
                    }
                  },
                  "required": ["documentId", "page"],
                  "additionalProperties": false
                },
                "origin": {
                  "type": "string",
                  "enum": ["rule", "manual", "connector"]
                },
                "ruleId": {
                  "type": "string",
                  "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A lkr identifier (TypeID, conventions C5)."
                },
                "confidence": { "type": "number", "minimum": 0, "maximum": 1 },
                "key": { "type": "string", "minLength": 1 },
                "status": { "type": "string", "enum": ["active", "stale"] },
                "staleSince": {
                  "type": "string",
                  "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))$"
                },
                "staleReason": { "type": "string", "enum": ["page_removed"] },
                "schemaVersion": { "type": "number", "const": 1 },
                "createdAt": {
                  "type": "string",
                  "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))$"
                },
                "updatedAt": {
                  "type": "string",
                  "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))$"
                },
                "revision": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "createdBy": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listMembersInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: createdAt | -createdAt.",
            "type": "string",
            "enum": ["createdAt", "-createdAt"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "listMembersOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "minLength": 1,
                  "description": "Same value as `uid`."
                },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "uid": {
                  "type": "string",
                  "minLength": 1,
                  "description": "The member's Firebase Auth uid."
                },
                "role": {
                  "type": "string",
                  "enum": ["owner", "admin", "publisher", "member", "guest"]
                },
                "status": {
                  "type": "string",
                  "enum": ["active", "invited", "suspended", "removed"]
                },
                "blocked": { "type": "boolean" },
                "createdAt": {
                  "type": "string",
                  "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))$"
                },
                "updatedAt": {
                  "type": "string",
                  "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))$"
                },
                "revision": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "userId": {
                  "type": "string",
                  "pattern": "^usr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "The member's `usr_` id -- the `actor.id` their actions carry in the activity log (`listAuditEvents`)."
                },
                "displayName": {
                  "description": "The member's name, when known (kept after removal).",
                  "type": "string",
                  "minLength": 1
                },
                "email": {
                  "description": "The member's e-mail address, when known (erased on removal).",
                  "type": "string",
                  "minLength": 1
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listMyInvitationsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {},
        "additionalProperties": false
      },
      "listMyInvitationsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "maxItems": 20,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^inv_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A inv identifier (TypeID, conventions C5)."
                },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "organizationName": { "type": "string", "minLength": 1 },
                "role": {
                  "type": "string",
                  "enum": ["admin", "publisher", "member", "guest"]
                },
                "projectIds": {
                  "maxItems": 10,
                  "type": "array",
                  "items": {
                    "type": "string",
                    "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A prj identifier (TypeID, conventions C5)."
                  }
                },
                "expiresAt": {
                  "type": "string",
                  "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))$"
                },
                "inviterDisplayName": { "type": "string", "minLength": 1 }
              },
              "required": [
                "id",
                "organizationId",
                "organizationName",
                "role",
                "projectIds",
                "expiresAt"
              ],
              "additionalProperties": false
            }
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listMyNotificationsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: -createdAt.",
            "type": "string",
            "enum": ["-createdAt"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          }
        },
        "additionalProperties": false
      },
      "listMyNotificationsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^ntf_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A ntf identifier (TypeID, conventions C5)."
                },
                "type": {
                  "type": "string",
                  "enum": ["processing_ready", "processing_failed"]
                },
                "titleKey": {
                  "type": "string",
                  "minLength": 1,
                  "description": "UI message key for the notification's text (notifications.processingReady | notifications.processingFailed)."
                },
                "params": {
                  "type": "object",
                  "properties": {
                    "projectName": { "type": "string", "minLength": 1 },
                    "modelName": { "type": "string", "minLength": 1 },
                    "versionNumber": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["projectName", "modelName", "versionNumber"],
                  "additionalProperties": false
                },
                "linkPath": {
                  "type": "string",
                  "format": "starts_with",
                  "pattern": "^\\/.*",
                  "description": "App-relative path the notification opens: the model version's detail screen."
                },
                "sourceEventId": {
                  "type": "string",
                  "pattern": "^evt_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A evt identifier (TypeID, conventions C5)."
                },
                "createdAt": {
                  "type": "string",
                  "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))$"
                },
                "readAt": {
                  "type": "string",
                  "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))$"
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listMyOAuthGrantsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: createdAt | -createdAt | lastUsedAt | -lastUsedAt.",
            "type": "string",
            "enum": ["createdAt", "-createdAt", "lastUsedAt", "-lastUsedAt"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          }
        },
        "additionalProperties": false
      },
      "listMyOAuthGrantsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^grt_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A grt identifier (TypeID, conventions C5)."
                },
                "uid": { "type": "string", "minLength": 1 },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "clientId": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 512
                },
                "clientName": { "type": "string" },
                "clientHost": { "type": "string", "minLength": 1 },
                "scopes": {
                  "minItems": 1,
                  "type": "array",
                  "items": { "type": "string", "minLength": 1 }
                },
                "resource": { "type": "string", "minLength": 1 },
                "status": {
                  "type": "string",
                  "enum": ["active", "revoked", "expired"]
                },
                "refreshExpiresAt": {
                  "type": "string",
                  "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))$"
                },
                "createdAt": {
                  "type": "string",
                  "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))$"
                },
                "lastUsedAt": {
                  "type": "string",
                  "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))$"
                },
                "revokedAt": {
                  "type": "string",
                  "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))$"
                },
                "revokedReason": {
                  "type": "string",
                  "enum": ["user_revoked", "reuse_detected", "member_removed"]
                },
                "schemaVersion": { "type": "number", "const": 1 },
                "revision": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listMyOrganizationsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: name | -name.",
            "type": "string",
            "enum": ["name", "-name"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          }
        },
        "additionalProperties": false
      },
      "listMyOrganizationsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "name": {
                  "type": "string",
                  "minLength": 1,
                  "description": "The organisation's display name."
                },
                "role": {
                  "type": "string",
                  "enum": ["owner", "admin", "publisher", "member", "guest"],
                  "description": "The caller's role in this organisation."
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listOAuthGrantsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: createdAt | -createdAt | lastUsedAt | -lastUsedAt.",
            "type": "string",
            "enum": ["createdAt", "-createdAt", "lastUsedAt", "-lastUsedAt"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "listOAuthGrantsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^grt_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A grt identifier (TypeID, conventions C5)."
                },
                "uid": { "type": "string", "minLength": 1 },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "clientId": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 512
                },
                "clientName": { "type": "string" },
                "clientHost": { "type": "string", "minLength": 1 },
                "scopes": {
                  "minItems": 1,
                  "type": "array",
                  "items": { "type": "string", "minLength": 1 }
                },
                "resource": { "type": "string", "minLength": 1 },
                "status": {
                  "type": "string",
                  "enum": ["active", "revoked", "expired"]
                },
                "refreshExpiresAt": {
                  "type": "string",
                  "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))$"
                },
                "createdAt": {
                  "type": "string",
                  "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))$"
                },
                "lastUsedAt": {
                  "type": "string",
                  "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))$"
                },
                "revokedAt": {
                  "type": "string",
                  "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))$"
                },
                "revokedReason": {
                  "type": "string",
                  "enum": ["user_revoked", "reuse_detected", "member_removed"]
                },
                "schemaVersion": { "type": "number", "const": 1 },
                "revision": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listOrganizationActivationsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: name.",
            "type": "string",
            "enum": ["name"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "cohort": {
            "description": "Only organisations tagged with exactly this beta cohort, e.g. `wave1`.",
            "type": "string",
            "minLength": 1,
            "maxLength": 100
          }
        },
        "additionalProperties": false
      },
      "listOrganizationActivationsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "name": {
                  "type": "string",
                  "minLength": 2,
                  "maxLength": 80,
                  "description": "Organisation display name (2-80 chars after trimming, BR-10)."
                },
                "cohort": {
                  "description": "The organisation's beta wave tag (e.g. `wave1`), set by a platform admin. Absent when untagged.",
                  "type": "string",
                  "minLength": 1
                },
                "stage": {
                  "type": "string",
                  "enum": [
                    "signed_up",
                    "org_created",
                    "first_project_created",
                    "first_model_published",
                    "first_field_open"
                  ],
                  "description": "The furthest funnel step reached, each step counting only once every earlier one is reached: signed_up -> org_created -> first_project_created (a project other than the onboarding sample) -> first_model_published (a model version of such a project was published) -> first_field_open (a model opened by a member or workstation)."
                },
                "createdAt": {
                  "type": "string",
                  "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))$"
                },
                "lastActiveAt": {
                  "description": "The newest model opened by a member or workstation. Absent when there is none.",
                  "type": "string",
                  "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))$"
                },
                "activeWeeksCount": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 26,
                  "description": "Consecutive ISO calendar weeks (Monday to Sunday, UTC), up to this one, with at least one model opened by a member or workstation. The current week counts once it has activity; until then the streak ends with last week. Capped at 26."
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listPlansInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "includeInternal": {
            "description": "`true` also returns the plans that are not offered publicly (`internal`, `tryout`). Platform admins only.",
            "type": "string",
            "enum": ["true", "false"]
          },
          "includeTryout": {
            "description": "`true` also returns the `tryout` row (the limits of a tryout without an account), as the try page reads its size cap. Open to anyone.",
            "type": "string",
            "enum": ["true", "false"]
          },
          "organizationId": {
            "description": "Returns this organisation's own price (its discount applied) instead of the list price. Owners and admins of the organisation only.",
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
          }
        },
        "additionalProperties": false
      },
      "listPlansOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "enum": ["free", "team", "enterprise", "internal", "tryout"]
                },
                "name": {
                  "type": "object",
                  "properties": {
                    "nl": { "type": "string" },
                    "en": { "type": "string" },
                    "fr": { "type": "string" }
                  },
                  "required": ["nl", "en", "fr"],
                  "additionalProperties": false,
                  "description": "The plan's name in Dutch, English and French."
                },
                "limits": {
                  "type": "object",
                  "properties": {
                    "seats": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "guests": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "workstations": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "projects": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "storageBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "maxModelFileBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 1073741824,
                      "description": "Largest single model file, in bytes, for direct upload and URL import. Never above 1 GiB (BR-10)."
                    },
                    "maxModelsPerProject": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "processingMinutesPerMonth": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "apiTokens": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "maxDocumentFileBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991,
                      "description": "Largest single drawing file (PDF, DXF, DWG), in bytes. The format's own ceiling still applies on top."
                    },
                    "maxDocumentsPerProject": {
                      "description": "Most drawings (documents) in one project. Absent: no limit.",
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "retentionDays": {
                      "anyOf": [
                        {
                          "type": "integer",
                          "exclusiveMinimum": 0,
                          "maximum": 9007199254740991
                        },
                        { "type": "null" }
                      ],
                      "description": "How many days content on this plan is kept before it is deleted, counted from its creation: `7` on `tryout`, `null` on every plan whose content does not expire."
                    }
                  },
                  "required": [
                    "seats",
                    "guests",
                    "workstations",
                    "projects",
                    "storageBytes",
                    "maxModelFileBytes",
                    "maxModelsPerProject",
                    "processingMinutesPerMonth",
                    "apiTokens",
                    "maxDocumentFileBytes",
                    "retentionDays"
                  ],
                  "additionalProperties": false
                },
                "hiddenLimits": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "enum": [
                      "seats",
                      "guests",
                      "workstations",
                      "projects",
                      "storageBytes",
                      "maxModelFileBytes",
                      "maxModelsPerProject",
                      "processingMinutesPerMonth",
                      "apiTokens",
                      "maxDocumentFileBytes",
                      "maxDocumentsPerProject"
                    ]
                  },
                  "description": "Keys in `limits` that are not a difference between plans and are not to be shown: the server holds no one to them (`maxModelsPerProject`: a project has one 3D model, with revisions; `processingMinutesPerMonth`: not counted). They stay in `limits` for older readers."
                },
                "features": {
                  "type": "object",
                  "properties": {
                    "autoDimensions": { "type": "boolean" },
                    "workstationMode": { "type": "boolean" },
                    "auditLogExport": {
                      "type": "boolean",
                      "description": "Whether the activity log can be exported as CSV (`requestAuditLogExport`)."
                    },
                    "sso": {
                      "type": "boolean",
                      "description": "Reserved for single sign-on. Not in use yet."
                    },
                    "cadDrawings": {
                      "type": "boolean",
                      "description": "Whether the plan takes DXF and DWG drawings next to PDF, in this environment: the CAD drawings flag for this plan (its default, or the plan's rollout group). The API's upload rules read the same value. An organisation in a rollout cohort can differ from its plan."
                    }
                  },
                  "required": [
                    "autoDimensions",
                    "workstationMode",
                    "auditLogExport",
                    "sso",
                    "cadDrawings"
                  ],
                  "additionalProperties": false
                },
                "customisable": {
                  "description": "Present on a plan whose limits and price are agreed per organisation (`enterprise`).",
                  "type": "boolean",
                  "const": true
                },
                "price": {
                  "description": "Only on a plan with a published price (`team`): EUR cents, excl. VAT, per month and per year.",
                  "type": "object",
                  "properties": {
                    "currency": { "type": "string", "const": "EUR" },
                    "list": {
                      "type": "object",
                      "properties": {
                        "monthlyCents": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "yearlyCents": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        }
                      },
                      "required": ["monthlyCents", "yearlyCents"],
                      "additionalProperties": false,
                      "description": "The list price, excl. VAT."
                    },
                    "current": {
                      "type": "object",
                      "properties": {
                        "monthlyCents": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "yearlyCents": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        }
                      },
                      "required": ["monthlyCents", "yearlyCents"],
                      "additionalProperties": false,
                      "description": "What this caller pays now, excl. VAT: the list price, or the list price after its organisation's discount."
                    },
                    "discount": {
                      "description": "The discount behind `current`; never sent to an anonymous caller.",
                      "type": "object",
                      "properties": {
                        "id": { "type": "string" },
                        "name": { "type": "string" },
                        "endsAt": {
                          "type": "string",
                          "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))$"
                        }
                      },
                      "required": ["id", "name"],
                      "additionalProperties": false
                    },
                    "revision": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["currency", "list", "current", "revision"],
                  "additionalProperties": false
                },
                "trial": {
                  "description": "Only on a priced plan that can be tried (`team`): the trial an owner starts once per organisation.",
                  "type": "object",
                  "properties": {
                    "days": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991,
                      "description": "How long the trial runs, in days. No card needed."
                    }
                  },
                  "required": ["days"],
                  "additionalProperties": false
                },
                "graceDays": {
                  "description": "Only on a priced plan (`team`): how many days the plan is kept after a failed payment, before the organisation returns to the free plan.",
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                }
              },
              "required": ["id", "name", "limits", "hiddenLimits", "features"],
              "additionalProperties": false
            }
          },
          "asOf": {
            "type": "string",
            "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))$",
            "description": "When this answer was made."
          },
          "revision": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991,
            "description": "Changes whenever anything in this answer changes (the REST ETag). Opaque, not a counter."
          }
        },
        "required": ["data", "asOf", "revision"],
        "additionalProperties": false
      },
      "listPlatformOrganizationsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: name.",
            "type": "string",
            "enum": ["name"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "q": {
            "description": "Part of the organisation's name (case- and accent-insensitive), or its exact id.",
            "type": "string",
            "maxLength": 200
          },
          "planId": {
            "type": "string",
            "enum": ["beta", "free", "team", "enterprise", "internal", "tryout"]
          },
          "orgStatus": { "type": "string", "enum": ["active", "suspended"] }
        },
        "additionalProperties": false
      },
      "listPlatformOrganizationsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "name": {
                  "type": "string",
                  "minLength": 2,
                  "maxLength": 80,
                  "description": "Organisation display name (2-80 chars after trimming, BR-10)."
                },
                "planId": {
                  "type": "string",
                  "enum": [
                    "beta",
                    "free",
                    "team",
                    "enterprise",
                    "internal",
                    "tryout"
                  ]
                },
                "orgStatus": {
                  "type": "string",
                  "enum": ["active", "suspended"],
                  "description": "`suspended` while a platform admin has paused the organisation's writes."
                },
                "createdAt": {
                  "type": "string",
                  "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))$"
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listProjectMembersInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: addedAt | -addedAt.",
            "type": "string",
            "enum": ["addedAt", "-addedAt"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId"],
        "additionalProperties": false
      },
      "listProjectMembersOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "projectId": {
                  "type": "string",
                  "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A prj identifier (TypeID, conventions C5)."
                },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "addedAt": {
                  "type": "string",
                  "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))$"
                },
                "addedBy": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                },
                "id": {
                  "type": "string",
                  "minLength": 1,
                  "description": "The member's uid (user or workstation) -- also this row's Firestore id."
                },
                "displayName": {
                  "description": "The member's name, when known.",
                  "type": "string",
                  "minLength": 1
                },
                "email": {
                  "description": "The member's e-mail address, when known.",
                  "type": "string",
                  "minLength": 1
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listProjectRevisionsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: -number.",
            "type": "string",
            "enum": ["-number"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId"],
        "additionalProperties": false
      },
      "listProjectRevisionsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A ver identifier (TypeID, conventions C5)."
                },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "projectId": {
                  "type": "string",
                  "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A prj identifier (TypeID, conventions C5)."
                },
                "modelId": {
                  "type": "string",
                  "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A mdl identifier (TypeID, conventions C5)."
                },
                "versionNumber": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "status": {
                  "type": "string",
                  "enum": [
                    "uploading",
                    "uploaded",
                    "processing",
                    "ready",
                    "failed",
                    "archived",
                    "cancelled"
                  ]
                },
                "publication": {
                  "type": "string",
                  "enum": ["draft", "published", "superseded"]
                },
                "fieldVisible": { "type": "boolean" },
                "source": {
                  "oneOf": [
                    {
                      "type": "object",
                      "properties": {
                        "kind": { "type": "string", "const": "upload" },
                        "fileName": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 255,
                          "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                        },
                        "sizeBytes": {
                          "type": "integer",
                          "minimum": 1,
                          "maximum": 1073741824,
                          "description": "Declared file size in bytes (BR-24)."
                        },
                        "contentType": { "type": "string", "minLength": 1 },
                        "sha256": {
                          "type": "string",
                          "pattern": "^[0-9a-f]{64}$",
                          "description": "Optional SHA-256 of the source file, 64 hex chars."
                        }
                      },
                      "required": [
                        "kind",
                        "fileName",
                        "sizeBytes",
                        "contentType"
                      ],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "kind": { "type": "string", "const": "copy" },
                        "sourceVersionId": {
                          "type": "string",
                          "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A ver identifier (TypeID, conventions C5)."
                        },
                        "fileName": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 255,
                          "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                        },
                        "sizeBytes": {
                          "type": "integer",
                          "minimum": 1,
                          "maximum": 1073741824,
                          "description": "Declared file size in bytes (BR-24)."
                        },
                        "contentType": { "type": "string", "minLength": 1 },
                        "sha256": {
                          "type": "string",
                          "pattern": "^[0-9a-f]{64}$",
                          "description": "Optional SHA-256 of the source file, 64 hex chars."
                        }
                      },
                      "required": [
                        "kind",
                        "sourceVersionId",
                        "fileName",
                        "sizeBytes",
                        "contentType"
                      ],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "kind": { "type": "string", "const": "url" },
                        "url": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 2048,
                          "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                        },
                        "fileName": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 255,
                          "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                        },
                        "sizeBytes": {
                          "type": "integer",
                          "minimum": 1,
                          "maximum": 1073741824,
                          "description": "Declared file size in bytes (BR-24)."
                        },
                        "contentType": { "type": "string", "minLength": 1 },
                        "sha256": {
                          "type": "string",
                          "pattern": "^[0-9a-f]{64}$",
                          "description": "Optional SHA-256 of the source file, 64 hex chars."
                        }
                      },
                      "required": ["kind", "url", "fileName", "contentType"],
                      "additionalProperties": false
                    }
                  ]
                },
                "upload": {
                  "type": "object",
                  "properties": {
                    "method": { "type": "string", "const": "PUT" },
                    "url": { "type": "string" },
                    "headers": {
                      "type": "object",
                      "propertyNames": { "type": "string" },
                      "additionalProperties": { "type": "string" }
                    },
                    "expiresAt": {
                      "type": "string",
                      "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))$"
                    },
                    "maxBytes": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    },
                    "resumable": { "type": "boolean", "const": true },
                    "chunkSizeBytes": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": [
                    "method",
                    "url",
                    "headers",
                    "expiresAt",
                    "maxBytes",
                    "resumable",
                    "chunkSizeBytes"
                  ],
                  "additionalProperties": false
                },
                "expiresAt": {
                  "type": "string",
                  "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))$"
                },
                "cancelReason": {
                  "type": "string",
                  "enum": ["user", "expired"]
                },
                "pipelineVersion": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "warnings": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "code": { "type": "string" },
                      "blocking": { "type": "boolean" },
                      "params": {
                        "type": "object",
                        "propertyNames": { "type": "string" },
                        "additionalProperties": {}
                      }
                    },
                    "required": ["code"],
                    "additionalProperties": false
                  }
                },
                "failure": {
                  "type": "object",
                  "properties": {
                    "code": { "type": "string", "minLength": 1 },
                    "retryable": { "type": "boolean" },
                    "params": {
                      "type": "object",
                      "propertyNames": { "type": "string" },
                      "additionalProperties": {}
                    },
                    "messageKey": { "type": "string", "minLength": 1 },
                    "supportRef": { "type": "string", "minLength": 1 }
                  },
                  "required": ["code", "retryable"],
                  "additionalProperties": false
                },
                "processing": {
                  "type": "object",
                  "properties": {
                    "sizeClass": {
                      "type": "string",
                      "enum": ["s", "m", "l", "xl"]
                    },
                    "executionName": { "type": "string", "minLength": 1 },
                    "startedAt": {
                      "type": "string",
                      "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))$"
                    },
                    "heartbeatAt": {
                      "type": "string",
                      "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))$"
                    },
                    "queuedAt": {
                      "type": "string",
                      "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))$"
                    },
                    "queuedTraceparent": {
                      "type": "string",
                      "pattern": "^(?!ff)[0-9a-f]{2}-(?!0{32})[0-9a-f]{32}-(?!0{16})[0-9a-f]{16}-[0-9a-f]{2}$"
                    },
                    "queuedEscalation": {
                      "type": "object",
                      "properties": {
                        "sizeClass": {
                          "type": "string",
                          "enum": ["s", "m", "l", "xl"]
                        },
                        "attempt": {
                          "type": "integer",
                          "exclusiveMinimum": 0,
                          "maximum": 9007199254740991
                        }
                      },
                      "required": ["sizeClass", "attempt"],
                      "additionalProperties": false
                    },
                    "attempt": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    },
                    "progressReportedAt": {
                      "type": "string",
                      "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))$"
                    },
                    "requestId": { "type": "string", "minLength": 1 }
                  },
                  "additionalProperties": false
                },
                "progress": {
                  "type": "object",
                  "properties": {
                    "stage": { "type": "string", "minLength": 1 },
                    "percent": {
                      "type": "number",
                      "minimum": 0,
                      "maximum": 100
                    }
                  },
                  "required": ["stage", "percent"],
                  "additionalProperties": false
                },
                "reprocessing": {
                  "type": "object",
                  "properties": {
                    "requestedAt": {
                      "type": "string",
                      "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))$"
                    },
                    "requestedBy": { "type": "string", "minLength": 1 },
                    "attempt": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    },
                    "reason": {
                      "type": "string",
                      "enum": ["retry", "pipeline_upgrade"]
                    },
                    "targetPipelineVersion": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    },
                    "state": {
                      "type": "string",
                      "enum": [
                        "requested",
                        "deferred",
                        "awaiting_rollout",
                        "done",
                        "failed"
                      ]
                    },
                    "completedAt": {
                      "type": "string",
                      "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))$"
                    },
                    "failure": {
                      "type": "object",
                      "properties": {
                        "code": { "type": "string", "minLength": 1 },
                        "retryable": { "type": "boolean" },
                        "params": {
                          "type": "object",
                          "propertyNames": { "type": "string" },
                          "additionalProperties": {}
                        },
                        "messageKey": { "type": "string", "minLength": 1 },
                        "supportRef": { "type": "string", "minLength": 1 }
                      },
                      "required": ["code", "retryable"],
                      "additionalProperties": false
                    }
                  },
                  "required": ["requestedAt", "requestedBy", "attempt"],
                  "additionalProperties": false
                },
                "releasedAt": {
                  "type": "string",
                  "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))$"
                },
                "releasedBy": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                },
                "supersededAt": {
                  "type": "string",
                  "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))$"
                },
                "activeArtifactSet": {
                  "type": "object",
                  "properties": {
                    "path": { "type": "string", "minLength": 1 },
                    "pipelineVersion": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    },
                    "startedAt": {
                      "type": "string",
                      "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))$"
                    },
                    "files": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "name": { "type": "string", "minLength": 1 },
                          "sizeBytes": {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          }
                        },
                        "required": ["name", "sizeBytes"],
                        "additionalProperties": false
                      }
                    },
                    "totalBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "contractVersion": {
                      "type": "string",
                      "pattern": "^\\d+\\.\\d+$"
                    }
                  },
                  "required": ["path", "pipelineVersion", "startedAt", "files"],
                  "additionalProperties": false
                },
                "nextArtifactSet": {
                  "type": "object",
                  "properties": {
                    "path": { "type": "string", "minLength": 1 },
                    "pipelineVersion": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    },
                    "startedAt": {
                      "type": "string",
                      "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))$"
                    },
                    "files": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "name": { "type": "string", "minLength": 1 },
                          "sizeBytes": {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          }
                        },
                        "required": ["name", "sizeBytes"],
                        "additionalProperties": false
                      }
                    },
                    "totalBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "contractVersion": {
                      "type": "string",
                      "pattern": "^\\d+\\.\\d+$"
                    }
                  },
                  "required": ["path", "pipelineVersion", "startedAt", "files"],
                  "additionalProperties": false
                },
                "stats": {
                  "type": "object",
                  "properties": {
                    "elementCount": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "boundsMm": {
                      "type": "object",
                      "properties": {
                        "min": {
                          "type": "array",
                          "prefixItems": [
                            { "type": "number" },
                            { "type": "number" },
                            { "type": "number" }
                          ],
                          "items": false,
                          "minItems": 3,
                          "maxItems": 3
                        },
                        "max": {
                          "type": "array",
                          "prefixItems": [
                            { "type": "number" },
                            { "type": "number" },
                            { "type": "number" }
                          ],
                          "items": false,
                          "minItems": 3,
                          "maxItems": 3
                        }
                      },
                      "required": ["min", "max"],
                      "additionalProperties": false
                    },
                    "coveragePct": {
                      "type": "number",
                      "minimum": 0,
                      "maximum": 100
                    }
                  },
                  "required": ["elementCount", "boundsMm"],
                  "additionalProperties": false
                },
                "churn": {
                  "type": "object",
                  "properties": {
                    "ratio": { "type": "number", "minimum": 0, "maximum": 1 },
                    "added": { "type": "array", "items": { "type": "string" } },
                    "removed": {
                      "type": "array",
                      "items": { "type": "string" }
                    },
                    "moved": { "type": "array", "items": { "type": "string" } },
                    "recreated": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "from": { "type": "string" },
                          "to": { "type": "string" }
                        },
                        "required": ["from", "to"],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "ratio",
                    "added",
                    "removed",
                    "moved",
                    "recreated"
                  ],
                  "additionalProperties": false
                },
                "label": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 40,
                  "description": "Short version name, e.g. \"Roof fix\" (1-40 chars after trimming, BR-10)."
                },
                "notes": {
                  "type": "string",
                  "maxLength": 2000,
                  "description": "Free-form notes for the crew (max 2000 chars, BR-10)."
                },
                "detailsEditedAt": {
                  "type": "string",
                  "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))$"
                },
                "archivedAt": {
                  "type": "string",
                  "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))$"
                },
                "publishOnReady": {
                  "description": "Publish this version automatically, in the same write that marks it ready (FV-383).",
                  "type": "boolean"
                },
                "schemaVersion": { "type": "number", "const": 1 },
                "createdAt": {
                  "type": "string",
                  "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))$"
                },
                "updatedAt": {
                  "type": "string",
                  "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))$"
                },
                "revision": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "createdBy": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                },
                "number": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991,
                  "description": "The revision number within the project (1, 2, 3...)."
                },
                "current": {
                  "type": "boolean",
                  "description": "Whether this is the revision the field sees now."
                },
                "publishedAt": {
                  "description": "When this revision was (last) published; absent for a revision never published.",
                  "type": "string",
                  "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))$"
                },
                "publishedBy": {
                  "description": "Who published it; absent for a revision never published, or published before FV-384 and no longer current.",
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                },
                "publishedByName": {
                  "description": "The publisher's display name, when they are a member.",
                  "type": "string",
                  "minLength": 1
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listProjectsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: updatedAt | -updatedAt.",
            "type": "string",
            "enum": ["updatedAt", "-updatedAt"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "status": {
            "description": "Which projects to list (FV-134): active (default, every field list), archived, or deleted (the 'Recently deleted' view). archived needs project.archive, deleted needs project.delete (owner/admin).",
            "type": "string",
            "enum": ["active", "archived", "deleted"]
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "listProjectsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A prj identifier (TypeID, conventions C5)."
                },
                "name": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 80,
                  "description": "Project display name (1-80 chars after trimming, BR-2)."
                },
                "reference": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 40,
                  "description": "Free-form job/reference code, e.g. \"2026-041\" (BR-2)."
                },
                "updatedAt": {
                  "type": "string",
                  "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))$",
                  "description": "When this project was last updated (RFC 3339 UTC)."
                },
                "isSample": {
                  "description": "Present (true) only on the organisation's onboarding sample project (FV-205) and its demo projects (FV-600).",
                  "type": "boolean",
                  "const": true
                },
                "demoSlug": {
                  "description": "Present only on a demo project the organisation started with (FV-600): which one. Shown as an example project.",
                  "type": "string",
                  "enum": [
                    "landhuis_hulstveld",
                    "landhuis_hulstveld_hsb",
                    "woning_lindehof",
                    "villa_berkenhaag",
                    "hal_noorderkempen",
                    "paneelset_werkplaats"
                  ]
                },
                "lastPublishedAt": {
                  "description": "When a model in this project was last published; absent until the first publish.",
                  "type": "string",
                  "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))$"
                },
                "status": {
                  "type": "string",
                  "enum": ["active", "archived", "deleted"],
                  "description": "Lifecycle status (FV-134): active, archived (read-only) or deleted (restorable until purgeAfter)."
                },
                "archivedAt": {
                  "description": "When the project was archived; present while archived.",
                  "type": "string",
                  "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))$"
                },
                "deletedAt": {
                  "description": "When the project was deleted; present while deleted.",
                  "type": "string",
                  "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))$"
                },
                "purgeAfter": {
                  "description": "When a deleted project is purged for good; restoreProject works until then.",
                  "type": "string",
                  "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))$"
                },
                "access": {
                  "type": "object",
                  "properties": {
                    "mode": {
                      "type": "string",
                      "enum": ["organisation", "restricted"],
                      "description": "organisation: everyone in the organisation can open it; restricted: owners, admins and the project's own members only."
                    },
                    "memberCount": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991,
                      "description": "People who can open the project right now (in organisation mode the org-wide count)."
                    },
                    "pendingInvitationCount": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991,
                      "description": "Pending, unexpired e-mail invitations that would give access to this project."
                    },
                    "preview": {
                      "description": "The first three people, owners and admins first. Absent for a guest caller.",
                      "maxItems": 3,
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "uid": { "type": "string", "minLength": 1 },
                          "displayName": { "type": "string", "minLength": 1 },
                          "initials": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 4,
                            "description": "One or two letters for an avatar without a picture."
                          },
                          "avatarUrl": { "type": "string", "format": "uri" }
                        },
                        "required": ["uid", "displayName", "initials"],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": ["mode", "memberCount", "pendingInvitationCount"],
                  "additionalProperties": false,
                  "description": "Who can open the project, at a glance (FV-380)."
                },
                "currentRevision": {
                  "type": "object",
                  "properties": {
                    "number": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    },
                    "publishedAt": {
                      "type": "string",
                      "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))$"
                    },
                    "publishedBy": {
                      "type": "object",
                      "properties": {
                        "type": {
                          "type": "string",
                          "enum": [
                            "user",
                            "apiToken",
                            "oauth",
                            "workstation",
                            "platformAdmin"
                          ]
                        },
                        "id": { "type": "string" }
                      },
                      "required": ["type", "id"],
                      "additionalProperties": false
                    },
                    "publishedByName": {
                      "description": "The publisher's display name, when they are a member.",
                      "type": "string",
                      "minLength": 1
                    }
                  },
                  "required": ["number", "publishedAt", "publishedBy"],
                  "additionalProperties": false,
                  "description": "The project's current (published) revision; absent until the first publish (FV-384)."
                },
                "latestRevision": {
                  "type": "object",
                  "properties": {
                    "number": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    },
                    "status": {
                      "type": "string",
                      "enum": [
                        "uploading",
                        "uploaded",
                        "processing",
                        "ready",
                        "failed",
                        "archived",
                        "cancelled"
                      ]
                    }
                  },
                  "required": ["number", "status"],
                  "additionalProperties": false,
                  "description": "The project's newest revision and its processing status; absent with no revision yet (FV-384)."
                },
                "thumbnail": {
                  "type": "object",
                  "properties": {
                    "url": {
                      "type": "string",
                      "format": "uri",
                      "description": "Short-lived signed GET URL to the current revision's thumbnail (512 x 512 WebP)."
                    },
                    "expiresAt": {
                      "type": "string",
                      "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))$",
                      "description": "When `url` stops working (RFC 3339 UTC)."
                    },
                    "cacheKey": {
                      "type": "string",
                      "minLength": 1,
                      "description": "Stable identity of this exact image: it changes only when a new image is published, so a client may keep the bytes under it (offline)."
                    },
                    "dark": {
                      "type": "object",
                      "properties": {
                        "url": {
                          "type": "string",
                          "format": "uri",
                          "description": "Short-lived signed GET URL to the current revision's thumbnail (512 x 512 WebP)."
                        },
                        "expiresAt": {
                          "type": "string",
                          "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))$",
                          "description": "When `url` stops working (RFC 3339 UTC)."
                        },
                        "cacheKey": {
                          "type": "string",
                          "minLength": 1,
                          "description": "Stable identity of this exact image: it changes only when a new image is published, so a client may keep the bytes under it (offline)."
                        }
                      },
                      "required": ["url", "expiresAt", "cacheKey"],
                      "additionalProperties": false,
                      "description": "The same thumbnail drawn in the dim theme's colours; absent for revisions processed before it existed -- show the light image then (FV-436)."
                    }
                  },
                  "required": ["url", "expiresAt", "cacheKey"],
                  "additionalProperties": false,
                  "description": "The project's current revision as a thumbnail; absent before the first publish, while it has no thumbnail (processing failed to draw one), or when it cannot be signed (FV-132)."
                },
                "drawingCount": {
                  "description": "How many drawings (active documents with a published version) the field sees in the project (FV-771). Returned by listProjects; absent elsewhere, and when the count could not be read -- the list never fails for it.",
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listRolesInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: rank | -rank.",
            "type": "string",
            "enum": ["rank", "-rank"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          }
        },
        "additionalProperties": false
      },
      "listRolesOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "description": "The role key: owner, admin, publisher, member, guest or workstation."
                },
                "rank": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991,
                  "description": "§2.3's rank (owner 100 · admin 80 · publisher 60 · member 40 · guest 20; workstation 0, a device principal never ranked against an org role)."
                },
                "labelKey": {
                  "type": "string",
                  "description": "i18n key for this role's display label."
                },
                "capabilities": {
                  "type": "array",
                  "items": { "type": "string" },
                  "description": "Every capability id this role's §2.3 matrix column grants."
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listSamplesInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "locale": {
            "description": "The language of `name` and `audience` (nl, en or fr); the request's Accept-Language, else Dutch, when omitted.",
            "type": "string",
            "enum": ["nl", "en", "fr"]
          }
        },
        "additionalProperties": false
      },
      "listSamplesOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "slug": {
                  "type": "string",
                  "enum": [
                    "landhuis_hulstveld",
                    "landhuis_hulstveld_hsb",
                    "woning_lindehof",
                    "villa_berkenhaag",
                    "hal_noorderkempen",
                    "paneelset_werkplaats"
                  ],
                  "description": "The sample's id, e.g. `woning_lindehof` (the demo project it is)."
                },
                "name": {
                  "type": "string",
                  "description": "The sample's name."
                },
                "audience": {
                  "type": "string",
                  "description": "One line on who it is for, in the asked language (e.g. timber frame)."
                },
                "thumbnailUrl": {
                  "description": "A signed URL of the model's card image (WebP), valid for 24 hours; absent when the model has none.",
                  "type": "string"
                }
              },
              "required": ["slug", "name", "audience"],
              "additionalProperties": false
            }
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listSupportAccessInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: -startedAt.",
            "type": "string",
            "enum": ["-startedAt"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "listSupportAccessOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": { "type": "string", "minLength": 1 },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "uid": {
                  "type": "string",
                  "minLength": 1,
                  "description": "The platform admin's user id."
                },
                "reason": { "type": "string" },
                "status": {
                  "type": "string",
                  "enum": ["active", "ended", "expired"]
                },
                "startedAt": {
                  "type": "string",
                  "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))$"
                },
                "expiresAt": {
                  "type": "string",
                  "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))$"
                },
                "endedAt": {
                  "type": "string",
                  "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))$"
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listSupportAccessRequestsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: -requestedAt.",
            "type": "string",
            "enum": ["-requestedAt"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "listSupportAccessRequestsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": { "type": "string", "minLength": 1 },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "uid": {
                  "type": "string",
                  "minLength": 1,
                  "description": "The platform admin's user id."
                },
                "reason": { "type": "string" },
                "durationMinutes": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "status": {
                  "type": "string",
                  "enum": ["pending", "approved", "denied", "used", "expired"]
                },
                "requestedAt": {
                  "type": "string",
                  "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))$"
                },
                "expiresAt": {
                  "type": "string",
                  "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))$"
                },
                "decidedAt": {
                  "type": "string",
                  "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))$"
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listViewsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: createdAt | -createdAt | name.",
            "type": "string",
            "enum": ["createdAt", "-createdAt", "name"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId"],
        "additionalProperties": false
      },
      "listViewsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A vw identifier (TypeID, conventions C5)."
                },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "projectId": {
                  "type": "string",
                  "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A prj identifier (TypeID, conventions C5)."
                },
                "name": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 80,
                  "description": "The view's name, 1-80 characters."
                },
                "description": {
                  "type": "string",
                  "maxLength": 280,
                  "description": "Optional note, max 280 characters."
                },
                "scope": { "type": "string", "enum": ["personal", "shared"] },
                "ownerUid": { "type": "string", "minLength": 1 },
                "isProjectDefault": {
                  "description": "true on the project's default view (at most one shared view per project); absent otherwise.",
                  "type": "boolean",
                  "const": true
                },
                "order": {
                  "description": "A shared view's place in the project's list (0 first); absent until the list is reordered.",
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "state": {
                  "type": "object",
                  "properties": {
                    "schemaVersion": { "type": "number", "const": 1 },
                    "camera": {
                      "type": "object",
                      "properties": {
                        "position": {
                          "type": "object",
                          "properties": {
                            "x": {
                              "type": "number",
                              "minimum": -100000,
                              "maximum": 100000
                            },
                            "y": {
                              "type": "number",
                              "minimum": -100000,
                              "maximum": 100000
                            },
                            "z": {
                              "type": "number",
                              "minimum": -100000,
                              "maximum": 100000
                            }
                          },
                          "required": ["x", "y", "z"],
                          "additionalProperties": false
                        },
                        "target": {
                          "type": "object",
                          "properties": {
                            "x": {
                              "type": "number",
                              "minimum": -100000,
                              "maximum": 100000
                            },
                            "y": {
                              "type": "number",
                              "minimum": -100000,
                              "maximum": 100000
                            },
                            "z": {
                              "type": "number",
                              "minimum": -100000,
                              "maximum": 100000
                            }
                          },
                          "required": ["x", "y", "z"],
                          "additionalProperties": false
                        },
                        "up": { "type": "string", "const": "z" },
                        "fovDeg": {
                          "type": "number",
                          "minimum": 20,
                          "maximum": 90
                        },
                        "orthoHeightM": {
                          "type": "number",
                          "exclusiveMinimum": 0
                        }
                      },
                      "required": ["position", "target", "up"],
                      "additionalProperties": false
                    },
                    "visibility": {
                      "type": "object",
                      "properties": {
                        "hiddenRefs": {
                          "maxItems": 5000,
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "globalId": { "type": "string", "minLength": 1 },
                              "modelId": {
                                "type": "string",
                                "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                "description": "A mdl identifier (TypeID, conventions C5)."
                              }
                            },
                            "required": ["globalId"],
                            "additionalProperties": false
                          }
                        },
                        "isolateRefs": {
                          "maxItems": 5000,
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "globalId": { "type": "string", "minLength": 1 },
                              "modelId": {
                                "type": "string",
                                "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                "description": "A mdl identifier (TypeID, conventions C5)."
                              }
                            },
                            "required": ["globalId"],
                            "additionalProperties": false
                          }
                        },
                        "ghost": { "type": "boolean" },
                        "isolateSource": { "type": "string", "const": "storey" }
                      },
                      "required": ["hiddenRefs", "isolateRefs", "ghost"],
                      "additionalProperties": false
                    },
                    "section": {
                      "type": "object",
                      "properties": {
                        "axis": { "type": "string", "enum": ["x", "y", "z"] },
                        "offsetMm": { "type": "number" },
                        "flipped": { "type": "boolean" }
                      },
                      "required": ["axis", "offsetMm", "flipped"],
                      "additionalProperties": false
                    },
                    "layerSetRef": {
                      "type": "object",
                      "properties": {
                        "layerSetId": {
                          "type": "string",
                          "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A lys identifier (TypeID, conventions C5)."
                        },
                        "overrides": {
                          "type": "object",
                          "propertyNames": { "type": "string" },
                          "additionalProperties": { "type": "boolean" }
                        }
                      },
                      "required": ["layerSetId", "overrides"],
                      "additionalProperties": false
                    },
                    "selection": {
                      "maxItems": 50,
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "globalId": { "type": "string", "minLength": 1 },
                          "modelId": {
                            "type": "string",
                            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                            "description": "A mdl identifier (TypeID, conventions C5)."
                          }
                        },
                        "required": ["globalId"],
                        "additionalProperties": false
                      }
                    },
                    "activeTool": { "type": "string", "minLength": 1 },
                    "theme": { "type": "string", "enum": ["sunlight", "dim"] },
                    "storeyFocusId": { "type": "string" },
                    "splitView": {
                      "type": "object",
                      "properties": {
                        "active": { "type": "boolean" },
                        "ratio": {
                          "type": "number",
                          "minimum": 0.1,
                          "maximum": 0.9
                        },
                        "primaryPane": {
                          "type": "string",
                          "enum": ["model", "document"]
                        },
                        "document": {
                          "type": "object",
                          "properties": {
                            "documentId": {
                              "type": "string",
                              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                              "description": "A doc identifier (TypeID, conventions C5)."
                            },
                            "page": {
                              "type": "integer",
                              "minimum": 1,
                              "maximum": 9007199254740991
                            },
                            "zoom": { "type": "number", "exclusiveMinimum": 0 },
                            "panPct": {
                              "type": "object",
                              "properties": {
                                "x": { "type": "number" },
                                "y": { "type": "number" }
                              },
                              "required": ["x", "y"],
                              "additionalProperties": false
                            },
                            "cad": {
                              "description": "FV-497: a CAD sheet's view -- the drawing point at the pane's centre (drawing units) and the scale in CSS px per drawing unit.",
                              "type": "object",
                              "properties": {
                                "center": {
                                  "type": "object",
                                  "properties": {
                                    "x": { "type": "number" },
                                    "y": { "type": "number" }
                                  },
                                  "required": ["x", "y"],
                                  "additionalProperties": false
                                },
                                "scale": {
                                  "type": "number",
                                  "exclusiveMinimum": 0
                                }
                              },
                              "required": ["center", "scale"],
                              "additionalProperties": false
                            }
                          },
                          "required": ["documentId", "page"],
                          "additionalProperties": false
                        },
                        "fullscreenPane": {
                          "type": "string",
                          "enum": ["model", "document"]
                        }
                      },
                      "required": ["active", "ratio", "primaryPane"],
                      "additionalProperties": false
                    },
                    "filter": {
                      "description": "FV-473: the filter terms behind the hidden and isolate sets, and the built-in layers (panels, loose parts) that are off.",
                      "type": "object",
                      "properties": {
                        "terms": {
                          "maxItems": 20,
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "mode": {
                                "type": "string",
                                "enum": ["only", "hide"]
                              },
                              "key": {
                                "type": "string",
                                "enum": [
                                  "search",
                                  "class",
                                  "type",
                                  "material",
                                  "layer",
                                  "panel",
                                  "storey",
                                  "property",
                                  "elements"
                                ]
                              },
                              "value": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 500
                              },
                              "name": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 200
                              },
                              "set": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 200
                              }
                            },
                            "required": ["mode", "key", "value"],
                            "additionalProperties": false
                          }
                        },
                        "builtInOff": {
                          "maxItems": 2,
                          "type": "array",
                          "items": {
                            "type": "string",
                            "enum": ["panels", "loose"]
                          }
                        }
                      },
                      "required": ["terms"],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "schemaVersion",
                    "camera",
                    "visibility",
                    "selection",
                    "activeTool",
                    "theme"
                  ],
                  "additionalProperties": false,
                  "description": "A full ViewState v1 (E05 §4.2): camera, visibility, section, layerSetRef, selection, activeTool, theme, storeyFocusId, splitView, filter."
                },
                "originOffsetMm": {
                  "type": "array",
                  "prefixItems": [
                    { "type": "number" },
                    { "type": "number" },
                    { "type": "number" }
                  ],
                  "items": false,
                  "minItems": 3,
                  "maxItems": 3,
                  "description": "The scene's origin offset in millimetres the state's camera and section are relative to."
                },
                "schemaVersion": { "type": "number", "const": 1 },
                "createdAt": {
                  "type": "string",
                  "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))$"
                },
                "updatedAt": {
                  "type": "string",
                  "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))$"
                },
                "revision": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "createdBy": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                },
                "thumbnail": {
                  "type": "object",
                  "properties": {
                    "contentType": {
                      "type": "string",
                      "enum": ["image/webp", "image/png"],
                      "description": "image/webp or image/png."
                    },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 1,
                      "maximum": 1048576,
                      "description": "The image size in bytes (max 1048576)."
                    }
                  },
                  "required": ["contentType", "sizeBytes"],
                  "additionalProperties": false
                },
                "thumbnailUrl": {
                  "description": "Signed URL of the thumbnail (15 minutes). Absent while the image has not been uploaded.",
                  "type": "object",
                  "properties": {
                    "url": { "type": "string" },
                    "expiresAt": {
                      "type": "string",
                      "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))$"
                    }
                  },
                  "required": ["url", "expiresAt"],
                  "additionalProperties": false
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "listWorkstationsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "limit": {
            "description": "Max items per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque pagination cursor from a previous page's nextCursor.",
            "type": "string",
            "minLength": 1
          },
          "sort": {
            "description": "Sort order: name | -name | createdAt | -createdAt.",
            "type": "string",
            "enum": ["name", "-name", "createdAt", "-createdAt"]
          },
          "fields": {
            "description": "Comma-separated top-level field names to project. 'id' is always included.",
            "type": "string",
            "minLength": 1
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "listWorkstationsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A wks identifier (TypeID, conventions C5)."
                },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "name": { "type": "string", "minLength": 1 },
                "assignedProjectId": {
                  "type": "string",
                  "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A prj identifier (TypeID, conventions C5)."
                },
                "projectIds": {
                  "default": [],
                  "maxItems": 20,
                  "type": "array",
                  "items": {
                    "type": "string",
                    "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A prj identifier (TypeID, conventions C5)."
                  }
                },
                "status": {
                  "type": "string",
                  "enum": ["unpaired", "active", "revoked"]
                },
                "blocked": { "type": "boolean" },
                "pairedAt": {
                  "type": "string",
                  "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))$"
                },
                "lastSeenAt": {
                  "type": "string",
                  "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))$"
                },
                "revokedAt": {
                  "type": "string",
                  "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))$"
                },
                "revokedBy": { "type": "string", "minLength": 1 },
                "preset": {
                  "oneOf": [
                    {
                      "type": "object",
                      "properties": {
                        "mode": { "type": "string", "const": "fixed" },
                        "projectId": {
                          "type": "string",
                          "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A prj identifier (TypeID, conventions C5)."
                        },
                        "modelPolicy": {
                          "type": "string",
                          "const": "latest_published"
                        },
                        "viewId": {
                          "type": "string",
                          "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A vw identifier (TypeID, conventions C5)."
                        },
                        "toolbarConfig": {
                          "maxItems": 7,
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "^[a-z][a-zA-Z0-9-]{0,39}$"
                          }
                        },
                        "lockedSettings": {
                          "type": "object",
                          "properties": {
                            "allowProjectSwitch": { "type": "boolean" },
                            "allowShare": { "type": "boolean" },
                            "theme": {
                              "type": "string",
                              "enum": ["sunlight", "dim"]
                            },
                            "idleResetMinutes": {
                              "type": "integer",
                              "minimum": 1,
                              "maximum": 120
                            }
                          },
                          "required": [
                            "allowProjectSwitch",
                            "allowShare",
                            "idleResetMinutes"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "required": [
                        "mode",
                        "projectId",
                        "modelPolicy",
                        "lockedSettings"
                      ],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "mode": { "type": "string", "const": "crew" },
                        "projectIds": {
                          "minItems": 1,
                          "maxItems": 20,
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                            "description": "A prj identifier (TypeID, conventions C5)."
                          }
                        },
                        "modelPolicy": {
                          "type": "string",
                          "const": "latest_published"
                        },
                        "viewId": {
                          "type": "string",
                          "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A vw identifier (TypeID, conventions C5)."
                        },
                        "toolbarConfig": {
                          "maxItems": 7,
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "^[a-z][a-zA-Z0-9-]{0,39}$"
                          }
                        },
                        "lockedSettings": {
                          "type": "object",
                          "properties": {
                            "allowProjectSwitch": { "type": "boolean" },
                            "allowShare": { "type": "boolean" },
                            "theme": {
                              "type": "string",
                              "enum": ["sunlight", "dim"]
                            },
                            "idleResetMinutes": {
                              "type": "integer",
                              "minimum": 1,
                              "maximum": 120
                            }
                          },
                          "required": [
                            "allowProjectSwitch",
                            "allowShare",
                            "idleResetMinutes"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "required": [
                        "mode",
                        "projectIds",
                        "modelPolicy",
                        "lockedSettings"
                      ],
                      "additionalProperties": false
                    }
                  ]
                },
                "runtime": {
                  "type": "object",
                  "properties": {
                    "heartbeatAt": {
                      "type": "string",
                      "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))$"
                    },
                    "currentProjectId": {
                      "type": "string",
                      "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A prj identifier (TypeID, conventions C5)."
                    },
                    "appVersion": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 64
                    },
                    "state": { "type": "string", "enum": ["ready", "error"] }
                  },
                  "required": ["heartbeatAt"],
                  "additionalProperties": false
                },
                "schemaVersion": { "type": "number", "const": 1 },
                "createdAt": {
                  "type": "string",
                  "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))$"
                },
                "updatedAt": {
                  "type": "string",
                  "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))$"
                },
                "revision": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "createdBy": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                }
              },
              "required": ["id"],
              "additionalProperties": false
            },
            "description": "This page of results (the resource's summary schema, C10)."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "markNotificationReadInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ntf_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ntf identifier (TypeID, conventions C5)."
          }
        },
        "required": ["id"],
        "additionalProperties": false
      },
      "markNotificationReadOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ntf_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ntf identifier (TypeID, conventions C5)."
          },
          "type": {
            "type": "string",
            "enum": ["processing_ready", "processing_failed"]
          },
          "titleKey": {
            "type": "string",
            "minLength": 1,
            "description": "UI message key for the notification's text (notifications.processingReady | notifications.processingFailed)."
          },
          "params": {
            "type": "object",
            "properties": {
              "projectName": { "type": "string", "minLength": 1 },
              "modelName": { "type": "string", "minLength": 1 },
              "versionNumber": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": ["projectName", "modelName", "versionNumber"],
            "additionalProperties": false
          },
          "linkPath": {
            "type": "string",
            "format": "starts_with",
            "pattern": "^\\/.*",
            "description": "App-relative path the notification opens: the model version's detail screen."
          },
          "sourceEventId": {
            "type": "string",
            "pattern": "^evt_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A evt identifier (TypeID, conventions C5)."
          },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "readAt": {
            "type": "string",
            "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))$"
          }
        },
        "required": [
          "id",
          "type",
          "titleKey",
          "params",
          "linkPath",
          "sourceEventId",
          "createdAt"
        ],
        "additionalProperties": false
      },
      "previewLayerRuleInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "rule": {
            "description": "The rule to count, as updateLayerSet takes it. Omit it to only list the properties.",
            "type": "object",
            "properties": {
              "source": {
                "description": "What the rule tests: `property` (the default) a property value (`psetName`, `propName`); `name` the element name, `material` its material, `ifcClass` its IFC class, `panel` the name or tag of the panel (`IfcElementAssembly`) it is part of -- these four take no psetName/propName, are counted on the device and work offline.",
                "type": "string",
                "enum": ["property", "name", "material", "ifcClass", "panel"]
              },
              "psetName": {
                "type": "string",
                "minLength": 1,
                "maxLength": 255,
                "description": "Property (or quantity) set name exactly as in the model, e.g. `Pset_WallCommon`. Property rules only."
              },
              "propName": {
                "type": "string",
                "minLength": 1,
                "maxLength": 255,
                "description": "Property name exactly as in the model, e.g. `IsExternal`. Property rules only."
              },
              "op": {
                "type": "string",
                "enum": ["eq", "neq", "contains"],
                "description": "`eq` equals, `neq` differs from (elements without the property never match), `contains` contains the value."
              },
              "value": {
                "type": "string",
                "maxLength": 1000,
                "description": "Text to compare; case, accents and surrounding spaces are ignored. Booleans read `true`/`false`; a number also matches numerically (`0,24` = `0.24`). For name, material, ifcClass and panel rules several values may be separated by commas (any matches), and an empty value with eq/contains matches every element that has one (e.g. part of any panel)."
              }
            },
            "required": ["op", "value"],
            "additionalProperties": false
          },
          "includeProperties": {
            "description": "`true`: also list the property sets and properties of the published elements, with some of their values (for building a rule).",
            "type": "boolean"
          }
        },
        "required": ["organizationId", "projectId"],
        "additionalProperties": false
      },
      "previewLayerRuleOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "elementCount": {
            "description": "Elements the rule matches in the published models now (absent without a rule).",
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "properties": {
            "description": "With includeProperties: every set/property pair on the published elements (max 500).",
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "psetName": { "type": "string" },
                "propName": { "type": "string" },
                "values": {
                  "type": "array",
                  "items": { "type": "string" },
                  "description": "Up to 20 distinct values seen on elements, sorted."
                }
              },
              "required": ["psetName", "propName", "values"],
              "additionalProperties": false
            }
          },
          "propertiesTruncated": { "type": "boolean" },
          "complete": {
            "type": "boolean",
            "description": "`false` when some published model's properties could not be read; the count is then a lower bound."
          }
        },
        "required": ["complete"],
        "additionalProperties": false
      },
      "provisionSampleProjectInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "provisionSampleProjectOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "project": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A prj identifier (TypeID, conventions C5)."
              },
              "organizationId": {
                "type": "string",
                "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A org identifier (TypeID, conventions C5)."
              },
              "name": {
                "type": "string",
                "minLength": 1,
                "maxLength": 80,
                "description": "Project display name (1-80 chars after trimming, BR-2)."
              },
              "reference": {
                "type": "string",
                "minLength": 1,
                "maxLength": 40,
                "description": "Free-form job/reference code, e.g. \"2026-041\" (BR-2)."
              },
              "description": {
                "type": "string",
                "maxLength": 500,
                "description": "Free-form project description (BR-2)."
              },
              "status": {
                "type": "string",
                "enum": ["active", "archived", "deleted"]
              },
              "access": { "type": "string", "enum": ["org", "restricted"] },
              "memberIds": {
                "maxItems": 500,
                "type": "array",
                "items": { "type": "string", "minLength": 1 }
              },
              "fieldVersionIds": {
                "maxItems": 500,
                "type": "array",
                "items": {
                  "type": "string",
                  "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A ver identifier (TypeID, conventions C5)."
                }
              },
              "publishSeq": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "lastPublishedAt": {
                "type": "string",
                "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))$"
              },
              "isSample": { "type": "boolean", "const": true },
              "demoSlug": {
                "type": "string",
                "enum": [
                  "landhuis_hulstveld",
                  "landhuis_hulstveld_hsb",
                  "woning_lindehof",
                  "villa_berkenhaag",
                  "hal_noorderkempen",
                  "paneelset_werkplaats"
                ]
              },
              "archivedAt": {
                "type": "string",
                "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))$"
              },
              "deletedAt": {
                "type": "string",
                "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))$"
              },
              "purgeAfter": {
                "type": "string",
                "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))$"
              },
              "statusBeforeDeletion": {
                "type": "string",
                "enum": ["active", "archived"]
              },
              "purgeStartedAt": {
                "type": "string",
                "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))$"
              },
              "sheetMetadata": {
                "type": "object",
                "properties": {
                  "fileNamePattern": {
                    "type": "string",
                    "description": "Regular expression matched against the file name without its .pdf extension, with named groups sheetNumber and/or discipline, e.g. ^(?<discipline>[A-Z])-(?<sheetNumber>\\d+) (max 200 chars; no backreferences or nested repeats)."
                  },
                  "disciplineMap": {
                    "type": "object",
                    "propertyNames": {
                      "type": "string",
                      "pattern": "^[A-Za-z0-9]{1,8}$"
                    },
                    "additionalProperties": {
                      "type": "string",
                      "enum": [
                        "architecture",
                        "structure",
                        "mechanical",
                        "electrical",
                        "plumbing",
                        "fire_protection",
                        "civil",
                        "landscape",
                        "general"
                      ]
                    }
                  }
                },
                "additionalProperties": false,
                "description": "How this project's PDF file names map to sheet number and discipline (BR-11). Without a fileNamePattern the file-name stem is the sheet number."
              },
              "schemaVersion": { "type": "number", "const": 1 },
              "createdAt": {
                "type": "string",
                "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))$"
              },
              "updatedAt": {
                "type": "string",
                "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))$"
              },
              "revision": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "createdBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              }
            },
            "required": [
              "id",
              "organizationId",
              "name",
              "status",
              "access",
              "memberIds",
              "schemaVersion",
              "createdAt",
              "updatedAt",
              "revision",
              "createdBy"
            ],
            "additionalProperties": false
          },
          "status": {
            "type": "string",
            "enum": ["preparing", "ready"],
            "description": "`ready`: the sample model is published and opens in the viewer. `preparing`: its artefacts are still being copied; poll listProjects until the project has lastPublishedAt."
          }
        },
        "required": ["project", "status"],
        "additionalProperties": false
      },
      "publishDocumentVersionInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dvr identifier (TypeID, conventions C5)."
          },
          "expectedPublishedVersionId": {
            "anyOf": [
              {
                "type": "string",
                "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A dvr identifier (TypeID, conventions C5)."
              },
              { "type": "null" }
            ]
          }
        },
        "required": ["organizationId", "projectId", "documentId", "versionId"],
        "additionalProperties": false
      },
      "publishDocumentVersionOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dvr identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": [
              "uploading",
              "uploaded",
              "processing",
              "ready",
              "failed",
              "archived",
              "cancelled"
            ]
          },
          "publication": {
            "type": "string",
            "enum": ["draft", "published", "superseded"]
          },
          "fieldVisible": { "type": "boolean" },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "upload" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "fileName", "sizeBytes", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "url" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "url": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 2048,
                    "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "url", "fileName", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "copy" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "sourceVersionId": {
                    "type": "string",
                    "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A dvr identifier (TypeID, conventions C5)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": [
                  "kind",
                  "sourceVersionId",
                  "fileName",
                  "sizeBytes",
                  "contentType"
                ],
                "additionalProperties": false
              }
            ]
          },
          "upload": {
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          },
          "cancelReason": { "type": "string", "enum": ["user"] },
          "pipelineVersion": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": { "type": "string" },
                "blocking": { "type": "boolean" },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": {}
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "progress": {
            "type": "object",
            "properties": {
              "stage": { "type": "string", "minLength": 1 },
              "percent": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["stage", "percent"],
            "additionalProperties": false
          },
          "processing": {
            "type": "object",
            "properties": {
              "sizeClass": { "type": "string", "enum": ["s", "m", "l", "xl"] },
              "executionName": { "type": "string", "minLength": 1 },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "queuedAt": {
                "type": "string",
                "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))$"
              },
              "queuedTraceparent": {
                "type": "string",
                "pattern": "^(?!ff)[0-9a-f]{2}-(?!0{32})[0-9a-f]{32}-(?!0{16})[0-9a-f]{16}-[0-9a-f]{2}$"
              },
              "queuedEscalation": {
                "type": "object",
                "properties": {
                  "sizeClass": {
                    "type": "string",
                    "enum": ["s", "m", "l", "xl"]
                  },
                  "attempt": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["sizeClass", "attempt"],
                "additionalProperties": false
              },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "progressReportedAt": {
                "type": "string",
                "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))$"
              },
              "requestId": { "type": "string", "minLength": 1 }
            },
            "additionalProperties": false
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": { "type": "string", "minLength": 1 },
              "retryable": { "type": "boolean" },
              "params": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": {}
              },
              "messageKey": { "type": "string", "minLength": 1 },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "retryable"],
            "additionalProperties": false
          },
          "activeArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "reprocessing": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "reason": {
                "type": "string",
                "enum": ["retry", "pipeline_upgrade"]
              },
              "targetPipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "state": {
                "type": "string",
                "enum": [
                  "requested",
                  "deferred",
                  "awaiting_rollout",
                  "done",
                  "failed"
                ]
              },
              "completedAt": {
                "type": "string",
                "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))$"
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1 },
                  "retryable": { "type": "boolean" },
                  "params": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": {}
                  },
                  "messageKey": { "type": "string", "minLength": 1 },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "retryable"],
                "additionalProperties": false
              }
            },
            "required": ["requestedAt", "requestedBy", "attempt"],
            "additionalProperties": false
          },
          "pageCount": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "pages": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "pageNumber": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "scanned": { "type": "boolean" },
                "sheetNumber": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 100,
                  "description": "Sheet number, e.g. \"W-101\" (BR-11)."
                },
                "title": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 200,
                  "description": "Sheet title, e.g. from the PDF outline (BR-11)."
                },
                "discipline": {
                  "type": "string",
                  "enum": [
                    "architecture",
                    "structure",
                    "mechanical",
                    "electrical",
                    "plumbing",
                    "fire_protection",
                    "civil",
                    "landscape",
                    "general"
                  ]
                },
                "storeyId": { "type": "string", "minLength": 1 },
                "overridden": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "enum": ["sheetNumber", "title", "discipline"]
                  }
                },
                "layout": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "kind": { "type": "string", "enum": ["model", "paper"] }
                  },
                  "required": ["name", "kind"],
                  "additionalProperties": false
                },
                "titleBlock": {
                  "type": "object",
                  "propertyNames": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 64
                  },
                  "additionalProperties": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "description": "FV-490 (E13 §4.4): a CAD page's primary title block, attribute tag -> value (<= 32 entries, values <= 200 chars)."
                },
                "scale": {
                  "type": "object",
                  "properties": {
                    "factor": {
                      "type": "number",
                      "exclusiveMinimum": 0,
                      "maximum": 10000,
                      "description": "Real millimetres per paper millimetre (1:50 is 50)."
                    },
                    "source": {
                      "type": "string",
                      "enum": ["calibration", "label"],
                      "description": "calibration: two points and a known length; label: the title-block scale, confirmed."
                    },
                    "basis": {
                      "description": "For a calibration: the two points (fractions of the page) and the real length in mm.",
                      "type": "object",
                      "properties": {
                        "a": {
                          "type": "object",
                          "properties": {
                            "xPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            },
                            "yPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            }
                          },
                          "required": ["xPct", "yPct"],
                          "additionalProperties": false
                        },
                        "b": {
                          "type": "object",
                          "properties": {
                            "xPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            },
                            "yPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            }
                          },
                          "required": ["xPct", "yPct"],
                          "additionalProperties": false
                        },
                        "lengthMm": { "type": "number", "exclusiveMinimum": 0 }
                      },
                      "required": ["a", "b", "lengthMm"],
                      "additionalProperties": false
                    },
                    "setBy": { "type": "string", "minLength": 1 },
                    "setAt": {
                      "type": "string",
                      "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))$"
                    }
                  },
                  "required": ["factor", "source", "setBy", "setAt"],
                  "additionalProperties": false
                }
              },
              "required": ["pageNumber", "scanned"],
              "additionalProperties": false
            }
          },
          "cad": {
            "type": "object",
            "properties": {
              "insunits": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "unitToMm": {
                "anyOf": [
                  { "type": "number", "exclusiveMinimum": 0 },
                  { "type": "null" }
                ]
              },
              "unitsOverride": {
                "type": "string",
                "enum": ["mm", "cm", "m", "in", "ft"],
                "description": "The drawing's units, set by a publisher because the file declares none: mm, cm, m, in or ft."
              },
              "defaultLayersOff": {
                "maxItems": 256,
                "type": "array",
                "items": { "type": "string", "minLength": 1, "maxLength": 255 },
                "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
              },
              "parser": { "type": "string", "const": "acad-ts" },
              "parserVersion": { "type": "string", "minLength": 1 },
              "version": { "type": "string", "minLength": 1 },
              "layoutCount": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "insunits",
              "unitToMm",
              "parser",
              "parserVersion",
              "version",
              "layoutCount"
            ],
            "additionalProperties": false
          },
          "layerDefault": {
            "type": "object",
            "properties": {
              "off": {
                "maxItems": 256,
                "type": "array",
                "items": { "type": "string", "minLength": 1, "maxLength": 255 },
                "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
              }
            },
            "required": ["off"],
            "additionalProperties": false,
            "description": "The layers off by default for everyone who opens this drawing (CAD layers or PDF optional content groups, by name). A person's own choice on their device still wins."
          },
          "publishOnReady": {
            "description": "Publish this version automatically, in the same write that marks it ready (FV-745).",
            "type": "boolean"
          },
          "releasedAt": {
            "type": "string",
            "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))$"
          },
          "supersededAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "documentId",
          "versionNumber",
          "status",
          "publication",
          "fieldVisible",
          "source",
          "pipelineVersion",
          "warnings",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "publishProjectRevisionInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "number": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991,
            "description": "The revision number within the project."
          },
          "note": { "type": "string", "maxLength": 500 },
          "acknowledgeWarnings": { "type": "boolean" },
          "expectedCurrentRevision": {
            "description": "Optimistic concurrency: the revision number you expect to be current now (null: none). A mismatch is model.publish_conflict.",
            "anyOf": [
              {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              { "type": "null" }
            ]
          }
        },
        "required": ["organizationId", "projectId", "number"],
        "additionalProperties": false
      },
      "publishProjectRevisionOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": [
              "uploading",
              "uploaded",
              "processing",
              "ready",
              "failed",
              "archived",
              "cancelled"
            ]
          },
          "publication": {
            "type": "string",
            "enum": ["draft", "published", "superseded"]
          },
          "fieldVisible": { "type": "boolean" },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "upload" },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "fileName", "sizeBytes", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "copy" },
                  "sourceVersionId": {
                    "type": "string",
                    "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A ver identifier (TypeID, conventions C5)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": [
                  "kind",
                  "sourceVersionId",
                  "fileName",
                  "sizeBytes",
                  "contentType"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "url" },
                  "url": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 2048,
                    "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "url", "fileName", "contentType"],
                "additionalProperties": false
              }
            ]
          },
          "upload": {
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "cancelReason": { "type": "string", "enum": ["user", "expired"] },
          "pipelineVersion": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": { "type": "string" },
                "blocking": { "type": "boolean" },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": {}
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": { "type": "string", "minLength": 1 },
              "retryable": { "type": "boolean" },
              "params": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": {}
              },
              "messageKey": { "type": "string", "minLength": 1 },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "retryable"],
            "additionalProperties": false
          },
          "processing": {
            "type": "object",
            "properties": {
              "sizeClass": { "type": "string", "enum": ["s", "m", "l", "xl"] },
              "executionName": { "type": "string", "minLength": 1 },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "queuedAt": {
                "type": "string",
                "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))$"
              },
              "queuedTraceparent": {
                "type": "string",
                "pattern": "^(?!ff)[0-9a-f]{2}-(?!0{32})[0-9a-f]{32}-(?!0{16})[0-9a-f]{16}-[0-9a-f]{2}$"
              },
              "queuedEscalation": {
                "type": "object",
                "properties": {
                  "sizeClass": {
                    "type": "string",
                    "enum": ["s", "m", "l", "xl"]
                  },
                  "attempt": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["sizeClass", "attempt"],
                "additionalProperties": false
              },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "progressReportedAt": {
                "type": "string",
                "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))$"
              },
              "requestId": { "type": "string", "minLength": 1 }
            },
            "additionalProperties": false
          },
          "progress": {
            "type": "object",
            "properties": {
              "stage": { "type": "string", "minLength": 1 },
              "percent": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["stage", "percent"],
            "additionalProperties": false
          },
          "reprocessing": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "reason": {
                "type": "string",
                "enum": ["retry", "pipeline_upgrade"]
              },
              "targetPipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "state": {
                "type": "string",
                "enum": [
                  "requested",
                  "deferred",
                  "awaiting_rollout",
                  "done",
                  "failed"
                ]
              },
              "completedAt": {
                "type": "string",
                "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))$"
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1 },
                  "retryable": { "type": "boolean" },
                  "params": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": {}
                  },
                  "messageKey": { "type": "string", "minLength": 1 },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "retryable"],
                "additionalProperties": false
              }
            },
            "required": ["requestedAt", "requestedBy", "attempt"],
            "additionalProperties": false
          },
          "releasedAt": {
            "type": "string",
            "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))$"
          },
          "releasedBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "supersededAt": {
            "type": "string",
            "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))$"
          },
          "activeArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "nextArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "stats": {
            "type": "object",
            "properties": {
              "elementCount": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "boundsMm": {
                "type": "object",
                "properties": {
                  "min": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3
                  },
                  "max": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3
                  }
                },
                "required": ["min", "max"],
                "additionalProperties": false
              },
              "coveragePct": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["elementCount", "boundsMm"],
            "additionalProperties": false
          },
          "churn": {
            "type": "object",
            "properties": {
              "ratio": { "type": "number", "minimum": 0, "maximum": 1 },
              "added": { "type": "array", "items": { "type": "string" } },
              "removed": { "type": "array", "items": { "type": "string" } },
              "moved": { "type": "array", "items": { "type": "string" } },
              "recreated": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "from": { "type": "string" },
                    "to": { "type": "string" }
                  },
                  "required": ["from", "to"],
                  "additionalProperties": false
                }
              }
            },
            "required": ["ratio", "added", "removed", "moved", "recreated"],
            "additionalProperties": false
          },
          "label": {
            "type": "string",
            "minLength": 1,
            "maxLength": 40,
            "description": "Short version name, e.g. \"Roof fix\" (1-40 chars after trimming, BR-10)."
          },
          "notes": {
            "type": "string",
            "maxLength": 2000,
            "description": "Free-form notes for the crew (max 2000 chars, BR-10)."
          },
          "detailsEditedAt": {
            "type": "string",
            "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))$"
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "publishOnReady": {
            "description": "Publish this version automatically, in the same write that marks it ready (FV-383).",
            "type": "boolean"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "number": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991,
            "description": "The revision number within the project (1, 2, 3...)."
          },
          "current": {
            "type": "boolean",
            "description": "Whether this is the revision the field sees now."
          },
          "publishedAt": {
            "description": "When this revision was (last) published; absent for a revision never published.",
            "type": "string",
            "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))$"
          },
          "publishedBy": {
            "description": "Who published it; absent for a revision never published, or published before FV-384 and no longer current.",
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "publishedByName": {
            "description": "The publisher's display name, when they are a member.",
            "type": "string",
            "minLength": 1
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "modelId",
          "versionNumber",
          "status",
          "publication",
          "fieldVisible",
          "source",
          "pipelineVersion",
          "warnings",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy",
          "number",
          "current"
        ],
        "additionalProperties": false
      },
      "reactivateOrganizationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "reason": { "type": "string", "minLength": 1, "maxLength": 500 }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "reactivateOrganizationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 2,
            "maxLength": 80,
            "description": "Organisation display name (2-80 chars after trimming, BR-10)."
          },
          "planId": {
            "type": "string",
            "enum": ["beta", "free", "team", "enterprise", "internal", "tryout"]
          },
          "orgStatus": {
            "type": "string",
            "enum": ["active", "suspended"],
            "description": "`suspended` while a platform admin has paused the organisation's writes."
          },
          "createdAt": {
            "type": "string",
            "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))$"
          }
        },
        "required": ["id", "name", "planId", "orgStatus", "createdAt"],
        "additionalProperties": false
      },
      "redeemBetaAccessCodeInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "code": {
            "type": "string",
            "pattern": "^[23456789ABCDEFGHJKLMNPQRSTUVWXYZ]{10}$",
            "description": "10-character opaque code, unambiguous alphabet (no 0/O/1/I)."
          }
        },
        "required": ["code"],
        "additionalProperties": false
      },
      "redeemBetaAccessCodeOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "codeId": {
            "type": "string",
            "pattern": "^bac_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A bac identifier (TypeID, conventions C5)."
          },
          "grantedAt": {
            "type": "string",
            "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))$"
          }
        },
        "required": ["codeId", "grantedAt"],
        "additionalProperties": false
      },
      "refreshMySecurityStateInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {},
        "additionalProperties": false
      },
      "refreshMySecurityStateOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^usr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A usr identifier (TypeID, conventions C5)."
          },
          "displayName": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "Display name shown in the UI (1-80 chars, §5.4)."
          },
          "locale": {
            "type": "string",
            "enum": ["nl", "en", "fr"],
            "description": "BCP 47 UI locale, one of nl | en | fr."
          },
          "localeChosen": {
            "description": "Whether the user explicitly chose `locale` (profile screen); then every device follows it. Absent: false.",
            "type": "boolean"
          },
          "email": {
            "description": "The account's sign-in e-mail address, as last synced from the identity provider.",
            "type": "string",
            "maxLength": 254,
            "format": "email",
            "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
          },
          "security": {
            "type": "object",
            "properties": {
              "providers": {
                "type": "array",
                "items": { "type": "string" },
                "description": "Sign-in provider ids this user has used (e.g. password, google.com)."
              },
              "passwordSet": {
                "description": "Whether the account can sign in with a password (set by refreshMySecurityState).",
                "type": "boolean"
              },
              "mfaEnrolled": {
                "description": "Whether two-step verification is enrolled (set by refreshMySecurityState).",
                "type": "boolean"
              }
            },
            "required": ["providers"],
            "additionalProperties": false
          },
          "preferences": {
            "type": "object",
            "properties": {
              "lastOrgId": {
                "description": "The last organisation this user was active in, if any.",
                "type": "string",
                "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
              },
              "onboardingChecklistDismissed": {
                "description": "Whether the caller dismissed the get-started checklist panel (FV-208, per user).",
                "type": "boolean"
              },
              "gesturesCoached": {
                "description": "The viewer gesture coach-marks this account has been shown (orbit, zoom, select; FV-219).",
                "type": "array",
                "items": {
                  "type": "string",
                  "enum": ["orbit", "zoom", "select"]
                }
              },
              "lengthUnit": {
                "description": "Display unit for measured lengths: mm (default when absent), cm or m (FV-238). Display only; stored values stay mm.",
                "type": "string",
                "enum": ["mm", "cm", "m"]
              },
              "measureSnap": {
                "description": "Measure snap settings: the targets switched off and the snap radius (FV-433). Absent: all on, medium.",
                "type": "object",
                "properties": {
                  "off": {
                    "maxItems": 7,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "enum": [
                        "vertex",
                        "edgeIntersection",
                        "edgeMidpoint",
                        "circleCentre",
                        "perpendicular",
                        "edgePoint",
                        "facePoint"
                      ]
                    },
                    "description": "Snap targets switched off: vertex, edgeIntersection, edgeMidpoint, circleCentre, perpendicular, edgePoint, facePoint."
                  },
                  "radius": {
                    "type": "string",
                    "enum": ["small", "medium", "large"],
                    "description": "Snap radius: small, medium (default) or large."
                  }
                },
                "required": ["off", "radius"],
                "additionalProperties": false
              },
              "trackpadScroll": {
                "description": "What a two-finger trackpad scroll does in the 3D viewer: pan (default when absent) or zoom (FV-472). A pinch always zooms.",
                "type": "string",
                "enum": ["pan", "zoom"]
              },
              "modelColours": {
                "description": "How the 3D viewer colours a model: file (default when absent: the file's own colours, the Field-Viewer palette where it has none) or palette (always the Field-Viewer palette) (FV-515).",
                "type": "string",
                "enum": ["file", "palette"]
              },
              "layers": {
                "description": "Personal layer defaults (FV-513): byProject (a project's own on/off overrides, the 30 most recently saved) and mine (on/off by template layer or derivation key, across projects). Absent: none.",
                "type": "object",
                "properties": {
                  "byProject": {
                    "maxItems": 30,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "projectId": {
                          "type": "string",
                          "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A prj identifier (TypeID, conventions C5)."
                        },
                        "layerSetId": {
                          "type": "string",
                          "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A lys identifier (TypeID, conventions C5)."
                        },
                        "off": {
                          "maxItems": 100,
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "^[a-z0-9][a-z0-9-]{0,63}$"
                          },
                          "description": "Field layers switched off against the project's default."
                        },
                        "on": {
                          "maxItems": 100,
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "^[a-z0-9][a-z0-9-]{0,63}$"
                          },
                          "description": "Field layers switched on against the project's default."
                        },
                        "mode": {
                          "description": "project-default: this project opens on its own defaults, never on my default.",
                          "type": "string",
                          "enum": ["project-default"]
                        },
                        "updatedAt": {
                          "type": "string",
                          "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))$"
                        }
                      },
                      "required": [
                        "projectId",
                        "layerSetId",
                        "off",
                        "on",
                        "updatedAt"
                      ],
                      "additionalProperties": false
                    },
                    "description": "This person's own layer state per project, most recently saved first (at most 30)."
                  },
                  "mineOff": {
                    "maxItems": 200,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "maxLength": 120,
                      "pattern": "^(?:template:ltp_[0-9a-z]{26}:[a-z0-9][a-z0-9-]{0,39}|(?:assignment|type|attribute):\\S.*)$"
                    },
                    "description": "My default, off across projects: template:<template>:<layer> or <kind>:<derivation key>."
                  },
                  "mineOn": {
                    "maxItems": 200,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "maxLength": 120,
                      "pattern": "^(?:template:ltp_[0-9a-z]{26}:[a-z0-9][a-z0-9-]{0,39}|(?:assignment|type|attribute):\\S.*)$"
                    },
                    "description": "My default, on across projects (same keys)."
                  }
                },
                "required": ["byProject", "mineOff", "mineOn"],
                "additionalProperties": false
              },
              "analyticsOptOut": {
                "description": "Whether the caller switched off technical measurements (web vitals, client logs; FV-464). Absent: allowed.",
                "type": "boolean"
              }
            },
            "additionalProperties": false
          },
          "betaAccess": {
            "type": "object",
            "properties": {
              "codeId": {
                "type": "string",
                "pattern": "^bac_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A bac identifier (TypeID, conventions C5)."
              },
              "grantedAt": {
                "type": "string",
                "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))$"
              },
              "consumedAt": {
                "type": "string",
                "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))$"
              },
              "consumedOrgId": {
                "type": "string",
                "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A org identifier (TypeID, conventions C5)."
              }
            },
            "required": ["codeId", "grantedAt"],
            "additionalProperties": false
          },
          "legal": {
            "type": "object",
            "properties": {
              "privacyAcknowledgedVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "privacyAcknowledgedAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["privacyAcknowledgedVersion", "privacyAcknowledgedAt"],
            "additionalProperties": false,
            "description": "The privacy notice version the user acknowledged, and when."
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "displayName",
          "locale",
          "security",
          "preferences",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "removeMemberInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "uid": {
            "type": "string",
            "minLength": 1,
            "description": "The member's Firebase Auth uid."
          }
        },
        "required": ["organizationId", "uid"],
        "additionalProperties": false
      },
      "removeMemberOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "minLength": 1,
            "description": "Same value as `uid`."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "uid": {
            "type": "string",
            "minLength": 1,
            "description": "The member's Firebase Auth uid."
          },
          "role": {
            "type": "string",
            "enum": ["owner", "admin", "publisher", "member", "guest"]
          },
          "status": {
            "type": "string",
            "enum": ["active", "invited", "suspended", "removed"]
          },
          "blocked": { "type": "boolean" },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          }
        },
        "required": [
          "id",
          "organizationId",
          "uid",
          "role",
          "status",
          "blocked",
          "createdAt",
          "updatedAt",
          "revision"
        ],
        "additionalProperties": false
      },
      "removeProjectMemberInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "uid": { "type": "string", "minLength": 1 }
        },
        "required": ["organizationId", "projectId", "uid"],
        "additionalProperties": false
      },
      "removeProjectMemberOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "addedAt": {
            "type": "string",
            "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))$"
          },
          "addedBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "id": {
            "type": "string",
            "minLength": 1,
            "description": "The member's uid (user or workstation) -- also this row's Firestore id."
          }
        },
        "required": ["projectId", "organizationId", "id"],
        "additionalProperties": false
      },
      "reprocessLayerSetInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "layerSetId": {
            "type": "string",
            "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lys identifier (TypeID, conventions C5)."
          },
          "grouping": {
            "description": "Group the automatic layers by these element attributes from now on: one source, or a source and the complement that groups what it leaves (e.g. `[\"name-role\", \"material\"]`). Omit to let the derivation choose.",
            "minItems": 1,
            "maxItems": 2,
            "type": "array",
            "items": {
              "type": "string",
              "enum": ["classification", "name-role", "material", "object-type"]
            }
          },
          "merges": {
            "description": "FV-504: merge layers of the reset set, by derivation key: the layers derived from `keys` go into the layer derived from `into`, as `updateLayerSet`'s `mergeEntryIds` would. Each key may appear once across all merges.",
            "minItems": 1,
            "maxItems": 100,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "into": { "type": "string", "minLength": 1, "maxLength": 512 },
                "keys": {
                  "minItems": 1,
                  "maxItems": 100,
                  "type": "array",
                  "items": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 512
                  }
                }
              },
              "required": ["into", "keys"],
              "additionalProperties": false
            }
          }
        },
        "required": ["organizationId", "projectId", "layerSetId"],
        "additionalProperties": false
      },
      "reprocessLayerSetOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lys identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "status": {
            "type": "string",
            "enum": ["ready", "materializing", "failed"]
          },
          "materializingSince": {
            "type": "string",
            "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))$"
          },
          "materializeAttempts": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "enum": ["layer_rule_materialization_failed"]
              },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "supportRef"],
            "additionalProperties": false
          },
          "derivationSource": {
            "type": "string",
            "enum": [
              "assignment",
              "type",
              "classification",
              "name-role",
              "material",
              "object-type"
            ]
          },
          "grouping": {
            "minItems": 1,
            "maxItems": 2,
            "type": "array",
            "items": {
              "type": "string",
              "enum": ["classification", "name-role", "material", "object-type"]
            }
          },
          "sourceCoveragePct": {
            "type": "number",
            "minimum": 0,
            "maximum": 100
          },
          "sources": {
            "maxItems": 100,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "modelId": {
                  "type": "string",
                  "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A mdl identifier (TypeID, conventions C5)."
                },
                "versionId": {
                  "type": "string",
                  "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A ver identifier (TypeID, conventions C5)."
                }
              },
              "required": ["modelId", "versionId"],
              "additionalProperties": false
            }
          },
          "generatedFromVersionId": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          },
          "derivedAtPublishSeq": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "generatedAt": {
            "type": "string",
            "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))$"
          },
          "warnings": {
            "maxItems": 100,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": {
                  "type": "string",
                  "enum": [
                    "layers_index_failed",
                    "layer_source_unavailable",
                    "layer_source_invalid",
                    "layer_assignment_skipped",
                    "layer_entries_truncated",
                    "layer_rule_truncated",
                    "layer_template_truncated"
                  ]
                },
                "modelId": {
                  "type": "string",
                  "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A mdl identifier (TypeID, conventions C5)."
                },
                "versionId": {
                  "type": "string",
                  "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A ver identifier (TypeID, conventions C5)."
                },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": { "type": ["string", "number"] }
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "entries": {
            "maxItems": 100,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^[a-z0-9][a-z0-9-]{0,63}$"
                },
                "kind": {
                  "type": "string",
                  "enum": ["assignment", "type", "manual", "rule", "attribute"]
                },
                "derivationKeys": {
                  "maxItems": 100,
                  "type": "array",
                  "items": { "type": "string", "minLength": 1 }
                },
                "manualGlobalIds": {
                  "maxItems": 500,
                  "type": "array",
                  "items": { "type": "string", "minLength": 1 }
                },
                "rule": {
                  "type": "object",
                  "properties": {
                    "source": {
                      "type": "string",
                      "enum": [
                        "property",
                        "name",
                        "material",
                        "ifcClass",
                        "panel"
                      ]
                    },
                    "psetName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255
                    },
                    "propName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255
                    },
                    "op": {
                      "type": "string",
                      "enum": ["eq", "neq", "contains"]
                    },
                    "value": { "type": "string", "maxLength": 1000 }
                  },
                  "required": ["op", "value"],
                  "additionalProperties": false
                },
                "materializedGlobalIds": {
                  "maxItems": 20000,
                  "type": "array",
                  "items": { "type": "string", "minLength": 1 }
                },
                "elementCount": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "displayName": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 60
                },
                "colorHex": { "type": "string", "pattern": "^#[0-9a-f]{6}$" },
                "order": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "defaultOn": { "type": "boolean" },
                "hiddenFromField": { "type": "boolean" },
                "origin": { "type": "string", "enum": ["template", "project"] },
                "templateKey": {
                  "type": "string",
                  "pattern": "^template:ltp_[0-9a-z]{26}:[a-z0-9][a-z0-9-]{0,39}$"
                },
                "locked": { "type": "boolean" },
                "curated": { "type": "boolean" }
              },
              "required": [
                "id",
                "kind",
                "derivationKeys",
                "elementCount",
                "displayName",
                "order",
                "defaultOn",
                "hiddenFromField"
              ],
              "additionalProperties": false
            }
          },
          "template": {
            "type": "object",
            "properties": {
              "templateId": {
                "type": "string",
                "pattern": "^ltp_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A ltp identifier (TypeID, conventions C5)."
              },
              "revision": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": ["templateId", "revision"],
            "additionalProperties": false
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "status",
          "derivationSource",
          "sourceCoveragePct",
          "sources",
          "derivedAtPublishSeq",
          "generatedAt",
          "warnings",
          "entries",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "reprocessModelVersionAsSupportInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "modelId", "versionId"],
        "additionalProperties": false
      },
      "reprocessModelVersionAsSupportOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          },
          "status": {
            "type": "string",
            "enum": [
              "uploading",
              "uploaded",
              "processing",
              "ready",
              "failed",
              "archived",
              "cancelled"
            ],
            "description": "`uploaded`: queued for processing again."
          },
          "attempt": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991,
            "description": "The reprocess attempt this call started."
          },
          "requestedAt": {
            "type": "string",
            "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))$"
          }
        },
        "required": [
          "organizationId",
          "projectId",
          "modelId",
          "versionId",
          "status",
          "attempt",
          "requestedAt"
        ],
        "additionalProperties": false
      },
      "reprocessModelVersionInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "modelId", "versionId"],
        "additionalProperties": false
      },
      "reprocessModelVersionOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": [
              "uploading",
              "uploaded",
              "processing",
              "ready",
              "failed",
              "archived",
              "cancelled"
            ]
          },
          "publication": {
            "type": "string",
            "enum": ["draft", "published", "superseded"]
          },
          "fieldVisible": { "type": "boolean" },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "upload" },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "fileName", "sizeBytes", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "copy" },
                  "sourceVersionId": {
                    "type": "string",
                    "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A ver identifier (TypeID, conventions C5)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": [
                  "kind",
                  "sourceVersionId",
                  "fileName",
                  "sizeBytes",
                  "contentType"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "url" },
                  "url": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 2048,
                    "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "url", "fileName", "contentType"],
                "additionalProperties": false
              }
            ]
          },
          "upload": {
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "cancelReason": { "type": "string", "enum": ["user", "expired"] },
          "pipelineVersion": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": { "type": "string" },
                "blocking": { "type": "boolean" },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": {}
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": { "type": "string", "minLength": 1 },
              "retryable": { "type": "boolean" },
              "params": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": {}
              },
              "messageKey": { "type": "string", "minLength": 1 },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "retryable"],
            "additionalProperties": false
          },
          "processing": {
            "type": "object",
            "properties": {
              "sizeClass": { "type": "string", "enum": ["s", "m", "l", "xl"] },
              "executionName": { "type": "string", "minLength": 1 },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "queuedAt": {
                "type": "string",
                "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))$"
              },
              "queuedTraceparent": {
                "type": "string",
                "pattern": "^(?!ff)[0-9a-f]{2}-(?!0{32})[0-9a-f]{32}-(?!0{16})[0-9a-f]{16}-[0-9a-f]{2}$"
              },
              "queuedEscalation": {
                "type": "object",
                "properties": {
                  "sizeClass": {
                    "type": "string",
                    "enum": ["s", "m", "l", "xl"]
                  },
                  "attempt": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["sizeClass", "attempt"],
                "additionalProperties": false
              },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "progressReportedAt": {
                "type": "string",
                "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))$"
              },
              "requestId": { "type": "string", "minLength": 1 }
            },
            "additionalProperties": false
          },
          "progress": {
            "type": "object",
            "properties": {
              "stage": { "type": "string", "minLength": 1 },
              "percent": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["stage", "percent"],
            "additionalProperties": false
          },
          "reprocessing": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "reason": {
                "type": "string",
                "enum": ["retry", "pipeline_upgrade"]
              },
              "targetPipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "state": {
                "type": "string",
                "enum": [
                  "requested",
                  "deferred",
                  "awaiting_rollout",
                  "done",
                  "failed"
                ]
              },
              "completedAt": {
                "type": "string",
                "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))$"
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1 },
                  "retryable": { "type": "boolean" },
                  "params": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": {}
                  },
                  "messageKey": { "type": "string", "minLength": 1 },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "retryable"],
                "additionalProperties": false
              }
            },
            "required": ["requestedAt", "requestedBy", "attempt"],
            "additionalProperties": false
          },
          "releasedAt": {
            "type": "string",
            "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))$"
          },
          "releasedBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "supersededAt": {
            "type": "string",
            "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))$"
          },
          "activeArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "nextArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "stats": {
            "type": "object",
            "properties": {
              "elementCount": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "boundsMm": {
                "type": "object",
                "properties": {
                  "min": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3
                  },
                  "max": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3
                  }
                },
                "required": ["min", "max"],
                "additionalProperties": false
              },
              "coveragePct": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["elementCount", "boundsMm"],
            "additionalProperties": false
          },
          "churn": {
            "type": "object",
            "properties": {
              "ratio": { "type": "number", "minimum": 0, "maximum": 1 },
              "added": { "type": "array", "items": { "type": "string" } },
              "removed": { "type": "array", "items": { "type": "string" } },
              "moved": { "type": "array", "items": { "type": "string" } },
              "recreated": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "from": { "type": "string" },
                    "to": { "type": "string" }
                  },
                  "required": ["from", "to"],
                  "additionalProperties": false
                }
              }
            },
            "required": ["ratio", "added", "removed", "moved", "recreated"],
            "additionalProperties": false
          },
          "label": {
            "type": "string",
            "minLength": 1,
            "maxLength": 40,
            "description": "Short version name, e.g. \"Roof fix\" (1-40 chars after trimming, BR-10)."
          },
          "notes": {
            "type": "string",
            "maxLength": 2000,
            "description": "Free-form notes for the crew (max 2000 chars, BR-10)."
          },
          "detailsEditedAt": {
            "type": "string",
            "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))$"
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "publishOnReady": {
            "description": "Publish this version automatically, in the same write that marks it ready (FV-383).",
            "type": "boolean"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "modelId",
          "versionNumber",
          "status",
          "publication",
          "fieldVisible",
          "source",
          "pipelineVersion",
          "warnings",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "requestAuditLogExportInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "type": {
            "description": "Only events of these types, comma-separated (max 10), e.g. `member.roleChanged,member.removed`. A denied attempt has the type `<type>.denied`.",
            "type": "string",
            "pattern": "^[a-zA-Z0-9._]+(,[a-zA-Z0-9._]+)*$"
          },
          "actor": {
            "description": "Only events by this actor id (a `usr_`/`tok_`/`wks_` id, as in `actor.id`).",
            "type": "string",
            "minLength": 1,
            "maxLength": 128
          },
          "occurredAfter": {
            "description": "Only events at or after this instant (RFC 3339).",
            "type": "string",
            "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))$"
          },
          "occurredBefore": {
            "description": "Only events before this instant (RFC 3339).",
            "type": "string",
            "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))$"
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "requestAuditLogExportOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^alx_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A alx identifier (TypeID, conventions C5)."
          },
          "status": {
            "type": "string",
            "enum": ["pending", "ready", "failed", "expired"],
            "description": "pending (being built) | ready (downloadable until expiresAt) | failed (request a new one; see error) | expired (past its 24 h window)."
          },
          "requestedAt": {
            "type": "string",
            "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))$"
          },
          "filters": {
            "type": "object",
            "properties": {
              "types": {
                "type": "array",
                "items": { "type": "string", "minLength": 1 }
              },
              "actor": { "type": "string", "minLength": 1 },
              "occurredAfter": {
                "type": "string",
                "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))$"
              },
              "occurredBefore": {
                "type": "string",
                "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))$"
              }
            },
            "additionalProperties": false,
            "description": "The filters the export was requested with."
          },
          "readyAt": {
            "type": "string",
            "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))$"
          },
          "expiresAt": {
            "description": "End of the 24 h download window.",
            "type": "string",
            "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))$"
          },
          "rowCount": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "sizeBytes": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "error": {
            "description": "Only on a failed export. too_many_rows: more than 50,000 events match -- narrow the date range.",
            "type": "string",
            "enum": ["build_failed", "too_many_rows"]
          },
          "download": {
            "description": "Present only while status is ready: a CSV (one row per event, every field except metadata) behind a signed URL valid for 15 minutes (C13). Call getAuditLogExport again for a fresh one until expiresAt.",
            "type": "object",
            "properties": {
              "url": { "type": "string", "format": "uri" },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "contentType": { "type": "string", "minLength": 1 },
              "sizeBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": ["url", "expiresAt", "contentType", "sizeBytes"],
            "additionalProperties": false
          }
        },
        "required": ["id", "status", "requestedAt", "filters"],
        "additionalProperties": false
      },
      "requestEmailChangeInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "newEmail": {
            "type": "string",
            "maxLength": 254,
            "format": "email",
            "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$",
            "description": "The address the account should move to."
          }
        },
        "required": ["newEmail"],
        "additionalProperties": false
      },
      "requestEmailChangeOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "newEmail": {
            "type": "string",
            "format": "email",
            "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$",
            "description": "The requested address, trimmed and lower-cased."
          },
          "requestedAt": {
            "type": "string",
            "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))$"
          }
        },
        "required": ["newEmail", "requestedAt"],
        "additionalProperties": false
      },
      "requestEmailSignInInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "email": {
            "type": "string",
            "format": "email",
            "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
          },
          "locale": { "type": "string", "enum": ["nl", "en", "fr"] },
          "continueUrl": { "type": "string", "format": "uri" },
          "recaptchaToken": {
            "type": "string",
            "minLength": 1,
            "maxLength": 4096
          }
        },
        "required": ["email", "locale", "continueUrl"],
        "additionalProperties": false
      },
      "requestEmailSignInOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "challengeId": {
            "type": "string",
            "pattern": "^sic_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A sic identifier (TypeID, conventions C5)."
          }
        },
        "required": ["challengeId"],
        "additionalProperties": false
      },
      "requestEmailVerificationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "locale": {
            "description": "Language of the mail (the app's active language). Omitted: the profile language, then the request's Accept-Language, then en.",
            "type": "string",
            "enum": ["nl", "en", "fr"]
          }
        },
        "additionalProperties": false
      },
      "requestEmailVerificationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "email": {
            "type": "string",
            "format": "email",
            "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$",
            "description": "The caller's own address."
          },
          "status": {
            "type": "string",
            "enum": ["sent", "alreadyVerified"],
            "description": "`sent`: the mail is on its way. `alreadyVerified`: nothing to confirm, no mail sent."
          }
        },
        "required": ["email", "status"],
        "additionalProperties": false
      },
      "requestMyDataExportInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {},
        "additionalProperties": false
      },
      "requestMyDataExportOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^dex_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dex identifier (TypeID, conventions C5)."
          },
          "status": {
            "type": "string",
            "enum": ["pending", "ready", "failed", "expired"],
            "description": "pending (being built) | ready (downloadable until expiresAt) | failed (request a new one) | expired (past its 24 h window)."
          },
          "requestedAt": {
            "type": "string",
            "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))$"
          },
          "readyAt": {
            "type": "string",
            "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))$"
          },
          "expiresAt": {
            "description": "End of the 24 h download window (BR-45).",
            "type": "string",
            "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))$"
          },
          "sizeBytes": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "download": {
            "description": "Present only while status is ready. The URL itself is valid for 15 minutes (C13); call getMyDataExport again for a fresh one until expiresAt.",
            "type": "object",
            "properties": {
              "url": { "type": "string", "format": "uri" },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "contentType": { "type": "string", "minLength": 1 },
              "sizeBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": ["url", "expiresAt", "contentType", "sizeBytes"],
            "additionalProperties": false
          }
        },
        "required": ["id", "status", "requestedAt"],
        "additionalProperties": false
      },
      "requestOrganizationDeletionInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "requestOrganizationDeletionOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 2,
            "maxLength": 80,
            "description": "Organisation display name (2-80 chars after trimming, BR-10)."
          },
          "defaultLocale": {
            "type": "string",
            "enum": ["nl", "en", "fr"],
            "description": "The organisation's default UI locale, one of nl | en | fr."
          },
          "status": {
            "type": "string",
            "enum": ["active", "pending_deletion"]
          },
          "deletion": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "purgeAfter": {
                "type": "string",
                "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))$"
              },
              "cancelledAt": {
                "type": "string",
                "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))$"
              },
              "purgeStartedAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["requestedAt", "requestedBy", "purgeAfter"],
            "additionalProperties": false
          },
          "supportAccess": {
            "description": "Whether Field-Viewer support may open a read-only support session: allowed (default when absent; owners are e-mailed) or ask (an owner approves each request first).",
            "type": "string",
            "enum": ["allowed", "ask"]
          },
          "settings": {
            "type": "object",
            "properties": {
              "analytics": {
                "type": "object",
                "properties": {
                  "mode": {
                    "type": "string",
                    "enum": ["enabled", "disabled"],
                    "description": "Product analytics for every member: enabled (the default) or disabled. Disabled, no usage event is recorded for anyone in the organisation."
                  }
                },
                "required": ["mode"],
                "additionalProperties": false
              },
              "cad": {
                "type": "object",
                "properties": {
                  "producerDetailTags": {
                    "type": "object",
                    "properties": {
                      "scale": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's scale text (1:n)."
                      },
                      "xFactor": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's x factor (1/n)."
                      },
                      "yFactor": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's y factor (1/n)."
                      },
                      "xMin": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's minimum x."
                      },
                      "yMin": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's minimum y."
                      },
                      "xMax": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's maximum x."
                      },
                      "yMax": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's maximum y."
                      }
                    },
                    "required": [
                      "scale",
                      "xFactor",
                      "yFactor",
                      "xMin",
                      "yMin",
                      "xMax",
                      "yMax"
                    ],
                    "additionalProperties": false,
                    "description": "The CAD producer's detail attribute tags: all seven, each the tag (not the value) of one block attribute. With them, scaled details in model space measure in real millimetres at their own scale; without them they read 'scale unknown'."
                  }
                },
                "additionalProperties": false
              }
            },
            "additionalProperties": false
          },
          "legal": {
            "type": "object",
            "properties": {
              "termsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "privacyVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "dpaVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "subprocessorsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "acceptedAt": {
                "type": "string",
                "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))$"
              },
              "acceptedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              }
            },
            "required": [
              "termsVersion",
              "privacyVersion",
              "dpaVersion",
              "subprocessorsVersion",
              "acceptedAt",
              "acceptedBy"
            ],
            "additionalProperties": false,
            "description": "The terms, privacy notice, DPA and sub-processor list versions an owner accepted for the organisation."
          },
          "kind": {
            "description": "standard (default when absent) or tryout: an anonymous visitor's 7-day try-it organisation.",
            "type": "string",
            "enum": ["standard", "tryout"]
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "logoUrl": {
            "type": "object",
            "properties": {
              "url": { "type": "string" },
              "expiresAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["url", "expiresAt"],
            "additionalProperties": false,
            "description": "Signed URL of the organisation's logo (15 minutes). Absent when it has no logo."
          },
          "reacceptanceRequired": {
            "description": "True when an owner must accept a newer material version of the terms, the DPA or the sub-processor list (or never accepted them).",
            "type": "boolean"
          }
        },
        "required": [
          "id",
          "name",
          "defaultLocale",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "requestSupportAccessInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "reason": {
            "type": "string",
            "minLength": 10,
            "maxLength": 500,
            "description": "Why support needs access, at least 10 characters (BR-44). Shown to the organisation's owners."
          },
          "durationMinutes": {
            "description": "How long the grant lasts, in minutes. Default 60, at most 120.",
            "type": "integer",
            "minimum": 1,
            "maximum": 120
          }
        },
        "required": ["organizationId", "reason"],
        "additionalProperties": false
      },
      "requestSupportAccessOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": { "type": "string", "minLength": 1 },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "uid": {
            "type": "string",
            "minLength": 1,
            "description": "The platform admin's user id."
          },
          "reason": { "type": "string" },
          "durationMinutes": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": ["pending", "approved", "denied", "used", "expired"]
          },
          "requestedAt": {
            "type": "string",
            "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))$"
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "decidedAt": {
            "type": "string",
            "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))$"
          }
        },
        "required": [
          "id",
          "organizationId",
          "uid",
          "reason",
          "durationMinutes",
          "status",
          "requestedAt",
          "expiresAt"
        ],
        "additionalProperties": false
      },
      "resendInvitationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "id": {
            "type": "string",
            "pattern": "^inv_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A inv identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "id"],
        "additionalProperties": false
      },
      "resendInvitationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^inv_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A inv identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "kind": { "type": "string", "enum": ["email", "link"] },
          "role": {
            "type": "string",
            "enum": ["admin", "publisher", "member", "guest"]
          },
          "projectIds": {
            "maxItems": 10,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          "email": {
            "type": "string",
            "maxLength": 254,
            "format": "email",
            "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
          },
          "status": {
            "type": "string",
            "enum": ["pending", "accepted", "revoked", "expired", "exhausted"]
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "maxUses": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 250
          },
          "useCount": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "resendCount": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "lastSentAt": {
            "type": "string",
            "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))$"
          },
          "locale": { "type": "string", "enum": ["nl", "en", "fr"] },
          "acceptedBy": {
            "maxItems": 250,
            "type": "array",
            "items": { "type": "string", "minLength": 1 }
          },
          "acceptedAt": {
            "type": "string",
            "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))$"
          },
          "acceptedEmail": { "type": "string" },
          "revokedBy": { "type": "string", "minLength": 1 },
          "revokedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "link": {
            "type": "string",
            "format": "uri",
            "description": "The fresh accept link (the one the e-mail carries). Returned only here, once; only a SHA-256 of its token is stored."
          }
        },
        "required": [
          "id",
          "organizationId",
          "kind",
          "role",
          "projectIds",
          "status",
          "expiresAt",
          "useCount",
          "resendCount",
          "locale",
          "acceptedBy",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy",
          "link"
        ],
        "additionalProperties": false
      },
      "resolveDeepLinkInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "globalIds": {
            "type": "string",
            "pattern": "^[0-9A-Za-z_$]{22}(,[0-9A-Za-z_$]{22}){0,19}$",
            "description": "The link's element refs: 1-20 IFC GlobalIds (22 characters of `[0-9A-Za-z_$]`), comma-separated."
          }
        },
        "required": ["organizationId", "projectId", "globalIds"],
        "additionalProperties": false
      },
      "resolveDeepLinkOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "refs": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "globalId": { "type": "string" },
                "status": {
                  "type": "string",
                  "enum": ["present", "missing", "unknown"]
                },
                "lastSeen": {
                  "type": "object",
                  "properties": {
                    "modelId": {
                      "type": "string",
                      "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A mdl identifier (TypeID, conventions C5)."
                    },
                    "versionNumber": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["modelId", "versionNumber"],
                  "additionalProperties": false
                }
              },
              "required": ["globalId", "status"],
              "additionalProperties": false
            }
          }
        },
        "required": ["refs"],
        "additionalProperties": false
      },
      "restoreDocumentInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "documentId"],
        "additionalProperties": false
      },
      "restoreDocumentOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "title": {
            "type": "string",
            "minLength": 1,
            "maxLength": 200,
            "description": "Document display title (1-200 chars after trimming)."
          },
          "status": {
            "type": "string",
            "enum": ["active", "archived", "deleted"]
          },
          "nextVersionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "format": { "type": "string", "enum": ["pdf", "dxf", "dwg"] },
          "published": {
            "type": "object",
            "properties": {
              "versionId": {
                "type": "string",
                "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A dvr identifier (TypeID, conventions C5)."
              },
              "publishedAt": {
                "type": "string",
                "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))$"
              },
              "publishedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              },
              "publishSeq": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "versionId",
              "publishedAt",
              "publishedBy",
              "publishSeq"
            ],
            "additionalProperties": false
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "deletedAt": {
            "type": "string",
            "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))$"
          },
          "purgeAfter": {
            "type": "string",
            "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))$"
          },
          "statusBeforeDeletion": {
            "type": "string",
            "enum": ["active", "archived"]
          },
          "purgeStartedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "status",
          "nextVersionNumber",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "restoreModelVersionInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "modelId", "versionId"],
        "additionalProperties": false
      },
      "restoreModelVersionOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": [
              "uploading",
              "uploaded",
              "processing",
              "ready",
              "failed",
              "archived",
              "cancelled"
            ]
          },
          "publication": {
            "type": "string",
            "enum": ["draft", "published", "superseded"]
          },
          "fieldVisible": { "type": "boolean" },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "upload" },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "fileName", "sizeBytes", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "copy" },
                  "sourceVersionId": {
                    "type": "string",
                    "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A ver identifier (TypeID, conventions C5)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": [
                  "kind",
                  "sourceVersionId",
                  "fileName",
                  "sizeBytes",
                  "contentType"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "url" },
                  "url": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 2048,
                    "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "url", "fileName", "contentType"],
                "additionalProperties": false
              }
            ]
          },
          "upload": {
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "cancelReason": { "type": "string", "enum": ["user", "expired"] },
          "pipelineVersion": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": { "type": "string" },
                "blocking": { "type": "boolean" },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": {}
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": { "type": "string", "minLength": 1 },
              "retryable": { "type": "boolean" },
              "params": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": {}
              },
              "messageKey": { "type": "string", "minLength": 1 },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "retryable"],
            "additionalProperties": false
          },
          "processing": {
            "type": "object",
            "properties": {
              "sizeClass": { "type": "string", "enum": ["s", "m", "l", "xl"] },
              "executionName": { "type": "string", "minLength": 1 },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "queuedAt": {
                "type": "string",
                "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))$"
              },
              "queuedTraceparent": {
                "type": "string",
                "pattern": "^(?!ff)[0-9a-f]{2}-(?!0{32})[0-9a-f]{32}-(?!0{16})[0-9a-f]{16}-[0-9a-f]{2}$"
              },
              "queuedEscalation": {
                "type": "object",
                "properties": {
                  "sizeClass": {
                    "type": "string",
                    "enum": ["s", "m", "l", "xl"]
                  },
                  "attempt": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["sizeClass", "attempt"],
                "additionalProperties": false
              },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "progressReportedAt": {
                "type": "string",
                "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))$"
              },
              "requestId": { "type": "string", "minLength": 1 }
            },
            "additionalProperties": false
          },
          "progress": {
            "type": "object",
            "properties": {
              "stage": { "type": "string", "minLength": 1 },
              "percent": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["stage", "percent"],
            "additionalProperties": false
          },
          "reprocessing": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "reason": {
                "type": "string",
                "enum": ["retry", "pipeline_upgrade"]
              },
              "targetPipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "state": {
                "type": "string",
                "enum": [
                  "requested",
                  "deferred",
                  "awaiting_rollout",
                  "done",
                  "failed"
                ]
              },
              "completedAt": {
                "type": "string",
                "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))$"
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1 },
                  "retryable": { "type": "boolean" },
                  "params": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": {}
                  },
                  "messageKey": { "type": "string", "minLength": 1 },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "retryable"],
                "additionalProperties": false
              }
            },
            "required": ["requestedAt", "requestedBy", "attempt"],
            "additionalProperties": false
          },
          "releasedAt": {
            "type": "string",
            "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))$"
          },
          "releasedBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "supersededAt": {
            "type": "string",
            "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))$"
          },
          "activeArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "nextArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "stats": {
            "type": "object",
            "properties": {
              "elementCount": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "boundsMm": {
                "type": "object",
                "properties": {
                  "min": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3
                  },
                  "max": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3
                  }
                },
                "required": ["min", "max"],
                "additionalProperties": false
              },
              "coveragePct": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["elementCount", "boundsMm"],
            "additionalProperties": false
          },
          "churn": {
            "type": "object",
            "properties": {
              "ratio": { "type": "number", "minimum": 0, "maximum": 1 },
              "added": { "type": "array", "items": { "type": "string" } },
              "removed": { "type": "array", "items": { "type": "string" } },
              "moved": { "type": "array", "items": { "type": "string" } },
              "recreated": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "from": { "type": "string" },
                    "to": { "type": "string" }
                  },
                  "required": ["from", "to"],
                  "additionalProperties": false
                }
              }
            },
            "required": ["ratio", "added", "removed", "moved", "recreated"],
            "additionalProperties": false
          },
          "label": {
            "type": "string",
            "minLength": 1,
            "maxLength": 40,
            "description": "Short version name, e.g. \"Roof fix\" (1-40 chars after trimming, BR-10)."
          },
          "notes": {
            "type": "string",
            "maxLength": 2000,
            "description": "Free-form notes for the crew (max 2000 chars, BR-10)."
          },
          "detailsEditedAt": {
            "type": "string",
            "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))$"
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "publishOnReady": {
            "description": "Publish this version automatically, in the same write that marks it ready (FV-383).",
            "type": "boolean"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "modelId",
          "versionNumber",
          "status",
          "publication",
          "fieldVisible",
          "source",
          "pipelineVersion",
          "warnings",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "restoreProjectInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId"],
        "additionalProperties": false
      },
      "restoreProjectOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "Project display name (1-80 chars after trimming, BR-2)."
          },
          "reference": {
            "type": "string",
            "minLength": 1,
            "maxLength": 40,
            "description": "Free-form job/reference code, e.g. \"2026-041\" (BR-2)."
          },
          "description": {
            "type": "string",
            "maxLength": 500,
            "description": "Free-form project description (BR-2)."
          },
          "status": {
            "type": "string",
            "enum": ["active", "archived", "deleted"]
          },
          "access": { "type": "string", "enum": ["org", "restricted"] },
          "memberIds": {
            "maxItems": 500,
            "type": "array",
            "items": { "type": "string", "minLength": 1 }
          },
          "fieldVersionIds": {
            "maxItems": 500,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ver identifier (TypeID, conventions C5)."
            }
          },
          "publishSeq": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "lastPublishedAt": {
            "type": "string",
            "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))$"
          },
          "isSample": { "type": "boolean", "const": true },
          "demoSlug": {
            "type": "string",
            "enum": [
              "landhuis_hulstveld",
              "landhuis_hulstveld_hsb",
              "woning_lindehof",
              "villa_berkenhaag",
              "hal_noorderkempen",
              "paneelset_werkplaats"
            ]
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "deletedAt": {
            "type": "string",
            "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))$"
          },
          "purgeAfter": {
            "type": "string",
            "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))$"
          },
          "statusBeforeDeletion": {
            "type": "string",
            "enum": ["active", "archived"]
          },
          "purgeStartedAt": {
            "type": "string",
            "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))$"
          },
          "sheetMetadata": {
            "type": "object",
            "properties": {
              "fileNamePattern": {
                "type": "string",
                "description": "Regular expression matched against the file name without its .pdf extension, with named groups sheetNumber and/or discipline, e.g. ^(?<discipline>[A-Z])-(?<sheetNumber>\\d+) (max 200 chars; no backreferences or nested repeats)."
              },
              "disciplineMap": {
                "type": "object",
                "propertyNames": {
                  "type": "string",
                  "pattern": "^[A-Za-z0-9]{1,8}$"
                },
                "additionalProperties": {
                  "type": "string",
                  "enum": [
                    "architecture",
                    "structure",
                    "mechanical",
                    "electrical",
                    "plumbing",
                    "fire_protection",
                    "civil",
                    "landscape",
                    "general"
                  ]
                }
              }
            },
            "additionalProperties": false,
            "description": "How this project's PDF file names map to sheet number and discipline (BR-11). Without a fileNamePattern the file-name stem is the sheet number."
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "name",
          "status",
          "access",
          "memberIds",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "revokeApiTokenInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "apiTokenId": {
            "type": "string",
            "pattern": "^tok_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A tok identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "apiTokenId"],
        "additionalProperties": false
      },
      "revokeApiTokenOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^tok_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A tok identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": { "type": "string", "minLength": 1 },
          "ownerUid": { "type": "string", "minLength": 1 },
          "scopes": {
            "type": "array",
            "items": { "type": "string", "minLength": 1 }
          },
          "status": { "type": "string", "enum": ["active", "revoked"] },
          "tokenPrefix": { "type": "string", "minLength": 1 },
          "previousSecretGraceUntil": {
            "type": "string",
            "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))$"
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "lastUsedAt": {
            "type": "string",
            "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))$"
          },
          "revokedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "name",
          "scopes",
          "status",
          "tokenPrefix",
          "expiresAt",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "revokeBetaAccessCodeInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^bac_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A bac identifier (TypeID, conventions C5)."
          }
        },
        "required": ["id"],
        "additionalProperties": false
      },
      "revokeBetaAccessCodeOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": { "type": "string", "description": "The bac_ TypeID." },
          "boundEmail": {
            "type": "string",
            "format": "email",
            "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
          },
          "maxRedemptions": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "redeemedCount": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "consumedOrgId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "status": {
            "type": "string",
            "enum": ["active", "revoked", "exhausted"]
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "createdAt": {
            "type": "string",
            "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))$"
          }
        },
        "required": [
          "id",
          "boundEmail",
          "maxRedemptions",
          "redeemedCount",
          "status",
          "expiresAt",
          "createdAt"
        ],
        "additionalProperties": false
      },
      "revokeInvitationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "id": {
            "type": "string",
            "pattern": "^inv_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A inv identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "id"],
        "additionalProperties": false
      },
      "revokeInvitationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^inv_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A inv identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "kind": { "type": "string", "enum": ["email", "link"] },
          "role": {
            "type": "string",
            "enum": ["admin", "publisher", "member", "guest"]
          },
          "projectIds": {
            "maxItems": 10,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          "email": {
            "type": "string",
            "maxLength": 254,
            "format": "email",
            "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
          },
          "status": {
            "type": "string",
            "enum": ["pending", "accepted", "revoked", "expired", "exhausted"]
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "maxUses": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 250
          },
          "useCount": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "resendCount": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "lastSentAt": {
            "type": "string",
            "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))$"
          },
          "locale": { "type": "string", "enum": ["nl", "en", "fr"] },
          "acceptedBy": {
            "maxItems": 250,
            "type": "array",
            "items": { "type": "string", "minLength": 1 }
          },
          "acceptedAt": {
            "type": "string",
            "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))$"
          },
          "acceptedEmail": { "type": "string" },
          "revokedBy": { "type": "string", "minLength": 1 },
          "revokedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "kind",
          "role",
          "projectIds",
          "status",
          "expiresAt",
          "useCount",
          "resendCount",
          "locale",
          "acceptedBy",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "revokeMyOAuthGrantInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "grantId": {
            "type": "string",
            "pattern": "^grt_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A grt identifier (TypeID, conventions C5)."
          }
        },
        "required": ["grantId"],
        "additionalProperties": false
      },
      "revokeMyOAuthGrantOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^grt_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A grt identifier (TypeID, conventions C5)."
          },
          "uid": { "type": "string", "minLength": 1 },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "clientId": { "type": "string", "minLength": 1, "maxLength": 512 },
          "clientName": { "type": "string" },
          "clientHost": { "type": "string", "minLength": 1 },
          "scopes": {
            "minItems": 1,
            "type": "array",
            "items": { "type": "string", "minLength": 1 }
          },
          "resource": { "type": "string", "minLength": 1 },
          "status": {
            "type": "string",
            "enum": ["active", "revoked", "expired"]
          },
          "refreshExpiresAt": {
            "type": "string",
            "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))$"
          },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "lastUsedAt": {
            "type": "string",
            "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))$"
          },
          "revokedAt": {
            "type": "string",
            "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))$"
          },
          "revokedReason": {
            "type": "string",
            "enum": ["user_revoked", "reuse_detected", "member_removed"]
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          }
        },
        "required": [
          "id",
          "uid",
          "organizationId",
          "clientId",
          "clientHost",
          "scopes",
          "resource",
          "status",
          "createdAt",
          "schemaVersion",
          "revision"
        ],
        "additionalProperties": false
      },
      "revokeMySessionsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {},
        "additionalProperties": false
      },
      "revokeMySessionsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "sessionsValidAfter": {
            "type": "string",
            "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))$",
            "description": "Sessions that began before this moment are signed out. Sign in again to continue."
          },
          "organizationIds": {
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A org identifier (TypeID, conventions C5)."
            },
            "description": "The organisations whose access was ended for the older sessions."
          }
        },
        "required": ["sessionsValidAfter", "organizationIds"],
        "additionalProperties": false
      },
      "revokeOAuthGrantInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "grantId": {
            "type": "string",
            "pattern": "^grt_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A grt identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "grantId"],
        "additionalProperties": false
      },
      "revokeOAuthGrantOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^grt_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A grt identifier (TypeID, conventions C5)."
          },
          "uid": { "type": "string", "minLength": 1 },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "clientId": { "type": "string", "minLength": 1, "maxLength": 512 },
          "clientName": { "type": "string" },
          "clientHost": { "type": "string", "minLength": 1 },
          "scopes": {
            "minItems": 1,
            "type": "array",
            "items": { "type": "string", "minLength": 1 }
          },
          "resource": { "type": "string", "minLength": 1 },
          "status": {
            "type": "string",
            "enum": ["active", "revoked", "expired"]
          },
          "refreshExpiresAt": {
            "type": "string",
            "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))$"
          },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "lastUsedAt": {
            "type": "string",
            "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))$"
          },
          "revokedAt": {
            "type": "string",
            "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))$"
          },
          "revokedReason": {
            "type": "string",
            "enum": ["user_revoked", "reuse_detected", "member_removed"]
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          }
        },
        "required": [
          "id",
          "uid",
          "organizationId",
          "clientId",
          "clientHost",
          "scopes",
          "resource",
          "status",
          "createdAt",
          "schemaVersion",
          "revision"
        ],
        "additionalProperties": false
      },
      "revokeOrganizationDiscountInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "discountId": { "type": "string", "minLength": 1 },
          "note": { "type": "string", "minLength": 1, "maxLength": 500 }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "revokeOrganizationDiscountOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "revoked": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": { "type": "string", "minLength": 1 },
                "name": { "type": "string", "minLength": 1 },
                "kind": { "type": "string", "enum": ["organization", "code"] },
                "planIds": {
                  "minItems": 1,
                  "type": "array",
                  "items": {
                    "type": "string",
                    "enum": ["free", "team", "enterprise", "internal", "tryout"]
                  }
                },
                "discount": {
                  "oneOf": [
                    {
                      "type": "object",
                      "properties": {
                        "type": { "type": "string", "const": "percent" },
                        "value": {
                          "type": "number",
                          "exclusiveMinimum": 0,
                          "maximum": 100
                        }
                      },
                      "required": ["type", "value"],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "type": { "type": "string", "const": "amount_off" },
                        "cents": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        }
                      },
                      "required": ["type", "cents"],
                      "additionalProperties": false
                    }
                  ]
                },
                "duration": {
                  "anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "months": {
                          "type": "integer",
                          "exclusiveMinimum": 0,
                          "maximum": 9007199254740991
                        }
                      },
                      "required": ["months"],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "forever": { "type": "boolean", "const": true }
                      },
                      "required": ["forever"],
                      "additionalProperties": false
                    }
                  ]
                },
                "organizationId": { "type": "string", "minLength": 1 },
                "codePrefix": { "type": "string", "minLength": 1 },
                "status": { "type": "string", "enum": ["active", "ended"] },
                "startsAt": {
                  "type": "string",
                  "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))$"
                },
                "updatedAt": {
                  "type": "string",
                  "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))$"
                },
                "updatedBy": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                },
                "revision": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "endsAt": {
                  "type": "string",
                  "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))$"
                }
              },
              "required": [
                "id",
                "name",
                "kind",
                "planIds",
                "discount",
                "duration",
                "status",
                "startsAt",
                "updatedAt",
                "revision"
              ],
              "additionalProperties": false
            }
          },
          "price": {
            "description": "What the organisation pays now, usually the list price.",
            "type": "object",
            "properties": {
              "currency": { "type": "string", "const": "EUR" },
              "list": {
                "type": "object",
                "properties": {
                  "monthlyCents": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "yearlyCents": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["monthlyCents", "yearlyCents"],
                "additionalProperties": false,
                "description": "The list price, excl. VAT."
              },
              "current": {
                "type": "object",
                "properties": {
                  "monthlyCents": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "yearlyCents": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["monthlyCents", "yearlyCents"],
                "additionalProperties": false,
                "description": "What this caller pays now, excl. VAT: the list price, or the list price after its organisation's discount."
              },
              "discount": {
                "description": "The discount behind `current`; never sent to an anonymous caller.",
                "type": "object",
                "properties": {
                  "id": { "type": "string" },
                  "name": { "type": "string" },
                  "endsAt": {
                    "type": "string",
                    "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))$"
                  }
                },
                "required": ["id", "name"],
                "additionalProperties": false
              },
              "revision": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": ["currency", "list", "current", "revision"],
            "additionalProperties": false
          }
        },
        "required": ["revoked"],
        "additionalProperties": false
      },
      "revokeWorkstationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "workstationId": {
            "type": "string",
            "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A wks identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "workstationId"],
        "additionalProperties": false
      },
      "revokeWorkstationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A wks identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": { "type": "string", "minLength": 1 },
          "assignedProjectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "projectIds": {
            "default": [],
            "maxItems": 20,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          "status": {
            "type": "string",
            "enum": ["unpaired", "active", "revoked"]
          },
          "blocked": { "type": "boolean" },
          "pairedAt": {
            "type": "string",
            "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))$"
          },
          "lastSeenAt": {
            "type": "string",
            "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))$"
          },
          "revokedAt": {
            "type": "string",
            "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))$"
          },
          "revokedBy": { "type": "string", "minLength": 1 },
          "preset": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "mode": { "type": "string", "const": "fixed" },
                  "projectId": {
                    "type": "string",
                    "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A prj identifier (TypeID, conventions C5)."
                  },
                  "modelPolicy": {
                    "type": "string",
                    "const": "latest_published"
                  },
                  "viewId": {
                    "type": "string",
                    "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A vw identifier (TypeID, conventions C5)."
                  },
                  "toolbarConfig": {
                    "maxItems": 7,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^[a-z][a-zA-Z0-9-]{0,39}$"
                    }
                  },
                  "lockedSettings": {
                    "type": "object",
                    "properties": {
                      "allowProjectSwitch": { "type": "boolean" },
                      "allowShare": { "type": "boolean" },
                      "theme": {
                        "type": "string",
                        "enum": ["sunlight", "dim"]
                      },
                      "idleResetMinutes": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 120
                      }
                    },
                    "required": [
                      "allowProjectSwitch",
                      "allowShare",
                      "idleResetMinutes"
                    ],
                    "additionalProperties": false
                  }
                },
                "required": [
                  "mode",
                  "projectId",
                  "modelPolicy",
                  "lockedSettings"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "mode": { "type": "string", "const": "crew" },
                  "projectIds": {
                    "minItems": 1,
                    "maxItems": 20,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A prj identifier (TypeID, conventions C5)."
                    }
                  },
                  "modelPolicy": {
                    "type": "string",
                    "const": "latest_published"
                  },
                  "viewId": {
                    "type": "string",
                    "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A vw identifier (TypeID, conventions C5)."
                  },
                  "toolbarConfig": {
                    "maxItems": 7,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^[a-z][a-zA-Z0-9-]{0,39}$"
                    }
                  },
                  "lockedSettings": {
                    "type": "object",
                    "properties": {
                      "allowProjectSwitch": { "type": "boolean" },
                      "allowShare": { "type": "boolean" },
                      "theme": {
                        "type": "string",
                        "enum": ["sunlight", "dim"]
                      },
                      "idleResetMinutes": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 120
                      }
                    },
                    "required": [
                      "allowProjectSwitch",
                      "allowShare",
                      "idleResetMinutes"
                    ],
                    "additionalProperties": false
                  }
                },
                "required": [
                  "mode",
                  "projectIds",
                  "modelPolicy",
                  "lockedSettings"
                ],
                "additionalProperties": false
              }
            ]
          },
          "runtime": {
            "type": "object",
            "properties": {
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "currentProjectId": {
                "type": "string",
                "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A prj identifier (TypeID, conventions C5)."
              },
              "appVersion": {
                "type": "string",
                "minLength": 1,
                "maxLength": 64
              },
              "state": { "type": "string", "enum": ["ready", "error"] }
            },
            "required": ["heartbeatAt"],
            "additionalProperties": false
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "name",
          "projectIds",
          "status",
          "blocked",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "rotateApiTokenInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "apiTokenId": {
            "type": "string",
            "pattern": "^tok_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A tok identifier (TypeID, conventions C5)."
          },
          "graceHours": {
            "description": "0-168 h the OLD secret stays valid (BR-12). Defaults to 24.",
            "type": "integer",
            "minimum": 0,
            "maximum": 168
          }
        },
        "required": ["organizationId", "apiTokenId"],
        "additionalProperties": false
      },
      "rotateApiTokenOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^tok_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A tok identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": { "type": "string", "minLength": 1 },
          "ownerUid": { "type": "string", "minLength": 1 },
          "scopes": {
            "type": "array",
            "items": { "type": "string", "minLength": 1 }
          },
          "status": { "type": "string", "enum": ["active", "revoked"] },
          "tokenPrefix": { "type": "string", "minLength": 1 },
          "previousSecretGraceUntil": {
            "type": "string",
            "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))$"
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "lastUsedAt": {
            "type": "string",
            "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))$"
          },
          "revokedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "secret": {
            "type": "string",
            "description": "The NEW raw bearer secret -- shown here ONCE, same as createApiToken."
          }
        },
        "required": [
          "id",
          "organizationId",
          "name",
          "scopes",
          "status",
          "tokenPrefix",
          "expiresAt",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy",
          "secret"
        ],
        "additionalProperties": false
      },
      "searchDocumentTextInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "query": {
            "type": "string",
            "minLength": 2,
            "maxLength": 200,
            "description": "The text to find on the drawings, e.g. `W-103` (at least 2 characters). A word matches when it contains the query; case and accents are ignored."
          },
          "documentIds": {
            "description": "Only these drawings: a comma-separated list of up to 50 document ids.",
            "type": "string",
            "pattern": "^doc_[0-9a-z]{26}(,doc_[0-9a-z]{26}){0,49}$"
          },
          "limit": {
            "description": "Drawings searched per page (1-50). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 50
          },
          "cursor": {
            "description": "Opaque cursor from a previous page's nextCursor (same query and documentIds).",
            "type": "string",
            "minLength": 1
          }
        },
        "required": ["organizationId", "projectId", "query"],
        "additionalProperties": false
      },
      "searchDocumentTextOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "documentId": {
                  "type": "string",
                  "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A doc identifier (TypeID, conventions C5)."
                },
                "versionId": {
                  "type": "string",
                  "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A dvr identifier (TypeID, conventions C5)."
                },
                "page": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991,
                  "description": "1-based page (sheet)."
                },
                "text": {
                  "type": "string",
                  "description": "The whole word that matched."
                },
                "xPct": { "type": "number", "minimum": 0, "maximum": 1 },
                "yPct": { "type": "number", "minimum": 0, "maximum": 1 },
                "wPct": { "type": "number", "minimum": 0, "maximum": 1 },
                "hPct": { "type": "number", "minimum": 0, "maximum": 1 },
                "box": {
                  "description": "CAD only: the word's box in drawing units, `[x, y, w, h]` (bottom-left origin).",
                  "type": "array",
                  "prefixItems": [
                    { "type": "number" },
                    { "type": "number" },
                    { "type": "number" },
                    { "type": "number" }
                  ],
                  "items": false,
                  "minItems": 4,
                  "maxItems": 4
                }
              },
              "required": [
                "documentId",
                "versionId",
                "page",
                "text",
                "xPct",
                "yPct",
                "wPct",
                "hPct"
              ],
              "additionalProperties": false,
              "description": "One word on a page that contains the query; its box as fractions of the page (top-left origin), and on a CAD sheet also in drawing units."
            },
            "description": "This page's hits: drawing by drawing, page by page, in reading order."
          },
          "truncated": {
            "description": "True when this page found more than 500 hits and returned the first 500.",
            "type": "boolean"
          },
          "nextCursor": {
            "description": "Opaque cursor for the next drawings. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "searchElementsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "q": {
            "type": "string",
            "minLength": 1,
            "maxLength": 200,
            "description": "What to look for in the element's name, tag or IFC class, e.g. `W-103`. Case and accents are ignored; every word must occur."
          },
          "limit": {
            "description": "Max hits per page (1-100). Defaults per transport (REST 25, MCP 20).",
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "cursor": {
            "description": "Opaque cursor from a previous page's nextCursor (same q).",
            "type": "string",
            "minLength": 1
          }
        },
        "required": ["organizationId", "projectId", "q"],
        "additionalProperties": false
      },
      "searchElementsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "globalId": {
                  "type": "string",
                  "description": "The element's IFC GlobalId."
                },
                "name": { "type": ["string", "null"] },
                "tag": { "type": ["string", "null"] },
                "type": {
                  "type": "string",
                  "description": "IFC class, e.g. `IfcWall`."
                },
                "storey": {
                  "anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "globalId": { "type": "string" },
                        "name": { "type": ["string", "null"] }
                      },
                      "required": ["globalId", "name"],
                      "additionalProperties": false
                    },
                    { "type": "null" }
                  ]
                }
              },
              "required": ["globalId", "name", "tag", "type", "storey"],
              "additionalProperties": false
            },
            "description": "This page of hits, best match first."
          },
          "nextCursor": {
            "description": "Opaque cursor for the next page. Absent (not null) on the last page.",
            "type": "string"
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "sendWorkstationHeartbeatInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "workstationId": {
            "type": "string",
            "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "The calling device's own workstation id."
          },
          "currentProjectId": {
            "description": "The project on screen. Kept only when it is one of the workstation's own projects.",
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
          },
          "appVersion": {
            "description": "The app build the screen runs.",
            "type": "string",
            "minLength": 1,
            "maxLength": 64
          },
          "state": {
            "description": "`ready` while the scene is interactive; `error` once it has failed to open three times in a row.",
            "type": "string",
            "enum": ["ready", "error"]
          }
        },
        "required": ["organizationId", "workstationId"],
        "additionalProperties": false
      },
      "sendWorkstationHeartbeatOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "workstationId": {
            "type": "string",
            "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A wks identifier (TypeID, conventions C5)."
          },
          "heartbeatAt": {
            "type": "string",
            "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))$"
          },
          "recorded": {
            "type": "boolean",
            "description": "`false` when the previous heartbeat is under 30 seconds old: nothing was written."
          }
        },
        "required": ["workstationId", "heartbeatAt", "recorded"],
        "additionalProperties": false
      },
      "setCurrentProjectRevisionInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "number": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991,
            "description": "The revision number within the project."
          }
        },
        "required": ["organizationId", "projectId", "number"],
        "additionalProperties": false
      },
      "setCurrentProjectRevisionOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": [
              "uploading",
              "uploaded",
              "processing",
              "ready",
              "failed",
              "archived",
              "cancelled"
            ]
          },
          "publication": {
            "type": "string",
            "enum": ["draft", "published", "superseded"]
          },
          "fieldVisible": { "type": "boolean" },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "upload" },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "fileName", "sizeBytes", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "copy" },
                  "sourceVersionId": {
                    "type": "string",
                    "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A ver identifier (TypeID, conventions C5)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": [
                  "kind",
                  "sourceVersionId",
                  "fileName",
                  "sizeBytes",
                  "contentType"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "url" },
                  "url": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 2048,
                    "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "url", "fileName", "contentType"],
                "additionalProperties": false
              }
            ]
          },
          "upload": {
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "cancelReason": { "type": "string", "enum": ["user", "expired"] },
          "pipelineVersion": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": { "type": "string" },
                "blocking": { "type": "boolean" },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": {}
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": { "type": "string", "minLength": 1 },
              "retryable": { "type": "boolean" },
              "params": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": {}
              },
              "messageKey": { "type": "string", "minLength": 1 },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "retryable"],
            "additionalProperties": false
          },
          "processing": {
            "type": "object",
            "properties": {
              "sizeClass": { "type": "string", "enum": ["s", "m", "l", "xl"] },
              "executionName": { "type": "string", "minLength": 1 },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "queuedAt": {
                "type": "string",
                "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))$"
              },
              "queuedTraceparent": {
                "type": "string",
                "pattern": "^(?!ff)[0-9a-f]{2}-(?!0{32})[0-9a-f]{32}-(?!0{16})[0-9a-f]{16}-[0-9a-f]{2}$"
              },
              "queuedEscalation": {
                "type": "object",
                "properties": {
                  "sizeClass": {
                    "type": "string",
                    "enum": ["s", "m", "l", "xl"]
                  },
                  "attempt": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["sizeClass", "attempt"],
                "additionalProperties": false
              },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "progressReportedAt": {
                "type": "string",
                "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))$"
              },
              "requestId": { "type": "string", "minLength": 1 }
            },
            "additionalProperties": false
          },
          "progress": {
            "type": "object",
            "properties": {
              "stage": { "type": "string", "minLength": 1 },
              "percent": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["stage", "percent"],
            "additionalProperties": false
          },
          "reprocessing": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "reason": {
                "type": "string",
                "enum": ["retry", "pipeline_upgrade"]
              },
              "targetPipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "state": {
                "type": "string",
                "enum": [
                  "requested",
                  "deferred",
                  "awaiting_rollout",
                  "done",
                  "failed"
                ]
              },
              "completedAt": {
                "type": "string",
                "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))$"
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1 },
                  "retryable": { "type": "boolean" },
                  "params": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": {}
                  },
                  "messageKey": { "type": "string", "minLength": 1 },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "retryable"],
                "additionalProperties": false
              }
            },
            "required": ["requestedAt", "requestedBy", "attempt"],
            "additionalProperties": false
          },
          "releasedAt": {
            "type": "string",
            "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))$"
          },
          "releasedBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "supersededAt": {
            "type": "string",
            "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))$"
          },
          "activeArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "nextArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "stats": {
            "type": "object",
            "properties": {
              "elementCount": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "boundsMm": {
                "type": "object",
                "properties": {
                  "min": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3
                  },
                  "max": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3
                  }
                },
                "required": ["min", "max"],
                "additionalProperties": false
              },
              "coveragePct": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["elementCount", "boundsMm"],
            "additionalProperties": false
          },
          "churn": {
            "type": "object",
            "properties": {
              "ratio": { "type": "number", "minimum": 0, "maximum": 1 },
              "added": { "type": "array", "items": { "type": "string" } },
              "removed": { "type": "array", "items": { "type": "string" } },
              "moved": { "type": "array", "items": { "type": "string" } },
              "recreated": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "from": { "type": "string" },
                    "to": { "type": "string" }
                  },
                  "required": ["from", "to"],
                  "additionalProperties": false
                }
              }
            },
            "required": ["ratio", "added", "removed", "moved", "recreated"],
            "additionalProperties": false
          },
          "label": {
            "type": "string",
            "minLength": 1,
            "maxLength": 40,
            "description": "Short version name, e.g. \"Roof fix\" (1-40 chars after trimming, BR-10)."
          },
          "notes": {
            "type": "string",
            "maxLength": 2000,
            "description": "Free-form notes for the crew (max 2000 chars, BR-10)."
          },
          "detailsEditedAt": {
            "type": "string",
            "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))$"
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "publishOnReady": {
            "description": "Publish this version automatically, in the same write that marks it ready (FV-383).",
            "type": "boolean"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "number": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991,
            "description": "The revision number within the project (1, 2, 3...)."
          },
          "current": {
            "type": "boolean",
            "description": "Whether this is the revision the field sees now."
          },
          "publishedAt": {
            "description": "When this revision was (last) published; absent for a revision never published.",
            "type": "string",
            "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))$"
          },
          "publishedBy": {
            "description": "Who published it; absent for a revision never published, or published before FV-384 and no longer current.",
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "publishedByName": {
            "description": "The publisher's display name, when they are a member.",
            "type": "string",
            "minLength": 1
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "modelId",
          "versionNumber",
          "status",
          "publication",
          "fieldVisible",
          "source",
          "pipelineVersion",
          "warnings",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy",
          "number",
          "current"
        ],
        "additionalProperties": false
      },
      "setDocumentVersionPageScaleInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dvr identifier (TypeID, conventions C5)."
          },
          "pageNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991,
            "description": "The 1-based page (sheet) of the version."
          },
          "scale": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "factor": {
                    "type": "number",
                    "exclusiveMinimum": 0,
                    "maximum": 10000,
                    "description": "Real millimetres per paper millimetre (1:50 is 50)."
                  },
                  "source": {
                    "type": "string",
                    "enum": ["calibration", "label"],
                    "description": "calibration: two points and a known length; label: the title-block scale, confirmed."
                  },
                  "basis": {
                    "description": "For a calibration: the two points (fractions of the page) and the real length in mm.",
                    "type": "object",
                    "properties": {
                      "a": {
                        "type": "object",
                        "properties": {
                          "xPct": {
                            "type": "number",
                            "minimum": 0,
                            "maximum": 1
                          },
                          "yPct": {
                            "type": "number",
                            "minimum": 0,
                            "maximum": 1
                          }
                        },
                        "required": ["xPct", "yPct"],
                        "additionalProperties": false
                      },
                      "b": {
                        "type": "object",
                        "properties": {
                          "xPct": {
                            "type": "number",
                            "minimum": 0,
                            "maximum": 1
                          },
                          "yPct": {
                            "type": "number",
                            "minimum": 0,
                            "maximum": 1
                          }
                        },
                        "required": ["xPct", "yPct"],
                        "additionalProperties": false
                      },
                      "lengthMm": { "type": "number", "exclusiveMinimum": 0 }
                    },
                    "required": ["a", "b", "lengthMm"],
                    "additionalProperties": false
                  }
                },
                "required": ["factor", "source"],
                "additionalProperties": false
              },
              { "type": "null" }
            ],
            "description": "The page's scale: factor (real mm per paper mm, 1:50 is 50, at most 10 000), source (calibration | label) and, for a calibration, the two points and the real length; null clears it."
          }
        },
        "required": [
          "organizationId",
          "projectId",
          "documentId",
          "versionId",
          "pageNumber",
          "scale"
        ],
        "additionalProperties": false
      },
      "setDocumentVersionPageScaleOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dvr identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": [
              "uploading",
              "uploaded",
              "processing",
              "ready",
              "failed",
              "archived",
              "cancelled"
            ]
          },
          "publication": {
            "type": "string",
            "enum": ["draft", "published", "superseded"]
          },
          "fieldVisible": { "type": "boolean" },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "upload" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "fileName", "sizeBytes", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "url" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "url": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 2048,
                    "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "url", "fileName", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "copy" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "sourceVersionId": {
                    "type": "string",
                    "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A dvr identifier (TypeID, conventions C5)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": [
                  "kind",
                  "sourceVersionId",
                  "fileName",
                  "sizeBytes",
                  "contentType"
                ],
                "additionalProperties": false
              }
            ]
          },
          "upload": {
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          },
          "cancelReason": { "type": "string", "enum": ["user"] },
          "pipelineVersion": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": { "type": "string" },
                "blocking": { "type": "boolean" },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": {}
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "progress": {
            "type": "object",
            "properties": {
              "stage": { "type": "string", "minLength": 1 },
              "percent": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["stage", "percent"],
            "additionalProperties": false
          },
          "processing": {
            "type": "object",
            "properties": {
              "sizeClass": { "type": "string", "enum": ["s", "m", "l", "xl"] },
              "executionName": { "type": "string", "minLength": 1 },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "queuedAt": {
                "type": "string",
                "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))$"
              },
              "queuedTraceparent": {
                "type": "string",
                "pattern": "^(?!ff)[0-9a-f]{2}-(?!0{32})[0-9a-f]{32}-(?!0{16})[0-9a-f]{16}-[0-9a-f]{2}$"
              },
              "queuedEscalation": {
                "type": "object",
                "properties": {
                  "sizeClass": {
                    "type": "string",
                    "enum": ["s", "m", "l", "xl"]
                  },
                  "attempt": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["sizeClass", "attempt"],
                "additionalProperties": false
              },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "progressReportedAt": {
                "type": "string",
                "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))$"
              },
              "requestId": { "type": "string", "minLength": 1 }
            },
            "additionalProperties": false
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": { "type": "string", "minLength": 1 },
              "retryable": { "type": "boolean" },
              "params": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": {}
              },
              "messageKey": { "type": "string", "minLength": 1 },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "retryable"],
            "additionalProperties": false
          },
          "activeArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "reprocessing": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "reason": {
                "type": "string",
                "enum": ["retry", "pipeline_upgrade"]
              },
              "targetPipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "state": {
                "type": "string",
                "enum": [
                  "requested",
                  "deferred",
                  "awaiting_rollout",
                  "done",
                  "failed"
                ]
              },
              "completedAt": {
                "type": "string",
                "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))$"
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1 },
                  "retryable": { "type": "boolean" },
                  "params": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": {}
                  },
                  "messageKey": { "type": "string", "minLength": 1 },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "retryable"],
                "additionalProperties": false
              }
            },
            "required": ["requestedAt", "requestedBy", "attempt"],
            "additionalProperties": false
          },
          "pageCount": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "pages": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "pageNumber": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "scanned": { "type": "boolean" },
                "sheetNumber": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 100,
                  "description": "Sheet number, e.g. \"W-101\" (BR-11)."
                },
                "title": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 200,
                  "description": "Sheet title, e.g. from the PDF outline (BR-11)."
                },
                "discipline": {
                  "type": "string",
                  "enum": [
                    "architecture",
                    "structure",
                    "mechanical",
                    "electrical",
                    "plumbing",
                    "fire_protection",
                    "civil",
                    "landscape",
                    "general"
                  ]
                },
                "storeyId": { "type": "string", "minLength": 1 },
                "overridden": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "enum": ["sheetNumber", "title", "discipline"]
                  }
                },
                "layout": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "kind": { "type": "string", "enum": ["model", "paper"] }
                  },
                  "required": ["name", "kind"],
                  "additionalProperties": false
                },
                "titleBlock": {
                  "type": "object",
                  "propertyNames": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 64
                  },
                  "additionalProperties": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "description": "FV-490 (E13 §4.4): a CAD page's primary title block, attribute tag -> value (<= 32 entries, values <= 200 chars)."
                },
                "scale": {
                  "type": "object",
                  "properties": {
                    "factor": {
                      "type": "number",
                      "exclusiveMinimum": 0,
                      "maximum": 10000,
                      "description": "Real millimetres per paper millimetre (1:50 is 50)."
                    },
                    "source": {
                      "type": "string",
                      "enum": ["calibration", "label"],
                      "description": "calibration: two points and a known length; label: the title-block scale, confirmed."
                    },
                    "basis": {
                      "description": "For a calibration: the two points (fractions of the page) and the real length in mm.",
                      "type": "object",
                      "properties": {
                        "a": {
                          "type": "object",
                          "properties": {
                            "xPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            },
                            "yPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            }
                          },
                          "required": ["xPct", "yPct"],
                          "additionalProperties": false
                        },
                        "b": {
                          "type": "object",
                          "properties": {
                            "xPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            },
                            "yPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            }
                          },
                          "required": ["xPct", "yPct"],
                          "additionalProperties": false
                        },
                        "lengthMm": { "type": "number", "exclusiveMinimum": 0 }
                      },
                      "required": ["a", "b", "lengthMm"],
                      "additionalProperties": false
                    },
                    "setBy": { "type": "string", "minLength": 1 },
                    "setAt": {
                      "type": "string",
                      "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))$"
                    }
                  },
                  "required": ["factor", "source", "setBy", "setAt"],
                  "additionalProperties": false
                }
              },
              "required": ["pageNumber", "scanned"],
              "additionalProperties": false
            }
          },
          "cad": {
            "type": "object",
            "properties": {
              "insunits": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "unitToMm": {
                "anyOf": [
                  { "type": "number", "exclusiveMinimum": 0 },
                  { "type": "null" }
                ]
              },
              "unitsOverride": {
                "type": "string",
                "enum": ["mm", "cm", "m", "in", "ft"],
                "description": "The drawing's units, set by a publisher because the file declares none: mm, cm, m, in or ft."
              },
              "defaultLayersOff": {
                "maxItems": 256,
                "type": "array",
                "items": { "type": "string", "minLength": 1, "maxLength": 255 },
                "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
              },
              "parser": { "type": "string", "const": "acad-ts" },
              "parserVersion": { "type": "string", "minLength": 1 },
              "version": { "type": "string", "minLength": 1 },
              "layoutCount": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "insunits",
              "unitToMm",
              "parser",
              "parserVersion",
              "version",
              "layoutCount"
            ],
            "additionalProperties": false
          },
          "layerDefault": {
            "type": "object",
            "properties": {
              "off": {
                "maxItems": 256,
                "type": "array",
                "items": { "type": "string", "minLength": 1, "maxLength": 255 },
                "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
              }
            },
            "required": ["off"],
            "additionalProperties": false,
            "description": "The layers off by default for everyone who opens this drawing (CAD layers or PDF optional content groups, by name). A person's own choice on their device still wins."
          },
          "publishOnReady": {
            "description": "Publish this version automatically, in the same write that marks it ready (FV-745).",
            "type": "boolean"
          },
          "releasedAt": {
            "type": "string",
            "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))$"
          },
          "supersededAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "documentId",
          "versionNumber",
          "status",
          "publication",
          "fieldVisible",
          "source",
          "pipelineVersion",
          "warnings",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "setOrganizationSupportAccessInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "supportAccess": {
            "type": "string",
            "enum": ["allowed", "ask"],
            "description": "allowed: support may open access, owners are e-mailed. ask: an owner approves first."
          }
        },
        "required": ["organizationId", "supportAccess"],
        "additionalProperties": false
      },
      "setOrganizationSupportAccessOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 2,
            "maxLength": 80,
            "description": "Organisation display name (2-80 chars after trimming, BR-10)."
          },
          "defaultLocale": {
            "type": "string",
            "enum": ["nl", "en", "fr"],
            "description": "The organisation's default UI locale, one of nl | en | fr."
          },
          "status": {
            "type": "string",
            "enum": ["active", "pending_deletion"]
          },
          "deletion": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "purgeAfter": {
                "type": "string",
                "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))$"
              },
              "cancelledAt": {
                "type": "string",
                "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))$"
              },
              "purgeStartedAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["requestedAt", "requestedBy", "purgeAfter"],
            "additionalProperties": false
          },
          "supportAccess": {
            "description": "Whether Field-Viewer support may open a read-only support session: allowed (default when absent; owners are e-mailed) or ask (an owner approves each request first).",
            "type": "string",
            "enum": ["allowed", "ask"]
          },
          "settings": {
            "type": "object",
            "properties": {
              "analytics": {
                "type": "object",
                "properties": {
                  "mode": {
                    "type": "string",
                    "enum": ["enabled", "disabled"],
                    "description": "Product analytics for every member: enabled (the default) or disabled. Disabled, no usage event is recorded for anyone in the organisation."
                  }
                },
                "required": ["mode"],
                "additionalProperties": false
              },
              "cad": {
                "type": "object",
                "properties": {
                  "producerDetailTags": {
                    "type": "object",
                    "properties": {
                      "scale": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's scale text (1:n)."
                      },
                      "xFactor": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's x factor (1/n)."
                      },
                      "yFactor": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's y factor (1/n)."
                      },
                      "xMin": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's minimum x."
                      },
                      "yMin": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's minimum y."
                      },
                      "xMax": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's maximum x."
                      },
                      "yMax": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's maximum y."
                      }
                    },
                    "required": [
                      "scale",
                      "xFactor",
                      "yFactor",
                      "xMin",
                      "yMin",
                      "xMax",
                      "yMax"
                    ],
                    "additionalProperties": false,
                    "description": "The CAD producer's detail attribute tags: all seven, each the tag (not the value) of one block attribute. With them, scaled details in model space measure in real millimetres at their own scale; without them they read 'scale unknown'."
                  }
                },
                "additionalProperties": false
              }
            },
            "additionalProperties": false
          },
          "legal": {
            "type": "object",
            "properties": {
              "termsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "privacyVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "dpaVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "subprocessorsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "acceptedAt": {
                "type": "string",
                "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))$"
              },
              "acceptedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              }
            },
            "required": [
              "termsVersion",
              "privacyVersion",
              "dpaVersion",
              "subprocessorsVersion",
              "acceptedAt",
              "acceptedBy"
            ],
            "additionalProperties": false,
            "description": "The terms, privacy notice, DPA and sub-processor list versions an owner accepted for the organisation."
          },
          "kind": {
            "description": "standard (default when absent) or tryout: an anonymous visitor's 7-day try-it organisation.",
            "type": "string",
            "enum": ["standard", "tryout"]
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "logoUrl": {
            "type": "object",
            "properties": {
              "url": { "type": "string" },
              "expiresAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["url", "expiresAt"],
            "additionalProperties": false,
            "description": "Signed URL of the organisation's logo (15 minutes). Absent when it has no logo."
          },
          "reacceptanceRequired": {
            "description": "True when an owner must accept a newer material version of the terms, the DPA or the sub-processor list (or never accepted them).",
            "type": "boolean"
          }
        },
        "required": [
          "id",
          "name",
          "defaultLocale",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "setProjectAccessModeInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "access": { "type": "string", "enum": ["org", "restricted"] }
        },
        "required": ["organizationId", "projectId", "access"],
        "additionalProperties": false
      },
      "setProjectAccessModeOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "project": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A prj identifier (TypeID, conventions C5)."
              },
              "organizationId": {
                "type": "string",
                "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A org identifier (TypeID, conventions C5)."
              },
              "name": {
                "type": "string",
                "minLength": 1,
                "maxLength": 80,
                "description": "Project display name (1-80 chars after trimming, BR-2)."
              },
              "reference": {
                "type": "string",
                "minLength": 1,
                "maxLength": 40,
                "description": "Free-form job/reference code, e.g. \"2026-041\" (BR-2)."
              },
              "description": {
                "type": "string",
                "maxLength": 500,
                "description": "Free-form project description (BR-2)."
              },
              "status": {
                "type": "string",
                "enum": ["active", "archived", "deleted"]
              },
              "access": { "type": "string", "enum": ["org", "restricted"] },
              "memberIds": {
                "maxItems": 500,
                "type": "array",
                "items": { "type": "string", "minLength": 1 }
              },
              "fieldVersionIds": {
                "maxItems": 500,
                "type": "array",
                "items": {
                  "type": "string",
                  "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A ver identifier (TypeID, conventions C5)."
                }
              },
              "publishSeq": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "lastPublishedAt": {
                "type": "string",
                "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))$"
              },
              "isSample": { "type": "boolean", "const": true },
              "demoSlug": {
                "type": "string",
                "enum": [
                  "landhuis_hulstveld",
                  "landhuis_hulstveld_hsb",
                  "woning_lindehof",
                  "villa_berkenhaag",
                  "hal_noorderkempen",
                  "paneelset_werkplaats"
                ]
              },
              "archivedAt": {
                "type": "string",
                "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))$"
              },
              "deletedAt": {
                "type": "string",
                "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))$"
              },
              "purgeAfter": {
                "type": "string",
                "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))$"
              },
              "statusBeforeDeletion": {
                "type": "string",
                "enum": ["active", "archived"]
              },
              "purgeStartedAt": {
                "type": "string",
                "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))$"
              },
              "sheetMetadata": {
                "type": "object",
                "properties": {
                  "fileNamePattern": {
                    "type": "string",
                    "description": "Regular expression matched against the file name without its .pdf extension, with named groups sheetNumber and/or discipline, e.g. ^(?<discipline>[A-Z])-(?<sheetNumber>\\d+) (max 200 chars; no backreferences or nested repeats)."
                  },
                  "disciplineMap": {
                    "type": "object",
                    "propertyNames": {
                      "type": "string",
                      "pattern": "^[A-Za-z0-9]{1,8}$"
                    },
                    "additionalProperties": {
                      "type": "string",
                      "enum": [
                        "architecture",
                        "structure",
                        "mechanical",
                        "electrical",
                        "plumbing",
                        "fire_protection",
                        "civil",
                        "landscape",
                        "general"
                      ]
                    }
                  }
                },
                "additionalProperties": false,
                "description": "How this project's PDF file names map to sheet number and discipline (BR-11). Without a fileNamePattern the file-name stem is the sheet number."
              },
              "schemaVersion": { "type": "number", "const": 1 },
              "createdAt": {
                "type": "string",
                "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))$"
              },
              "updatedAt": {
                "type": "string",
                "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))$"
              },
              "revision": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "createdBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              }
            },
            "required": [
              "id",
              "organizationId",
              "name",
              "status",
              "access",
              "memberIds",
              "schemaVersion",
              "createdAt",
              "updatedAt",
              "revision",
              "createdBy"
            ],
            "additionalProperties": false
          },
          "impactCount": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          }
        },
        "required": ["project", "impactCount"],
        "additionalProperties": false
      },
      "startDocumentVersionProcessingInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dvr identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "documentId", "versionId"],
        "additionalProperties": false
      },
      "startDocumentVersionProcessingOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dvr identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": [
              "uploading",
              "uploaded",
              "processing",
              "ready",
              "failed",
              "archived",
              "cancelled"
            ]
          },
          "publication": {
            "type": "string",
            "enum": ["draft", "published", "superseded"]
          },
          "fieldVisible": { "type": "boolean" },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "upload" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "fileName", "sizeBytes", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "url" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "url": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 2048,
                    "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "url", "fileName", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "copy" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "sourceVersionId": {
                    "type": "string",
                    "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A dvr identifier (TypeID, conventions C5)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": [
                  "kind",
                  "sourceVersionId",
                  "fileName",
                  "sizeBytes",
                  "contentType"
                ],
                "additionalProperties": false
              }
            ]
          },
          "upload": {
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          },
          "cancelReason": { "type": "string", "enum": ["user"] },
          "pipelineVersion": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": { "type": "string" },
                "blocking": { "type": "boolean" },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": {}
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "progress": {
            "type": "object",
            "properties": {
              "stage": { "type": "string", "minLength": 1 },
              "percent": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["stage", "percent"],
            "additionalProperties": false
          },
          "processing": {
            "type": "object",
            "properties": {
              "sizeClass": { "type": "string", "enum": ["s", "m", "l", "xl"] },
              "executionName": { "type": "string", "minLength": 1 },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "queuedAt": {
                "type": "string",
                "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))$"
              },
              "queuedTraceparent": {
                "type": "string",
                "pattern": "^(?!ff)[0-9a-f]{2}-(?!0{32})[0-9a-f]{32}-(?!0{16})[0-9a-f]{16}-[0-9a-f]{2}$"
              },
              "queuedEscalation": {
                "type": "object",
                "properties": {
                  "sizeClass": {
                    "type": "string",
                    "enum": ["s", "m", "l", "xl"]
                  },
                  "attempt": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["sizeClass", "attempt"],
                "additionalProperties": false
              },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "progressReportedAt": {
                "type": "string",
                "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))$"
              },
              "requestId": { "type": "string", "minLength": 1 }
            },
            "additionalProperties": false
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": { "type": "string", "minLength": 1 },
              "retryable": { "type": "boolean" },
              "params": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": {}
              },
              "messageKey": { "type": "string", "minLength": 1 },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "retryable"],
            "additionalProperties": false
          },
          "activeArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "reprocessing": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "reason": {
                "type": "string",
                "enum": ["retry", "pipeline_upgrade"]
              },
              "targetPipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "state": {
                "type": "string",
                "enum": [
                  "requested",
                  "deferred",
                  "awaiting_rollout",
                  "done",
                  "failed"
                ]
              },
              "completedAt": {
                "type": "string",
                "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))$"
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1 },
                  "retryable": { "type": "boolean" },
                  "params": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": {}
                  },
                  "messageKey": { "type": "string", "minLength": 1 },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "retryable"],
                "additionalProperties": false
              }
            },
            "required": ["requestedAt", "requestedBy", "attempt"],
            "additionalProperties": false
          },
          "pageCount": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "pages": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "pageNumber": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "scanned": { "type": "boolean" },
                "sheetNumber": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 100,
                  "description": "Sheet number, e.g. \"W-101\" (BR-11)."
                },
                "title": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 200,
                  "description": "Sheet title, e.g. from the PDF outline (BR-11)."
                },
                "discipline": {
                  "type": "string",
                  "enum": [
                    "architecture",
                    "structure",
                    "mechanical",
                    "electrical",
                    "plumbing",
                    "fire_protection",
                    "civil",
                    "landscape",
                    "general"
                  ]
                },
                "storeyId": { "type": "string", "minLength": 1 },
                "overridden": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "enum": ["sheetNumber", "title", "discipline"]
                  }
                },
                "layout": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "kind": { "type": "string", "enum": ["model", "paper"] }
                  },
                  "required": ["name", "kind"],
                  "additionalProperties": false
                },
                "titleBlock": {
                  "type": "object",
                  "propertyNames": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 64
                  },
                  "additionalProperties": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "description": "FV-490 (E13 §4.4): a CAD page's primary title block, attribute tag -> value (<= 32 entries, values <= 200 chars)."
                },
                "scale": {
                  "type": "object",
                  "properties": {
                    "factor": {
                      "type": "number",
                      "exclusiveMinimum": 0,
                      "maximum": 10000,
                      "description": "Real millimetres per paper millimetre (1:50 is 50)."
                    },
                    "source": {
                      "type": "string",
                      "enum": ["calibration", "label"],
                      "description": "calibration: two points and a known length; label: the title-block scale, confirmed."
                    },
                    "basis": {
                      "description": "For a calibration: the two points (fractions of the page) and the real length in mm.",
                      "type": "object",
                      "properties": {
                        "a": {
                          "type": "object",
                          "properties": {
                            "xPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            },
                            "yPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            }
                          },
                          "required": ["xPct", "yPct"],
                          "additionalProperties": false
                        },
                        "b": {
                          "type": "object",
                          "properties": {
                            "xPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            },
                            "yPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            }
                          },
                          "required": ["xPct", "yPct"],
                          "additionalProperties": false
                        },
                        "lengthMm": { "type": "number", "exclusiveMinimum": 0 }
                      },
                      "required": ["a", "b", "lengthMm"],
                      "additionalProperties": false
                    },
                    "setBy": { "type": "string", "minLength": 1 },
                    "setAt": {
                      "type": "string",
                      "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))$"
                    }
                  },
                  "required": ["factor", "source", "setBy", "setAt"],
                  "additionalProperties": false
                }
              },
              "required": ["pageNumber", "scanned"],
              "additionalProperties": false
            }
          },
          "cad": {
            "type": "object",
            "properties": {
              "insunits": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "unitToMm": {
                "anyOf": [
                  { "type": "number", "exclusiveMinimum": 0 },
                  { "type": "null" }
                ]
              },
              "unitsOverride": {
                "type": "string",
                "enum": ["mm", "cm", "m", "in", "ft"],
                "description": "The drawing's units, set by a publisher because the file declares none: mm, cm, m, in or ft."
              },
              "defaultLayersOff": {
                "maxItems": 256,
                "type": "array",
                "items": { "type": "string", "minLength": 1, "maxLength": 255 },
                "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
              },
              "parser": { "type": "string", "const": "acad-ts" },
              "parserVersion": { "type": "string", "minLength": 1 },
              "version": { "type": "string", "minLength": 1 },
              "layoutCount": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "insunits",
              "unitToMm",
              "parser",
              "parserVersion",
              "version",
              "layoutCount"
            ],
            "additionalProperties": false
          },
          "layerDefault": {
            "type": "object",
            "properties": {
              "off": {
                "maxItems": 256,
                "type": "array",
                "items": { "type": "string", "minLength": 1, "maxLength": 255 },
                "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
              }
            },
            "required": ["off"],
            "additionalProperties": false,
            "description": "The layers off by default for everyone who opens this drawing (CAD layers or PDF optional content groups, by name). A person's own choice on their device still wins."
          },
          "publishOnReady": {
            "description": "Publish this version automatically, in the same write that marks it ready (FV-745).",
            "type": "boolean"
          },
          "releasedAt": {
            "type": "string",
            "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))$"
          },
          "supersededAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "documentId",
          "versionNumber",
          "status",
          "publication",
          "fieldVisible",
          "source",
          "pipelineVersion",
          "warnings",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "startSupportAccessInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "reason": {
            "type": "string",
            "minLength": 10,
            "maxLength": 500,
            "description": "Why support needs access, at least 10 characters (BR-44). Shown to the organisation's owners."
          },
          "durationMinutes": {
            "description": "How long the grant lasts, in minutes. Default 60, at most 120.",
            "type": "integer",
            "minimum": 1,
            "maximum": 120
          }
        },
        "required": ["organizationId", "reason"],
        "additionalProperties": false
      },
      "startSupportAccessOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": { "type": "string", "minLength": 1 },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "uid": {
            "type": "string",
            "minLength": 1,
            "description": "The platform admin's user id."
          },
          "reason": { "type": "string" },
          "status": {
            "type": "string",
            "enum": ["active", "ended", "expired"]
          },
          "startedAt": {
            "type": "string",
            "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))$"
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "endedAt": {
            "type": "string",
            "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))$"
          }
        },
        "required": [
          "id",
          "organizationId",
          "uid",
          "reason",
          "status",
          "startedAt",
          "expiresAt"
        ],
        "additionalProperties": false
      },
      "suspendOrganizationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "reason": {
            "type": "string",
            "minLength": 1,
            "maxLength": 500,
            "description": "Why the organisation is suspended, e.g. a support ticket. Kept in the audit log."
          }
        },
        "required": ["organizationId", "reason"],
        "additionalProperties": false
      },
      "suspendOrganizationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 2,
            "maxLength": 80,
            "description": "Organisation display name (2-80 chars after trimming, BR-10)."
          },
          "planId": {
            "type": "string",
            "enum": ["beta", "free", "team", "enterprise", "internal", "tryout"]
          },
          "orgStatus": {
            "type": "string",
            "enum": ["active", "suspended"],
            "description": "`suspended` while a platform admin has paused the organisation's writes."
          },
          "createdAt": {
            "type": "string",
            "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))$"
          }
        },
        "required": ["id", "name", "planId", "orgStatus", "createdAt"],
        "additionalProperties": false
      },
      "transferOwnershipInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "targetUid": {
            "type": "string",
            "minLength": 1,
            "description": "The member's Firebase Auth uid to promote to owner (BR-12)."
          },
          "selfDemote": {
            "default": false,
            "description": "Also demote the caller to admin, atomically (AC-4).",
            "type": "boolean"
          }
        },
        "required": ["organizationId", "targetUid", "selfDemote"],
        "additionalProperties": false
      },
      "transferOwnershipOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "minLength": 1,
            "description": "Same value as `uid`."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "uid": {
            "type": "string",
            "minLength": 1,
            "description": "The member's Firebase Auth uid."
          },
          "role": {
            "type": "string",
            "enum": ["owner", "admin", "publisher", "member", "guest"]
          },
          "status": {
            "type": "string",
            "enum": ["active", "invited", "suspended", "removed"]
          },
          "blocked": { "type": "boolean" },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          }
        },
        "required": [
          "id",
          "organizationId",
          "uid",
          "role",
          "status",
          "blocked",
          "createdAt",
          "updatedAt",
          "revision"
        ],
        "additionalProperties": false
      },
      "unpublishDocumentInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "expectedPublishedVersionId": {
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dvr identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "documentId"],
        "additionalProperties": false
      },
      "unpublishDocumentOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "title": {
            "type": "string",
            "minLength": 1,
            "maxLength": 200,
            "description": "Document display title (1-200 chars after trimming)."
          },
          "status": {
            "type": "string",
            "enum": ["active", "archived", "deleted"]
          },
          "nextVersionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "format": { "type": "string", "enum": ["pdf", "dxf", "dwg"] },
          "published": {
            "type": "object",
            "properties": {
              "versionId": {
                "type": "string",
                "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A dvr identifier (TypeID, conventions C5)."
              },
              "publishedAt": {
                "type": "string",
                "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))$"
              },
              "publishedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              },
              "publishSeq": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "versionId",
              "publishedAt",
              "publishedBy",
              "publishSeq"
            ],
            "additionalProperties": false
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "deletedAt": {
            "type": "string",
            "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))$"
          },
          "purgeAfter": {
            "type": "string",
            "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))$"
          },
          "statusBeforeDeletion": {
            "type": "string",
            "enum": ["active", "archived"]
          },
          "purgeStartedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "status",
          "nextVersionNumber",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "unpublishModelInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "expectedPublishedVersionId": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          }
        },
        "required": ["organizationId", "projectId", "modelId"],
        "additionalProperties": false
      },
      "unpublishModelOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "Model display name (1-80 chars after trimming, BR-8)."
          },
          "discipline": {
            "type": "string",
            "enum": ["architecture", "structure", "mep", "other"]
          },
          "status": { "type": "string", "enum": ["active"] },
          "nextVersionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "published": {
            "type": "object",
            "properties": {
              "versionId": {
                "type": "string",
                "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A ver identifier (TypeID, conventions C5)."
              },
              "publishedAt": {
                "type": "string",
                "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))$"
              },
              "publishedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              },
              "publishSeq": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "note": { "type": "string", "maxLength": 500 }
            },
            "required": [
              "versionId",
              "publishedAt",
              "publishedBy",
              "publishSeq"
            ],
            "additionalProperties": false
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "name",
          "discipline",
          "status",
          "nextVersionNumber",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "updateAnnotationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "annotationId": {
            "type": "string",
            "pattern": "^ann_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ann identifier (TypeID, conventions C5)."
          },
          "label": {
            "description": "New label (max 60 chars), or null to remove it.",
            "anyOf": [
              {
                "type": "string",
                "minLength": 1,
                "maxLength": 60,
                "description": "User-given name, 1-60 chars after trimming."
              },
              { "type": "null" }
            ]
          },
          "visibility": {
            "description": "personal (only you) or shared (everyone in the project).",
            "type": "string",
            "enum": ["personal", "shared"]
          },
          "needsCheck": {
            "description": "Send null to dismiss the 'needs check' flag after a new model version (still fine).",
            "type": "null"
          }
        },
        "required": ["organizationId", "projectId", "annotationId"],
        "additionalProperties": false
      },
      "updateAnnotationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ann_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ann identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "subtype": { "type": "string", "enum": ["measurement"] },
          "visibility": { "type": "string", "enum": ["personal", "shared"] },
          "measurement": {
            "type": "object",
            "properties": {
              "kind": {
                "type": "string",
                "enum": [
                  "distance",
                  "edgeLength",
                  "angle",
                  "areaFace",
                  "perpendicularPointFace",
                  "perpendicularFaceFace",
                  "areaPolygon",
                  "overallDimensions"
                ]
              },
              "anchors": {
                "minItems": 1,
                "maxItems": 100,
                "type": "array",
                "items": {
                  "oneOf": [
                    {
                      "type": "object",
                      "properties": {
                        "kind": { "type": "string", "const": "element" },
                        "globalId": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 64,
                          "description": "IFC GlobalId of the anchored element."
                        },
                        "modelId": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        },
                        "versionId": {
                          "type": "string",
                          "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A ver identifier (TypeID, conventions C5)."
                        },
                        "localPointMm": {
                          "type": "object",
                          "properties": {
                            "x": { "type": "number" },
                            "y": { "type": "number" },
                            "z": { "type": "number" }
                          },
                          "required": ["x", "y", "z"],
                          "additionalProperties": false,
                          "description": "Snapped point in the version's coordinates, millimetres."
                        },
                        "edgeDirection": {
                          "description": "For an angle taken off an edge: the edge's unit direction in the version's coordinates.",
                          "type": "object",
                          "properties": {
                            "x": { "type": "number" },
                            "y": { "type": "number" },
                            "z": { "type": "number" }
                          },
                          "required": ["x", "y", "z"],
                          "additionalProperties": false
                        },
                        "faceNormal": {
                          "description": "For an angle or a face area taken off a face: the face's unit normal in the version's coordinates.",
                          "type": "object",
                          "properties": {
                            "x": { "type": "number" },
                            "y": { "type": "number" },
                            "z": { "type": "number" }
                          },
                          "required": ["x", "y", "z"],
                          "additionalProperties": false
                        }
                      },
                      "required": ["globalId", "versionId", "localPointMm"],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "kind": { "type": "string", "const": "document" },
                        "documentId": {
                          "type": "string",
                          "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A doc identifier (TypeID, conventions C5)."
                        },
                        "documentVersionId": {
                          "type": "string",
                          "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A dvr identifier (TypeID, conventions C5)."
                        },
                        "page": {
                          "type": "integer",
                          "minimum": 1,
                          "maximum": 9007199254740991,
                          "description": "1-based page (sheet) number."
                        },
                        "point": {
                          "type": "object",
                          "properties": {
                            "x": { "type": "number" },
                            "y": { "type": "number" }
                          },
                          "required": ["x", "y"],
                          "additionalProperties": false,
                          "description": "The point on the page, in the page's drawing units."
                        },
                        "entityHandle": {
                          "description": "The CAD entity handle the point snapped to.",
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 32
                        },
                        "snapKind": {
                          "description": "How the point snapped; absent for a free point.",
                          "type": "string",
                          "enum": [
                            "endpoint",
                            "intersection",
                            "midpoint",
                            "centre",
                            "quadrant",
                            "perpendicular",
                            "nearest"
                          ]
                        }
                      },
                      "required": [
                        "kind",
                        "documentId",
                        "documentVersionId",
                        "page",
                        "point"
                      ],
                      "additionalProperties": false
                    }
                  ]
                }
              },
              "valueMm": { "type": "number", "minimum": 0 },
              "valueDeg": { "type": "number", "minimum": 0, "maximum": 180 },
              "valueM2": { "type": "number", "minimum": 0 },
              "axisComponentsMm": {
                "type": "object",
                "properties": {
                  "dx": { "type": "number" },
                  "dy": { "type": "number" },
                  "dz": { "type": "number" }
                },
                "required": ["dx", "dy", "dz"],
                "additionalProperties": false
              },
              "vertexIndex": {
                "description": "For a three-point angle: the index of the anchor the angle is measured at (its vertex).",
                "type": "integer",
                "minimum": 0,
                "maximum": 2
              },
              "slopeReference": {
                "description": "For a slope (an angle with one anchor): what its edge or face is measured against.",
                "type": "string",
                "enum": ["horizontal", "vertical"]
              },
              "dimensions": {
                "minItems": 1,
                "maxItems": 3,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": {
                      "type": "string",
                      "enum": ["length", "width", "height", "thickness"]
                    },
                    "valueMm": { "type": "number", "minimum": 0 },
                    "axis": {
                      "type": "object",
                      "properties": {
                        "x": { "type": "number" },
                        "y": { "type": "number" },
                        "z": { "type": "number" }
                      },
                      "required": ["x", "y", "z"],
                      "additionalProperties": false
                    }
                  },
                  "required": ["name", "valueMm", "axis"],
                  "additionalProperties": false
                }
              },
              "tessellated": { "type": "boolean" },
              "inPlane": {
                "description": "For a distance, edge length or angle measured in a view: the view's normal and the value in its plane.",
                "type": "object",
                "properties": {
                  "normal": {
                    "type": "object",
                    "properties": {
                      "x": { "type": "number" },
                      "y": { "type": "number" },
                      "z": { "type": "number" }
                    },
                    "required": ["x", "y", "z"],
                    "additionalProperties": false,
                    "description": "The view's unit normal (towards the viewer) in the version's coordinates."
                  },
                  "valueMm": {
                    "description": "A distance's length in the view plane, millimetres.",
                    "type": "number",
                    "minimum": 0
                  },
                  "valueDeg": {
                    "description": "An angle as the view showed it, degrees.",
                    "type": "number",
                    "minimum": 0,
                    "maximum": 180
                  }
                },
                "required": ["normal"],
                "additionalProperties": false
              },
              "basis": {
                "description": "For a drawing measurement: real (read at the drawing's scale) or paper (millimetres on the sheet, no scale). Absent means real.",
                "type": "string",
                "enum": ["real", "paper"]
              }
            },
            "required": ["kind", "anchors", "tessellated"],
            "additionalProperties": false
          },
          "label": {
            "type": "string",
            "minLength": 1,
            "maxLength": 60,
            "description": "User-given name, 1-60 chars after trimming."
          },
          "needsCheck": {
            "type": "object",
            "properties": {
              "reason": {
                "type": "string",
                "enum": [
                  "geometry_changed",
                  "element_missing",
                  "drawing_changed"
                ]
              },
              "since": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["reason", "since"],
            "additionalProperties": false
          },
          "viewpoint": {
            "type": "object",
            "properties": {
              "camera": {
                "type": "object",
                "properties": {
                  "position": {
                    "type": "object",
                    "properties": {
                      "x": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "y": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "z": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      }
                    },
                    "required": ["x", "y", "z"],
                    "additionalProperties": false
                  },
                  "target": {
                    "type": "object",
                    "properties": {
                      "x": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "y": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "z": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      }
                    },
                    "required": ["x", "y", "z"],
                    "additionalProperties": false
                  },
                  "up": { "type": "string", "const": "z" },
                  "fovDeg": { "type": "number", "minimum": 20, "maximum": 90 },
                  "orthoHeightM": { "type": "number", "exclusiveMinimum": 0 }
                },
                "additionalProperties": false
              },
              "document": {
                "type": "object",
                "properties": {
                  "page": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 9007199254740991
                  },
                  "cad": {
                    "type": "object",
                    "properties": {
                      "center": {
                        "type": "object",
                        "properties": {
                          "x": { "type": "number" },
                          "y": { "type": "number" }
                        },
                        "required": ["x", "y"],
                        "additionalProperties": false
                      },
                      "scale": { "type": "number", "exclusiveMinimum": 0 }
                    },
                    "required": ["center", "scale"],
                    "additionalProperties": false
                  }
                },
                "required": ["page", "cad"],
                "additionalProperties": false
              }
            },
            "additionalProperties": false
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "subtype",
          "visibility",
          "measurement",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "updateApiTokenInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "apiTokenId": {
            "type": "string",
            "pattern": "^tok_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A tok identifier (TypeID, conventions C5)."
          },
          "name": { "type": "string", "minLength": 1, "maxLength": 100 },
          "scopes": {
            "minItems": 1,
            "type": "array",
            "items": { "type": "string", "minLength": 1 }
          }
        },
        "required": ["organizationId", "apiTokenId"],
        "additionalProperties": false
      },
      "updateApiTokenOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^tok_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A tok identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": { "type": "string", "minLength": 1 },
          "ownerUid": { "type": "string", "minLength": 1 },
          "scopes": {
            "type": "array",
            "items": { "type": "string", "minLength": 1 }
          },
          "status": { "type": "string", "enum": ["active", "revoked"] },
          "tokenPrefix": { "type": "string", "minLength": 1 },
          "previousSecretGraceUntil": {
            "type": "string",
            "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))$"
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "lastUsedAt": {
            "type": "string",
            "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))$"
          },
          "revokedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "name",
          "scopes",
          "status",
          "tokenPrefix",
          "expiresAt",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "updateDocumentInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "title": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 1,
                "maxLength": 200,
                "description": "Document display title (1-200 chars after trimming)."
              },
              { "type": "null" }
            ]
          }
        },
        "required": ["organizationId", "projectId", "documentId"],
        "additionalProperties": false
      },
      "updateDocumentOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "title": {
            "type": "string",
            "minLength": 1,
            "maxLength": 200,
            "description": "Document display title (1-200 chars after trimming)."
          },
          "status": {
            "type": "string",
            "enum": ["active", "archived", "deleted"]
          },
          "nextVersionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "format": { "type": "string", "enum": ["pdf", "dxf", "dwg"] },
          "published": {
            "type": "object",
            "properties": {
              "versionId": {
                "type": "string",
                "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A dvr identifier (TypeID, conventions C5)."
              },
              "publishedAt": {
                "type": "string",
                "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))$"
              },
              "publishedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              },
              "publishSeq": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "versionId",
              "publishedAt",
              "publishedBy",
              "publishSeq"
            ],
            "additionalProperties": false
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "deletedAt": {
            "type": "string",
            "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))$"
          },
          "purgeAfter": {
            "type": "string",
            "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))$"
          },
          "statusBeforeDeletion": {
            "type": "string",
            "enum": ["active", "archived"]
          },
          "purgeStartedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "status",
          "nextVersionNumber",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "updateDocumentVersionInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dvr identifier (TypeID, conventions C5)."
          },
          "pages": {
            "description": "Per-page metadata to set (a value) or clear (null); omitted fields are left alone.",
            "minItems": 1,
            "maxItems": 500,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "pageNumber": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "sheetNumber": {
                  "anyOf": [
                    {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 100,
                      "description": "Sheet number, e.g. \"W-101\" (BR-11)."
                    },
                    { "type": "null" }
                  ]
                },
                "title": {
                  "anyOf": [
                    {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 200,
                      "description": "Sheet title, e.g. from the PDF outline (BR-11)."
                    },
                    { "type": "null" }
                  ]
                },
                "discipline": {
                  "anyOf": [
                    {
                      "type": "string",
                      "enum": [
                        "architecture",
                        "structure",
                        "mechanical",
                        "electrical",
                        "plumbing",
                        "fire_protection",
                        "civil",
                        "landscape",
                        "general"
                      ]
                    },
                    { "type": "null" }
                  ]
                }
              },
              "required": ["pageNumber"],
              "additionalProperties": false
            }
          },
          "cad": {
            "description": "FV-488: a unitless CAD drawing's units (mm, cm, m, in, ft), or null to clear them (CAD versions whose file declares no units only). FV-500: defaultLayersOff, the layers off by default for everyone (CAD versions only; superseded by layerDefault).",
            "type": "object",
            "properties": {
              "unitsOverride": {
                "anyOf": [
                  {
                    "type": "string",
                    "enum": ["mm", "cm", "m", "in", "ft"],
                    "description": "The drawing's units, set by a publisher because the file declares none: mm, cm, m, in or ft."
                  },
                  { "type": "null" }
                ]
              },
              "defaultLayersOff": {
                "maxItems": 256,
                "type": "array",
                "items": { "type": "string", "minLength": 1, "maxLength": 255 },
                "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
              }
            },
            "additionalProperties": false
          },
          "layerDefault": {
            "type": "object",
            "properties": {
              "off": {
                "maxItems": 256,
                "type": "array",
                "items": { "type": "string", "minLength": 1, "maxLength": 255 },
                "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
              }
            },
            "required": ["off"],
            "additionalProperties": false,
            "description": "The layers off by default for everyone who opens this drawing (CAD layers or PDF optional content groups, by name). A person's own choice on their device still wins."
          }
        },
        "required": ["organizationId", "projectId", "documentId", "versionId"],
        "additionalProperties": false
      },
      "updateDocumentVersionOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dvr identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": [
              "uploading",
              "uploaded",
              "processing",
              "ready",
              "failed",
              "archived",
              "cancelled"
            ]
          },
          "publication": {
            "type": "string",
            "enum": ["draft", "published", "superseded"]
          },
          "fieldVisible": { "type": "boolean" },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "upload" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "fileName", "sizeBytes", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "url" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "url": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 2048,
                    "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "url", "fileName", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "copy" },
                  "format": {
                    "type": "string",
                    "enum": ["pdf", "dxf", "dwg"],
                    "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                  },
                  "sourceVersionId": {
                    "type": "string",
                    "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A dvr identifier (TypeID, conventions C5)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": [
                  "kind",
                  "sourceVersionId",
                  "fileName",
                  "sizeBytes",
                  "contentType"
                ],
                "additionalProperties": false
              }
            ]
          },
          "upload": {
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          },
          "cancelReason": { "type": "string", "enum": ["user"] },
          "pipelineVersion": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": { "type": "string" },
                "blocking": { "type": "boolean" },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": {}
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "progress": {
            "type": "object",
            "properties": {
              "stage": { "type": "string", "minLength": 1 },
              "percent": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["stage", "percent"],
            "additionalProperties": false
          },
          "processing": {
            "type": "object",
            "properties": {
              "sizeClass": { "type": "string", "enum": ["s", "m", "l", "xl"] },
              "executionName": { "type": "string", "minLength": 1 },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "queuedAt": {
                "type": "string",
                "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))$"
              },
              "queuedTraceparent": {
                "type": "string",
                "pattern": "^(?!ff)[0-9a-f]{2}-(?!0{32})[0-9a-f]{32}-(?!0{16})[0-9a-f]{16}-[0-9a-f]{2}$"
              },
              "queuedEscalation": {
                "type": "object",
                "properties": {
                  "sizeClass": {
                    "type": "string",
                    "enum": ["s", "m", "l", "xl"]
                  },
                  "attempt": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["sizeClass", "attempt"],
                "additionalProperties": false
              },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "progressReportedAt": {
                "type": "string",
                "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))$"
              },
              "requestId": { "type": "string", "minLength": 1 }
            },
            "additionalProperties": false
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": { "type": "string", "minLength": 1 },
              "retryable": { "type": "boolean" },
              "params": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": {}
              },
              "messageKey": { "type": "string", "minLength": 1 },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "retryable"],
            "additionalProperties": false
          },
          "activeArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "reprocessing": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "reason": {
                "type": "string",
                "enum": ["retry", "pipeline_upgrade"]
              },
              "targetPipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "state": {
                "type": "string",
                "enum": [
                  "requested",
                  "deferred",
                  "awaiting_rollout",
                  "done",
                  "failed"
                ]
              },
              "completedAt": {
                "type": "string",
                "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))$"
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1 },
                  "retryable": { "type": "boolean" },
                  "params": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": {}
                  },
                  "messageKey": { "type": "string", "minLength": 1 },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "retryable"],
                "additionalProperties": false
              }
            },
            "required": ["requestedAt", "requestedBy", "attempt"],
            "additionalProperties": false
          },
          "pageCount": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "pages": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "pageNumber": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "scanned": { "type": "boolean" },
                "sheetNumber": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 100,
                  "description": "Sheet number, e.g. \"W-101\" (BR-11)."
                },
                "title": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 200,
                  "description": "Sheet title, e.g. from the PDF outline (BR-11)."
                },
                "discipline": {
                  "type": "string",
                  "enum": [
                    "architecture",
                    "structure",
                    "mechanical",
                    "electrical",
                    "plumbing",
                    "fire_protection",
                    "civil",
                    "landscape",
                    "general"
                  ]
                },
                "storeyId": { "type": "string", "minLength": 1 },
                "overridden": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "enum": ["sheetNumber", "title", "discipline"]
                  }
                },
                "layout": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "kind": { "type": "string", "enum": ["model", "paper"] }
                  },
                  "required": ["name", "kind"],
                  "additionalProperties": false
                },
                "titleBlock": {
                  "type": "object",
                  "propertyNames": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 64
                  },
                  "additionalProperties": {
                    "type": "string",
                    "maxLength": 200
                  },
                  "description": "FV-490 (E13 §4.4): a CAD page's primary title block, attribute tag -> value (<= 32 entries, values <= 200 chars)."
                },
                "scale": {
                  "type": "object",
                  "properties": {
                    "factor": {
                      "type": "number",
                      "exclusiveMinimum": 0,
                      "maximum": 10000,
                      "description": "Real millimetres per paper millimetre (1:50 is 50)."
                    },
                    "source": {
                      "type": "string",
                      "enum": ["calibration", "label"],
                      "description": "calibration: two points and a known length; label: the title-block scale, confirmed."
                    },
                    "basis": {
                      "description": "For a calibration: the two points (fractions of the page) and the real length in mm.",
                      "type": "object",
                      "properties": {
                        "a": {
                          "type": "object",
                          "properties": {
                            "xPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            },
                            "yPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            }
                          },
                          "required": ["xPct", "yPct"],
                          "additionalProperties": false
                        },
                        "b": {
                          "type": "object",
                          "properties": {
                            "xPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            },
                            "yPct": {
                              "type": "number",
                              "minimum": 0,
                              "maximum": 1
                            }
                          },
                          "required": ["xPct", "yPct"],
                          "additionalProperties": false
                        },
                        "lengthMm": { "type": "number", "exclusiveMinimum": 0 }
                      },
                      "required": ["a", "b", "lengthMm"],
                      "additionalProperties": false
                    },
                    "setBy": { "type": "string", "minLength": 1 },
                    "setAt": {
                      "type": "string",
                      "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))$"
                    }
                  },
                  "required": ["factor", "source", "setBy", "setAt"],
                  "additionalProperties": false
                }
              },
              "required": ["pageNumber", "scanned"],
              "additionalProperties": false
            }
          },
          "cad": {
            "type": "object",
            "properties": {
              "insunits": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "unitToMm": {
                "anyOf": [
                  { "type": "number", "exclusiveMinimum": 0 },
                  { "type": "null" }
                ]
              },
              "unitsOverride": {
                "type": "string",
                "enum": ["mm", "cm", "m", "in", "ft"],
                "description": "The drawing's units, set by a publisher because the file declares none: mm, cm, m, in or ft."
              },
              "defaultLayersOff": {
                "maxItems": 256,
                "type": "array",
                "items": { "type": "string", "minLength": 1, "maxLength": 255 },
                "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
              },
              "parser": { "type": "string", "const": "acad-ts" },
              "parserVersion": { "type": "string", "minLength": 1 },
              "version": { "type": "string", "minLength": 1 },
              "layoutCount": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "insunits",
              "unitToMm",
              "parser",
              "parserVersion",
              "version",
              "layoutCount"
            ],
            "additionalProperties": false
          },
          "layerDefault": {
            "type": "object",
            "properties": {
              "off": {
                "maxItems": 256,
                "type": "array",
                "items": { "type": "string", "minLength": 1, "maxLength": 255 },
                "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
              }
            },
            "required": ["off"],
            "additionalProperties": false,
            "description": "The layers off by default for everyone who opens this drawing (CAD layers or PDF optional content groups, by name). A person's own choice on their device still wins."
          },
          "publishOnReady": {
            "description": "Publish this version automatically, in the same write that marks it ready (FV-745).",
            "type": "boolean"
          },
          "releasedAt": {
            "type": "string",
            "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))$"
          },
          "supersededAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "documentId",
          "versionNumber",
          "status",
          "publication",
          "fieldVisible",
          "source",
          "pipelineVersion",
          "warnings",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "updateLayerSetInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "layerSetId": {
            "type": "string",
            "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lys identifier (TypeID, conventions C5)."
          },
          "entries": {
            "minItems": 1,
            "maxItems": 100,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^[a-z0-9][a-z0-9-]{0,63}$",
                  "description": "The entry to change."
                },
                "displayName": {
                  "description": "New name, 1-60 characters (trimmed).",
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 60
                },
                "colorHex": {
                  "description": "Colour as #rgb or #rrggbb (stored as lower-case #rrggbb); null removes it.",
                  "anyOf": [
                    {
                      "type": "string",
                      "pattern": "^#(?:[0-9a-fA-F]{3}|[0-9a-fA-F]{6})$"
                    },
                    { "type": "null" }
                  ]
                },
                "order": {
                  "description": "New position (0 = first). The entries are renumbered 0..n-1; a moved entry goes before an unmoved one at the same position.",
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 99
                },
                "defaultOn": { "type": "boolean" },
                "hiddenFromField": { "type": "boolean" },
                "mergeEntryIds": {
                  "description": "Entries to merge into this one: their derivation keys move here and they disappear. Same derivation kind only.",
                  "minItems": 1,
                  "maxItems": 99,
                  "type": "array",
                  "items": {
                    "type": "string",
                    "pattern": "^[a-z0-9][a-z0-9-]{0,63}$"
                  }
                },
                "rule": {
                  "description": "A rule layer's predicate. With an id the set does not have yet (and a displayName), creates that rule layer; on an existing rule layer, replaces its rule.",
                  "type": "object",
                  "properties": {
                    "source": {
                      "description": "What the rule tests: `property` (the default) a property value (`psetName`, `propName`); `name` the element name, `material` its material, `ifcClass` its IFC class, `panel` the name or tag of the panel (`IfcElementAssembly`) it is part of -- these four take no psetName/propName, are counted on the device and work offline.",
                      "type": "string",
                      "enum": [
                        "property",
                        "name",
                        "material",
                        "ifcClass",
                        "panel"
                      ]
                    },
                    "psetName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255,
                      "description": "Property (or quantity) set name exactly as in the model, e.g. `Pset_WallCommon`. Property rules only."
                    },
                    "propName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255,
                      "description": "Property name exactly as in the model, e.g. `IsExternal`. Property rules only."
                    },
                    "op": {
                      "type": "string",
                      "enum": ["eq", "neq", "contains"],
                      "description": "`eq` equals, `neq` differs from (elements without the property never match), `contains` contains the value."
                    },
                    "value": {
                      "type": "string",
                      "maxLength": 1000,
                      "description": "Text to compare; case, accents and surrounding spaces are ignored. Booleans read `true`/`false`; a number also matches numerically (`0,24` = `0.24`). For name, material, ifcClass and panel rules several values may be separated by commas (any matches), and an empty value with eq/contains matches every element that has one (e.g. part of any panel)."
                    }
                  },
                  "required": ["op", "value"],
                  "additionalProperties": false
                },
                "remove": {
                  "description": "Deletes this rule or saved (manual) layer. Derived layers cannot be removed.",
                  "type": "boolean",
                  "const": true
                },
                "manualGlobalIds": {
                  "description": "With an id the set does not have yet (and a displayName): saves a layer of exactly these elements (IFC GlobalIds, at most 500), e.g. a search result.",
                  "minItems": 1,
                  "maxItems": 500,
                  "type": "array",
                  "items": { "type": "string", "minLength": 1, "maxLength": 64 }
                },
                "followTemplate": {
                  "description": "On a layer of the company's layer template: it follows the template again, so a later template update sets its name, colour and default-on. Send the template's values with it to take them at once.",
                  "type": "boolean",
                  "const": true
                }
              },
              "required": ["id"],
              "additionalProperties": false
            }
          }
        },
        "required": ["organizationId", "projectId", "layerSetId", "entries"],
        "additionalProperties": false
      },
      "updateLayerSetOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lys identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "status": {
            "type": "string",
            "enum": ["ready", "materializing", "failed"]
          },
          "materializingSince": {
            "type": "string",
            "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))$"
          },
          "materializeAttempts": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": {
                "type": "string",
                "enum": ["layer_rule_materialization_failed"]
              },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "supportRef"],
            "additionalProperties": false
          },
          "derivationSource": {
            "type": "string",
            "enum": [
              "assignment",
              "type",
              "classification",
              "name-role",
              "material",
              "object-type"
            ]
          },
          "grouping": {
            "minItems": 1,
            "maxItems": 2,
            "type": "array",
            "items": {
              "type": "string",
              "enum": ["classification", "name-role", "material", "object-type"]
            }
          },
          "sourceCoveragePct": {
            "type": "number",
            "minimum": 0,
            "maximum": 100
          },
          "sources": {
            "maxItems": 100,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "modelId": {
                  "type": "string",
                  "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A mdl identifier (TypeID, conventions C5)."
                },
                "versionId": {
                  "type": "string",
                  "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A ver identifier (TypeID, conventions C5)."
                }
              },
              "required": ["modelId", "versionId"],
              "additionalProperties": false
            }
          },
          "generatedFromVersionId": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          },
          "derivedAtPublishSeq": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "generatedAt": {
            "type": "string",
            "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))$"
          },
          "warnings": {
            "maxItems": 100,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": {
                  "type": "string",
                  "enum": [
                    "layers_index_failed",
                    "layer_source_unavailable",
                    "layer_source_invalid",
                    "layer_assignment_skipped",
                    "layer_entries_truncated",
                    "layer_rule_truncated",
                    "layer_template_truncated"
                  ]
                },
                "modelId": {
                  "type": "string",
                  "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A mdl identifier (TypeID, conventions C5)."
                },
                "versionId": {
                  "type": "string",
                  "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A ver identifier (TypeID, conventions C5)."
                },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": { "type": ["string", "number"] }
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "entries": {
            "maxItems": 100,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^[a-z0-9][a-z0-9-]{0,63}$"
                },
                "kind": {
                  "type": "string",
                  "enum": ["assignment", "type", "manual", "rule", "attribute"]
                },
                "derivationKeys": {
                  "maxItems": 100,
                  "type": "array",
                  "items": { "type": "string", "minLength": 1 }
                },
                "manualGlobalIds": {
                  "maxItems": 500,
                  "type": "array",
                  "items": { "type": "string", "minLength": 1 }
                },
                "rule": {
                  "type": "object",
                  "properties": {
                    "source": {
                      "type": "string",
                      "enum": [
                        "property",
                        "name",
                        "material",
                        "ifcClass",
                        "panel"
                      ]
                    },
                    "psetName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255
                    },
                    "propName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255
                    },
                    "op": {
                      "type": "string",
                      "enum": ["eq", "neq", "contains"]
                    },
                    "value": { "type": "string", "maxLength": 1000 }
                  },
                  "required": ["op", "value"],
                  "additionalProperties": false
                },
                "materializedGlobalIds": {
                  "maxItems": 20000,
                  "type": "array",
                  "items": { "type": "string", "minLength": 1 }
                },
                "elementCount": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "displayName": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 60
                },
                "colorHex": { "type": "string", "pattern": "^#[0-9a-f]{6}$" },
                "order": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "defaultOn": { "type": "boolean" },
                "hiddenFromField": { "type": "boolean" },
                "origin": { "type": "string", "enum": ["template", "project"] },
                "templateKey": {
                  "type": "string",
                  "pattern": "^template:ltp_[0-9a-z]{26}:[a-z0-9][a-z0-9-]{0,39}$"
                },
                "locked": { "type": "boolean" },
                "curated": { "type": "boolean" }
              },
              "required": [
                "id",
                "kind",
                "derivationKeys",
                "elementCount",
                "displayName",
                "order",
                "defaultOn",
                "hiddenFromField"
              ],
              "additionalProperties": false
            }
          },
          "template": {
            "type": "object",
            "properties": {
              "templateId": {
                "type": "string",
                "pattern": "^ltp_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A ltp identifier (TypeID, conventions C5)."
              },
              "revision": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": ["templateId", "revision"],
            "additionalProperties": false
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "status",
          "derivationSource",
          "sourceCoveragePct",
          "sources",
          "derivedAtPublishSeq",
          "generatedAt",
          "warnings",
          "entries",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "updateLayerTemplateInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "templateId": {
            "type": "string",
            "pattern": "^ltp_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ltp identifier (TypeID, conventions C5)."
          },
          "name": {
            "description": "New name, 1-60 characters.",
            "type": "string",
            "minLength": 1,
            "maxLength": 60
          },
          "layers": {
            "description": "The template's complete new layer list (replaces the old one). Keep a layer's id to keep it in the projects; a layer left out disappears from them.",
            "maxItems": 50,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^[a-z0-9][a-z0-9-]{0,39}$",
                  "description": "Stable id of the layer within the template (lower-case letters, digits, hyphens; at most 40). Projects match the layer by it, so keep it when you rename the layer."
                },
                "displayName": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 60,
                  "description": "Name, 1-60 characters."
                },
                "colorHex": {
                  "description": "Colour as #rgb or #rrggbb.",
                  "type": "string",
                  "pattern": "^#(?:[0-9a-fA-F]{3}|[0-9a-fA-F]{6})$"
                },
                "rule": {
                  "type": "object",
                  "properties": {
                    "source": {
                      "description": "What the rule tests: `property` (the default) a property value (`psetName`, `propName`); `name` the element name, `material` its material, `ifcClass` its IFC class, `panel` the name or tag of the panel (`IfcElementAssembly`) it is part of -- these four take no psetName/propName, are counted on the device and work offline.",
                      "type": "string",
                      "enum": [
                        "property",
                        "name",
                        "material",
                        "ifcClass",
                        "panel"
                      ]
                    },
                    "psetName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255,
                      "description": "Property (or quantity) set name exactly as in the model, e.g. `Pset_WallCommon`. Property rules only."
                    },
                    "propName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255,
                      "description": "Property name exactly as in the model, e.g. `IsExternal`. Property rules only."
                    },
                    "op": {
                      "type": "string",
                      "enum": ["eq", "neq", "contains"],
                      "description": "`eq` equals, `neq` differs from (elements without the property never match), `contains` contains the value."
                    },
                    "value": {
                      "type": "string",
                      "maxLength": 1000,
                      "description": "Text to compare; case, accents and surrounding spaces are ignored. Booleans read `true`/`false`; a number also matches numerically (`0,24` = `0.24`). For name, material, ifcClass and panel rules several values may be separated by commas (any matches), and an empty value with eq/contains matches every element that has one (e.g. part of any panel)."
                    }
                  },
                  "required": ["op", "value"],
                  "additionalProperties": false
                },
                "defaultOn": {
                  "description": "On when a project opens. Default true.",
                  "type": "boolean"
                },
                "hiddenFromField": {
                  "description": "Hidden from the field panel. Default false.",
                  "type": "boolean"
                },
                "locked": {
                  "description": "Locked: every project keeps the template's name, colour and default-on. Unlocked (the default): a project may change them. Default false.",
                  "type": "boolean"
                }
              },
              "required": ["id", "displayName", "rule"],
              "additionalProperties": false
            }
          }
        },
        "required": ["organizationId", "templateId"],
        "additionalProperties": false
      },
      "updateLayerTemplateOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ltp_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ltp identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": { "type": "string", "minLength": 1, "maxLength": 60 },
          "layers": {
            "maxItems": 50,
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^[a-z0-9][a-z0-9-]{0,39}$"
                },
                "displayName": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 60
                },
                "colorHex": { "type": "string", "pattern": "^#[0-9a-f]{6}$" },
                "rule": {
                  "type": "object",
                  "properties": {
                    "source": {
                      "type": "string",
                      "enum": [
                        "property",
                        "name",
                        "material",
                        "ifcClass",
                        "panel"
                      ]
                    },
                    "psetName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255
                    },
                    "propName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255
                    },
                    "op": {
                      "type": "string",
                      "enum": ["eq", "neq", "contains"]
                    },
                    "value": { "type": "string", "maxLength": 1000 }
                  },
                  "required": ["op", "value"],
                  "additionalProperties": false
                },
                "defaultOn": { "type": "boolean" },
                "hiddenFromField": { "type": "boolean" },
                "locked": { "type": "boolean" }
              },
              "required": [
                "id",
                "displayName",
                "rule",
                "defaultOn",
                "hiddenFromField",
                "locked"
              ],
              "additionalProperties": false
            }
          },
          "applyTo": { "type": "string", "enum": ["all", "chosen"] },
          "projectIds": {
            "minItems": 1,
            "maxItems": 400,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          "appliedAt": {
            "type": "string",
            "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))$"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "name",
          "layers",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "updateLinkInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "linkId": {
            "type": "string",
            "pattern": "^lnk_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lnk identifier (TypeID, conventions C5)."
          },
          "target": {
            "description": "The new target, replacing the old one: a page of a published drawing of this project.",
            "type": "object",
            "properties": {
              "documentId": {
                "type": "string",
                "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A doc identifier (TypeID, conventions C5)."
              },
              "page": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "region": {
                "description": "Part of the page as fractions (0-1) of its width and height (D-8: never pixels, so it holds at any zoom); omitted: the whole page.",
                "type": "object",
                "properties": {
                  "xPct": { "type": "number", "minimum": 0, "maximum": 1 },
                  "yPct": { "type": "number", "minimum": 0, "maximum": 1 },
                  "wPct": { "type": "number", "minimum": 0, "maximum": 1 },
                  "hPct": { "type": "number", "minimum": 0, "maximum": 1 }
                },
                "required": ["xPct", "yPct", "wPct", "hPct"],
                "additionalProperties": false
              },
              "cadRegion": {
                "description": "CAD drawings: part of the page in drawing units ({x, y, w, h} with w, h > 0) and the space it is drawn in (model or paper). Not together with region or textRef.",
                "type": "object",
                "properties": {
                  "x": { "type": "number" },
                  "y": { "type": "number" },
                  "w": { "type": "number", "exclusiveMinimum": 0 },
                  "h": { "type": "number", "exclusiveMinimum": 0 },
                  "space": { "type": "string", "enum": ["model", "paper"] }
                },
                "required": ["x", "y", "w", "h", "space"],
                "additionalProperties": false
              },
              "textRef": {
                "description": "CAD drawings: one text of the page -- its index in the page's text layer and its content, which heals the link when the text moves. The text must be a word of that page (422 validation.failed, pointer /target/textRef, otherwise); the index is a hint: when it names another word, the occurrence nearest to it is stored. Not together with region or cadRegion.",
                "type": "object",
                "properties": {
                  "textIndex": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "text": { "type": "string", "minLength": 1, "maxLength": 200 }
                },
                "required": ["textIndex", "text"],
                "additionalProperties": false
              },
              "layoutName": {
                "description": "CAD drawings: the page's layout name. When a later version moves that layout to another page, the link follows it.",
                "type": "string",
                "minLength": 1,
                "maxLength": 255
              }
            },
            "required": ["documentId", "page"],
            "additionalProperties": false
          }
        },
        "required": ["organizationId", "projectId", "linkId"],
        "additionalProperties": false
      },
      "updateLinkOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^lnk_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lnk identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "element" },
                  "modelId": {
                    "type": "string",
                    "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A mdl identifier (TypeID, conventions C5)."
                  },
                  "globalId": { "type": "string", "minLength": 1 }
                },
                "required": ["kind", "modelId", "globalId"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "assembly" },
                  "modelId": {
                    "type": "string",
                    "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A mdl identifier (TypeID, conventions C5)."
                  },
                  "assemblyMark": { "type": "string", "minLength": 1 }
                },
                "required": ["kind", "modelId", "assemblyMark"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "storey" },
                  "modelId": {
                    "type": "string",
                    "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A mdl identifier (TypeID, conventions C5)."
                  },
                  "storeyId": { "type": "string", "minLength": 1 }
                },
                "required": ["kind", "modelId", "storeyId"],
                "additionalProperties": false
              }
            ]
          },
          "target": {
            "type": "object",
            "properties": {
              "documentId": {
                "type": "string",
                "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A doc identifier (TypeID, conventions C5)."
              },
              "page": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "layoutName": {
                "type": "string",
                "minLength": 1,
                "maxLength": 255
              },
              "region": {
                "type": "object",
                "properties": {
                  "xPct": { "type": "number", "minimum": 0, "maximum": 1 },
                  "yPct": { "type": "number", "minimum": 0, "maximum": 1 },
                  "wPct": { "type": "number", "minimum": 0, "maximum": 1 },
                  "hPct": { "type": "number", "minimum": 0, "maximum": 1 }
                },
                "required": ["xPct", "yPct", "wPct", "hPct"],
                "additionalProperties": false
              },
              "cadRegion": {
                "type": "object",
                "properties": {
                  "x": { "type": "number" },
                  "y": { "type": "number" },
                  "w": { "type": "number", "exclusiveMinimum": 0 },
                  "h": { "type": "number", "exclusiveMinimum": 0 },
                  "space": { "type": "string", "enum": ["model", "paper"] }
                },
                "required": ["x", "y", "w", "h", "space"],
                "additionalProperties": false
              },
              "textRef": {
                "type": "object",
                "properties": {
                  "textIndex": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "text": { "type": "string", "minLength": 1, "maxLength": 200 }
                },
                "required": ["textIndex", "text"],
                "additionalProperties": false
              }
            },
            "required": ["documentId", "page"],
            "additionalProperties": false
          },
          "origin": {
            "type": "string",
            "enum": ["rule", "manual", "connector"]
          },
          "ruleId": {
            "type": "string",
            "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lkr identifier (TypeID, conventions C5)."
          },
          "confidence": { "type": "number", "minimum": 0, "maximum": 1 },
          "key": { "type": "string", "minLength": 1 },
          "status": { "type": "string", "enum": ["active", "stale"] },
          "staleSince": {
            "type": "string",
            "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))$"
          },
          "staleReason": { "type": "string", "enum": ["page_removed"] },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "source",
          "target",
          "origin",
          "status",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "updateLinkRuleInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "ruleId": {
            "type": "string",
            "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lkr identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "description": "Rule name, 1-100 chars after trimming."
          },
          "enabled": { "type": "boolean" },
          "priority": {
            "type": "integer",
            "minimum": 0,
            "maximum": 1000,
            "description": "0-1000; lower runs first when rules run together."
          },
          "matchModel": {
            "type": "object",
            "properties": {
              "field": {
                "type": "string",
                "enum": [
                  "tag",
                  "assemblyMark",
                  "storeyName",
                  "name",
                  "property"
                ]
              },
              "property": {
                "type": "object",
                "properties": {
                  "set": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 128,
                    "description": "Property set, e.g. Pset_Panel."
                  },
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 128,
                    "description": "Property name, e.g. Drawing."
                  }
                },
                "required": ["set", "name"],
                "additionalProperties": false
              }
            },
            "required": ["field"],
            "additionalProperties": false
          },
          "matchDocument": {
            "type": "object",
            "properties": {
              "field": {
                "type": "string",
                "enum": [
                  "fileName",
                  "sheetNumber",
                  "outlineTitle",
                  "titleBlock",
                  "layoutName",
                  "blockAttribute",
                  "sheetText"
                ]
              },
              "attributeTag": {
                "type": "string",
                "minLength": 1,
                "maxLength": 128
              }
            },
            "required": ["field"],
            "additionalProperties": false
          },
          "normalization": {
            "type": "object",
            "properties": {
              "caseInsensitive": { "type": "boolean" },
              "stripWhitespace": { "type": "boolean" },
              "stripLeadingZeros": { "type": "boolean" },
              "regex": {
                "anyOf": [
                  {
                    "type": "string",
                    "description": "Regular expression applied to both sides after the other normalisation steps: a value that does not match is ignored, otherwise the match (or its named group `key`) is the value compared, e.g. W-\\d{3} (max 200 chars; no backreferences or nested repeats)."
                  },
                  { "type": "null" }
                ]
              }
            },
            "additionalProperties": false
          },
          "autoApply": { "type": "boolean" }
        },
        "required": ["organizationId", "projectId", "ruleId"],
        "additionalProperties": false
      },
      "updateLinkRuleOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lkr identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 100,
            "description": "Rule name, 1-100 chars after trimming."
          },
          "enabled": { "type": "boolean" },
          "priority": { "type": "integer", "minimum": 0, "maximum": 1000 },
          "matchModel": {
            "type": "object",
            "properties": {
              "field": {
                "type": "string",
                "enum": [
                  "tag",
                  "assemblyMark",
                  "storeyName",
                  "name",
                  "property"
                ]
              },
              "property": {
                "type": "object",
                "properties": {
                  "set": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 128,
                    "description": "Property set, e.g. Pset_Panel."
                  },
                  "name": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 128,
                    "description": "Property name, e.g. Drawing."
                  }
                },
                "required": ["set", "name"],
                "additionalProperties": false
              }
            },
            "required": ["field"],
            "additionalProperties": false
          },
          "matchDocument": {
            "type": "object",
            "properties": {
              "field": {
                "type": "string",
                "enum": [
                  "fileName",
                  "sheetNumber",
                  "outlineTitle",
                  "titleBlock",
                  "layoutName",
                  "blockAttribute",
                  "sheetText"
                ]
              },
              "attributeTag": {
                "type": "string",
                "minLength": 1,
                "maxLength": 128
              }
            },
            "required": ["field"],
            "additionalProperties": false
          },
          "normalization": {
            "type": "object",
            "properties": {
              "caseInsensitive": { "type": "boolean" },
              "stripWhitespace": { "type": "boolean" },
              "stripLeadingZeros": { "type": "boolean" },
              "regex": {
                "type": "string",
                "description": "Regular expression applied to both sides after the other normalisation steps: a value that does not match is ignored, otherwise the match (or its named group `key`) is the value compared, e.g. W-\\d{3} (max 200 chars; no backreferences or nested repeats)."
              }
            },
            "required": [
              "caseInsensitive",
              "stripWhitespace",
              "stripLeadingZeros"
            ],
            "additionalProperties": false
          },
          "autoApply": { "type": "boolean" },
          "discoveryRunId": {
            "type": "string",
            "pattern": "^ldr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ldr identifier (TypeID, conventions C5)."
          },
          "ambiguousDocumentIds": {
            "maxItems": 500,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A doc identifier (TypeID, conventions C5)."
            }
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "name",
          "enabled",
          "priority",
          "matchModel",
          "matchDocument",
          "normalization",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "updateMeInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "displayName": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "Display name shown in the UI (1-80 chars, §5.4)."
          },
          "locale": { "type": "string", "enum": ["nl", "en", "fr"] },
          "localeChosen": {
            "description": "True when the user explicitly chose `locale` (profile screen): every device then opens in it (FV-452). Omit to leave `localeChosen` unchanged.",
            "type": "boolean"
          },
          "lastOrgId": {
            "description": "The organisation the caller just switched into (E02-S09). Omit to leave `preferences.lastOrgId` unchanged.",
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
          },
          "onboardingChecklistDismissed": {
            "description": "Dismiss (true) or re-show (false) the get-started checklist panel (FV-208). Omit to leave `preferences.onboardingChecklistDismissed` unchanged.",
            "type": "boolean"
          },
          "gesturesCoached": {
            "description": "Viewer gesture coach-marks the caller has now been shown (orbit, zoom, select; FV-219). Added to `preferences.gesturesCoached`, never removed from it. Omit to leave it unchanged.",
            "maxItems": 3,
            "type": "array",
            "items": { "type": "string", "enum": ["orbit", "zoom", "select"] }
          },
          "lengthUnit": {
            "description": "Display unit for measured lengths: mm, cm or m (FV-238). Display only. Omit to leave `preferences.lengthUnit` unchanged.",
            "type": "string",
            "enum": ["mm", "cm", "m"]
          },
          "measureSnap": {
            "description": "Measure snap settings (FV-433): the snap targets switched off and the snap radius (small, medium or large). Replaces `preferences.measureSnap`; omit to leave it unchanged.",
            "type": "object",
            "properties": {
              "off": {
                "maxItems": 7,
                "type": "array",
                "items": {
                  "type": "string",
                  "enum": [
                    "vertex",
                    "edgeIntersection",
                    "edgeMidpoint",
                    "circleCentre",
                    "perpendicular",
                    "edgePoint",
                    "facePoint"
                  ]
                },
                "description": "Snap targets switched off: vertex, edgeIntersection, edgeMidpoint, circleCentre, perpendicular, edgePoint, facePoint."
              },
              "radius": {
                "type": "string",
                "enum": ["small", "medium", "large"],
                "description": "Snap radius: small, medium (default) or large."
              }
            },
            "required": ["off", "radius"],
            "additionalProperties": false
          },
          "trackpadScroll": {
            "description": "What a two-finger trackpad scroll does in the 3D viewer: pan or zoom (FV-472). Omit to leave `preferences.trackpadScroll` unchanged.",
            "type": "string",
            "enum": ["pan", "zoom"]
          },
          "modelColours": {
            "description": "How the 3D viewer colours a model: file (the file's own colours, the Field-Viewer palette where it has none) or palette (always the Field-Viewer palette) (FV-515). Omit to leave `preferences.modelColours` unchanged.",
            "type": "string",
            "enum": ["file", "palette"]
          },
          "layers": {
            "description": "Personal layer defaults (FV-513), merged into `preferences.layers`: `projects` sets a project's own on/off overrides (or forgets it with null; the 30 most recently saved are kept), `mine` sets or removes (null) my default by template layer or derivation key, `clear` forgets everything first. Omit to leave them unchanged.",
            "type": "object",
            "properties": {
              "clear": {
                "description": "Forget every personal layer state first.",
                "type": "boolean"
              },
              "projects": {
                "description": "Per project: its overrides to keep (replacing the stored ones), or null to forget it.",
                "type": "object",
                "propertyNames": {
                  "type": "string",
                  "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A prj identifier (TypeID, conventions C5)."
                },
                "additionalProperties": {
                  "anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "layerSetId": {
                          "type": "string",
                          "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A lys identifier (TypeID, conventions C5)."
                        },
                        "overrides": {
                          "type": "object",
                          "propertyNames": {
                            "type": "string",
                            "pattern": "^[a-z0-9][a-z0-9-]{0,63}$"
                          },
                          "additionalProperties": { "type": "boolean" },
                          "description": "Layer entry id -> on, at most 100."
                        },
                        "mode": {
                          "type": "string",
                          "enum": ["project-default"]
                        }
                      },
                      "required": ["layerSetId", "overrides"],
                      "additionalProperties": false
                    },
                    { "type": "null" }
                  ]
                }
              },
              "mine": {
                "description": "My default: key -> on, or null to remove the key.",
                "type": "object",
                "propertyNames": {
                  "type": "string",
                  "maxLength": 120,
                  "pattern": "^(?:template:ltp_[0-9a-z]{26}:[a-z0-9][a-z0-9-]{0,39}|(?:assignment|type|attribute):\\S.*)$"
                },
                "additionalProperties": { "type": ["boolean", "null"] }
              }
            },
            "additionalProperties": false
          },
          "analyticsOptOut": {
            "description": "Switch the app's technical measurements (web vitals, client logs) off (true) or on (false) for the caller (FV-464). Omit to leave `preferences.analyticsOptOut` unchanged.",
            "type": "boolean"
          },
          "privacyAcknowledgedVersion": {
            "description": "The privacy notice version the caller acknowledges (FV-174); must be the current version (409 legal.version_outdated otherwise). Stored with the time as `legal`. Omit to leave it unchanged.",
            "type": "string",
            "pattern": "^\\d{1,3}\\.\\d{1,3}$"
          }
        },
        "required": ["displayName", "locale"],
        "additionalProperties": false
      },
      "updateMeOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^usr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A usr identifier (TypeID, conventions C5)."
          },
          "displayName": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "Display name shown in the UI (1-80 chars, §5.4)."
          },
          "locale": {
            "type": "string",
            "enum": ["nl", "en", "fr"],
            "description": "BCP 47 UI locale, one of nl | en | fr."
          },
          "localeChosen": {
            "description": "Whether the user explicitly chose `locale` (profile screen); then every device follows it. Absent: false.",
            "type": "boolean"
          },
          "email": {
            "description": "The account's sign-in e-mail address, as last synced from the identity provider.",
            "type": "string",
            "maxLength": 254,
            "format": "email",
            "pattern": "^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
          },
          "security": {
            "type": "object",
            "properties": {
              "providers": {
                "type": "array",
                "items": { "type": "string" },
                "description": "Sign-in provider ids this user has used (e.g. password, google.com)."
              },
              "passwordSet": {
                "description": "Whether the account can sign in with a password (set by refreshMySecurityState).",
                "type": "boolean"
              },
              "mfaEnrolled": {
                "description": "Whether two-step verification is enrolled (set by refreshMySecurityState).",
                "type": "boolean"
              }
            },
            "required": ["providers"],
            "additionalProperties": false
          },
          "preferences": {
            "type": "object",
            "properties": {
              "lastOrgId": {
                "description": "The last organisation this user was active in, if any.",
                "type": "string",
                "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$"
              },
              "onboardingChecklistDismissed": {
                "description": "Whether the caller dismissed the get-started checklist panel (FV-208, per user).",
                "type": "boolean"
              },
              "gesturesCoached": {
                "description": "The viewer gesture coach-marks this account has been shown (orbit, zoom, select; FV-219).",
                "type": "array",
                "items": {
                  "type": "string",
                  "enum": ["orbit", "zoom", "select"]
                }
              },
              "lengthUnit": {
                "description": "Display unit for measured lengths: mm (default when absent), cm or m (FV-238). Display only; stored values stay mm.",
                "type": "string",
                "enum": ["mm", "cm", "m"]
              },
              "measureSnap": {
                "description": "Measure snap settings: the targets switched off and the snap radius (FV-433). Absent: all on, medium.",
                "type": "object",
                "properties": {
                  "off": {
                    "maxItems": 7,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "enum": [
                        "vertex",
                        "edgeIntersection",
                        "edgeMidpoint",
                        "circleCentre",
                        "perpendicular",
                        "edgePoint",
                        "facePoint"
                      ]
                    },
                    "description": "Snap targets switched off: vertex, edgeIntersection, edgeMidpoint, circleCentre, perpendicular, edgePoint, facePoint."
                  },
                  "radius": {
                    "type": "string",
                    "enum": ["small", "medium", "large"],
                    "description": "Snap radius: small, medium (default) or large."
                  }
                },
                "required": ["off", "radius"],
                "additionalProperties": false
              },
              "trackpadScroll": {
                "description": "What a two-finger trackpad scroll does in the 3D viewer: pan (default when absent) or zoom (FV-472). A pinch always zooms.",
                "type": "string",
                "enum": ["pan", "zoom"]
              },
              "modelColours": {
                "description": "How the 3D viewer colours a model: file (default when absent: the file's own colours, the Field-Viewer palette where it has none) or palette (always the Field-Viewer palette) (FV-515).",
                "type": "string",
                "enum": ["file", "palette"]
              },
              "layers": {
                "description": "Personal layer defaults (FV-513): byProject (a project's own on/off overrides, the 30 most recently saved) and mine (on/off by template layer or derivation key, across projects). Absent: none.",
                "type": "object",
                "properties": {
                  "byProject": {
                    "maxItems": 30,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "projectId": {
                          "type": "string",
                          "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A prj identifier (TypeID, conventions C5)."
                        },
                        "layerSetId": {
                          "type": "string",
                          "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A lys identifier (TypeID, conventions C5)."
                        },
                        "off": {
                          "maxItems": 100,
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "^[a-z0-9][a-z0-9-]{0,63}$"
                          },
                          "description": "Field layers switched off against the project's default."
                        },
                        "on": {
                          "maxItems": 100,
                          "type": "array",
                          "items": {
                            "type": "string",
                            "pattern": "^[a-z0-9][a-z0-9-]{0,63}$"
                          },
                          "description": "Field layers switched on against the project's default."
                        },
                        "mode": {
                          "description": "project-default: this project opens on its own defaults, never on my default.",
                          "type": "string",
                          "enum": ["project-default"]
                        },
                        "updatedAt": {
                          "type": "string",
                          "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))$"
                        }
                      },
                      "required": [
                        "projectId",
                        "layerSetId",
                        "off",
                        "on",
                        "updatedAt"
                      ],
                      "additionalProperties": false
                    },
                    "description": "This person's own layer state per project, most recently saved first (at most 30)."
                  },
                  "mineOff": {
                    "maxItems": 200,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "maxLength": 120,
                      "pattern": "^(?:template:ltp_[0-9a-z]{26}:[a-z0-9][a-z0-9-]{0,39}|(?:assignment|type|attribute):\\S.*)$"
                    },
                    "description": "My default, off across projects: template:<template>:<layer> or <kind>:<derivation key>."
                  },
                  "mineOn": {
                    "maxItems": 200,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "maxLength": 120,
                      "pattern": "^(?:template:ltp_[0-9a-z]{26}:[a-z0-9][a-z0-9-]{0,39}|(?:assignment|type|attribute):\\S.*)$"
                    },
                    "description": "My default, on across projects (same keys)."
                  }
                },
                "required": ["byProject", "mineOff", "mineOn"],
                "additionalProperties": false
              },
              "analyticsOptOut": {
                "description": "Whether the caller switched off technical measurements (web vitals, client logs; FV-464). Absent: allowed.",
                "type": "boolean"
              }
            },
            "additionalProperties": false
          },
          "betaAccess": {
            "type": "object",
            "properties": {
              "codeId": {
                "type": "string",
                "pattern": "^bac_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A bac identifier (TypeID, conventions C5)."
              },
              "grantedAt": {
                "type": "string",
                "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))$"
              },
              "consumedAt": {
                "type": "string",
                "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))$"
              },
              "consumedOrgId": {
                "type": "string",
                "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A org identifier (TypeID, conventions C5)."
              }
            },
            "required": ["codeId", "grantedAt"],
            "additionalProperties": false
          },
          "legal": {
            "type": "object",
            "properties": {
              "privacyAcknowledgedVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "privacyAcknowledgedAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["privacyAcknowledgedVersion", "privacyAcknowledgedAt"],
            "additionalProperties": false,
            "description": "The privacy notice version the user acknowledged, and when."
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "displayName",
          "locale",
          "security",
          "preferences",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "updateMemberRoleInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "uid": {
            "type": "string",
            "minLength": 1,
            "description": "The member's Firebase Auth uid."
          },
          "role": {
            "type": "string",
            "enum": ["owner", "admin", "publisher", "member", "guest"],
            "description": "The new org role to set."
          }
        },
        "required": ["organizationId", "uid", "role"],
        "additionalProperties": false
      },
      "updateMemberRoleOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "minLength": 1,
            "description": "Same value as `uid`."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "uid": {
            "type": "string",
            "minLength": 1,
            "description": "The member's Firebase Auth uid."
          },
          "role": {
            "type": "string",
            "enum": ["owner", "admin", "publisher", "member", "guest"]
          },
          "status": {
            "type": "string",
            "enum": ["active", "invited", "suspended", "removed"]
          },
          "blocked": { "type": "boolean" },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          }
        },
        "required": [
          "id",
          "organizationId",
          "uid",
          "role",
          "status",
          "blocked",
          "createdAt",
          "updatedAt",
          "revision"
        ],
        "additionalProperties": false
      },
      "updateModelVersionInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          },
          "label": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 1,
                "maxLength": 40,
                "description": "Short version name, e.g. \"Roof fix\" (1-40 chars after trimming, BR-10)."
              },
              { "type": "null" }
            ]
          },
          "notes": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 2000,
                "description": "Free-form notes for the crew (max 2000 chars, BR-10)."
              },
              { "type": "null" }
            ]
          },
          "editedAt": {
            "description": "When the edit was made (RFC 3339), for an edit sent later than it was made: an edit older than the one already stored is dropped (last-write-wins). Omit for a live edit.",
            "type": "string",
            "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))$"
          }
        },
        "required": ["organizationId", "projectId", "modelId", "versionId"],
        "additionalProperties": false
      },
      "updateModelVersionOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionNumber": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "status": {
            "type": "string",
            "enum": [
              "uploading",
              "uploaded",
              "processing",
              "ready",
              "failed",
              "archived",
              "cancelled"
            ]
          },
          "publication": {
            "type": "string",
            "enum": ["draft", "published", "superseded"]
          },
          "fieldVisible": { "type": "boolean" },
          "source": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "upload" },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "fileName", "sizeBytes", "contentType"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "copy" },
                  "sourceVersionId": {
                    "type": "string",
                    "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A ver identifier (TypeID, conventions C5)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": [
                  "kind",
                  "sourceVersionId",
                  "fileName",
                  "sizeBytes",
                  "contentType"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "url" },
                  "url": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 2048,
                    "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                  },
                  "fileName": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 255,
                    "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                  },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 1073741824,
                    "description": "Declared file size in bytes (BR-24)."
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sha256": {
                    "type": "string",
                    "pattern": "^[0-9a-f]{64}$",
                    "description": "Optional SHA-256 of the source file, 64 hex chars."
                  }
                },
                "required": ["kind", "url", "fileName", "contentType"],
                "additionalProperties": false
              }
            ]
          },
          "upload": {
            "type": "object",
            "properties": {
              "method": { "type": "string", "const": "PUT" },
              "url": { "type": "string" },
              "headers": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": { "type": "string" }
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "maxBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "resumable": { "type": "boolean", "const": true },
              "chunkSizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "method",
              "url",
              "headers",
              "expiresAt",
              "maxBytes",
              "resumable",
              "chunkSizeBytes"
            ],
            "additionalProperties": false
          },
          "expiresAt": {
            "type": "string",
            "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))$"
          },
          "cancelReason": { "type": "string", "enum": ["user", "expired"] },
          "pipelineVersion": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "warnings": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "code": { "type": "string" },
                "blocking": { "type": "boolean" },
                "params": {
                  "type": "object",
                  "propertyNames": { "type": "string" },
                  "additionalProperties": {}
                }
              },
              "required": ["code"],
              "additionalProperties": false
            }
          },
          "failure": {
            "type": "object",
            "properties": {
              "code": { "type": "string", "minLength": 1 },
              "retryable": { "type": "boolean" },
              "params": {
                "type": "object",
                "propertyNames": { "type": "string" },
                "additionalProperties": {}
              },
              "messageKey": { "type": "string", "minLength": 1 },
              "supportRef": { "type": "string", "minLength": 1 }
            },
            "required": ["code", "retryable"],
            "additionalProperties": false
          },
          "processing": {
            "type": "object",
            "properties": {
              "sizeClass": { "type": "string", "enum": ["s", "m", "l", "xl"] },
              "executionName": { "type": "string", "minLength": 1 },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "queuedAt": {
                "type": "string",
                "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))$"
              },
              "queuedTraceparent": {
                "type": "string",
                "pattern": "^(?!ff)[0-9a-f]{2}-(?!0{32})[0-9a-f]{32}-(?!0{16})[0-9a-f]{16}-[0-9a-f]{2}$"
              },
              "queuedEscalation": {
                "type": "object",
                "properties": {
                  "sizeClass": {
                    "type": "string",
                    "enum": ["s", "m", "l", "xl"]
                  },
                  "attempt": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["sizeClass", "attempt"],
                "additionalProperties": false
              },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "progressReportedAt": {
                "type": "string",
                "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))$"
              },
              "requestId": { "type": "string", "minLength": 1 }
            },
            "additionalProperties": false
          },
          "progress": {
            "type": "object",
            "properties": {
              "stage": { "type": "string", "minLength": 1 },
              "percent": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["stage", "percent"],
            "additionalProperties": false
          },
          "reprocessing": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "attempt": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "reason": {
                "type": "string",
                "enum": ["retry", "pipeline_upgrade"]
              },
              "targetPipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "state": {
                "type": "string",
                "enum": [
                  "requested",
                  "deferred",
                  "awaiting_rollout",
                  "done",
                  "failed"
                ]
              },
              "completedAt": {
                "type": "string",
                "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))$"
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1 },
                  "retryable": { "type": "boolean" },
                  "params": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": {}
                  },
                  "messageKey": { "type": "string", "minLength": 1 },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "retryable"],
                "additionalProperties": false
              }
            },
            "required": ["requestedAt", "requestedBy", "attempt"],
            "additionalProperties": false
          },
          "releasedAt": {
            "type": "string",
            "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))$"
          },
          "releasedBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "supersededAt": {
            "type": "string",
            "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))$"
          },
          "activeArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "nextArtifactSet": {
            "type": "object",
            "properties": {
              "path": { "type": "string", "minLength": 1 },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "startedAt": {
                "type": "string",
                "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))$"
              },
              "files": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "name": { "type": "string", "minLength": 1 },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "required": ["name", "sizeBytes"],
                  "additionalProperties": false
                }
              },
              "totalBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "contractVersion": {
                "type": "string",
                "pattern": "^\\d+\\.\\d+$"
              }
            },
            "required": ["path", "pipelineVersion", "startedAt", "files"],
            "additionalProperties": false
          },
          "stats": {
            "type": "object",
            "properties": {
              "elementCount": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "boundsMm": {
                "type": "object",
                "properties": {
                  "min": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3
                  },
                  "max": {
                    "type": "array",
                    "prefixItems": [
                      { "type": "number" },
                      { "type": "number" },
                      { "type": "number" }
                    ],
                    "items": false,
                    "minItems": 3,
                    "maxItems": 3
                  }
                },
                "required": ["min", "max"],
                "additionalProperties": false
              },
              "coveragePct": { "type": "number", "minimum": 0, "maximum": 100 }
            },
            "required": ["elementCount", "boundsMm"],
            "additionalProperties": false
          },
          "churn": {
            "type": "object",
            "properties": {
              "ratio": { "type": "number", "minimum": 0, "maximum": 1 },
              "added": { "type": "array", "items": { "type": "string" } },
              "removed": { "type": "array", "items": { "type": "string" } },
              "moved": { "type": "array", "items": { "type": "string" } },
              "recreated": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "from": { "type": "string" },
                    "to": { "type": "string" }
                  },
                  "required": ["from", "to"],
                  "additionalProperties": false
                }
              }
            },
            "required": ["ratio", "added", "removed", "moved", "recreated"],
            "additionalProperties": false
          },
          "label": {
            "type": "string",
            "minLength": 1,
            "maxLength": 40,
            "description": "Short version name, e.g. \"Roof fix\" (1-40 chars after trimming, BR-10)."
          },
          "notes": {
            "type": "string",
            "maxLength": 2000,
            "description": "Free-form notes for the crew (max 2000 chars, BR-10)."
          },
          "detailsEditedAt": {
            "type": "string",
            "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))$"
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "publishOnReady": {
            "description": "Publish this version automatically, in the same write that marks it ready (FV-383).",
            "type": "boolean"
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "modelId",
          "versionNumber",
          "status",
          "publication",
          "fieldVisible",
          "source",
          "pipelineVersion",
          "warnings",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "updateOrganizationEntitlementsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "planId": {
            "description": "Moves the organisation to this plan: its limits and features become the plan's catalogue row. An override stays as it is.",
            "type": "string",
            "enum": ["beta", "free", "team", "enterprise", "internal", "tryout"]
          },
          "cohort": {
            "description": "Beta wave tag. `null` removes it.",
            "anyOf": [{ "type": "string", "minLength": 1 }, { "type": "null" }]
          },
          "overrides": {
            "description": "Merged into the current override. `null` removes the override entirely.",
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "limits": {
                    "type": "object",
                    "properties": {
                      "seats": {
                        "anyOf": [
                          {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          },
                          { "type": "null" }
                        ]
                      },
                      "guests": {
                        "anyOf": [
                          {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          },
                          { "type": "null" }
                        ]
                      },
                      "workstations": {
                        "anyOf": [
                          {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          },
                          { "type": "null" }
                        ]
                      },
                      "projects": {
                        "anyOf": [
                          {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          },
                          { "type": "null" }
                        ]
                      },
                      "storageBytes": {
                        "anyOf": [
                          {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          },
                          { "type": "null" }
                        ]
                      },
                      "maxModelFileBytes": {
                        "anyOf": [
                          {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 1073741824,
                            "description": "Largest single model file, in bytes, for direct upload and URL import. Never above 1 GiB (BR-10)."
                          },
                          { "type": "null" }
                        ]
                      },
                      "maxModelsPerProject": {
                        "anyOf": [
                          {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          },
                          { "type": "null" }
                        ]
                      },
                      "processingMinutesPerMonth": {
                        "anyOf": [
                          {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          },
                          { "type": "null" }
                        ]
                      },
                      "apiTokens": {
                        "anyOf": [
                          {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          },
                          { "type": "null" }
                        ]
                      },
                      "maxDocumentFileBytes": {
                        "anyOf": [
                          {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991,
                            "description": "Largest single drawing file (PDF, DXF, DWG), in bytes. The format's own ceiling still applies on top."
                          },
                          { "type": "null" }
                        ]
                      },
                      "maxDocumentsPerProject": {
                        "anyOf": [
                          {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 9007199254740991
                          },
                          { "type": "null" }
                        ]
                      }
                    },
                    "additionalProperties": false
                  },
                  "features": {
                    "type": "object",
                    "properties": {
                      "autoDimensions": { "type": ["boolean", "null"] },
                      "workstationMode": { "type": ["boolean", "null"] },
                      "auditLogExport": { "type": ["boolean", "null"] },
                      "sso": { "type": ["boolean", "null"] }
                    },
                    "additionalProperties": false
                  },
                  "reason": {
                    "type": "string",
                    "minLength": 1,
                    "maxLength": 500,
                    "description": "Why the override is set, e.g. a support ticket. Required for every override change; kept in the audit log."
                  },
                  "expiresAt": {
                    "description": "When the override stops applying. Omit to keep the current expiry; `null` makes it permanent.",
                    "anyOf": [
                      {
                        "type": "string",
                        "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))$"
                      },
                      { "type": "null" }
                    ]
                  }
                },
                "required": ["reason"],
                "additionalProperties": false
              },
              { "type": "null" }
            ]
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "updateOrganizationEntitlementsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "planId": {
            "type": "string",
            "enum": ["beta", "free", "team", "enterprise", "internal", "tryout"]
          },
          "cohort": { "type": "string", "minLength": 1 },
          "orgStatus": { "type": "string", "enum": ["active", "suspended"] },
          "limits": {
            "type": "object",
            "properties": {
              "seats": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "guests": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "workstations": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "projects": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "storageBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "maxModelFileBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 1073741824,
                "description": "Largest single model file, in bytes, for direct upload and URL import. Never above 1 GiB (BR-10)."
              },
              "maxModelsPerProject": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "processingMinutesPerMonth": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "apiTokens": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "maxDocumentFileBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991,
                "description": "Largest single drawing file (PDF, DXF, DWG), in bytes. The format's own ceiling still applies on top."
              },
              "maxDocumentsPerProject": {
                "description": "Most drawings (documents) in one project. Absent: no limit.",
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              }
            },
            "required": [
              "seats",
              "guests",
              "workstations",
              "projects",
              "storageBytes",
              "maxModelFileBytes",
              "maxModelsPerProject",
              "processingMinutesPerMonth",
              "apiTokens",
              "maxDocumentFileBytes"
            ],
            "additionalProperties": false
          },
          "features": {
            "type": "object",
            "properties": {
              "autoDimensions": { "type": "boolean" },
              "workstationMode": { "type": "boolean" },
              "auditLogExport": {
                "type": "boolean",
                "description": "Whether the activity log can be exported as CSV (`requestAuditLogExport`)."
              },
              "sso": {
                "type": "boolean",
                "description": "Reserved for single sign-on. Not in use yet."
              }
            },
            "required": [
              "autoDimensions",
              "workstationMode",
              "auditLogExport",
              "sso"
            ],
            "additionalProperties": false
          },
          "overrides": {
            "type": "object",
            "properties": {
              "limits": {
                "type": "object",
                "properties": {
                  "seats": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "guests": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "workstations": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "projects": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "storageBytes": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "maxModelFileBytes": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 1073741824,
                    "description": "Largest single model file, in bytes, for direct upload and URL import. Never above 1 GiB (BR-10)."
                  },
                  "maxModelsPerProject": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "processingMinutesPerMonth": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "apiTokens": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "maxDocumentFileBytes": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991,
                    "description": "Largest single drawing file (PDF, DXF, DWG), in bytes. The format's own ceiling still applies on top."
                  },
                  "maxDocumentsPerProject": {
                    "description": "Most drawings (documents) in one project. Absent: no limit.",
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "additionalProperties": false
              },
              "features": {
                "type": "object",
                "properties": {
                  "autoDimensions": { "type": "boolean" },
                  "workstationMode": { "type": "boolean" },
                  "auditLogExport": {
                    "type": "boolean",
                    "description": "Whether the activity log can be exported as CSV (`requestAuditLogExport`)."
                  },
                  "sso": {
                    "type": "boolean",
                    "description": "Reserved for single sign-on. Not in use yet."
                  }
                },
                "additionalProperties": false
              },
              "reason": { "type": "string", "minLength": 1 },
              "appliedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              },
              "appliedAt": {
                "type": "string",
                "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))$"
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["reason", "appliedBy", "appliedAt"],
            "additionalProperties": false
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991,
            "description": "The entitlements document's revision after this write; send it as If-Match on the next change."
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          }
        },
        "required": [
          "planId",
          "orgStatus",
          "limits",
          "features",
          "revision",
          "updatedAt"
        ],
        "additionalProperties": false
      },
      "updateOrganizationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 2,
            "maxLength": 80,
            "description": "Organisation display name (2-80 chars after trimming, BR-10)."
          },
          "defaultLocale": {
            "description": "The organisation's default UI locale: nl, en or fr.",
            "type": "string",
            "enum": ["nl", "en", "fr"]
          },
          "logo": {
            "description": "The uploaded logo to use ({uploadId, contentType} from createOrganizationLogoUpload, after the PUT finished), or null to remove the logo.",
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "uploadId": {
                    "type": "string",
                    "pattern": "^upl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A upl identifier (TypeID, conventions C5)."
                  },
                  "contentType": {
                    "type": "string",
                    "enum": ["image/png", "image/jpeg", "image/webp"],
                    "description": "The content type the upload declared: image/png, image/jpeg or image/webp."
                  }
                },
                "required": ["uploadId", "contentType"],
                "additionalProperties": false
              },
              { "type": "null" }
            ]
          },
          "settings": {
            "description": "Organisation-wide settings. settings.analytics.mode switches product analytics (anonymous usage events) on or off for every member (FV-168). settings.cad.producerDetailTags names the CAD producer's detail attribute tags, so panel drawings measure at their real scale (FV-560).",
            "type": "object",
            "properties": {
              "analytics": {
                "type": "object",
                "properties": {
                  "mode": {
                    "type": "string",
                    "enum": ["enabled", "disabled"],
                    "description": "enabled (the default) or disabled: product analytics for every member."
                  }
                },
                "required": ["mode"],
                "additionalProperties": false
              },
              "cad": {
                "type": "object",
                "properties": {
                  "producerDetailTags": {
                    "description": "The CAD producer's detail attribute tags (all seven), or null to remove them. New DXF/DWG uploads of the organisation read scaled model-space details with them (FV-560).",
                    "anyOf": [
                      {
                        "type": "object",
                        "properties": {
                          "scale": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 64,
                            "pattern": "^\\S+$",
                            "description": "Tag of the attribute holding the detail's scale text (1:n)."
                          },
                          "xFactor": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 64,
                            "pattern": "^\\S+$",
                            "description": "Tag of the attribute holding the detail's x factor (1/n)."
                          },
                          "yFactor": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 64,
                            "pattern": "^\\S+$",
                            "description": "Tag of the attribute holding the detail's y factor (1/n)."
                          },
                          "xMin": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 64,
                            "pattern": "^\\S+$",
                            "description": "Tag of the attribute holding the detail region's minimum x."
                          },
                          "yMin": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 64,
                            "pattern": "^\\S+$",
                            "description": "Tag of the attribute holding the detail region's minimum y."
                          },
                          "xMax": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 64,
                            "pattern": "^\\S+$",
                            "description": "Tag of the attribute holding the detail region's maximum x."
                          },
                          "yMax": {
                            "type": "string",
                            "minLength": 1,
                            "maxLength": 64,
                            "pattern": "^\\S+$",
                            "description": "Tag of the attribute holding the detail region's maximum y."
                          }
                        },
                        "required": [
                          "scale",
                          "xFactor",
                          "yFactor",
                          "xMin",
                          "yMin",
                          "xMax",
                          "yMax"
                        ],
                        "additionalProperties": false,
                        "description": "The CAD producer's detail attribute tags: all seven, each the tag (not the value) of one block attribute. With them, scaled details in model space measure in real millimetres at their own scale; without them they read 'scale unknown'."
                      },
                      { "type": "null" }
                    ]
                  }
                },
                "additionalProperties": false
              }
            },
            "additionalProperties": false
          }
        },
        "required": ["organizationId"],
        "additionalProperties": false
      },
      "updateOrganizationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 2,
            "maxLength": 80,
            "description": "Organisation display name (2-80 chars after trimming, BR-10)."
          },
          "defaultLocale": {
            "type": "string",
            "enum": ["nl", "en", "fr"],
            "description": "The organisation's default UI locale, one of nl | en | fr."
          },
          "status": {
            "type": "string",
            "enum": ["active", "pending_deletion"]
          },
          "deletion": {
            "type": "object",
            "properties": {
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": { "type": "string", "minLength": 1 },
              "purgeAfter": {
                "type": "string",
                "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))$"
              },
              "cancelledAt": {
                "type": "string",
                "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))$"
              },
              "purgeStartedAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["requestedAt", "requestedBy", "purgeAfter"],
            "additionalProperties": false
          },
          "supportAccess": {
            "description": "Whether Field-Viewer support may open a read-only support session: allowed (default when absent; owners are e-mailed) or ask (an owner approves each request first).",
            "type": "string",
            "enum": ["allowed", "ask"]
          },
          "settings": {
            "type": "object",
            "properties": {
              "analytics": {
                "type": "object",
                "properties": {
                  "mode": {
                    "type": "string",
                    "enum": ["enabled", "disabled"],
                    "description": "Product analytics for every member: enabled (the default) or disabled. Disabled, no usage event is recorded for anyone in the organisation."
                  }
                },
                "required": ["mode"],
                "additionalProperties": false
              },
              "cad": {
                "type": "object",
                "properties": {
                  "producerDetailTags": {
                    "type": "object",
                    "properties": {
                      "scale": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's scale text (1:n)."
                      },
                      "xFactor": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's x factor (1/n)."
                      },
                      "yFactor": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail's y factor (1/n)."
                      },
                      "xMin": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's minimum x."
                      },
                      "yMin": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's minimum y."
                      },
                      "xMax": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's maximum x."
                      },
                      "yMax": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64,
                        "pattern": "^\\S+$",
                        "description": "Tag of the attribute holding the detail region's maximum y."
                      }
                    },
                    "required": [
                      "scale",
                      "xFactor",
                      "yFactor",
                      "xMin",
                      "yMin",
                      "xMax",
                      "yMax"
                    ],
                    "additionalProperties": false,
                    "description": "The CAD producer's detail attribute tags: all seven, each the tag (not the value) of one block attribute. With them, scaled details in model space measure in real millimetres at their own scale; without them they read 'scale unknown'."
                  }
                },
                "additionalProperties": false
              }
            },
            "additionalProperties": false
          },
          "legal": {
            "type": "object",
            "properties": {
              "termsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "privacyVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "dpaVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "subprocessorsVersion": {
                "type": "string",
                "pattern": "^\\d{1,3}\\.\\d{1,3}$",
                "description": "A legal document version, `<major>.<minor>` (e.g. 0.1)."
              },
              "acceptedAt": {
                "type": "string",
                "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))$"
              },
              "acceptedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              }
            },
            "required": [
              "termsVersion",
              "privacyVersion",
              "dpaVersion",
              "subprocessorsVersion",
              "acceptedAt",
              "acceptedBy"
            ],
            "additionalProperties": false,
            "description": "The terms, privacy notice, DPA and sub-processor list versions an owner accepted for the organisation."
          },
          "kind": {
            "description": "standard (default when absent) or tryout: an anonymous visitor's 7-day try-it organisation.",
            "type": "string",
            "enum": ["standard", "tryout"]
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "logoUrl": {
            "type": "object",
            "properties": {
              "url": { "type": "string" },
              "expiresAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["url", "expiresAt"],
            "additionalProperties": false,
            "description": "Signed URL of the organisation's logo (15 minutes). Absent when it has no logo."
          },
          "reacceptanceRequired": {
            "description": "True when an owner must accept a newer material version of the terms, the DPA or the sub-processor list (or never accepted them).",
            "type": "boolean"
          }
        },
        "required": [
          "id",
          "name",
          "defaultLocale",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "updatePlanPriceInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "planId": {
            "type": "string",
            "enum": ["free", "team", "enterprise", "internal", "tryout"]
          },
          "intervals": {
            "type": "object",
            "properties": {
              "monthly": {
                "type": "object",
                "properties": {
                  "amountCents": {
                    "type": "integer",
                    "minimum": -9007199254740991,
                    "maximum": 9007199254740991,
                    "description": "The new amount in EUR cents, excl. VAT; more than 0."
                  }
                },
                "required": ["amountCents"],
                "additionalProperties": false
              },
              "yearly": {
                "type": "object",
                "properties": {
                  "amountCents": {
                    "type": "integer",
                    "minimum": -9007199254740991,
                    "maximum": 9007199254740991,
                    "description": "The new amount in EUR cents, excl. VAT; more than 0."
                  }
                },
                "required": ["amountCents"],
                "additionalProperties": false
              }
            },
            "additionalProperties": false
          },
          "note": {
            "description": "Why the price changes; kept in the history and the log.",
            "type": "string",
            "minLength": 1,
            "maxLength": 500
          }
        },
        "required": ["planId", "intervals"],
        "additionalProperties": false
      },
      "updatePlanPriceOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "planId": {
            "type": "string",
            "enum": ["free", "team", "enterprise", "internal", "tryout"]
          },
          "currency": { "type": "string", "const": "EUR" },
          "intervals": {
            "type": "object",
            "properties": {
              "monthly": {
                "type": "object",
                "properties": {
                  "amountCents": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "validFrom": {
                    "type": "string",
                    "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))$"
                  }
                },
                "required": ["amountCents", "validFrom"],
                "additionalProperties": false
              },
              "yearly": {
                "type": "object",
                "properties": {
                  "amountCents": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "validFrom": {
                    "type": "string",
                    "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))$"
                  }
                },
                "required": ["amountCents", "validFrom"],
                "additionalProperties": false
              }
            },
            "required": ["monthly", "yearly"],
            "additionalProperties": false
          },
          "history": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "interval": { "type": "string", "enum": ["monthly", "yearly"] },
                "amountCents": {
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "validFrom": {
                  "type": "string",
                  "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))$"
                },
                "validUntil": {
                  "type": "string",
                  "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))$"
                },
                "changedBy": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                },
                "note": { "type": "string", "maxLength": 500 }
              },
              "required": [
                "interval",
                "amountCents",
                "validFrom",
                "validUntil"
              ],
              "additionalProperties": false
            }
          },
          "atProvider": { "type": "boolean" },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "updatedBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          }
        },
        "required": [
          "planId",
          "currency",
          "intervals",
          "history",
          "atProvider",
          "updatedAt",
          "revision"
        ],
        "additionalProperties": false
      },
      "updatePlatformFlagInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "flag": {
            "type": "string",
            "pattern": "^ff_e\\d{2}_[a-z0-9]+(?:_[a-z0-9]+)*$",
            "description": "A registered flag key, `ff_<epic>_<feature>` (docs/flags.md)."
          },
          "group": {
            "description": "The rollout group to switch: a cohort, or a plan. Absent: the flag's unconditional default for everyone.",
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "cohort" },
                  "cohort": {
                    "type": "string",
                    "pattern": "^[a-z0-9][a-z0-9_-]{0,39}$",
                    "description": "The cohort tag, e.g. `wave1`."
                  }
                },
                "required": ["kind", "cohort"],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "kind": { "type": "string", "const": "plan" },
                  "planId": {
                    "type": "string",
                    "enum": ["free", "team", "enterprise", "internal", "tryout"]
                  }
                },
                "required": ["kind", "planId"],
                "additionalProperties": false
              }
            ]
          },
          "value": {
            "description": "On or off. `null` (only with `group`) removes the group's rule, so it follows the default again.",
            "type": ["boolean", "null"]
          },
          "reason": {
            "type": "string",
            "minLength": 1,
            "maxLength": 500,
            "description": "Why the flag changes; kept in the platform log."
          },
          "etags": {
            "type": "object",
            "properties": {
              "client": { "type": "string", "minLength": 1 },
              "server": { "type": "string", "minLength": 1 }
            },
            "additionalProperties": false,
            "description": "The ETag of every template the flag lives in, from `getPlatformFlags` (`*` for a template that does not exist yet)."
          }
        },
        "required": ["flag", "value", "reason", "etags"],
        "additionalProperties": false
      },
      "updatePlatformFlagOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "changed": {
            "type": "boolean",
            "description": "False when the value asked for was already live: nothing was published."
          },
          "flag": {
            "type": "object",
            "properties": {
              "key": {
                "type": "string",
                "pattern": "^ff_e\\d{2}_[a-z0-9]+(?:_[a-z0-9]+)*$",
                "description": "A registered flag key, `ff_<epic>_<feature>` (docs/flags.md)."
              },
              "purpose": { "type": "string" },
              "owner": { "type": "string" },
              "templates": {
                "minItems": 1,
                "type": "array",
                "items": { "type": "string", "enum": ["client", "server"] }
              },
              "repoDefault": {
                "type": "boolean",
                "description": "The repo template's default: what a new environment starts with."
              },
              "inSync": {
                "type": "boolean",
                "description": "A flag in both templates: whether its default and rules are the same in both. Always true for a flag in one template."
              },
              "client": {
                "type": "object",
                "properties": {
                  "present": {
                    "type": "boolean",
                    "description": "Whether the live template has the parameter (a new environment gets it at the next deploy)."
                  },
                  "defaultValue": {
                    "description": "The unconditional default; `null` when absent or when it uses the in-app default.",
                    "type": ["boolean", "null"]
                  },
                  "rules": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "condition": {
                          "type": "string",
                          "minLength": 1,
                          "description": "The Remote Config condition's name."
                        },
                        "group": {
                          "description": "The rollout group the condition matches; absent for a condition this screen cannot read (several terms, several values): shown, never written.",
                          "oneOf": [
                            {
                              "type": "object",
                              "properties": {
                                "kind": { "type": "string", "const": "cohort" },
                                "cohort": {
                                  "type": "string",
                                  "pattern": "^[a-z0-9][a-z0-9_-]{0,39}$",
                                  "description": "The cohort tag, e.g. `wave1`."
                                }
                              },
                              "required": ["kind", "cohort"],
                              "additionalProperties": false
                            },
                            {
                              "type": "object",
                              "properties": {
                                "kind": { "type": "string", "const": "plan" },
                                "planId": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 40,
                                  "description": "The plan id the condition matches (`planId` signal)."
                                }
                              },
                              "required": ["kind", "planId"],
                              "additionalProperties": false
                            }
                          ]
                        },
                        "value": { "type": "boolean" }
                      },
                      "required": ["condition", "value"],
                      "additionalProperties": false
                    },
                    "description": "One rule per condition with a value, in the template's priority order."
                  }
                },
                "required": ["present", "defaultValue", "rules"],
                "additionalProperties": false
              },
              "server": {
                "type": "object",
                "properties": {
                  "present": {
                    "type": "boolean",
                    "description": "Whether the live template has the parameter (a new environment gets it at the next deploy)."
                  },
                  "defaultValue": {
                    "description": "The unconditional default; `null` when absent or when it uses the in-app default.",
                    "type": ["boolean", "null"]
                  },
                  "rules": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "condition": {
                          "type": "string",
                          "minLength": 1,
                          "description": "The Remote Config condition's name."
                        },
                        "group": {
                          "description": "The rollout group the condition matches; absent for a condition this screen cannot read (several terms, several values): shown, never written.",
                          "oneOf": [
                            {
                              "type": "object",
                              "properties": {
                                "kind": { "type": "string", "const": "cohort" },
                                "cohort": {
                                  "type": "string",
                                  "pattern": "^[a-z0-9][a-z0-9_-]{0,39}$",
                                  "description": "The cohort tag, e.g. `wave1`."
                                }
                              },
                              "required": ["kind", "cohort"],
                              "additionalProperties": false
                            },
                            {
                              "type": "object",
                              "properties": {
                                "kind": { "type": "string", "const": "plan" },
                                "planId": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 40,
                                  "description": "The plan id the condition matches (`planId` signal)."
                                }
                              },
                              "required": ["kind", "planId"],
                              "additionalProperties": false
                            }
                          ]
                        },
                        "value": { "type": "boolean" }
                      },
                      "required": ["condition", "value"],
                      "additionalProperties": false
                    },
                    "description": "One rule per condition with a value, in the template's priority order."
                  }
                },
                "required": ["present", "defaultValue", "rules"],
                "additionalProperties": false
              }
            },
            "required": [
              "key",
              "purpose",
              "owner",
              "templates",
              "repoDefault",
              "inSync"
            ],
            "additionalProperties": false
          },
          "templates": {
            "type": "object",
            "properties": {
              "client": {
                "type": "object",
                "properties": {
                  "exists": {
                    "type": "boolean",
                    "description": "False while the environment has no template of this kind yet."
                  },
                  "etag": {
                    "type": "string",
                    "minLength": 1,
                    "description": "The template's ETag; send it back in `etags` on a change (`*` while none exists)."
                  },
                  "versionNumber": { "type": "string" },
                  "updateTime": { "type": "string" }
                },
                "required": ["exists", "etag"],
                "additionalProperties": false
              },
              "server": {
                "type": "object",
                "properties": {
                  "exists": {
                    "type": "boolean",
                    "description": "False while the environment has no template of this kind yet."
                  },
                  "etag": {
                    "type": "string",
                    "minLength": 1,
                    "description": "The template's ETag; send it back in `etags` on a change (`*` while none exists)."
                  },
                  "versionNumber": { "type": "string" },
                  "updateTime": { "type": "string" }
                },
                "required": ["exists", "etag"],
                "additionalProperties": false
              }
            },
            "required": ["client", "server"],
            "additionalProperties": false
          }
        },
        "required": ["changed", "flag", "templates"],
        "additionalProperties": false
      },
      "updatePlatformRuntimeInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": { "tryoutsPaused": { "type": "boolean" } },
        "required": ["tryoutsPaused"],
        "additionalProperties": false
      },
      "updatePlatformRuntimeOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "processingPaused": {
            "type": "boolean",
            "description": "All pausable uploads answer `503 processing.paused` (the budget guard's prod degrade)."
          },
          "tryoutsPaused": {
            "type": "boolean",
            "description": "Only new tryouts answer `503 processing.paused`; uploads by organisations keep working."
          }
        },
        "required": ["processingPaused", "tryoutsPaused"],
        "additionalProperties": false
      },
      "updatePricingSettingsInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "gaAt": {
            "description": "When Field-Viewer goes live, RFC 3339 UTC; null clears it. From then on every beta organisation gets its 30 days. Omit to leave it as it is.",
            "anyOf": [
              {
                "type": "string",
                "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))$"
              },
              { "type": "null" }
            ]
          },
          "marginalCostCents": {
            "description": "Our marginal cost per organisation per month, in EUR cents excl. VAT (more than 0); null clears it. Omit to leave it as it is.",
            "anyOf": [
              {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              { "type": "null" }
            ]
          }
        },
        "additionalProperties": false
      },
      "updatePricingSettingsOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "gaAt": {
            "anyOf": [
              {
                "type": "string",
                "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))$"
              },
              { "type": "null" }
            ],
            "description": "When Field-Viewer goes live, RFC 3339 UTC; null while not set. Beta organisations get their 30 days from then."
          },
          "marginalCostCents": {
            "anyOf": [
              {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              { "type": "null" }
            ],
            "description": "Our marginal cost per organisation per month, in EUR cents excl. VAT (the backoffice's margin hint); null while not set."
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          }
        },
        "required": ["gaAt", "marginalCostCents", "updatedAt", "revision"],
        "additionalProperties": false
      },
      "updateProjectInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "Project display name (1-80 chars after trimming, BR-2)."
          },
          "reference": {
            "anyOf": [
              {
                "type": "string",
                "minLength": 1,
                "maxLength": 40,
                "description": "Free-form job/reference code, e.g. \"2026-041\" (BR-2)."
              },
              { "type": "null" }
            ]
          },
          "description": {
            "anyOf": [
              {
                "type": "string",
                "maxLength": 500,
                "description": "Free-form project description (BR-2)."
              },
              { "type": "null" }
            ]
          },
          "access": { "type": "string", "enum": ["org", "restricted"] },
          "sheetMetadata": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "fileNamePattern": {
                    "type": "string",
                    "description": "Regular expression matched against the file name without its .pdf extension, with named groups sheetNumber and/or discipline, e.g. ^(?<discipline>[A-Z])-(?<sheetNumber>\\d+) (max 200 chars; no backreferences or nested repeats)."
                  },
                  "disciplineMap": {
                    "type": "object",
                    "propertyNames": {
                      "type": "string",
                      "pattern": "^[A-Za-z0-9]{1,8}$"
                    },
                    "additionalProperties": {
                      "type": "string",
                      "enum": [
                        "architecture",
                        "structure",
                        "mechanical",
                        "electrical",
                        "plumbing",
                        "fire_protection",
                        "civil",
                        "landscape",
                        "general"
                      ]
                    }
                  }
                },
                "additionalProperties": false,
                "description": "How this project's PDF file names map to sheet number and discipline (BR-11). Without a fileNamePattern the file-name stem is the sheet number."
              },
              { "type": "null" }
            ]
          }
        },
        "required": ["organizationId", "projectId"],
        "additionalProperties": false
      },
      "updateProjectOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "Project display name (1-80 chars after trimming, BR-2)."
          },
          "reference": {
            "type": "string",
            "minLength": 1,
            "maxLength": 40,
            "description": "Free-form job/reference code, e.g. \"2026-041\" (BR-2)."
          },
          "description": {
            "type": "string",
            "maxLength": 500,
            "description": "Free-form project description (BR-2)."
          },
          "status": {
            "type": "string",
            "enum": ["active", "archived", "deleted"]
          },
          "access": { "type": "string", "enum": ["org", "restricted"] },
          "memberIds": {
            "maxItems": 500,
            "type": "array",
            "items": { "type": "string", "minLength": 1 }
          },
          "fieldVersionIds": {
            "maxItems": 500,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A ver identifier (TypeID, conventions C5)."
            }
          },
          "publishSeq": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "lastPublishedAt": {
            "type": "string",
            "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))$"
          },
          "isSample": { "type": "boolean", "const": true },
          "demoSlug": {
            "type": "string",
            "enum": [
              "landhuis_hulstveld",
              "landhuis_hulstveld_hsb",
              "woning_lindehof",
              "villa_berkenhaag",
              "hal_noorderkempen",
              "paneelset_werkplaats"
            ]
          },
          "archivedAt": {
            "type": "string",
            "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))$"
          },
          "deletedAt": {
            "type": "string",
            "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))$"
          },
          "purgeAfter": {
            "type": "string",
            "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))$"
          },
          "statusBeforeDeletion": {
            "type": "string",
            "enum": ["active", "archived"]
          },
          "purgeStartedAt": {
            "type": "string",
            "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))$"
          },
          "sheetMetadata": {
            "type": "object",
            "properties": {
              "fileNamePattern": {
                "type": "string",
                "description": "Regular expression matched against the file name without its .pdf extension, with named groups sheetNumber and/or discipline, e.g. ^(?<discipline>[A-Z])-(?<sheetNumber>\\d+) (max 200 chars; no backreferences or nested repeats)."
              },
              "disciplineMap": {
                "type": "object",
                "propertyNames": {
                  "type": "string",
                  "pattern": "^[A-Za-z0-9]{1,8}$"
                },
                "additionalProperties": {
                  "type": "string",
                  "enum": [
                    "architecture",
                    "structure",
                    "mechanical",
                    "electrical",
                    "plumbing",
                    "fire_protection",
                    "civil",
                    "landscape",
                    "general"
                  ]
                }
              }
            },
            "additionalProperties": false,
            "description": "How this project's PDF file names map to sheet number and discipline (BR-11). Without a fileNamePattern the file-name stem is the sheet number."
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "name",
          "status",
          "access",
          "memberIds",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "updateSavedViewInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "viewId": {
            "type": "string",
            "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A vw identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "The view's name, 1-80 characters."
          },
          "description": {
            "description": "New note (max 280 chars), or null to remove it.",
            "anyOf": [
              {
                "type": "string",
                "maxLength": 280,
                "description": "Optional note, max 280 characters."
              },
              { "type": "null" }
            ]
          },
          "scope": {
            "description": "shared: promote your personal view to the project, so everyone in it sees it. Needs view.manage. A shared view cannot go back to personal.",
            "type": "string",
            "const": "shared"
          },
          "isProjectDefault": {
            "description": "true: make this shared view the project default (the previous default is cleared in the same write); false: the project has no default any more. Needs view.manage.",
            "type": "boolean"
          }
        },
        "required": ["organizationId", "projectId", "viewId"],
        "additionalProperties": false
      },
      "updateSavedViewOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A vw identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "name": {
            "type": "string",
            "minLength": 1,
            "maxLength": 80,
            "description": "The view's name, 1-80 characters."
          },
          "description": {
            "type": "string",
            "maxLength": 280,
            "description": "Optional note, max 280 characters."
          },
          "scope": { "type": "string", "enum": ["personal", "shared"] },
          "ownerUid": { "type": "string", "minLength": 1 },
          "isProjectDefault": {
            "description": "true on the project's default view (at most one shared view per project); absent otherwise.",
            "type": "boolean",
            "const": true
          },
          "order": {
            "description": "A shared view's place in the project's list (0 first); absent until the list is reordered.",
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "state": {
            "type": "object",
            "properties": {
              "schemaVersion": { "type": "number", "const": 1 },
              "camera": {
                "type": "object",
                "properties": {
                  "position": {
                    "type": "object",
                    "properties": {
                      "x": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "y": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "z": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      }
                    },
                    "required": ["x", "y", "z"],
                    "additionalProperties": false
                  },
                  "target": {
                    "type": "object",
                    "properties": {
                      "x": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "y": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      },
                      "z": {
                        "type": "number",
                        "minimum": -100000,
                        "maximum": 100000
                      }
                    },
                    "required": ["x", "y", "z"],
                    "additionalProperties": false
                  },
                  "up": { "type": "string", "const": "z" },
                  "fovDeg": { "type": "number", "minimum": 20, "maximum": 90 },
                  "orthoHeightM": { "type": "number", "exclusiveMinimum": 0 }
                },
                "required": ["position", "target", "up"],
                "additionalProperties": false
              },
              "visibility": {
                "type": "object",
                "properties": {
                  "hiddenRefs": {
                    "maxItems": 5000,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "globalId": { "type": "string", "minLength": 1 },
                        "modelId": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        }
                      },
                      "required": ["globalId"],
                      "additionalProperties": false
                    }
                  },
                  "isolateRefs": {
                    "maxItems": 5000,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "globalId": { "type": "string", "minLength": 1 },
                        "modelId": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        }
                      },
                      "required": ["globalId"],
                      "additionalProperties": false
                    }
                  },
                  "ghost": { "type": "boolean" },
                  "isolateSource": { "type": "string", "const": "storey" }
                },
                "required": ["hiddenRefs", "isolateRefs", "ghost"],
                "additionalProperties": false
              },
              "section": {
                "type": "object",
                "properties": {
                  "axis": { "type": "string", "enum": ["x", "y", "z"] },
                  "offsetMm": { "type": "number" },
                  "flipped": { "type": "boolean" }
                },
                "required": ["axis", "offsetMm", "flipped"],
                "additionalProperties": false
              },
              "layerSetRef": {
                "type": "object",
                "properties": {
                  "layerSetId": {
                    "type": "string",
                    "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A lys identifier (TypeID, conventions C5)."
                  },
                  "overrides": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": { "type": "boolean" }
                  }
                },
                "required": ["layerSetId", "overrides"],
                "additionalProperties": false
              },
              "selection": {
                "maxItems": 50,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "globalId": { "type": "string", "minLength": 1 },
                    "modelId": {
                      "type": "string",
                      "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A mdl identifier (TypeID, conventions C5)."
                    }
                  },
                  "required": ["globalId"],
                  "additionalProperties": false
                }
              },
              "activeTool": { "type": "string", "minLength": 1 },
              "theme": { "type": "string", "enum": ["sunlight", "dim"] },
              "storeyFocusId": { "type": "string" },
              "splitView": {
                "type": "object",
                "properties": {
                  "active": { "type": "boolean" },
                  "ratio": { "type": "number", "minimum": 0.1, "maximum": 0.9 },
                  "primaryPane": {
                    "type": "string",
                    "enum": ["model", "document"]
                  },
                  "document": {
                    "type": "object",
                    "properties": {
                      "documentId": {
                        "type": "string",
                        "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                        "description": "A doc identifier (TypeID, conventions C5)."
                      },
                      "page": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 9007199254740991
                      },
                      "zoom": { "type": "number", "exclusiveMinimum": 0 },
                      "panPct": {
                        "type": "object",
                        "properties": {
                          "x": { "type": "number" },
                          "y": { "type": "number" }
                        },
                        "required": ["x", "y"],
                        "additionalProperties": false
                      },
                      "cad": {
                        "description": "FV-497: a CAD sheet's view -- the drawing point at the pane's centre (drawing units) and the scale in CSS px per drawing unit.",
                        "type": "object",
                        "properties": {
                          "center": {
                            "type": "object",
                            "properties": {
                              "x": { "type": "number" },
                              "y": { "type": "number" }
                            },
                            "required": ["x", "y"],
                            "additionalProperties": false
                          },
                          "scale": { "type": "number", "exclusiveMinimum": 0 }
                        },
                        "required": ["center", "scale"],
                        "additionalProperties": false
                      }
                    },
                    "required": ["documentId", "page"],
                    "additionalProperties": false
                  },
                  "fullscreenPane": {
                    "type": "string",
                    "enum": ["model", "document"]
                  }
                },
                "required": ["active", "ratio", "primaryPane"],
                "additionalProperties": false
              },
              "filter": {
                "description": "FV-473: the filter terms behind the hidden and isolate sets, and the built-in layers (panels, loose parts) that are off.",
                "type": "object",
                "properties": {
                  "terms": {
                    "maxItems": 20,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "mode": { "type": "string", "enum": ["only", "hide"] },
                        "key": {
                          "type": "string",
                          "enum": [
                            "search",
                            "class",
                            "type",
                            "material",
                            "layer",
                            "panel",
                            "storey",
                            "property",
                            "elements"
                          ]
                        },
                        "value": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 500
                        },
                        "name": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 200
                        },
                        "set": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 200
                        }
                      },
                      "required": ["mode", "key", "value"],
                      "additionalProperties": false
                    }
                  },
                  "builtInOff": {
                    "maxItems": 2,
                    "type": "array",
                    "items": { "type": "string", "enum": ["panels", "loose"] }
                  }
                },
                "required": ["terms"],
                "additionalProperties": false
              }
            },
            "required": [
              "schemaVersion",
              "camera",
              "visibility",
              "selection",
              "activeTool",
              "theme"
            ],
            "additionalProperties": false,
            "description": "A full ViewState v1 (E05 §4.2): camera, visibility, section, layerSetRef, selection, activeTool, theme, storeyFocusId, splitView, filter."
          },
          "originOffsetMm": {
            "type": "array",
            "prefixItems": [
              { "type": "number" },
              { "type": "number" },
              { "type": "number" }
            ],
            "items": false,
            "minItems": 3,
            "maxItems": 3,
            "description": "The scene's origin offset in millimetres the state's camera and section are relative to."
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          },
          "thumbnail": {
            "type": "object",
            "properties": {
              "contentType": {
                "type": "string",
                "enum": ["image/webp", "image/png"],
                "description": "image/webp or image/png."
              },
              "sizeBytes": {
                "type": "integer",
                "minimum": 1,
                "maximum": 1048576,
                "description": "The image size in bytes (max 1048576)."
              }
            },
            "required": ["contentType", "sizeBytes"],
            "additionalProperties": false
          },
          "thumbnailUrl": {
            "description": "Signed URL of the thumbnail (15 minutes). Absent while the image has not been uploaded.",
            "type": "object",
            "properties": {
              "url": { "type": "string" },
              "expiresAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": ["url", "expiresAt"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "projectId",
          "name",
          "scope",
          "state",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "updateSharedViewOrderInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "viewIds": {
            "minItems": 1,
            "maxItems": 100,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A vw identifier (TypeID, conventions C5)."
            },
            "description": "The project's shared views, first to last (1-100 distinct vw_ ids)."
          }
        },
        "required": ["organizationId", "projectId", "viewIds"],
        "additionalProperties": false
      },
      "updateSharedViewOrderOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "type": "string",
                  "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A vw identifier (TypeID, conventions C5)."
                },
                "organizationId": {
                  "type": "string",
                  "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A org identifier (TypeID, conventions C5)."
                },
                "projectId": {
                  "type": "string",
                  "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A prj identifier (TypeID, conventions C5)."
                },
                "name": {
                  "type": "string",
                  "minLength": 1,
                  "maxLength": 80,
                  "description": "The view's name, 1-80 characters."
                },
                "description": {
                  "type": "string",
                  "maxLength": 280,
                  "description": "Optional note, max 280 characters."
                },
                "scope": { "type": "string", "enum": ["personal", "shared"] },
                "ownerUid": { "type": "string", "minLength": 1 },
                "isProjectDefault": {
                  "description": "true on the project's default view (at most one shared view per project); absent otherwise.",
                  "type": "boolean",
                  "const": true
                },
                "order": {
                  "description": "A shared view's place in the project's list (0 first); absent until the list is reordered.",
                  "type": "integer",
                  "minimum": 0,
                  "maximum": 9007199254740991
                },
                "state": {
                  "type": "object",
                  "properties": {
                    "schemaVersion": { "type": "number", "const": 1 },
                    "camera": {
                      "type": "object",
                      "properties": {
                        "position": {
                          "type": "object",
                          "properties": {
                            "x": {
                              "type": "number",
                              "minimum": -100000,
                              "maximum": 100000
                            },
                            "y": {
                              "type": "number",
                              "minimum": -100000,
                              "maximum": 100000
                            },
                            "z": {
                              "type": "number",
                              "minimum": -100000,
                              "maximum": 100000
                            }
                          },
                          "required": ["x", "y", "z"],
                          "additionalProperties": false
                        },
                        "target": {
                          "type": "object",
                          "properties": {
                            "x": {
                              "type": "number",
                              "minimum": -100000,
                              "maximum": 100000
                            },
                            "y": {
                              "type": "number",
                              "minimum": -100000,
                              "maximum": 100000
                            },
                            "z": {
                              "type": "number",
                              "minimum": -100000,
                              "maximum": 100000
                            }
                          },
                          "required": ["x", "y", "z"],
                          "additionalProperties": false
                        },
                        "up": { "type": "string", "const": "z" },
                        "fovDeg": {
                          "type": "number",
                          "minimum": 20,
                          "maximum": 90
                        },
                        "orthoHeightM": {
                          "type": "number",
                          "exclusiveMinimum": 0
                        }
                      },
                      "required": ["position", "target", "up"],
                      "additionalProperties": false
                    },
                    "visibility": {
                      "type": "object",
                      "properties": {
                        "hiddenRefs": {
                          "maxItems": 5000,
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "globalId": { "type": "string", "minLength": 1 },
                              "modelId": {
                                "type": "string",
                                "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                "description": "A mdl identifier (TypeID, conventions C5)."
                              }
                            },
                            "required": ["globalId"],
                            "additionalProperties": false
                          }
                        },
                        "isolateRefs": {
                          "maxItems": 5000,
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "globalId": { "type": "string", "minLength": 1 },
                              "modelId": {
                                "type": "string",
                                "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                "description": "A mdl identifier (TypeID, conventions C5)."
                              }
                            },
                            "required": ["globalId"],
                            "additionalProperties": false
                          }
                        },
                        "ghost": { "type": "boolean" },
                        "isolateSource": { "type": "string", "const": "storey" }
                      },
                      "required": ["hiddenRefs", "isolateRefs", "ghost"],
                      "additionalProperties": false
                    },
                    "section": {
                      "type": "object",
                      "properties": {
                        "axis": { "type": "string", "enum": ["x", "y", "z"] },
                        "offsetMm": { "type": "number" },
                        "flipped": { "type": "boolean" }
                      },
                      "required": ["axis", "offsetMm", "flipped"],
                      "additionalProperties": false
                    },
                    "layerSetRef": {
                      "type": "object",
                      "properties": {
                        "layerSetId": {
                          "type": "string",
                          "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A lys identifier (TypeID, conventions C5)."
                        },
                        "overrides": {
                          "type": "object",
                          "propertyNames": { "type": "string" },
                          "additionalProperties": { "type": "boolean" }
                        }
                      },
                      "required": ["layerSetId", "overrides"],
                      "additionalProperties": false
                    },
                    "selection": {
                      "maxItems": 50,
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "globalId": { "type": "string", "minLength": 1 },
                          "modelId": {
                            "type": "string",
                            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                            "description": "A mdl identifier (TypeID, conventions C5)."
                          }
                        },
                        "required": ["globalId"],
                        "additionalProperties": false
                      }
                    },
                    "activeTool": { "type": "string", "minLength": 1 },
                    "theme": { "type": "string", "enum": ["sunlight", "dim"] },
                    "storeyFocusId": { "type": "string" },
                    "splitView": {
                      "type": "object",
                      "properties": {
                        "active": { "type": "boolean" },
                        "ratio": {
                          "type": "number",
                          "minimum": 0.1,
                          "maximum": 0.9
                        },
                        "primaryPane": {
                          "type": "string",
                          "enum": ["model", "document"]
                        },
                        "document": {
                          "type": "object",
                          "properties": {
                            "documentId": {
                              "type": "string",
                              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                              "description": "A doc identifier (TypeID, conventions C5)."
                            },
                            "page": {
                              "type": "integer",
                              "minimum": 1,
                              "maximum": 9007199254740991
                            },
                            "zoom": { "type": "number", "exclusiveMinimum": 0 },
                            "panPct": {
                              "type": "object",
                              "properties": {
                                "x": { "type": "number" },
                                "y": { "type": "number" }
                              },
                              "required": ["x", "y"],
                              "additionalProperties": false
                            },
                            "cad": {
                              "description": "FV-497: a CAD sheet's view -- the drawing point at the pane's centre (drawing units) and the scale in CSS px per drawing unit.",
                              "type": "object",
                              "properties": {
                                "center": {
                                  "type": "object",
                                  "properties": {
                                    "x": { "type": "number" },
                                    "y": { "type": "number" }
                                  },
                                  "required": ["x", "y"],
                                  "additionalProperties": false
                                },
                                "scale": {
                                  "type": "number",
                                  "exclusiveMinimum": 0
                                }
                              },
                              "required": ["center", "scale"],
                              "additionalProperties": false
                            }
                          },
                          "required": ["documentId", "page"],
                          "additionalProperties": false
                        },
                        "fullscreenPane": {
                          "type": "string",
                          "enum": ["model", "document"]
                        }
                      },
                      "required": ["active", "ratio", "primaryPane"],
                      "additionalProperties": false
                    },
                    "filter": {
                      "description": "FV-473: the filter terms behind the hidden and isolate sets, and the built-in layers (panels, loose parts) that are off.",
                      "type": "object",
                      "properties": {
                        "terms": {
                          "maxItems": 20,
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "mode": {
                                "type": "string",
                                "enum": ["only", "hide"]
                              },
                              "key": {
                                "type": "string",
                                "enum": [
                                  "search",
                                  "class",
                                  "type",
                                  "material",
                                  "layer",
                                  "panel",
                                  "storey",
                                  "property",
                                  "elements"
                                ]
                              },
                              "value": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 500
                              },
                              "name": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 200
                              },
                              "set": {
                                "type": "string",
                                "minLength": 1,
                                "maxLength": 200
                              }
                            },
                            "required": ["mode", "key", "value"],
                            "additionalProperties": false
                          }
                        },
                        "builtInOff": {
                          "maxItems": 2,
                          "type": "array",
                          "items": {
                            "type": "string",
                            "enum": ["panels", "loose"]
                          }
                        }
                      },
                      "required": ["terms"],
                      "additionalProperties": false
                    }
                  },
                  "required": [
                    "schemaVersion",
                    "camera",
                    "visibility",
                    "selection",
                    "activeTool",
                    "theme"
                  ],
                  "additionalProperties": false,
                  "description": "A full ViewState v1 (E05 §4.2): camera, visibility, section, layerSetRef, selection, activeTool, theme, storeyFocusId, splitView, filter."
                },
                "originOffsetMm": {
                  "type": "array",
                  "prefixItems": [
                    { "type": "number" },
                    { "type": "number" },
                    { "type": "number" }
                  ],
                  "items": false,
                  "minItems": 3,
                  "maxItems": 3,
                  "description": "The scene's origin offset in millimetres the state's camera and section are relative to."
                },
                "schemaVersion": { "type": "number", "const": 1 },
                "createdAt": {
                  "type": "string",
                  "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))$"
                },
                "updatedAt": {
                  "type": "string",
                  "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))$"
                },
                "revision": {
                  "type": "integer",
                  "exclusiveMinimum": 0,
                  "maximum": 9007199254740991
                },
                "createdBy": {
                  "type": "object",
                  "properties": {
                    "type": {
                      "type": "string",
                      "enum": [
                        "user",
                        "apiToken",
                        "oauth",
                        "workstation",
                        "platformAdmin"
                      ]
                    },
                    "id": { "type": "string" }
                  },
                  "required": ["type", "id"],
                  "additionalProperties": false
                },
                "thumbnail": {
                  "type": "object",
                  "properties": {
                    "contentType": {
                      "type": "string",
                      "enum": ["image/webp", "image/png"],
                      "description": "image/webp or image/png."
                    },
                    "sizeBytes": {
                      "type": "integer",
                      "minimum": 1,
                      "maximum": 1048576,
                      "description": "The image size in bytes (max 1048576)."
                    }
                  },
                  "required": ["contentType", "sizeBytes"],
                  "additionalProperties": false
                },
                "thumbnailUrl": {
                  "description": "Signed URL of the thumbnail (15 minutes). Absent while the image has not been uploaded.",
                  "type": "object",
                  "properties": {
                    "url": { "type": "string" },
                    "expiresAt": {
                      "type": "string",
                      "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))$"
                    }
                  },
                  "required": ["url", "expiresAt"],
                  "additionalProperties": false
                }
              },
              "required": [
                "id",
                "organizationId",
                "projectId",
                "name",
                "scope",
                "state",
                "schemaVersion",
                "createdAt",
                "updatedAt",
                "revision",
                "createdBy"
              ],
              "additionalProperties": false
            },
            "description": "The views sent, in their new order, with their new `order`."
          }
        },
        "required": ["data"],
        "additionalProperties": false
      },
      "updateTryoutInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "researchConsent": {
            "type": "string",
            "enum": ["consented", "declined", "withdrawn"],
            "description": "consented: Field-Viewer may keep an anonymised copy of the IFC for 24 months. declined: no copy (the box unticked). withdrawn: a consent taken back later."
          }
        },
        "required": ["organizationId", "researchConsent"],
        "additionalProperties": false
      },
      "updateTryoutOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "status": {
            "type": "string",
            "enum": ["not_asked", "declined", "consented", "withdrawn"]
          },
          "decidedAt": {
            "type": "string",
            "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))$"
          },
          "legalVersion": { "type": "string", "minLength": 1 },
          "withdrawnAt": {
            "type": "string",
            "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))$"
          },
          "copiedAt": {
            "type": "string",
            "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))$"
          },
          "objectPath": { "type": "string", "minLength": 1 }
        },
        "required": ["status"],
        "additionalProperties": false
      },
      "updateWorkstationInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "workstationId": {
            "type": "string",
            "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A wks identifier (TypeID, conventions C5)."
          },
          "name": { "type": "string", "minLength": 1, "maxLength": 60 },
          "projectIds": {
            "maxItems": 20,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          }
        },
        "required": ["organizationId", "workstationId"],
        "additionalProperties": false
      },
      "updateWorkstationOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "pattern": "^wks_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A wks identifier (TypeID, conventions C5)."
          },
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "name": { "type": "string", "minLength": 1 },
          "assignedProjectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "projectIds": {
            "default": [],
            "maxItems": 20,
            "type": "array",
            "items": {
              "type": "string",
              "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
              "description": "A prj identifier (TypeID, conventions C5)."
            }
          },
          "status": {
            "type": "string",
            "enum": ["unpaired", "active", "revoked"]
          },
          "blocked": { "type": "boolean" },
          "pairedAt": {
            "type": "string",
            "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))$"
          },
          "lastSeenAt": {
            "type": "string",
            "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))$"
          },
          "revokedAt": {
            "type": "string",
            "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))$"
          },
          "revokedBy": { "type": "string", "minLength": 1 },
          "preset": {
            "oneOf": [
              {
                "type": "object",
                "properties": {
                  "mode": { "type": "string", "const": "fixed" },
                  "projectId": {
                    "type": "string",
                    "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A prj identifier (TypeID, conventions C5)."
                  },
                  "modelPolicy": {
                    "type": "string",
                    "const": "latest_published"
                  },
                  "viewId": {
                    "type": "string",
                    "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A vw identifier (TypeID, conventions C5)."
                  },
                  "toolbarConfig": {
                    "maxItems": 7,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^[a-z][a-zA-Z0-9-]{0,39}$"
                    }
                  },
                  "lockedSettings": {
                    "type": "object",
                    "properties": {
                      "allowProjectSwitch": { "type": "boolean" },
                      "allowShare": { "type": "boolean" },
                      "theme": {
                        "type": "string",
                        "enum": ["sunlight", "dim"]
                      },
                      "idleResetMinutes": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 120
                      }
                    },
                    "required": [
                      "allowProjectSwitch",
                      "allowShare",
                      "idleResetMinutes"
                    ],
                    "additionalProperties": false
                  }
                },
                "required": [
                  "mode",
                  "projectId",
                  "modelPolicy",
                  "lockedSettings"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "mode": { "type": "string", "const": "crew" },
                  "projectIds": {
                    "minItems": 1,
                    "maxItems": 20,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A prj identifier (TypeID, conventions C5)."
                    }
                  },
                  "modelPolicy": {
                    "type": "string",
                    "const": "latest_published"
                  },
                  "viewId": {
                    "type": "string",
                    "pattern": "^vw_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A vw identifier (TypeID, conventions C5)."
                  },
                  "toolbarConfig": {
                    "maxItems": 7,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^[a-z][a-zA-Z0-9-]{0,39}$"
                    }
                  },
                  "lockedSettings": {
                    "type": "object",
                    "properties": {
                      "allowProjectSwitch": { "type": "boolean" },
                      "allowShare": { "type": "boolean" },
                      "theme": {
                        "type": "string",
                        "enum": ["sunlight", "dim"]
                      },
                      "idleResetMinutes": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 120
                      }
                    },
                    "required": [
                      "allowProjectSwitch",
                      "allowShare",
                      "idleResetMinutes"
                    ],
                    "additionalProperties": false
                  }
                },
                "required": [
                  "mode",
                  "projectIds",
                  "modelPolicy",
                  "lockedSettings"
                ],
                "additionalProperties": false
              }
            ]
          },
          "runtime": {
            "type": "object",
            "properties": {
              "heartbeatAt": {
                "type": "string",
                "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))$"
              },
              "currentProjectId": {
                "type": "string",
                "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A prj identifier (TypeID, conventions C5)."
              },
              "appVersion": {
                "type": "string",
                "minLength": 1,
                "maxLength": 64
              },
              "state": { "type": "string", "enum": ["ready", "error"] }
            },
            "required": ["heartbeatAt"],
            "additionalProperties": false
          },
          "schemaVersion": { "type": "number", "const": 1 },
          "createdAt": {
            "type": "string",
            "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))$"
          },
          "updatedAt": {
            "type": "string",
            "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))$"
          },
          "revision": {
            "type": "integer",
            "exclusiveMinimum": 0,
            "maximum": 9007199254740991
          },
          "createdBy": {
            "type": "object",
            "properties": {
              "type": {
                "type": "string",
                "enum": [
                  "user",
                  "apiToken",
                  "oauth",
                  "workstation",
                  "platformAdmin"
                ]
              },
              "id": { "type": "string" }
            },
            "required": ["type", "id"],
            "additionalProperties": false
          }
        },
        "required": [
          "id",
          "organizationId",
          "name",
          "projectIds",
          "status",
          "blocked",
          "schemaVersion",
          "createdAt",
          "updatedAt",
          "revision",
          "createdBy"
        ],
        "additionalProperties": false
      },
      "verifyEmailSignInCodeInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "challengeId": {
            "type": "string",
            "pattern": "^sic_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A sic identifier (TypeID, conventions C5)."
          },
          "code": {
            "type": "string",
            "pattern": "^[0-9]{6}$",
            "description": "6-digit numeric one-time code."
          },
          "linkAnonymous": {
            "description": "true: verify the code for the caller's own anonymous session (keeping a tryout); the address is added to that account instead of signing in to another one.",
            "type": "boolean",
            "const": true
          }
        },
        "required": ["challengeId", "code"],
        "additionalProperties": false
      },
      "verifyEmailSignInCodeOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": { "customToken": { "type": "string", "minLength": 1 } },
        "required": ["customToken"],
        "additionalProperties": false
      },
      "waitAuditLogExportInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "exportId": {
            "type": "string",
            "pattern": "^alx_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A alx identifier (TypeID, conventions C5)."
          },
          "timeoutSeconds": { "type": "integer", "minimum": 1, "maximum": 25 }
        },
        "required": ["organizationId", "exportId"],
        "additionalProperties": false
      },
      "waitAuditLogExportOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "done": { "type": "boolean" },
          "retryAfterSeconds": {
            "type": "integer",
            "minimum": 1,
            "maximum": 9007199254740991
          },
          "resource": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "pattern": "^alx_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A alx identifier (TypeID, conventions C5)."
              },
              "status": {
                "type": "string",
                "enum": ["pending", "ready", "failed", "expired"],
                "description": "pending (being built) | ready (downloadable until expiresAt) | failed (request a new one; see error) | expired (past its 24 h window)."
              },
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "filters": {
                "type": "object",
                "properties": {
                  "types": {
                    "type": "array",
                    "items": { "type": "string", "minLength": 1 }
                  },
                  "actor": { "type": "string", "minLength": 1 },
                  "occurredAfter": {
                    "type": "string",
                    "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))$"
                  },
                  "occurredBefore": {
                    "type": "string",
                    "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))$"
                  }
                },
                "additionalProperties": false,
                "description": "The filters the export was requested with."
              },
              "readyAt": {
                "type": "string",
                "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))$"
              },
              "expiresAt": {
                "description": "End of the 24 h download window.",
                "type": "string",
                "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))$"
              },
              "rowCount": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "sizeBytes": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "error": {
                "description": "Only on a failed export. too_many_rows: more than 50,000 events match -- narrow the date range.",
                "type": "string",
                "enum": ["build_failed", "too_many_rows"]
              },
              "download": {
                "description": "Present only while status is ready: a CSV (one row per event, every field except metadata) behind a signed URL valid for 15 minutes (C13). Call getAuditLogExport again for a fresh one until expiresAt.",
                "type": "object",
                "properties": {
                  "url": { "type": "string", "format": "uri" },
                  "expiresAt": {
                    "type": "string",
                    "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))$"
                  },
                  "contentType": { "type": "string", "minLength": 1 },
                  "sizeBytes": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["url", "expiresAt", "contentType", "sizeBytes"],
                "additionalProperties": false
              }
            },
            "required": ["id", "status", "requestedAt", "filters"],
            "additionalProperties": false
          }
        },
        "required": ["done", "resource"],
        "additionalProperties": false
      },
      "waitDocumentVersionInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "documentId": {
            "type": "string",
            "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A doc identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A dvr identifier (TypeID, conventions C5)."
          },
          "timeoutSeconds": { "type": "integer", "minimum": 1, "maximum": 25 }
        },
        "required": ["organizationId", "projectId", "documentId", "versionId"],
        "additionalProperties": false
      },
      "waitDocumentVersionOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "done": { "type": "boolean" },
          "retryAfterSeconds": {
            "type": "integer",
            "minimum": 1,
            "maximum": 9007199254740991
          },
          "resource": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A dvr identifier (TypeID, conventions C5)."
              },
              "organizationId": {
                "type": "string",
                "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A org identifier (TypeID, conventions C5)."
              },
              "projectId": {
                "type": "string",
                "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A prj identifier (TypeID, conventions C5)."
              },
              "documentId": {
                "type": "string",
                "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A doc identifier (TypeID, conventions C5)."
              },
              "versionNumber": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "status": {
                "type": "string",
                "enum": [
                  "uploading",
                  "uploaded",
                  "processing",
                  "ready",
                  "failed",
                  "archived",
                  "cancelled"
                ]
              },
              "publication": {
                "type": "string",
                "enum": ["draft", "published", "superseded"]
              },
              "fieldVisible": { "type": "boolean" },
              "source": {
                "oneOf": [
                  {
                    "type": "object",
                    "properties": {
                      "kind": { "type": "string", "const": "upload" },
                      "format": {
                        "type": "string",
                        "enum": ["pdf", "dxf", "dwg"],
                        "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                      },
                      "fileName": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 255,
                        "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                      },
                      "sizeBytes": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 1073741824,
                        "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                      },
                      "contentType": { "type": "string", "minLength": 1 },
                      "sha256": {
                        "type": "string",
                        "pattern": "^[0-9a-f]{64}$",
                        "description": "Optional SHA-256 of the source file, 64 hex chars."
                      }
                    },
                    "required": [
                      "kind",
                      "fileName",
                      "sizeBytes",
                      "contentType"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "kind": { "type": "string", "const": "url" },
                      "format": {
                        "type": "string",
                        "enum": ["pdf", "dxf", "dwg"],
                        "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                      },
                      "url": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 2048,
                        "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                      },
                      "fileName": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 255,
                        "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                      },
                      "sizeBytes": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 1073741824,
                        "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                      },
                      "contentType": { "type": "string", "minLength": 1 },
                      "sha256": {
                        "type": "string",
                        "pattern": "^[0-9a-f]{64}$",
                        "description": "Optional SHA-256 of the source file, 64 hex chars."
                      }
                    },
                    "required": ["kind", "url", "fileName", "contentType"],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "kind": { "type": "string", "const": "copy" },
                      "format": {
                        "type": "string",
                        "enum": ["pdf", "dxf", "dwg"],
                        "description": "The drawing's file format: pdf, dxf or dwg. Fixed per document by its first version."
                      },
                      "sourceVersionId": {
                        "type": "string",
                        "pattern": "^dvr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                        "description": "A dvr identifier (TypeID, conventions C5)."
                      },
                      "fileName": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 255,
                        "description": "Original file name, <= 255 chars, ending .pdf, .dxf or .dwg (BR-2, E13 BR-1)."
                      },
                      "sizeBytes": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 1073741824,
                        "description": "Declared file size in bytes (BR-3). Above the organisation's limit (beta: 100 MB, hard ceiling 300 MB) the call returns 403 entitlement.limit_reached."
                      },
                      "contentType": { "type": "string", "minLength": 1 },
                      "sha256": {
                        "type": "string",
                        "pattern": "^[0-9a-f]{64}$",
                        "description": "Optional SHA-256 of the source file, 64 hex chars."
                      }
                    },
                    "required": [
                      "kind",
                      "sourceVersionId",
                      "fileName",
                      "sizeBytes",
                      "contentType"
                    ],
                    "additionalProperties": false
                  }
                ]
              },
              "upload": {
                "type": "object",
                "properties": {
                  "method": { "type": "string", "const": "PUT" },
                  "url": { "type": "string" },
                  "headers": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": { "type": "string" }
                  },
                  "expiresAt": {
                    "type": "string",
                    "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))$"
                  },
                  "maxBytes": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  },
                  "resumable": { "type": "boolean", "const": true },
                  "chunkSizeBytes": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": [
                  "method",
                  "url",
                  "headers",
                  "expiresAt",
                  "maxBytes",
                  "resumable",
                  "chunkSizeBytes"
                ],
                "additionalProperties": false
              },
              "cancelReason": { "type": "string", "enum": ["user"] },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "warnings": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "code": { "type": "string" },
                    "blocking": { "type": "boolean" },
                    "params": {
                      "type": "object",
                      "propertyNames": { "type": "string" },
                      "additionalProperties": {}
                    }
                  },
                  "required": ["code"],
                  "additionalProperties": false
                }
              },
              "progress": {
                "type": "object",
                "properties": {
                  "stage": { "type": "string", "minLength": 1 },
                  "percent": { "type": "number", "minimum": 0, "maximum": 100 }
                },
                "required": ["stage", "percent"],
                "additionalProperties": false
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1 },
                  "retryable": { "type": "boolean" },
                  "params": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": {}
                  },
                  "messageKey": { "type": "string", "minLength": 1 },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "retryable"],
                "additionalProperties": false
              },
              "activeArtifactSet": {
                "type": "object",
                "properties": {
                  "path": { "type": "string", "minLength": 1 },
                  "pipelineVersion": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  },
                  "startedAt": {
                    "type": "string",
                    "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))$"
                  },
                  "files": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "name": { "type": "string", "minLength": 1 },
                        "sizeBytes": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        }
                      },
                      "required": ["name", "sizeBytes"],
                      "additionalProperties": false
                    }
                  },
                  "totalBytes": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "contractVersion": {
                    "type": "string",
                    "pattern": "^\\d+\\.\\d+$"
                  }
                },
                "required": ["path", "pipelineVersion", "startedAt", "files"],
                "additionalProperties": false
              },
              "reprocessing": {
                "type": "object",
                "properties": {
                  "requestedAt": {
                    "type": "string",
                    "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))$"
                  },
                  "requestedBy": { "type": "string", "minLength": 1 },
                  "attempt": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  },
                  "reason": {
                    "type": "string",
                    "enum": ["retry", "pipeline_upgrade"]
                  },
                  "targetPipelineVersion": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  },
                  "state": {
                    "type": "string",
                    "enum": [
                      "requested",
                      "deferred",
                      "awaiting_rollout",
                      "done",
                      "failed"
                    ]
                  },
                  "completedAt": {
                    "type": "string",
                    "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))$"
                  },
                  "failure": {
                    "type": "object",
                    "properties": {
                      "code": { "type": "string", "minLength": 1 },
                      "retryable": { "type": "boolean" },
                      "params": {
                        "type": "object",
                        "propertyNames": { "type": "string" },
                        "additionalProperties": {}
                      },
                      "messageKey": { "type": "string", "minLength": 1 },
                      "supportRef": { "type": "string", "minLength": 1 }
                    },
                    "required": ["code", "retryable"],
                    "additionalProperties": false
                  }
                },
                "required": ["requestedAt", "requestedBy", "attempt"],
                "additionalProperties": false
              },
              "pageCount": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "pages": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "pageNumber": {
                      "type": "integer",
                      "exclusiveMinimum": 0,
                      "maximum": 9007199254740991
                    },
                    "scanned": { "type": "boolean" },
                    "sheetNumber": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 100,
                      "description": "Sheet number, e.g. \"W-101\" (BR-11)."
                    },
                    "title": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 200,
                      "description": "Sheet title, e.g. from the PDF outline (BR-11)."
                    },
                    "discipline": {
                      "type": "string",
                      "enum": [
                        "architecture",
                        "structure",
                        "mechanical",
                        "electrical",
                        "plumbing",
                        "fire_protection",
                        "civil",
                        "landscape",
                        "general"
                      ]
                    },
                    "storeyId": { "type": "string", "minLength": 1 },
                    "overridden": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "enum": ["sheetNumber", "title", "discipline"]
                      }
                    },
                    "layout": {
                      "type": "object",
                      "properties": {
                        "name": { "type": "string", "minLength": 1 },
                        "kind": { "type": "string", "enum": ["model", "paper"] }
                      },
                      "required": ["name", "kind"],
                      "additionalProperties": false
                    },
                    "titleBlock": {
                      "type": "object",
                      "propertyNames": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 64
                      },
                      "additionalProperties": {
                        "type": "string",
                        "maxLength": 200
                      },
                      "description": "FV-490 (E13 §4.4): a CAD page's primary title block, attribute tag -> value (<= 32 entries, values <= 200 chars)."
                    },
                    "scale": {
                      "type": "object",
                      "properties": {
                        "factor": {
                          "type": "number",
                          "exclusiveMinimum": 0,
                          "maximum": 10000,
                          "description": "Real millimetres per paper millimetre (1:50 is 50)."
                        },
                        "source": {
                          "type": "string",
                          "enum": ["calibration", "label"],
                          "description": "calibration: two points and a known length; label: the title-block scale, confirmed."
                        },
                        "basis": {
                          "description": "For a calibration: the two points (fractions of the page) and the real length in mm.",
                          "type": "object",
                          "properties": {
                            "a": {
                              "type": "object",
                              "properties": {
                                "xPct": {
                                  "type": "number",
                                  "minimum": 0,
                                  "maximum": 1
                                },
                                "yPct": {
                                  "type": "number",
                                  "minimum": 0,
                                  "maximum": 1
                                }
                              },
                              "required": ["xPct", "yPct"],
                              "additionalProperties": false
                            },
                            "b": {
                              "type": "object",
                              "properties": {
                                "xPct": {
                                  "type": "number",
                                  "minimum": 0,
                                  "maximum": 1
                                },
                                "yPct": {
                                  "type": "number",
                                  "minimum": 0,
                                  "maximum": 1
                                }
                              },
                              "required": ["xPct", "yPct"],
                              "additionalProperties": false
                            },
                            "lengthMm": {
                              "type": "number",
                              "exclusiveMinimum": 0
                            }
                          },
                          "required": ["a", "b", "lengthMm"],
                          "additionalProperties": false
                        },
                        "setBy": { "type": "string", "minLength": 1 },
                        "setAt": {
                          "type": "string",
                          "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))$"
                        }
                      },
                      "required": ["factor", "source", "setBy", "setAt"],
                      "additionalProperties": false
                    }
                  },
                  "required": ["pageNumber", "scanned"],
                  "additionalProperties": false
                }
              },
              "cad": {
                "type": "object",
                "properties": {
                  "insunits": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "unitToMm": {
                    "anyOf": [
                      { "type": "number", "exclusiveMinimum": 0 },
                      { "type": "null" }
                    ]
                  },
                  "unitsOverride": {
                    "type": "string",
                    "enum": ["mm", "cm", "m", "in", "ft"],
                    "description": "The drawing's units, set by a publisher because the file declares none: mm, cm, m, in or ft."
                  },
                  "defaultLayersOff": {
                    "maxItems": 256,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255
                    },
                    "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
                  },
                  "parser": { "type": "string", "const": "acad-ts" },
                  "parserVersion": { "type": "string", "minLength": 1 },
                  "version": { "type": "string", "minLength": 1 },
                  "layoutCount": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": [
                  "insunits",
                  "unitToMm",
                  "parser",
                  "parserVersion",
                  "version",
                  "layoutCount"
                ],
                "additionalProperties": false
              },
              "layerDefault": {
                "type": "object",
                "properties": {
                  "off": {
                    "maxItems": 256,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 255
                    },
                    "description": "The layers off by default for everyone who opens this drawing, by name (at most 256); [] is every layer on. A person's own choice on their device still wins."
                  }
                },
                "required": ["off"],
                "additionalProperties": false,
                "description": "The layers off by default for everyone who opens this drawing (CAD layers or PDF optional content groups, by name). A person's own choice on their device still wins."
              },
              "publishOnReady": {
                "description": "Publish this version automatically, in the same write that marks it ready (FV-745).",
                "type": "boolean"
              },
              "releasedAt": {
                "type": "string",
                "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))$"
              },
              "supersededAt": {
                "type": "string",
                "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))$"
              },
              "schemaVersion": { "type": "number", "const": 1 },
              "createdAt": {
                "type": "string",
                "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))$"
              },
              "updatedAt": {
                "type": "string",
                "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))$"
              },
              "revision": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "createdBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              }
            },
            "required": [
              "id",
              "organizationId",
              "projectId",
              "documentId",
              "versionNumber",
              "status",
              "publication",
              "fieldVisible",
              "source",
              "pipelineVersion",
              "warnings",
              "schemaVersion",
              "createdAt",
              "updatedAt",
              "revision",
              "createdBy"
            ],
            "additionalProperties": false
          }
        },
        "required": ["done", "resource"],
        "additionalProperties": false
      },
      "waitLayerSetInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "layerSetId": {
            "type": "string",
            "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lys identifier (TypeID, conventions C5)."
          },
          "view": {
            "description": "`field` (default): without the entries hidden from the field. `all`: every entry, for curation.",
            "type": "string",
            "enum": ["field", "all"]
          },
          "timeoutSeconds": { "type": "integer", "minimum": 1, "maximum": 25 }
        },
        "required": ["organizationId", "projectId", "layerSetId"],
        "additionalProperties": false
      },
      "waitLayerSetOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "done": { "type": "boolean" },
          "retryAfterSeconds": {
            "type": "integer",
            "minimum": 1,
            "maximum": 9007199254740991
          },
          "resource": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "pattern": "^lys_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A lys identifier (TypeID, conventions C5)."
              },
              "organizationId": {
                "type": "string",
                "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A org identifier (TypeID, conventions C5)."
              },
              "projectId": {
                "type": "string",
                "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A prj identifier (TypeID, conventions C5)."
              },
              "status": {
                "type": "string",
                "enum": ["ready", "materializing", "failed"]
              },
              "materializingSince": {
                "type": "string",
                "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))$"
              },
              "materializeAttempts": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": {
                    "type": "string",
                    "enum": ["layer_rule_materialization_failed"]
                  },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "supportRef"],
                "additionalProperties": false
              },
              "derivationSource": {
                "type": "string",
                "enum": [
                  "assignment",
                  "type",
                  "classification",
                  "name-role",
                  "material",
                  "object-type"
                ]
              },
              "grouping": {
                "minItems": 1,
                "maxItems": 2,
                "type": "array",
                "items": {
                  "type": "string",
                  "enum": [
                    "classification",
                    "name-role",
                    "material",
                    "object-type"
                  ]
                }
              },
              "sourceCoveragePct": {
                "type": "number",
                "minimum": 0,
                "maximum": 100
              },
              "sources": {
                "maxItems": 100,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "modelId": {
                      "type": "string",
                      "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A mdl identifier (TypeID, conventions C5)."
                    },
                    "versionId": {
                      "type": "string",
                      "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A ver identifier (TypeID, conventions C5)."
                    }
                  },
                  "required": ["modelId", "versionId"],
                  "additionalProperties": false
                }
              },
              "generatedFromVersionId": {
                "type": "string",
                "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A ver identifier (TypeID, conventions C5)."
              },
              "derivedAtPublishSeq": {
                "type": "integer",
                "minimum": 0,
                "maximum": 9007199254740991
              },
              "generatedAt": {
                "type": "string",
                "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))$"
              },
              "warnings": {
                "maxItems": 100,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "code": {
                      "type": "string",
                      "enum": [
                        "layers_index_failed",
                        "layer_source_unavailable",
                        "layer_source_invalid",
                        "layer_assignment_skipped",
                        "layer_entries_truncated",
                        "layer_rule_truncated",
                        "layer_template_truncated"
                      ]
                    },
                    "modelId": {
                      "type": "string",
                      "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A mdl identifier (TypeID, conventions C5)."
                    },
                    "versionId": {
                      "type": "string",
                      "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A ver identifier (TypeID, conventions C5)."
                    },
                    "params": {
                      "type": "object",
                      "propertyNames": { "type": "string" },
                      "additionalProperties": { "type": ["string", "number"] }
                    }
                  },
                  "required": ["code"],
                  "additionalProperties": false
                }
              },
              "entries": {
                "maxItems": 100,
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "id": {
                      "type": "string",
                      "pattern": "^[a-z0-9][a-z0-9-]{0,63}$"
                    },
                    "kind": {
                      "type": "string",
                      "enum": [
                        "assignment",
                        "type",
                        "manual",
                        "rule",
                        "attribute"
                      ]
                    },
                    "derivationKeys": {
                      "maxItems": 100,
                      "type": "array",
                      "items": { "type": "string", "minLength": 1 }
                    },
                    "manualGlobalIds": {
                      "maxItems": 500,
                      "type": "array",
                      "items": { "type": "string", "minLength": 1 }
                    },
                    "rule": {
                      "type": "object",
                      "properties": {
                        "source": {
                          "type": "string",
                          "enum": [
                            "property",
                            "name",
                            "material",
                            "ifcClass",
                            "panel"
                          ]
                        },
                        "psetName": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 255
                        },
                        "propName": {
                          "type": "string",
                          "minLength": 1,
                          "maxLength": 255
                        },
                        "op": {
                          "type": "string",
                          "enum": ["eq", "neq", "contains"]
                        },
                        "value": { "type": "string", "maxLength": 1000 }
                      },
                      "required": ["op", "value"],
                      "additionalProperties": false
                    },
                    "materializedGlobalIds": {
                      "maxItems": 20000,
                      "type": "array",
                      "items": { "type": "string", "minLength": 1 }
                    },
                    "elementCount": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "displayName": {
                      "type": "string",
                      "minLength": 1,
                      "maxLength": 60
                    },
                    "colorHex": {
                      "type": "string",
                      "pattern": "^#[0-9a-f]{6}$"
                    },
                    "order": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    },
                    "defaultOn": { "type": "boolean" },
                    "hiddenFromField": { "type": "boolean" },
                    "origin": {
                      "type": "string",
                      "enum": ["template", "project"]
                    },
                    "templateKey": {
                      "type": "string",
                      "pattern": "^template:ltp_[0-9a-z]{26}:[a-z0-9][a-z0-9-]{0,39}$"
                    },
                    "locked": { "type": "boolean" },
                    "curated": { "type": "boolean" }
                  },
                  "required": [
                    "id",
                    "kind",
                    "derivationKeys",
                    "elementCount",
                    "displayName",
                    "order",
                    "defaultOn",
                    "hiddenFromField"
                  ],
                  "additionalProperties": false
                }
              },
              "template": {
                "type": "object",
                "properties": {
                  "templateId": {
                    "type": "string",
                    "pattern": "^ltp_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                    "description": "A ltp identifier (TypeID, conventions C5)."
                  },
                  "revision": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["templateId", "revision"],
                "additionalProperties": false
              },
              "schemaVersion": { "type": "number", "const": 1 },
              "createdAt": {
                "type": "string",
                "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))$"
              },
              "updatedAt": {
                "type": "string",
                "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))$"
              },
              "revision": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "createdBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              }
            },
            "required": [
              "id",
              "organizationId",
              "projectId",
              "status",
              "derivationSource",
              "sourceCoveragePct",
              "sources",
              "derivedAtPublishSeq",
              "generatedAt",
              "warnings",
              "entries",
              "schemaVersion",
              "createdAt",
              "updatedAt",
              "revision",
              "createdBy"
            ],
            "additionalProperties": false
          }
        },
        "required": ["done", "resource"],
        "additionalProperties": false
      },
      "waitLinkDiscoveryRunInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "runId": {
            "type": "string",
            "pattern": "^ldr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ldr identifier (TypeID, conventions C5)."
          },
          "timeoutSeconds": { "type": "integer", "minimum": 1, "maximum": 25 }
        },
        "required": ["organizationId", "projectId", "runId"],
        "additionalProperties": false
      },
      "waitLinkDiscoveryRunOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "done": { "type": "boolean" },
          "retryAfterSeconds": {
            "type": "integer",
            "minimum": 1,
            "maximum": 9007199254740991
          },
          "resource": {
            "type": "object",
            "properties": {
              "schemaVersion": { "type": "number", "const": 1 },
              "id": {
                "type": "string",
                "pattern": "^ldr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A ldr identifier (TypeID, conventions C5)."
              },
              "organizationId": {
                "type": "string",
                "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A org identifier (TypeID, conventions C5)."
              },
              "projectId": {
                "type": "string",
                "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A prj identifier (TypeID, conventions C5)."
              },
              "status": {
                "type": "string",
                "enum": ["running", "done", "failed"]
              },
              "trigger": {
                "type": "string",
                "enum": ["manual", "upload_batch"]
              },
              "scope": {
                "type": "object",
                "properties": {
                  "documentIds": {
                    "minItems": 1,
                    "maxItems": 500,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A doc identifier (TypeID, conventions C5)."
                    }
                  },
                  "modelIds": {
                    "minItems": 1,
                    "maxItems": 4,
                    "type": "array",
                    "items": {
                      "type": "string",
                      "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                      "description": "A mdl identifier (TypeID, conventions C5)."
                    }
                  }
                },
                "additionalProperties": false
              },
              "result": {
                "type": "object",
                "properties": {
                  "evaluatedDocuments": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "evaluatedElements": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "truncated": { "type": "boolean" },
                  "strategies": {
                    "maxItems": 20,
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "strategy": {
                          "type": "string",
                          "enum": [
                            "file_name",
                            "layout_name",
                            "title_block_attribute",
                            "sheet_text",
                            "model_property",
                            "sheet_number"
                          ]
                        },
                        "ruleDraft": {
                          "type": "object",
                          "properties": {
                            "matchModel": {
                              "type": "object",
                              "properties": {
                                "field": {
                                  "type": "string",
                                  "enum": [
                                    "tag",
                                    "assemblyMark",
                                    "storeyName",
                                    "name",
                                    "property"
                                  ]
                                },
                                "property": {
                                  "type": "object",
                                  "properties": {
                                    "set": {
                                      "type": "string",
                                      "minLength": 1,
                                      "maxLength": 128,
                                      "description": "Property set, e.g. Pset_Panel."
                                    },
                                    "name": {
                                      "type": "string",
                                      "minLength": 1,
                                      "maxLength": 128,
                                      "description": "Property name, e.g. Drawing."
                                    }
                                  },
                                  "required": ["set", "name"],
                                  "additionalProperties": false
                                }
                              },
                              "required": ["field"],
                              "additionalProperties": false
                            },
                            "matchDocument": {
                              "type": "object",
                              "properties": {
                                "field": {
                                  "type": "string",
                                  "enum": [
                                    "fileName",
                                    "sheetNumber",
                                    "outlineTitle",
                                    "titleBlock",
                                    "layoutName",
                                    "blockAttribute",
                                    "sheetText"
                                  ]
                                },
                                "attributeTag": {
                                  "type": "string",
                                  "minLength": 1,
                                  "maxLength": 128
                                }
                              },
                              "required": ["field"],
                              "additionalProperties": false
                            },
                            "normalization": {
                              "type": "object",
                              "properties": {
                                "caseInsensitive": { "type": "boolean" },
                                "stripWhitespace": { "type": "boolean" },
                                "stripLeadingZeros": { "type": "boolean" },
                                "regex": {
                                  "type": "string",
                                  "description": "Regular expression applied to both sides after the other normalisation steps: a value that does not match is ignored, otherwise the match (or its named group `key`) is the value compared, e.g. W-\\d{3} (max 200 chars; no backreferences or nested repeats)."
                                }
                              },
                              "required": [
                                "caseInsensitive",
                                "stripWhitespace",
                                "stripLeadingZeros"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "required": [
                            "matchModel",
                            "matchDocument",
                            "normalization"
                          ],
                          "additionalProperties": false
                        },
                        "score": {
                          "type": "number",
                          "minimum": 0,
                          "maximum": 1
                        },
                        "coverage": {
                          "type": "number",
                          "minimum": 0,
                          "maximum": 1
                        },
                        "matched": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "ambiguous": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "unmatchedDocuments": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "unmatchedElements": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        },
                        "sampleMatches": {
                          "maxItems": 10,
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "documentId": {
                                "type": "string",
                                "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                "description": "A doc identifier (TypeID, conventions C5)."
                              },
                              "page": {
                                "type": "integer",
                                "exclusiveMinimum": 0,
                                "maximum": 9007199254740991
                              },
                              "key": { "type": "string" },
                              "source": {
                                "oneOf": [
                                  {
                                    "type": "object",
                                    "properties": {
                                      "kind": {
                                        "type": "string",
                                        "const": "element"
                                      },
                                      "modelId": {
                                        "type": "string",
                                        "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                        "description": "A mdl identifier (TypeID, conventions C5)."
                                      },
                                      "globalId": {
                                        "type": "string",
                                        "minLength": 1
                                      }
                                    },
                                    "required": ["kind", "modelId", "globalId"],
                                    "additionalProperties": false
                                  },
                                  {
                                    "type": "object",
                                    "properties": {
                                      "kind": {
                                        "type": "string",
                                        "const": "assembly"
                                      },
                                      "modelId": {
                                        "type": "string",
                                        "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                        "description": "A mdl identifier (TypeID, conventions C5)."
                                      },
                                      "assemblyMark": {
                                        "type": "string",
                                        "minLength": 1
                                      }
                                    },
                                    "required": [
                                      "kind",
                                      "modelId",
                                      "assemblyMark"
                                    ],
                                    "additionalProperties": false
                                  },
                                  {
                                    "type": "object",
                                    "properties": {
                                      "kind": {
                                        "type": "string",
                                        "const": "storey"
                                      },
                                      "modelId": {
                                        "type": "string",
                                        "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                        "description": "A mdl identifier (TypeID, conventions C5)."
                                      },
                                      "storeyId": {
                                        "type": "string",
                                        "minLength": 1
                                      }
                                    },
                                    "required": ["kind", "modelId", "storeyId"],
                                    "additionalProperties": false
                                  }
                                ]
                              }
                            },
                            "required": ["documentId", "page", "key", "source"],
                            "additionalProperties": false
                          }
                        },
                        "ambiguousSamples": {
                          "maxItems": 10,
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "key": { "type": "string" },
                              "documentIds": {
                                "minItems": 2,
                                "type": "array",
                                "items": {
                                  "type": "string",
                                  "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                  "description": "A doc identifier (TypeID, conventions C5)."
                                }
                              }
                            },
                            "required": ["key", "documentIds"],
                            "additionalProperties": false
                          }
                        }
                      },
                      "required": [
                        "strategy",
                        "ruleDraft",
                        "score",
                        "coverage",
                        "matched",
                        "ambiguous",
                        "unmatchedDocuments",
                        "unmatchedElements",
                        "sampleMatches",
                        "ambiguousSamples"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "recommended": {
                    "type": "array",
                    "items": {
                      "type": "integer",
                      "minimum": 0,
                      "maximum": 9007199254740991
                    }
                  },
                  "panels": {
                    "type": "object",
                    "properties": {
                      "total": {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 9007199254740991
                      },
                      "linkable": {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 9007199254740991
                      }
                    },
                    "required": ["total", "linkable"],
                    "additionalProperties": false
                  },
                  "skipped": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "strategy": {
                          "type": "string",
                          "enum": [
                            "file_name",
                            "layout_name",
                            "title_block_attribute",
                            "sheet_text",
                            "model_property",
                            "sheet_number"
                          ]
                        },
                        "reason": {
                          "type": "string",
                          "enum": ["model_index_missing", "no_keys"]
                        }
                      },
                      "required": ["strategy", "reason"],
                      "additionalProperties": false
                    }
                  }
                },
                "required": [
                  "evaluatedDocuments",
                  "evaluatedElements",
                  "strategies",
                  "recommended"
                ],
                "additionalProperties": false
              },
              "acceptedAt": {
                "type": "string",
                "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))$"
              },
              "acceptedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              },
              "acceptedRuleIds": {
                "type": "array",
                "items": {
                  "type": "string",
                  "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A lkr identifier (TypeID, conventions C5)."
                }
              },
              "acceptRunIds": {
                "type": "array",
                "items": {
                  "type": "string",
                  "pattern": "^lrr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                  "description": "A lrr identifier (TypeID, conventions C5)."
                }
              },
              "error": {
                "type": "object",
                "properties": {
                  "code": {
                    "type": "string",
                    "enum": ["discovery_timeout", "discovery_failed"]
                  },
                  "message": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "message"],
                "additionalProperties": false
              },
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              },
              "completedAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": [
              "schemaVersion",
              "id",
              "organizationId",
              "projectId",
              "status",
              "trigger",
              "scope",
              "requestedAt",
              "requestedBy"
            ],
            "additionalProperties": false
          }
        },
        "required": ["done", "resource"],
        "additionalProperties": false
      },
      "waitLinkImportInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "importId": {
            "type": "string",
            "pattern": "^lim_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lim identifier (TypeID, conventions C5)."
          },
          "timeoutSeconds": { "type": "integer", "minimum": 1, "maximum": 25 }
        },
        "required": ["organizationId", "projectId", "importId"],
        "additionalProperties": false
      },
      "waitLinkImportOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "done": { "type": "boolean" },
          "retryAfterSeconds": {
            "type": "integer",
            "minimum": 1,
            "maximum": 9007199254740991
          },
          "resource": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "pattern": "^lim_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A lim identifier (TypeID, conventions C5)."
              },
              "organizationId": {
                "type": "string",
                "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A org identifier (TypeID, conventions C5)."
              },
              "projectId": {
                "type": "string",
                "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A prj identifier (TypeID, conventions C5)."
              },
              "fileName": {
                "type": "string",
                "minLength": 5,
                "maxLength": 255,
                "description": "The CSV's file name, ending .csv (max 255 chars)."
              },
              "sizeBytes": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 2097152
              },
              "status": {
                "type": "string",
                "enum": ["uploading", "processing", "done", "failed"]
              },
              "progress": {
                "type": "object",
                "properties": {
                  "rowsProcessed": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "rowsTotal": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": ["rowsProcessed", "rowsTotal"],
                "additionalProperties": false
              },
              "result": {
                "type": "object",
                "properties": {
                  "rows": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "created": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "skipped": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "errors": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "row": {
                          "type": "integer",
                          "minimum": 2,
                          "maximum": 9007199254740991
                        },
                        "code": {
                          "type": "string",
                          "enum": [
                            "element_not_found",
                            "ambiguous_element",
                            "sheet_not_found",
                            "sheet_not_ready",
                            "ambiguous_sheet",
                            "page_out_of_range",
                            "invalid_page",
                            "invalid_region",
                            "missing_value"
                          ]
                        }
                      },
                      "required": ["row", "code"],
                      "additionalProperties": false
                    }
                  }
                },
                "required": ["rows", "created", "skipped", "errors"],
                "additionalProperties": false
              },
              "error": {
                "type": "object",
                "properties": {
                  "code": {
                    "type": "string",
                    "enum": [
                      "csv_too_large",
                      "csv_empty",
                      "csv_encoding",
                      "csv_malformed",
                      "csv_missing_column",
                      "csv_unknown_column",
                      "upload_missing",
                      "project_not_active"
                    ]
                  },
                  "detail": { "type": "string", "maxLength": 500 }
                },
                "required": ["code", "detail"],
                "additionalProperties": false
              },
              "completedAt": {
                "type": "string",
                "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))$"
              },
              "schemaVersion": { "type": "number", "const": 1 },
              "createdAt": {
                "type": "string",
                "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))$"
              },
              "updatedAt": {
                "type": "string",
                "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))$"
              },
              "revision": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "createdBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              }
            },
            "required": [
              "id",
              "organizationId",
              "projectId",
              "fileName",
              "sizeBytes",
              "status",
              "schemaVersion",
              "createdAt",
              "updatedAt",
              "revision",
              "createdBy"
            ],
            "additionalProperties": false
          }
        },
        "required": ["done", "resource"],
        "additionalProperties": false
      },
      "waitLinkRuleRunInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "runId": {
            "type": "string",
            "pattern": "^lrr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A lrr identifier (TypeID, conventions C5)."
          },
          "timeoutSeconds": { "type": "integer", "minimum": 1, "maximum": 25 }
        },
        "required": ["organizationId", "projectId", "runId"],
        "additionalProperties": false
      },
      "waitLinkRuleRunOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "done": { "type": "boolean" },
          "retryAfterSeconds": {
            "type": "integer",
            "minimum": 1,
            "maximum": 9007199254740991
          },
          "resource": {
            "type": "object",
            "properties": {
              "schemaVersion": { "type": "number", "const": 1 },
              "id": {
                "type": "string",
                "pattern": "^lrr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A lrr identifier (TypeID, conventions C5)."
              },
              "organizationId": {
                "type": "string",
                "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A org identifier (TypeID, conventions C5)."
              },
              "projectId": {
                "type": "string",
                "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A prj identifier (TypeID, conventions C5)."
              },
              "ruleId": {
                "type": "string",
                "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A lkr identifier (TypeID, conventions C5)."
              },
              "dryRun": { "type": "boolean" },
              "status": {
                "type": "string",
                "enum": ["running", "done", "failed"]
              },
              "result": {
                "type": "object",
                "properties": {
                  "candidates": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "source": {
                          "oneOf": [
                            {
                              "type": "object",
                              "properties": {
                                "kind": {
                                  "type": "string",
                                  "const": "element"
                                },
                                "modelId": {
                                  "type": "string",
                                  "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                  "description": "A mdl identifier (TypeID, conventions C5)."
                                },
                                "globalId": { "type": "string", "minLength": 1 }
                              },
                              "required": ["kind", "modelId", "globalId"],
                              "additionalProperties": false
                            },
                            {
                              "type": "object",
                              "properties": {
                                "kind": {
                                  "type": "string",
                                  "const": "assembly"
                                },
                                "modelId": {
                                  "type": "string",
                                  "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                  "description": "A mdl identifier (TypeID, conventions C5)."
                                },
                                "assemblyMark": {
                                  "type": "string",
                                  "minLength": 1
                                }
                              },
                              "required": ["kind", "modelId", "assemblyMark"],
                              "additionalProperties": false
                            },
                            {
                              "type": "object",
                              "properties": {
                                "kind": { "type": "string", "const": "storey" },
                                "modelId": {
                                  "type": "string",
                                  "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                                  "description": "A mdl identifier (TypeID, conventions C5)."
                                },
                                "storeyId": { "type": "string", "minLength": 1 }
                              },
                              "required": ["kind", "modelId", "storeyId"],
                              "additionalProperties": false
                            }
                          ]
                        },
                        "target": {
                          "type": "object",
                          "properties": {
                            "documentId": {
                              "type": "string",
                              "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                              "description": "A doc identifier (TypeID, conventions C5)."
                            },
                            "page": {
                              "type": "integer",
                              "exclusiveMinimum": 0,
                              "maximum": 9007199254740991
                            },
                            "layoutName": {
                              "type": "string",
                              "minLength": 1,
                              "maxLength": 255
                            }
                          },
                          "required": ["documentId", "page"],
                          "additionalProperties": false
                        },
                        "key": { "type": "string" },
                        "confidence": {
                          "type": "number",
                          "minimum": 0,
                          "maximum": 1
                        },
                        "ruleId": {
                          "type": "string",
                          "pattern": "^lkr_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A lkr identifier (TypeID, conventions C5)."
                        },
                        "ambiguous": { "type": "boolean" }
                      },
                      "required": [
                        "source",
                        "target",
                        "key",
                        "confidence",
                        "ruleId",
                        "ambiguous"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "wouldCreate": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "ambiguous": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "unmatched": {
                    "type": "object",
                    "properties": {
                      "model": {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 9007199254740991
                      },
                      "document": {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 9007199254740991
                      }
                    },
                    "required": ["model", "document"],
                    "additionalProperties": false
                  },
                  "truncated": { "type": "boolean" },
                  "warnings": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "code": {
                          "type": "string",
                          "enum": [
                            "links_index_unavailable",
                            "spatial_tree_unavailable",
                            "text_layer_unavailable",
                            "link_keys_unavailable"
                          ]
                        },
                        "modelId": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        },
                        "documentId": {
                          "type": "string",
                          "pattern": "^doc_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A doc identifier (TypeID, conventions C5)."
                        },
                        "page": {
                          "type": "integer",
                          "exclusiveMinimum": 0,
                          "maximum": 9007199254740991
                        }
                      },
                      "required": ["code"],
                      "additionalProperties": false
                    }
                  },
                  "skipped": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "reason": {
                          "type": "string",
                          "enum": ["model_index_missing"]
                        },
                        "modelId": {
                          "type": "string",
                          "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                          "description": "A mdl identifier (TypeID, conventions C5)."
                        }
                      },
                      "required": ["reason", "modelId"],
                      "additionalProperties": false
                    }
                  },
                  "applied": {
                    "type": "object",
                    "properties": {
                      "created": {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 9007199254740991
                      },
                      "updated": {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 9007199254740991
                      },
                      "unchanged": {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 9007199254740991
                      },
                      "manual": {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 9007199254740991
                      },
                      "remaining": {
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 9007199254740991
                      }
                    },
                    "required": [
                      "created",
                      "updated",
                      "unchanged",
                      "manual",
                      "remaining"
                    ],
                    "additionalProperties": false
                  }
                },
                "required": [
                  "candidates",
                  "wouldCreate",
                  "ambiguous",
                  "unmatched",
                  "truncated",
                  "warnings"
                ],
                "additionalProperties": false
              },
              "requestedAt": {
                "type": "string",
                "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))$"
              },
              "requestedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              },
              "completedAt": {
                "type": "string",
                "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))$"
              }
            },
            "required": [
              "schemaVersion",
              "id",
              "organizationId",
              "projectId",
              "ruleId",
              "dryRun",
              "status",
              "requestedAt",
              "requestedBy"
            ],
            "additionalProperties": false
          }
        },
        "required": ["done", "resource"],
        "additionalProperties": false
      },
      "waitModelVersionInput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "organizationId": {
            "type": "string",
            "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A org identifier (TypeID, conventions C5)."
          },
          "projectId": {
            "type": "string",
            "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A prj identifier (TypeID, conventions C5)."
          },
          "modelId": {
            "type": "string",
            "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A mdl identifier (TypeID, conventions C5)."
          },
          "versionId": {
            "type": "string",
            "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
            "description": "A ver identifier (TypeID, conventions C5)."
          },
          "timeoutSeconds": { "type": "integer", "minimum": 1, "maximum": 25 }
        },
        "required": ["organizationId", "projectId", "modelId", "versionId"],
        "additionalProperties": false
      },
      "waitModelVersionOutput": {
        "$schema": "https://json-schema.org/draft/2020-12/schema",
        "type": "object",
        "properties": {
          "done": { "type": "boolean" },
          "retryAfterSeconds": {
            "type": "integer",
            "minimum": 1,
            "maximum": 9007199254740991
          },
          "resource": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A ver identifier (TypeID, conventions C5)."
              },
              "organizationId": {
                "type": "string",
                "pattern": "^org_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A org identifier (TypeID, conventions C5)."
              },
              "projectId": {
                "type": "string",
                "pattern": "^prj_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A prj identifier (TypeID, conventions C5)."
              },
              "modelId": {
                "type": "string",
                "pattern": "^mdl_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                "description": "A mdl identifier (TypeID, conventions C5)."
              },
              "versionNumber": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "status": {
                "type": "string",
                "enum": [
                  "uploading",
                  "uploaded",
                  "processing",
                  "ready",
                  "failed",
                  "archived",
                  "cancelled"
                ]
              },
              "publication": {
                "type": "string",
                "enum": ["draft", "published", "superseded"]
              },
              "fieldVisible": { "type": "boolean" },
              "source": {
                "oneOf": [
                  {
                    "type": "object",
                    "properties": {
                      "kind": { "type": "string", "const": "upload" },
                      "fileName": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 255,
                        "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                      },
                      "sizeBytes": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 1073741824,
                        "description": "Declared file size in bytes (BR-24)."
                      },
                      "contentType": { "type": "string", "minLength": 1 },
                      "sha256": {
                        "type": "string",
                        "pattern": "^[0-9a-f]{64}$",
                        "description": "Optional SHA-256 of the source file, 64 hex chars."
                      }
                    },
                    "required": [
                      "kind",
                      "fileName",
                      "sizeBytes",
                      "contentType"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "kind": { "type": "string", "const": "copy" },
                      "sourceVersionId": {
                        "type": "string",
                        "pattern": "^ver_[01234567][0123456789abcdefghjkmnpqrstvwxyz]{25}$",
                        "description": "A ver identifier (TypeID, conventions C5)."
                      },
                      "fileName": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 255,
                        "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                      },
                      "sizeBytes": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 1073741824,
                        "description": "Declared file size in bytes (BR-24)."
                      },
                      "contentType": { "type": "string", "minLength": 1 },
                      "sha256": {
                        "type": "string",
                        "pattern": "^[0-9a-f]{64}$",
                        "description": "Optional SHA-256 of the source file, 64 hex chars."
                      }
                    },
                    "required": [
                      "kind",
                      "sourceVersionId",
                      "fileName",
                      "sizeBytes",
                      "contentType"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "kind": { "type": "string", "const": "url" },
                      "url": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 2048,
                        "description": "Where the file was imported from: scheme, host and path only (the query string is never stored)."
                      },
                      "fileName": {
                        "type": "string",
                        "minLength": 1,
                        "maxLength": 255,
                        "description": "Original file name, <= 255 chars, ending .ifc or .ifczip (BR-23)."
                      },
                      "sizeBytes": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 1073741824,
                        "description": "Declared file size in bytes (BR-24)."
                      },
                      "contentType": { "type": "string", "minLength": 1 },
                      "sha256": {
                        "type": "string",
                        "pattern": "^[0-9a-f]{64}$",
                        "description": "Optional SHA-256 of the source file, 64 hex chars."
                      }
                    },
                    "required": ["kind", "url", "fileName", "contentType"],
                    "additionalProperties": false
                  }
                ]
              },
              "upload": {
                "type": "object",
                "properties": {
                  "method": { "type": "string", "const": "PUT" },
                  "url": { "type": "string" },
                  "headers": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": { "type": "string" }
                  },
                  "expiresAt": {
                    "type": "string",
                    "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))$"
                  },
                  "maxBytes": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  },
                  "resumable": { "type": "boolean", "const": true },
                  "chunkSizeBytes": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  }
                },
                "required": [
                  "method",
                  "url",
                  "headers",
                  "expiresAt",
                  "maxBytes",
                  "resumable",
                  "chunkSizeBytes"
                ],
                "additionalProperties": false
              },
              "expiresAt": {
                "type": "string",
                "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))$"
              },
              "cancelReason": { "type": "string", "enum": ["user", "expired"] },
              "pipelineVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "warnings": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "code": { "type": "string" },
                    "blocking": { "type": "boolean" },
                    "params": {
                      "type": "object",
                      "propertyNames": { "type": "string" },
                      "additionalProperties": {}
                    }
                  },
                  "required": ["code"],
                  "additionalProperties": false
                }
              },
              "failure": {
                "type": "object",
                "properties": {
                  "code": { "type": "string", "minLength": 1 },
                  "retryable": { "type": "boolean" },
                  "params": {
                    "type": "object",
                    "propertyNames": { "type": "string" },
                    "additionalProperties": {}
                  },
                  "messageKey": { "type": "string", "minLength": 1 },
                  "supportRef": { "type": "string", "minLength": 1 }
                },
                "required": ["code", "retryable"],
                "additionalProperties": false
              },
              "processing": {
                "type": "object",
                "properties": {
                  "sizeClass": {
                    "type": "string",
                    "enum": ["s", "m", "l", "xl"]
                  },
                  "executionName": { "type": "string", "minLength": 1 },
                  "startedAt": {
                    "type": "string",
                    "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))$"
                  },
                  "heartbeatAt": {
                    "type": "string",
                    "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))$"
                  },
                  "queuedAt": {
                    "type": "string",
                    "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))$"
                  },
                  "queuedTraceparent": {
                    "type": "string",
                    "pattern": "^(?!ff)[0-9a-f]{2}-(?!0{32})[0-9a-f]{32}-(?!0{16})[0-9a-f]{16}-[0-9a-f]{2}$"
                  },
                  "queuedEscalation": {
                    "type": "object",
                    "properties": {
                      "sizeClass": {
                        "type": "string",
                        "enum": ["s", "m", "l", "xl"]
                      },
                      "attempt": {
                        "type": "integer",
                        "exclusiveMinimum": 0,
                        "maximum": 9007199254740991
                      }
                    },
                    "required": ["sizeClass", "attempt"],
                    "additionalProperties": false
                  },
                  "attempt": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  },
                  "progressReportedAt": {
                    "type": "string",
                    "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))$"
                  },
                  "requestId": { "type": "string", "minLength": 1 }
                },
                "additionalProperties": false
              },
              "progress": {
                "type": "object",
                "properties": {
                  "stage": { "type": "string", "minLength": 1 },
                  "percent": { "type": "number", "minimum": 0, "maximum": 100 }
                },
                "required": ["stage", "percent"],
                "additionalProperties": false
              },
              "reprocessing": {
                "type": "object",
                "properties": {
                  "requestedAt": {
                    "type": "string",
                    "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))$"
                  },
                  "requestedBy": { "type": "string", "minLength": 1 },
                  "attempt": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  },
                  "reason": {
                    "type": "string",
                    "enum": ["retry", "pipeline_upgrade"]
                  },
                  "targetPipelineVersion": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  },
                  "state": {
                    "type": "string",
                    "enum": [
                      "requested",
                      "deferred",
                      "awaiting_rollout",
                      "done",
                      "failed"
                    ]
                  },
                  "completedAt": {
                    "type": "string",
                    "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))$"
                  },
                  "failure": {
                    "type": "object",
                    "properties": {
                      "code": { "type": "string", "minLength": 1 },
                      "retryable": { "type": "boolean" },
                      "params": {
                        "type": "object",
                        "propertyNames": { "type": "string" },
                        "additionalProperties": {}
                      },
                      "messageKey": { "type": "string", "minLength": 1 },
                      "supportRef": { "type": "string", "minLength": 1 }
                    },
                    "required": ["code", "retryable"],
                    "additionalProperties": false
                  }
                },
                "required": ["requestedAt", "requestedBy", "attempt"],
                "additionalProperties": false
              },
              "releasedAt": {
                "type": "string",
                "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))$"
              },
              "releasedBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              },
              "supersededAt": {
                "type": "string",
                "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))$"
              },
              "activeArtifactSet": {
                "type": "object",
                "properties": {
                  "path": { "type": "string", "minLength": 1 },
                  "pipelineVersion": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  },
                  "startedAt": {
                    "type": "string",
                    "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))$"
                  },
                  "files": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "name": { "type": "string", "minLength": 1 },
                        "sizeBytes": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        }
                      },
                      "required": ["name", "sizeBytes"],
                      "additionalProperties": false
                    }
                  },
                  "totalBytes": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "contractVersion": {
                    "type": "string",
                    "pattern": "^\\d+\\.\\d+$"
                  }
                },
                "required": ["path", "pipelineVersion", "startedAt", "files"],
                "additionalProperties": false
              },
              "nextArtifactSet": {
                "type": "object",
                "properties": {
                  "path": { "type": "string", "minLength": 1 },
                  "pipelineVersion": {
                    "type": "integer",
                    "exclusiveMinimum": 0,
                    "maximum": 9007199254740991
                  },
                  "startedAt": {
                    "type": "string",
                    "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))$"
                  },
                  "files": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "name": { "type": "string", "minLength": 1 },
                        "sizeBytes": {
                          "type": "integer",
                          "minimum": 0,
                          "maximum": 9007199254740991
                        }
                      },
                      "required": ["name", "sizeBytes"],
                      "additionalProperties": false
                    }
                  },
                  "totalBytes": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "contractVersion": {
                    "type": "string",
                    "pattern": "^\\d+\\.\\d+$"
                  }
                },
                "required": ["path", "pipelineVersion", "startedAt", "files"],
                "additionalProperties": false
              },
              "stats": {
                "type": "object",
                "properties": {
                  "elementCount": {
                    "type": "integer",
                    "minimum": 0,
                    "maximum": 9007199254740991
                  },
                  "boundsMm": {
                    "type": "object",
                    "properties": {
                      "min": {
                        "type": "array",
                        "prefixItems": [
                          { "type": "number" },
                          { "type": "number" },
                          { "type": "number" }
                        ],
                        "items": false,
                        "minItems": 3,
                        "maxItems": 3
                      },
                      "max": {
                        "type": "array",
                        "prefixItems": [
                          { "type": "number" },
                          { "type": "number" },
                          { "type": "number" }
                        ],
                        "items": false,
                        "minItems": 3,
                        "maxItems": 3
                      }
                    },
                    "required": ["min", "max"],
                    "additionalProperties": false
                  },
                  "coveragePct": {
                    "type": "number",
                    "minimum": 0,
                    "maximum": 100
                  }
                },
                "required": ["elementCount", "boundsMm"],
                "additionalProperties": false
              },
              "churn": {
                "type": "object",
                "properties": {
                  "ratio": { "type": "number", "minimum": 0, "maximum": 1 },
                  "added": { "type": "array", "items": { "type": "string" } },
                  "removed": { "type": "array", "items": { "type": "string" } },
                  "moved": { "type": "array", "items": { "type": "string" } },
                  "recreated": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "from": { "type": "string" },
                        "to": { "type": "string" }
                      },
                      "required": ["from", "to"],
                      "additionalProperties": false
                    }
                  }
                },
                "required": ["ratio", "added", "removed", "moved", "recreated"],
                "additionalProperties": false
              },
              "label": {
                "type": "string",
                "minLength": 1,
                "maxLength": 40,
                "description": "Short version name, e.g. \"Roof fix\" (1-40 chars after trimming, BR-10)."
              },
              "notes": {
                "type": "string",
                "maxLength": 2000,
                "description": "Free-form notes for the crew (max 2000 chars, BR-10)."
              },
              "detailsEditedAt": {
                "type": "string",
                "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))$"
              },
              "archivedAt": {
                "type": "string",
                "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))$"
              },
              "publishOnReady": {
                "description": "Publish this version automatically, in the same write that marks it ready (FV-383).",
                "type": "boolean"
              },
              "schemaVersion": { "type": "number", "const": 1 },
              "createdAt": {
                "type": "string",
                "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))$"
              },
              "updatedAt": {
                "type": "string",
                "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))$"
              },
              "revision": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "createdBy": {
                "type": "object",
                "properties": {
                  "type": {
                    "type": "string",
                    "enum": [
                      "user",
                      "apiToken",
                      "oauth",
                      "workstation",
                      "platformAdmin"
                    ]
                  },
                  "id": { "type": "string" }
                },
                "required": ["type", "id"],
                "additionalProperties": false
              }
            },
            "required": [
              "id",
              "organizationId",
              "projectId",
              "modelId",
              "versionNumber",
              "status",
              "publication",
              "fieldVisible",
              "source",
              "pipelineVersion",
              "warnings",
              "schemaVersion",
              "createdAt",
              "updatedAt",
              "revision",
              "createdBy"
            ],
            "additionalProperties": false
          }
        },
        "required": ["done", "resource"],
        "additionalProperties": false
      }
    },
    "headers": {
      "ETag": {
        "description": "The resource's current `revision` as a strong entity tag, e.g. `\"4\"` (FV-68). Send it back as `If-Match` on an update (412 `precondition.failed` when stale) or as `If-None-Match` on a GET (304 when unchanged).",
        "schema": { "type": "string" }
      },
      "XBuildId": {
        "description": "The identifier of the `api` build that served this response.",
        "schema": { "type": "string" }
      },
      "XRequestId": {
        "description": "The `req_` id assigned to this request (conventions §5.3), echoed for tracing.",
        "schema": { "type": "string" }
      }
    },
    "securitySchemes": {
      "bearerAuth": {
        "type": "http",
        "scheme": "bearer",
        "description": "Send `Authorization: Bearer <token>`: an API token (`fvt_...`) or the access token of a connected OAuth app. Operations marked public need no credential."
      }
    }
  }
}
