/v1/management/customers/{businessCustomerId}/fieldsBehavior
Server only, with an owner-issued Management credential bound to one tenant/site/integration. The backend must authorize its administrator. Public intake, WhatsApp availability, customer phone verification and website customer mappings are not prerequisites. Existing contacts:record keys are not widened. Persist the exact request and its operation UUID. On an uncertain response retry that command or use its dedicated recovery route; a not_found result does not prove that an in-flight command cannot still commit. Receipts are immutable references, while current is reread under current authority and is null with contact_unavailable after deletion/reparent. Requires contacts:fields:read, contacts:fields:write and contacts:read, plus current readwrite owner approval for every selector. Supply grantRevision from the current fields GET, expectedExists/expectedValue per key and one Idempotency-Key. No global If-Match is used or accepted. All changes apply atomically; a value conflict returns 409 and a policy revision mismatch 412. Current scopes/definition eligibility/grants are rechecked after lock waits and on replay.
Authentication
ManagementCredential
Credential rules
One server-only owner-issued wbm_ API key can carry both management and integration permissions. Additional permissions require an explicit owner-issued grant. GET /v1/management returns the management discovery view, which may be empty for a booking-only key. For credentials with appointments:read, this discovery view omits whatsapp-templates:read, whatsapp-templates:write, whatsapp-profile:read and whatsapp-profile:write to preserve calendar-client compatibility. Discover these grants through GET /v1/management/messaging-capabilities. Template/profile command authorization still uses the stored grants. Server-only owner-issued Management authority with explicit application permissions. Calling this API does not expand a credential's grants. contacts:read/write/block/sync/fields:read/fields:write are separate approvals for canonical business contacts; fields also require current typed owner grants. contacts:record remains contact recording/recovery only. These grants create no customer phone proof, booking authority, messaging consent or automatic synchronization. Hours/blocks retain their independent resource grants. booking-policy:read/write separately delegate whole-business booking settings, without schedule/provider grants; write requires read. They preserve existing appointments and create no duration-rewrite authority. Provider duration policy additionally requires explicit provider-booking-policy:read/write and exact current providerIds; booking-duration:rewrite is separately approved and does not itself grant policy read/write. Service catalogue requires explicit services:read/write, independent of provider/calendar/schedule resources; write requires read. These operations do not expand an existing credential's grants. Public presentation and reviewed service selection require explicit website-content:read/write; write requires read, independently from services:* and provider resources. Existing provider metadata/activity/assignment additionally requires providers:read/write and a nonempty explicit current providerIds grant; write requires read. This grants no provider creation, deletion, login, invitation or schedule authority. WhatsApp template/profile management requires separate whatsapp-templates:read, whatsapp-templates:write, whatsapp-profile:read and whatsapp-profile:write application scopes. Write requires its matching read scope. These grants require explicit owner approval; Meta OAuth permissions remain separate.
Required application permissions
contacts:readcontacts:fields:readcontacts:fields:write
Use the current grantRevision and expectedExists/expectedValue for each field. If-Match is not accepted. An explicitly granted field can still become unavailable after its definition is retired or its visibility changes.
Request
Idempotency and recovery
Persist one UUID and the exact request before sending. After an uncertain result, retain that UUID, body and preconditions; do not create a replacement operation just to retry.
businessCustomerIdpath · stringRequiredFormat and constraints
{ "type": "string", "format": "uuid" }Idempotency-Keyheader · stringRequiredPersist a UUID before sending. Retry only the same UUID and exact body after an uncertain outcome.
Format and constraints
{ "type": "string", "format": "uuid" }
Request body · required
application/json · BusinessCustomerFieldsPatch
Atomic per-selector compare-and-set. Duplicate selectors, unknown keys, malformed values and unavailable grants/definitions are refused. A custom remove deletes its key; notes remove clears it to null. Independent keys can merge despite unrelated customer revisions. Preserve this exact body and the Idempotency-Key for uncertain-outcome recovery.
-
grantRevisionintegerRequiredminimum:0maximum:9007199254740991 -
changesarrayRequiredmaxItems:50minItems:1View nested fields
-
[]oneOf (object; allOf (unspecified) | object; allOf (unspecified) | object; allOf (unspecified) | object; allOf (unspecified))Array itemExactly one of these variants must match.
View nested fields
-
oneOf 1 · kind = "standard"object; allOf (unspecified)Schema branchAll of these schema rules apply together.
View branch fields and rules
-
kindstringRequired in this branchValue:
"standard" -
keystringRequired in this branchValue:
"notes" -
expectedExistsbooleanRequired in this branch -
expectedValueoneOf (string | number | boolean | null | array)Required in this branchExactly one of these variants must match.
View nested fields
-
oneOf 1stringSchema branchmaxLength:4096 -
oneOf 2numberSchema branchminimum:-9007199254740991maximum:9007199254740991 -
oneOf 3booleanSchema branch -
oneOf 4nullSchema branch -
oneOf 5arraySchema branchmaxItems:100View branch fields and rules
-
[]stringArray itemmaxLength:120
-
-
-
operationstringRequired in this branchValue:
"set" -
valueoneOf (string | number | boolean | null | array)Required in this branchExactly one of these variants must match.
View nested fields
-
oneOf 1stringSchema branchmaxLength:4096 -
oneOf 2numberSchema branchminimum:-9007199254740991maximum:9007199254740991 -
oneOf 3booleanSchema branch -
oneOf 4nullSchema branch -
oneOf 5arraySchema branchmaxItems:100View branch fields and rules
-
[]stringArray itemmaxLength:120
-
-
-
allOf 1unspecifiedSchema branchView branch fields and rules
-
ifobjectSchema ruleView branch fields and rules
-
expectedExistsbooleanCondition predicateValue:
false
-
-
thenobjectSchema ruleView branch fields and rules
-
expectedValuenullOptional in this branch
-
-
-
additionalPropertiesno value allowedSchema rule
-
-
oneOf 2 · kind = "standard"object; allOf (unspecified)Schema branchAll of these schema rules apply together.
View branch fields and rules
-
kindstringRequired in this branchValue:
"standard" -
keystringRequired in this branchValue:
"notes" -
expectedExistsbooleanRequired in this branch -
expectedValueoneOf (string | number | boolean | null | array)Required in this branchExactly one of these variants must match.
View nested fields
-
oneOf 1stringSchema branchmaxLength:4096 -
oneOf 2numberSchema branchminimum:-9007199254740991maximum:9007199254740991 -
oneOf 3booleanSchema branch -
oneOf 4nullSchema branch -
oneOf 5arraySchema branchmaxItems:100View branch fields and rules
-
[]stringArray itemmaxLength:120
-
-
-
operationstringRequired in this branchValue:
"remove" -
allOf 1unspecifiedSchema branchView branch fields and rules
-
ifobjectSchema ruleView branch fields and rules
-
expectedExistsbooleanCondition predicateValue:
false
-
-
thenobjectSchema ruleView branch fields and rules
-
expectedValuenullOptional in this branch
-
-
-
additionalPropertiesno value allowedSchema rule
-
-
oneOf 3 · kind = "custom"object; allOf (unspecified)Schema branchAll of these schema rules apply together.
View branch fields and rules
-
kindstringRequired in this branchValue:
"custom" -
fieldIdstring · uuidRequired in this branch -
expectedExistsbooleanRequired in this branch -
expectedValueoneOf (string | number | boolean | null | array)Required in this branchExactly one of these variants must match.
View nested fields
-
oneOf 1stringSchema branchmaxLength:4096 -
oneOf 2numberSchema branchminimum:-9007199254740991maximum:9007199254740991 -
oneOf 3booleanSchema branch -
oneOf 4nullSchema branch -
oneOf 5arraySchema branchmaxItems:100View branch fields and rules
-
[]stringArray itemmaxLength:120
-
-
-
operationstringRequired in this branchValue:
"set" -
valueoneOf (string | number | boolean | null | array)Required in this branchExactly one of these variants must match.
View nested fields
-
oneOf 1stringSchema branchmaxLength:4096 -
oneOf 2numberSchema branchminimum:-9007199254740991maximum:9007199254740991 -
oneOf 3booleanSchema branch -
oneOf 4nullSchema branch -
oneOf 5arraySchema branchmaxItems:100View branch fields and rules
-
[]stringArray itemmaxLength:120
-
-
-
allOf 1unspecifiedSchema branchView branch fields and rules
-
ifobjectSchema ruleView branch fields and rules
-
expectedExistsbooleanCondition predicateValue:
false
-
-
thenobjectSchema ruleView branch fields and rules
-
expectedValuenullOptional in this branch
-
-
-
additionalPropertiesno value allowedSchema rule
-
-
oneOf 4 · kind = "custom"object; allOf (unspecified)Schema branchAll of these schema rules apply together.
View branch fields and rules
-
kindstringRequired in this branchValue:
"custom" -
fieldIdstring · uuidRequired in this branch -
expectedExistsbooleanRequired in this branch -
expectedValueoneOf (string | number | boolean | null | array)Required in this branchExactly one of these variants must match.
View nested fields
-
oneOf 1stringSchema branchmaxLength:4096 -
oneOf 2numberSchema branchminimum:-9007199254740991maximum:9007199254740991 -
oneOf 3booleanSchema branch -
oneOf 4nullSchema branch -
oneOf 5arraySchema branchmaxItems:100View branch fields and rules
-
[]stringArray itemmaxLength:120
-
-
-
operationstringRequired in this branchValue:
"remove" -
allOf 1unspecifiedSchema branchView branch fields and rules
-
ifobjectSchema ruleView branch fields and rules
-
expectedExistsbooleanCondition predicateValue:
false
-
-
thenobjectSchema ruleView branch fields and rules
-
expectedValuenullOptional in this branch
-
-
-
additionalPropertiesno value allowedSchema rule
-
-
-
-
additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
{
"type": "object",
"additionalProperties": false,
"properties": {
"grantRevision": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"changes": {
"type": "array",
"maxItems": 50,
"minItems": 1,
"items": {
"oneOf": [
{
"type": "object",
"additionalProperties": false,
"properties": {
"kind": {
"const": "standard"
},
"key": {
"const": "notes"
},
"expectedExists": {
"type": "boolean"
},
"expectedValue": {
"oneOf": [
{
"type": "string",
"maxLength": 4096
},
{
"type": "number",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
{
"type": "boolean"
},
{
"type": "null"
},
{
"type": "array",
"maxItems": 100,
"items": {
"type": "string",
"maxLength": 120
}
}
]
},
"operation": {
"const": "set"
},
"value": {
"oneOf": [
{
"type": "string",
"maxLength": 4096
},
{
"type": "number",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
{
"type": "boolean"
},
{
"type": "null"
},
{
"type": "array",
"maxItems": 100,
"items": {
"type": "string",
"maxLength": 120
}
}
]
}
},
"required": [
"kind",
"key",
"expectedExists",
"expectedValue",
"operation",
"value"
],
"allOf": [
{
"if": {
"properties": {
"expectedExists": {
"const": false
}
},
"required": [
"expectedExists"
]
},
"then": {
"properties": {
"expectedValue": {
"type": "null"
}
}
}
}
]
},
{
"type": "object",
"additionalProperties": false,
"properties": {
"kind": {
"const": "standard"
},
"key": {
"const": "notes"
},
"expectedExists": {
"type": "boolean"
},
"expectedValue": {
"oneOf": [
{
"type": "string",
"maxLength": 4096
},
{
"type": "number",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
{
"type": "boolean"
},
{
"type": "null"
},
{
"type": "array",
"maxItems": 100,
"items": {
"type": "string",
"maxLength": 120
}
}
]
},
"operation": {
"const": "remove"
}
},
"required": [
"kind",
"key",
"expectedExists",
"expectedValue",
"operation"
],
"allOf": [
{
"if": {
"properties": {
"expectedExists": {
"const": false
}
},
"required": [
"expectedExists"
]
},
"then": {
"properties": {
"expectedValue": {
"type": "null"
}
}
}
}
]
},
{
"type": "object",
"additionalProperties": false,
"properties": {
"kind": {
"const": "custom"
},
"fieldId": {
"type": "string",
"format": "uuid"
},
"expectedExists": {
"type": "boolean"
},
"expectedValue": {
"oneOf": [
{
"type": "string",
"maxLength": 4096
},
{
"type": "number",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
{
"type": "boolean"
},
{
"type": "null"
},
{
"type": "array",
"maxItems": 100,
"items": {
"type": "string",
"maxLength": 120
}
}
]
},
"operation": {
"const": "set"
},
"value": {
"oneOf": [
{
"type": "string",
"maxLength": 4096
},
{
"type": "number",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
{
"type": "boolean"
},
{
"type": "null"
},
{
"type": "array",
"maxItems": 100,
"items": {
"type": "string",
"maxLength": 120
}
}
]
}
},
"required": [
"kind",
"fieldId",
"expectedExists",
"expectedValue",
"operation",
"value"
],
"allOf": [
{
"if": {
"properties": {
"expectedExists": {
"const": false
}
},
"required": [
"expectedExists"
]
},
"then": {
"properties": {
"expectedValue": {
"type": "null"
}
}
}
}
]
},
{
"type": "object",
"additionalProperties": false,
"properties": {
"kind": {
"const": "custom"
},
"fieldId": {
"type": "string",
"format": "uuid"
},
"expectedExists": {
"type": "boolean"
},
"expectedValue": {
"oneOf": [
{
"type": "string",
"maxLength": 4096
},
{
"type": "number",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
{
"type": "boolean"
},
{
"type": "null"
},
{
"type": "array",
"maxItems": 100,
"items": {
"type": "string",
"maxLength": 120
}
}
]
},
"operation": {
"const": "remove"
}
},
"required": [
"kind",
"fieldId",
"expectedExists",
"expectedValue",
"operation"
],
"allOf": [
{
"if": {
"properties": {
"expectedExists": {
"const": false
}
},
"required": [
"expectedExists"
]
},
"then": {
"properties": {
"expectedValue": {
"type": "null"
}
}
}
}
]
}
]
}
}
},
"required": [
"grantRevision",
"changes"
],
"description": "Atomic per-selector compare-and-set. Duplicate selectors, unknown keys, malformed values and unavailable grants/definitions are refused. A custom remove deletes its key; notes remove clears it to null. Independent keys can merge despite unrelated customer revisions. Preserve this exact body and the Idempotency-Key for uncertain-outcome recovery."
} Successful responses
200 · BusinessCustomerFieldResult
Success.
application/json · BusinessCustomerFieldResult
All of these schema rules apply together.
-
receiptobjectRequiredImmutable accepted operation reference and selectors only. No former field value is retained.
View nested fields
-
operationIdstring · uuidRequired -
businessCustomerIdstring · uuidRequired -
fieldsarrayRequiredmaxItems:50minItems:1View nested fields
-
[]oneOf (object | object)Array itemExactly one of these variants must match.
View nested fields
-
oneOf 1 · kind = "standard"objectSchema branchView branch fields and rules
-
kindstringRequired in this branchValue:
"standard" -
keystringRequired in this branchValue:
"notes" -
additionalPropertiesno value allowedSchema rule
-
-
oneOf 2 · kind = "custom"objectSchema branchView branch fields and rules
-
kindstringRequired in this branchValue:
"custom" -
fieldIdstring · uuidRequired in this branch -
additionalPropertiesno value allowedSchema rule
-
-
-
-
additionalPropertiesno value allowedSchema rule
-
-
currentanyOf (object | null)RequiredAt least one of these variants must match.
View nested fields
-
anyOf 1objectSchema branchCurrent granted field definitions and values. grantRevision supplies the policy precondition for PATCH; each change also compares expectedExists and expectedValue. projectionVersion describes this current projection and is not a global write precondition. Absent custom keys have exists:false,value:null; notes always has exists:true and may be null.
View branch fields and rules
-
businessCustomerIdstring · uuidRequired in this branch -
grantRevisionintegerRequired in this branchminimum:0maximum:9007199254740991 -
projectionEpochstringRequired in this branchpattern:"^[a-f0-9]{64}$" -
customerVersionstringRequired in this branchDatabase-owned canonical customer revision. Read a current customer and its ETag before a basic or block command. Native and API edits share this revision; no-op writes do not increment it. It is not a customer-mapping version.
pattern:"^c(0|[1-9][0-9]{0,18})$" -
projectionVersionstringRequired in this branchpattern:"^[a-f0-9]{64}$" -
fieldsarrayRequired in this branchmaxItems:50View nested fields
-
[]object; allOf (unspecified & unspecified & unspecified & unspecified & unspecified & unspecified & unspecified)Array itemOne currently eligible, independently owner-approved Management field. Standard selectors support notes only; custom selectors use the immutable definition UUID. Visibility alone is not approval. No ungranted value or metadata is exposed.
All of these schema rules apply together.
View nested fields
-
kindstringRequired in this branchAllowed values:
["standard","custom"] -
keystringRequired in this branchCurrent definition key; control and prototype keys are refused.
minLength:1maxLength:100 -
fieldIdanyOf (string | null)Required in this branchAt least one of these variants must match.
View nested fields
-
anyOf 1string · uuidSchema branch -
anyOf 2nullSchema branch
-
-
labelobjectRequired in this branchView nested fields
-
hestringOptional in this branchminLength:0maxLength:200 -
arstringOptional in this branchminLength:0maxLength:200 -
enstringOptional in this branchminLength:0maxLength:200 -
additionalPropertiesno value allowedSchema rule
-
-
typestringRequired in this branchAllowed values:
["text","textarea","number","date","select","phone","email","boolean","checkbox","multi_select","multiselect"] -
accessstringRequired in this branchAllowed values:
["read","readwrite"] -
existsbooleanRequired in this branch -
valueoneOf (string | number | boolean | null | array)Required in this branchExactly one of these variants must match.
View nested fields
-
oneOf 1stringSchema branchmaxLength:4096 -
oneOf 2numberSchema branchminimum:-9007199254740991maximum:9007199254740991 -
oneOf 3booleanSchema branch -
oneOf 4nullSchema branch -
oneOf 5arraySchema branchmaxItems:100View branch fields and rules
-
[]stringArray itemmaxLength:120
-
-
-
valueUnavailableReasonnull | stringRequired in this branchAllowed values:
[null,"invalid_stored_value","too_large"] -
optionsarrayRequired in this branchmaxItems:100View nested fields
-
[]objectArray itemView nested fields
-
idstringRequired in this branchminLength:1maxLength:120 -
labelobjectRequired in this branchView nested fields
-
hestringOptional in this branchminLength:0maxLength:200 -
arstringOptional in this branchminLength:0maxLength:200 -
enstringOptional in this branchminLength:0maxLength:200 -
additionalPropertiesno value allowedSchema rule
-
-
additionalPropertiesno value allowedSchema rule
-
-
-
allOf 1unspecifiedSchema branchView branch fields and rules
-
ifobjectSchema ruleView branch fields and rules
-
existsbooleanCondition predicateValue:
false
-
-
thenobjectSchema ruleView branch fields and rules
-
valuenullOptional in this branchValue:
null -
valueUnavailableReasonnullOptional in this branchValue:
null
-
-
-
allOf 2unspecifiedSchema branchView branch fields and rules
-
ifobjectSchema ruleView branch fields and rules
-
valueUnavailableReasonstringCondition predicateAllowed values:
["invalid_stored_value","too_large"]
-
-
thenobjectSchema ruleView branch fields and rules
-
valuenullOptional in this branchValue:
null -
existsbooleanOptional in this branchValue:
true
-
-
-
allOf 3unspecifiedSchema branchView branch fields and rules
-
ifobjectSchema ruleView branch fields and rules
-
typestringCondition predicateAllowed values:
["number"]
-
-
thenobjectSchema ruleView branch fields and rules
-
valuenumber | nullOptional in this branch
-
-
-
allOf 4unspecifiedSchema branchView branch fields and rules
-
ifobjectSchema ruleView branch fields and rules
-
typestringCondition predicateAllowed values:
["boolean","checkbox"]
-
-
thenobjectSchema ruleView branch fields and rules
-
valueboolean | nullOptional in this branch
-
-
-
allOf 5unspecifiedSchema branchView branch fields and rules
-
ifobjectSchema ruleView branch fields and rules
-
typestringCondition predicateAllowed values:
["multi_select","multiselect"]
-
-
thenobjectSchema ruleView branch fields and rules
-
valueoneOf (null | array)Optional in this branchExactly one of these variants must match.
View nested fields
-
oneOf 1nullSchema branch -
oneOf 2arraySchema branchmaxItems:100View branch fields and rules
-
[]stringArray itemmaxLength:120
-
-
-
-
-
allOf 6unspecifiedSchema branchView branch fields and rules
-
ifobjectSchema ruleView branch fields and rules
-
typestringCondition predicateAllowed values:
["text","textarea","date","select","phone","email"]
-
-
thenobjectSchema ruleView branch fields and rules
-
valuestring | nullOptional in this branch
-
-
-
allOf 7unspecifiedSchema branchView branch fields and rules
-
ifobjectSchema ruleView branch fields and rules
-
kindstringCondition predicateValue:
"standard"
-
-
thenobjectSchema ruleView branch fields and rules
-
keystringOptional in this branchValue:
"notes" -
fieldIdnullOptional in this branch -
typestringOptional in this branchValue:
"textarea"
-
-
elseobjectSchema ruleView branch fields and rules
-
fieldIdstring · uuidOptional in this branch
-
-
-
additionalPropertiesno value allowedSchema rule
-
-
-
additionalPropertiesno value allowedSchema rule
-
-
anyOf 2nullSchema branch
-
-
currentUnavailableReasonnull | stringRequiredAllowed values:
[null,"contact_unavailable"] -
replayedbooleanRequired -
allOf 1unspecifiedSchema branchView branch fields and rules
-
ifobjectSchema ruleView branch fields and rules
-
currentnullCondition predicate
-
-
thenobjectSchema ruleView branch fields and rules
-
currentUnavailableReasonstringOptional in this branchValue:
"contact_unavailable"
-
-
elseobjectSchema ruleView branch fields and rules
-
currentUnavailableReasonnullOptional in this branch
-
-
-
additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
{
"type": "object",
"additionalProperties": false,
"properties": {
"receipt": {
"type": "object",
"additionalProperties": false,
"properties": {
"operationId": {
"type": "string",
"format": "uuid"
},
"businessCustomerId": {
"type": "string",
"format": "uuid"
},
"fields": {
"type": "array",
"maxItems": 50,
"minItems": 1,
"items": {
"oneOf": [
{
"type": "object",
"additionalProperties": false,
"properties": {
"kind": {
"const": "standard"
},
"key": {
"const": "notes"
}
},
"required": [
"kind",
"key"
]
},
{
"type": "object",
"additionalProperties": false,
"properties": {
"kind": {
"const": "custom"
},
"fieldId": {
"type": "string",
"format": "uuid"
}
},
"required": [
"kind",
"fieldId"
]
}
]
}
}
},
"required": [
"operationId",
"businessCustomerId",
"fields"
],
"description": "Immutable accepted operation reference and selectors only. No former field value is retained."
},
"current": {
"anyOf": [
{
"type": "object",
"additionalProperties": false,
"properties": {
"businessCustomerId": {
"type": "string",
"format": "uuid"
},
"grantRevision": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"projectionEpoch": {
"type": "string",
"pattern": "^[a-f0-9]{64}$"
},
"customerVersion": {
"type": "string",
"pattern": "^c(0|[1-9][0-9]{0,18})$",
"description": "Database-owned canonical customer revision. Read a current customer and its ETag before a basic or block command. Native and API edits share this revision; no-op writes do not increment it. It is not a customer-mapping version."
},
"projectionVersion": {
"type": "string",
"pattern": "^[a-f0-9]{64}$"
},
"fields": {
"type": "array",
"maxItems": 50,
"items": {
"type": "object",
"additionalProperties": false,
"properties": {
"kind": {
"enum": [
"standard",
"custom"
]
},
"key": {
"type": "string",
"minLength": 1,
"maxLength": 100,
"description": "Current definition key; control and prototype keys are refused."
},
"fieldId": {
"anyOf": [
{
"type": "string",
"format": "uuid"
},
{
"type": "null"
}
]
},
"label": {
"type": "object",
"additionalProperties": false,
"properties": {
"he": {
"type": "string",
"minLength": 0,
"maxLength": 200
},
"ar": {
"type": "string",
"minLength": 0,
"maxLength": 200
},
"en": {
"type": "string",
"minLength": 0,
"maxLength": 200
}
},
"required": []
},
"type": {
"type": "string",
"enum": [
"text",
"textarea",
"number",
"date",
"select",
"phone",
"email",
"boolean",
"checkbox",
"multi_select",
"multiselect"
]
},
"access": {
"enum": [
"read",
"readwrite"
]
},
"exists": {
"type": "boolean"
},
"value": {
"oneOf": [
{
"type": "string",
"maxLength": 4096
},
{
"type": "number",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
{
"type": "boolean"
},
{
"type": "null"
},
{
"type": "array",
"maxItems": 100,
"items": {
"type": "string",
"maxLength": 120
}
}
]
},
"valueUnavailableReason": {
"enum": [
null,
"invalid_stored_value",
"too_large"
]
},
"options": {
"type": "array",
"maxItems": 100,
"items": {
"type": "object",
"additionalProperties": false,
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 120
},
"label": {
"type": "object",
"additionalProperties": false,
"properties": {
"he": {
"type": "string",
"minLength": 0,
"maxLength": 200
},
"ar": {
"type": "string",
"minLength": 0,
"maxLength": 200
},
"en": {
"type": "string",
"minLength": 0,
"maxLength": 200
}
},
"required": []
}
},
"required": [
"id",
"label"
]
}
}
},
"required": [
"kind",
"key",
"fieldId",
"label",
"type",
"access",
"exists",
"value",
"valueUnavailableReason",
"options"
],
"allOf": [
{
"if": {
"properties": {
"exists": {
"const": false
}
},
"required": [
"exists"
]
},
"then": {
"properties": {
"value": {
"const": null
},
"valueUnavailableReason": {
"const": null
}
}
}
},
{
"if": {
"properties": {
"valueUnavailableReason": {
"enum": [
"invalid_stored_value",
"too_large"
]
}
},
"required": [
"valueUnavailableReason"
]
},
"then": {
"properties": {
"value": {
"const": null
},
"exists": {
"const": true
}
}
}
},
{
"if": {
"properties": {
"type": {
"enum": [
"number"
]
}
},
"required": [
"type"
]
},
"then": {
"properties": {
"value": {
"type": [
"number",
"null"
]
}
}
}
},
{
"if": {
"properties": {
"type": {
"enum": [
"boolean",
"checkbox"
]
}
},
"required": [
"type"
]
},
"then": {
"properties": {
"value": {
"type": [
"boolean",
"null"
]
}
}
}
},
{
"if": {
"properties": {
"type": {
"enum": [
"multi_select",
"multiselect"
]
}
},
"required": [
"type"
]
},
"then": {
"properties": {
"value": {
"oneOf": [
{
"type": "null"
},
{
"type": "array",
"maxItems": 100,
"items": {
"type": "string",
"maxLength": 120
}
}
]
}
}
}
},
{
"if": {
"properties": {
"type": {
"enum": [
"text",
"textarea",
"date",
"select",
"phone",
"email"
]
}
},
"required": [
"type"
]
},
"then": {
"properties": {
"value": {
"type": [
"string",
"null"
]
}
}
}
},
{
"if": {
"properties": {
"kind": {
"const": "standard"
}
},
"required": [
"kind"
]
},
"then": {
"properties": {
"key": {
"const": "notes"
},
"fieldId": {
"type": "null"
},
"type": {
"const": "textarea"
}
}
},
"else": {
"properties": {
"fieldId": {
"type": "string",
"format": "uuid"
}
}
}
}
],
"description": "One currently eligible, independently owner-approved Management field. Standard selectors support notes only; custom selectors use the immutable definition UUID. Visibility alone is not approval. No ungranted value or metadata is exposed."
}
}
},
"required": [
"businessCustomerId",
"grantRevision",
"projectionEpoch",
"customerVersion",
"projectionVersion",
"fields"
],
"description": "Current granted field definitions and values. grantRevision supplies the policy precondition for PATCH; each change also compares expectedExists and expectedValue. projectionVersion describes this current projection and is not a global write precondition. Absent custom keys have exists:false,value:null; notes always has exists:true and may be null."
},
{
"type": "null"
}
]
},
"currentUnavailableReason": {
"enum": [
null,
"contact_unavailable"
]
},
"replayed": {
"type": "boolean"
}
},
"required": [
"receipt",
"current",
"currentUnavailableReason",
"replayed"
],
"allOf": [
{
"if": {
"properties": {
"current": {
"type": "null"
}
},
"required": [
"current"
]
},
"then": {
"properties": {
"currentUnavailableReason": {
"const": "contact_unavailable"
}
}
},
"else": {
"properties": {
"currentUnavailableReason": {
"type": "null"
}
}
}
}
]
} Errors and recovery
Error responses declared in the contract (12)
The preview contract shares generic error definitions across operations. This list is not an exhaustive list of runtime errors.
401 · Missing or invalid Management bearer.
application/json · Error
-
errorobjectRequiredView nested fields
-
codestringRequired -
requestIdstring · uuidRequired -
retryAfterintegerOptionalminimum:1 -
additionalPropertiesno value allowedSchema rule
-
-
additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
{
"type": "object",
"additionalProperties": false,
"properties": {
"error": {
"type": "object",
"additionalProperties": false,
"properties": {
"code": {
"type": "string"
},
"requestId": {
"type": "string",
"format": "uuid"
},
"retryAfter": {
"type": "integer",
"minimum": 1
}
},
"required": [
"code",
"requestId"
]
}
},
"required": [
"error"
]
} 403 · Current scope, grant or authority denied; browser Origin is refused.
application/json · Error
-
errorobjectRequiredView nested fields
-
codestringRequired -
requestIdstring · uuidRequired -
retryAfterintegerOptionalminimum:1 -
additionalPropertiesno value allowedSchema rule
-
-
additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
{
"type": "object",
"additionalProperties": false,
"properties": {
"error": {
"type": "object",
"additionalProperties": false,
"properties": {
"code": {
"type": "string"
},
"requestId": {
"type": "string",
"format": "uuid"
},
"retryAfter": {
"type": "integer",
"minimum": 1
}
},
"required": [
"code",
"requestId"
]
}
},
"required": [
"error"
]
} 404 · Canonical contact unavailable in this credential tenant.
application/json · Error
-
errorobjectRequiredView nested fields
-
codestringRequired -
requestIdstring · uuidRequired -
retryAfterintegerOptionalminimum:1 -
additionalPropertiesno value allowedSchema rule
-
-
additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
{
"type": "object",
"additionalProperties": false,
"properties": {
"error": {
"type": "object",
"additionalProperties": false,
"properties": {
"code": {
"type": "string"
},
"requestId": {
"type": "string",
"format": "uuid"
},
"retryAfter": {
"type": "integer",
"minimum": 1
}
},
"required": [
"code",
"requestId"
]
}
},
"required": [
"error"
]
} 405 · Method not allowed.
application/json · Error
-
errorobjectRequiredView nested fields
-
codestringRequired -
requestIdstring · uuidRequired -
retryAfterintegerOptionalminimum:1 -
additionalPropertiesno value allowedSchema rule
-
-
additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
{
"type": "object",
"additionalProperties": false,
"properties": {
"error": {
"type": "object",
"additionalProperties": false,
"properties": {
"code": {
"type": "string"
},
"requestId": {
"type": "string",
"format": "uuid"
},
"retryAfter": {
"type": "integer",
"minimum": 1
}
},
"required": [
"code",
"requestId"
]
}
},
"required": [
"error"
]
} 409 · Operation, field value, identity or checkpoint conflict. No partial write.
application/json · Error
-
errorobjectRequiredView nested fields
-
codestringRequired -
requestIdstring · uuidRequired -
retryAfterintegerOptionalminimum:1 -
additionalPropertiesno value allowedSchema rule
-
-
additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
{
"type": "object",
"additionalProperties": false,
"properties": {
"error": {
"type": "object",
"additionalProperties": false,
"properties": {
"code": {
"type": "string"
},
"requestId": {
"type": "string",
"format": "uuid"
},
"retryAfter": {
"type": "integer",
"minimum": 1
}
},
"required": [
"code",
"requestId"
]
}
},
"required": [
"error"
]
} 412 · Current canonical version or owner grant revision changed.
application/json · Error
-
errorobjectRequiredView nested fields
-
codestringRequired -
requestIdstring · uuidRequired -
retryAfterintegerOptionalminimum:1 -
additionalPropertiesno value allowedSchema rule
-
-
additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
{
"type": "object",
"additionalProperties": false,
"properties": {
"error": {
"type": "object",
"additionalProperties": false,
"properties": {
"code": {
"type": "string"
},
"requestId": {
"type": "string",
"format": "uuid"
},
"retryAfter": {
"type": "integer",
"minimum": 1
}
},
"required": [
"code",
"requestId"
]
}
},
"required": [
"error"
]
} 413 · Request exceeds the bounded body size.
application/json · Error
-
errorobjectRequiredView nested fields
-
codestringRequired -
requestIdstring · uuidRequired -
retryAfterintegerOptionalminimum:1 -
additionalPropertiesno value allowedSchema rule
-
-
additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
{
"type": "object",
"additionalProperties": false,
"properties": {
"error": {
"type": "object",
"additionalProperties": false,
"properties": {
"code": {
"type": "string"
},
"requestId": {
"type": "string",
"format": "uuid"
},
"retryAfter": {
"type": "integer",
"minimum": 1
}
},
"required": [
"code",
"requestId"
]
}
},
"required": [
"error"
]
} 415 · JSON content type required.
application/json · Error
-
errorobjectRequiredView nested fields
-
codestringRequired -
requestIdstring · uuidRequired -
retryAfterintegerOptionalminimum:1 -
additionalPropertiesno value allowedSchema rule
-
-
additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
{
"type": "object",
"additionalProperties": false,
"properties": {
"error": {
"type": "object",
"additionalProperties": false,
"properties": {
"code": {
"type": "string"
},
"requestId": {
"type": "string",
"format": "uuid"
},
"retryAfter": {
"type": "integer",
"minimum": 1
}
},
"required": [
"code",
"requestId"
]
}
},
"required": [
"error"
]
} 422 · Malformed or unsupported request; no tenant/resource selector is accepted.
application/json · Error
-
errorobjectRequiredView nested fields
-
codestringRequired -
requestIdstring · uuidRequired -
retryAfterintegerOptionalminimum:1 -
additionalPropertiesno value allowedSchema rule
-
-
additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
{
"type": "object",
"additionalProperties": false,
"properties": {
"error": {
"type": "object",
"additionalProperties": false,
"properties": {
"code": {
"type": "string"
},
"requestId": {
"type": "string",
"format": "uuid"
},
"retryAfter": {
"type": "integer",
"minimum": 1
}
},
"required": [
"code",
"requestId"
]
}
},
"required": [
"error"
]
} 428 · Required operation UUID or version precondition is missing.
application/json · Error
-
errorobjectRequiredView nested fields
-
codestringRequired -
requestIdstring · uuidRequired -
retryAfterintegerOptionalminimum:1 -
additionalPropertiesno value allowedSchema rule
-
-
additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
{
"type": "object",
"additionalProperties": false,
"properties": {
"error": {
"type": "object",
"additionalProperties": false,
"properties": {
"code": {
"type": "string"
},
"requestId": {
"type": "string",
"format": "uuid"
},
"retryAfter": {
"type": "integer",
"minimum": 1
}
},
"required": [
"code",
"requestId"
]
}
},
"required": [
"error"
]
} 429 · Request/snapshot limit reached.
application/json · Error
-
errorobjectRequiredView nested fields
-
codestringRequired -
requestIdstring · uuidRequired -
retryAfterintegerOptionalminimum:1 -
additionalPropertiesno value allowedSchema rule
-
-
additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
{
"type": "object",
"additionalProperties": false,
"properties": {
"error": {
"type": "object",
"additionalProperties": false,
"properties": {
"code": {
"type": "string"
},
"requestId": {
"type": "string",
"format": "uuid"
},
"retryAfter": {
"type": "integer",
"minimum": 1
}
},
"required": [
"code",
"requestId"
]
}
},
"required": [
"error"
]
} 503 · Storage unavailable or outcome uncertain. Retain the original UUID and exact command to reconcile.
application/json · Error
-
errorobjectRequiredView nested fields
-
codestringRequired -
requestIdstring · uuidRequired -
retryAfterintegerOptionalminimum:1 -
additionalPropertiesno value allowedSchema rule
-
-
additionalPropertiesno value allowedSchema rule
Complete schema and nested fields
{
"type": "object",
"additionalProperties": false,
"properties": {
"error": {
"type": "object",
"additionalProperties": false,
"properties": {
"code": {
"type": "string"
},
"requestId": {
"type": "string",
"format": "uuid"
},
"retryAfter": {
"type": "integer",
"minimum": 1
}
},
"required": [
"code",
"requestId"
]
}
},
"required": [
"error"
]
}