{
  "format": "takoform.host-api@v1alpha3",
  "apiGroup": "forms.takoform.com/v1alpha3",
  "discoveryPath": "/.well-known/takoform/v1alpha3",
  "wireSchema": "https://forms.takoform.com/schemas/v1alpha3/host-api-wire.schema.json",
  "requiredFeatures": [
    "service_forms",
    "exact_form_ref",
    "optimistic_concurrency",
    "idempotent_lifecycle",
    "operations",
    "artifact_upload",
    "support_profiles"
  ],
  "optionalFeatures": [],
  "requiredEndpoints": ["api"],
  "optionalEndpoints": ["artifacts", "operations", "support", "oidc_issuer"],
  "identity": {
    "uid": "host-issued-immutable; delete-and-recreate-changes-uid",
    "generation": {
      "encoding": "canonical-decimal-string",
      "minimum": "1",
      "maximum": "9223372036854775807",
      "increments": "only-on-portable-desired-spec-change",
      "fence": "expectedGeneration-or-Takoform-Expected-Generation",
      "staleFailure": "generation_conflict"
    },
    "revision": {
      "encoding": "canonical-decimal-string",
      "minimum": "1",
      "maximum": "9223372036854775807",
      "increments": "on-any-representation-change",
      "etag": "exactly-one-strong-quoted-revision",
      "fence": "If-Match",
      "staleFailure": "revision_conflict"
    },
    "packageDigest": "audit-evidence-only; never-identity-query-or-fence"
  },
  "prepareBinding": {
    "specDigest": "rfc8785-canonical-spec-digest",
    "prepareDigest": "binds-specDigest-identity-uid-generation-and-host-plan",
    "substitution": "invalid_argument-before-mutation"
  },
  "idempotency": {
    "header": "Idempotency-Key",
    "namespace": ["authenticated-tenant", "authenticated-principal", "space", "key"],
    "fingerprint": ["method", "request-target", "preconditions", "body-bytes"],
    "conflict": "invalid_argument",
    "replay": "recorded-status-etag-body"
  },
  "wireJSON": {
    "encoding": "utf-8-i-json",
    "rawDocumentValidation": "before-typed-decoding",
    "duplicateMember": "invalid_argument-before-mutation",
    "unknownEnvelopeField": "invalid_argument-before-mutation"
  },
  "bindingResolution": {
    "sourceSpace": "resource.metadata.space",
    "reference": "typed-binding-target-kind-and-name",
    "crossSpace": "unrepresentable",
    "missing": "resource_not_found/404-before-mutation",
    "boundTargetDeletion": "dependency_in_use/409"
  },
  "roleRules": {
    "revisionUpdate": "invalid_argument",
    "attachmentDeleteCascade": "never-deletes-parent",
    "deploymentTrafficAuthority": "deployment-role-only"
  },
  "operations": [
    {
      "name": "forms",
      "method": "GET",
      "path": "/apis/forms.takoform.com/v1alpha3/forms",
      "exactFormQuery": true,
      "precondition": "none",
      "idempotencyKey": false,
      "mutates": false,
      "successStatus": [200],
      "responseSchema": "https://forms.takoform.com/schemas/v1alpha3/host-api-wire.schema.json#/$defs/formsResponse"
    },
    {
      "name": "form-definition",
      "method": "GET",
      "path": "/apis/forms.takoform.com/v1alpha3/form-definitions/{group}/{kind}",
      "exactFormQuery": true,
      "precondition": "none",
      "idempotencyKey": false,
      "mutates": false,
      "successStatus": [200],
      "responseSchema": "https://forms.takoform.com/schemas/v1alpha3/host-api-wire.schema.json#/$defs/formDefinitionResponse"
    },
    {
      "name": "validate",
      "method": "POST",
      "path": "/apis/forms.takoform.com/v1alpha3/resources/validate",
      "exactFormQuery": false,
      "precondition": "none",
      "idempotencyKey": false,
      "mutates": false,
      "successStatus": [200],
      "requestSchema": "https://forms.takoform.com/schemas/v1alpha3/host-api-wire.schema.json#/$defs/resourceRequest",
      "responseSchema": "https://forms.takoform.com/schemas/v1alpha3/host-api-wire.schema.json#/$defs/validateResponse"
    },
    {
      "name": "prepare",
      "method": "POST",
      "path": "/apis/forms.takoform.com/v1alpha3/resources/prepare",
      "exactFormQuery": false,
      "precondition": "generation-fence-when-updating",
      "idempotencyKey": false,
      "mutates": false,
      "successStatus": [200],
      "requestSchema": "https://forms.takoform.com/schemas/v1alpha3/host-api-wire.schema.json#/$defs/resourceRequest",
      "responseSchema": "https://forms.takoform.com/schemas/v1alpha3/host-api-wire.schema.json#/$defs/prepareResponse"
    },
    {
      "name": "apply",
      "method": "PUT",
      "path": "/apis/forms.takoform.com/v1alpha3/resources/{group}/{kind}/{name}",
      "exactFormQuery": false,
      "precondition": "create:if-none-match-star update:generation-fence",
      "idempotencyKey": true,
      "mutates": true,
      "successStatus": [200, 201, 202],
      "requestSchema": "https://forms.takoform.com/schemas/v1alpha3/host-api-wire.schema.json#/$defs/applyRequest",
      "responseSchema": "https://forms.takoform.com/schemas/v1alpha3/host-api-wire.schema.json#/$defs/mutationAccepted"
    },
    {
      "name": "read",
      "method": "GET",
      "path": "/apis/forms.takoform.com/v1alpha3/resources/{group}/{kind}/{name}",
      "exactFormQuery": true,
      "precondition": "none",
      "idempotencyKey": false,
      "mutates": false,
      "successStatus": [200],
      "responseSchema": "https://forms.takoform.com/schemas/v1alpha3/host-api-wire.schema.json#/$defs/resourceResponse"
    },
    {
      "name": "import",
      "method": "POST",
      "path": "/apis/forms.takoform.com/v1alpha3/resources/{group}/{kind}/{name}/import",
      "exactFormQuery": false,
      "precondition": "new:if-none-match-star existing:generation-fence",
      "idempotencyKey": true,
      "mutates": true,
      "successStatus": [200, 201, 202],
      "requestSchema": "https://forms.takoform.com/schemas/v1alpha3/host-api-wire.schema.json#/$defs/importRequest",
      "responseSchema": "https://forms.takoform.com/schemas/v1alpha3/host-api-wire.schema.json#/$defs/mutationAccepted"
    },
    {
      "name": "observe",
      "method": "POST",
      "path": "/apis/forms.takoform.com/v1alpha3/resources/{group}/{kind}/{name}/observe",
      "exactFormQuery": true,
      "precondition": "generation-fence",
      "idempotencyKey": true,
      "mutates": false,
      "successStatus": [200],
      "successGeneration": "equals-fence",
      "responseSchema": "https://forms.takoform.com/schemas/v1alpha3/host-api-wire.schema.json#/$defs/resourceEnvelope"
    },
    {
      "name": "refresh",
      "method": "POST",
      "path": "/apis/forms.takoform.com/v1alpha3/resources/{group}/{kind}/{name}/refresh",
      "exactFormQuery": true,
      "precondition": "generation-fence",
      "idempotencyKey": true,
      "mutates": false,
      "successStatus": [200],
      "successGeneration": "equals-fence",
      "responseSchema": "https://forms.takoform.com/schemas/v1alpha3/host-api-wire.schema.json#/$defs/resourceEnvelope"
    },
    {
      "name": "delete",
      "method": "DELETE",
      "path": "/apis/forms.takoform.com/v1alpha3/resources/{group}/{kind}/{name}",
      "exactFormQuery": true,
      "precondition": "revision-fence",
      "idempotencyKey": true,
      "mutates": true,
      "successStatus": [202, 204]
    },
    {
      "name": "operation",
      "method": "GET",
      "path": "/apis/forms.takoform.com/v1alpha3/operations/{id}",
      "exactFormQuery": false,
      "precondition": "none",
      "idempotencyKey": false,
      "mutates": false,
      "successStatus": [200],
      "responseSchema": "https://forms.takoform.com/schemas/operations/v1alpha1/operation.schema.json"
    },
    {
      "name": "operation-cancel",
      "method": "POST",
      "path": "/apis/forms.takoform.com/v1alpha3/operations/{id}/cancel",
      "exactFormQuery": false,
      "precondition": "none",
      "idempotencyKey": true,
      "mutates": true,
      "successStatus": [200],
      "responseSchema": "https://forms.takoform.com/schemas/operations/v1alpha1/operation.schema.json"
    },
    {
      "name": "artifact-upload-start",
      "method": "POST",
      "path": "/apis/forms.takoform.com/v1alpha3/artifacts/uploads",
      "exactFormQuery": false,
      "precondition": "none",
      "idempotencyKey": true,
      "mutates": true,
      "successStatus": [200, 201],
      "requestSchema": "https://forms.takoform.com/schemas/v1alpha3/host-api-wire.schema.json#/$defs/artifactUploadRequest",
      "responseSchema": "https://forms.takoform.com/schemas/v1alpha3/host-api-wire.schema.json#/$defs/artifactUploadStatus"
    },
    {
      "name": "artifact-blob-upload",
      "method": "PUT",
      "path": "/apis/forms.takoform.com/v1alpha3/artifacts/uploads/{uploadId}/blobs/{sha256}",
      "exactFormQuery": false,
      "precondition": "none",
      "idempotencyKey": false,
      "mutates": true,
      "successStatus": [201, 204]
    },
    {
      "name": "artifact-commit",
      "method": "POST",
      "path": "/apis/forms.takoform.com/v1alpha3/artifacts/uploads/{uploadId}/commit",
      "exactFormQuery": false,
      "precondition": "none",
      "idempotencyKey": true,
      "mutates": true,
      "successStatus": [200, 201, 202],
      "responseSchema": "https://forms.takoform.com/schemas/v1alpha3/host-api-wire.schema.json#/$defs/artifactCommitResponse"
    },
    {
      "name": "artifact-manifest-read",
      "method": "GET",
      "path": "/apis/forms.takoform.com/v1alpha3/artifacts/{manifestDigest}",
      "exactFormQuery": false,
      "precondition": "none",
      "idempotencyKey": false,
      "mutates": false,
      "successStatus": [200],
      "responseSchema": "https://forms.takoform.com/schemas/artifacts/v1alpha1/artifact-manifest.schema.json"
    },
    {
      "name": "artifact-blob-head",
      "method": "HEAD",
      "path": "/apis/forms.takoform.com/v1alpha3/artifacts/blobs/{sha256}",
      "exactFormQuery": false,
      "precondition": "none",
      "idempotencyKey": false,
      "mutates": false,
      "successStatus": [200, 404]
    },
    {
      "name": "artifact-upload-abandon",
      "method": "DELETE",
      "path": "/apis/forms.takoform.com/v1alpha3/artifacts/uploads/{uploadId}",
      "exactFormQuery": false,
      "precondition": "none",
      "idempotencyKey": true,
      "mutates": true,
      "successStatus": [204]
    },
    {
      "name": "support-forms",
      "method": "GET",
      "path": "/apis/forms.takoform.com/v1alpha3/support/forms",
      "exactFormQuery": false,
      "precondition": "none",
      "idempotencyKey": false,
      "mutates": false,
      "successStatus": [200],
      "responseSchema": "https://forms.takoform.com/schemas/v1alpha3/host-api-wire.schema.json#/$defs/supportProfilesResponse"
    },
    {
      "name": "support-form",
      "method": "GET",
      "path": "/apis/forms.takoform.com/v1alpha3/support/forms/{group}/{kind}/{definitionVersion}",
      "exactFormQuery": false,
      "precondition": "none",
      "idempotencyKey": false,
      "mutates": false,
      "successStatus": [200],
      "responseSchema": "https://forms.takoform.com/schemas/support/v1alpha1/host-support-profile.schema.json"
    },
    {
      "name": "support-interface",
      "method": "GET",
      "path": "/apis/forms.takoform.com/v1alpha3/support/interfaces/{name}/{version}",
      "exactFormQuery": false,
      "precondition": "none",
      "idempotencyKey": false,
      "mutates": false,
      "successStatus": [200],
      "responseSchema": "https://forms.takoform.com/schemas/support/v1alpha1/host-support-profile.schema.json"
    },
    {
      "name": "support-binding",
      "method": "GET",
      "path": "/apis/forms.takoform.com/v1alpha3/support/bindings/{name}/{version}",
      "exactFormQuery": false,
      "precondition": "none",
      "idempotencyKey": false,
      "mutates": false,
      "successStatus": [200],
      "responseSchema": "https://forms.takoform.com/schemas/support/v1alpha1/host-support-profile.schema.json"
    }
  ],
  "errorEnvelope": {
    "schema": "https://forms.takoform.com/schemas/v1alpha3/host-api-wire.schema.json#/$defs/errorEnvelope",
    "codes": [
      "invalid_argument",
      "unauthenticated",
      "permission_denied",
      "form_unknown",
      "form_not_installed",
      "form_unavailable",
      "form_identity_conflict",
      "resource_not_found",
      "resource_busy",
      "import_conflict",
      "policy_denied",
      "backend_unavailable",
      "internal_error",
      "rate_limited",
      "deadline_exceeded",
      "operation_cancelled",
      "operation_not_found",
      "dependency_in_use",
      "deletion_protected",
      "artifact_missing",
      "artifact_invalid",
      "unsupported_capability",
      "migration_required",
      "uid_mismatch",
      "revision_conflict",
      "generation_conflict"
    ],
    "automaticallyRetryable": ["resource_busy", "backend_unavailable", "rate_limited", "deadline_exceeded"],
    "retryAfter": "honored-when-present-else-full-jitter-backoff",
    "httpStatusByCode": {
      "invalid_argument": 400,
      "unauthenticated": 401,
      "permission_denied": 403,
      "form_unknown": 404,
      "form_not_installed": 409,
      "form_unavailable": 409,
      "form_identity_conflict": 409,
      "resource_not_found": 404,
      "resource_busy": 409,
      "import_conflict": 409,
      "policy_denied": 403,
      "backend_unavailable": 503,
      "internal_error": 500,
      "rate_limited": 429,
      "deadline_exceeded": 504,
      "operation_cancelled": 409,
      "operation_not_found": 404,
      "dependency_in_use": 409,
      "deletion_protected": 409,
      "artifact_missing": 404,
      "artifact_invalid": 400,
      "unsupported_capability": 422,
      "migration_required": 409,
      "uid_mismatch": 409,
      "revision_conflict": 412,
      "generation_conflict": 412
    }
  }
}
