# Get scenario version GET /v1/a/scenario-version/by-scenario Select code sample ``` const url = 'https://example.com/v1/a/scenario-version/by-scenario?scenario_sid=example&version=1'; const options = {method: 'GET', headers: {Authorization: 'Bearer '}}; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` ``` curl --request GET \ --url 'https://example.com/v1/a/scenario-version/by-scenario?scenario_sid=example&version=1' \ --header 'Authorization: Bearer ' ``` - /v1/a/scenario-version/by-scenario Addresses one version record by parent scenario plus axis number. ## Permission This operation needs the permission [`scenario:read`](https://docs.aiva.apifonica.com/concepts/roles-and-permissions/#scenario-read). ## Authorizations - **[bearerAuth](https://docs.aiva.apifonica.com/api/account/#bearerauth)** ## Parameters ### Query Parameters **scenario\_sid** required string Parent scenario whose version record is addressed. **version** required integer Addresses a record by its axis number. By `draft`: - `draft=false`: the number is the published `version`. - `draft=true`: the number is the `draft_version`. `draft_version` 0 is the current work-in-progress draft. **draft** boolean Selects the axis; the default is `false`. Values: - `false`: selects the published record, where `version` equals the number. - `true`: selects the draft record, where `draft_version` equals the number. ### Header Parameters **X-Account-Sid** string Names the target account for account-scoped resources. By principal: - A tenant API key carries no account scope of its own and names the account here. - An account-scoped principal may omit it. Refused when: - A tenant API key omits it. - An account-scoped principal sends a value naming any other account. - The named account belongs to another tenant. - The named account does not exist; it is answered as not found. ## Responses ### 200 OK Media typeapplication/json Holds either a published version or a draft record. Rules: - Exactly one of `version` and `draft_version` is set. - `version` is set on a published version. - `draft_version` 0 is the mutable work-in-progress draft. - A `draft_version` above 0 is a frozen draft record. object **id** required string **scenario\_sid** required string **version** integer | null **draft\_version** integer | null **content\_hash** required Identifies the content of the record. Node positions and the order of brick outputs are not content. string **snapshot** required object **name** required string **constructor** Any of: object **bricks** Holds the properties of a brick, one key per brick type. Rules: - A text property reads a variable when it holds `{{name}}`, and a contact field when it holds `{{contact.}}`; the call puts the value in place when the brick runs. - A number, a boolean and an enum property take no variable. - `start_call`, `inbound_call`, `outbound_call`, `recording_setup`, `tree`, `start_tree`, `end_tree` and `end`: no property takes a variable. - `condition_group` and `assignment`: only `value` takes a variable. - `webhook`: only the method, the URL, the body, the names and values of the headers and of the form fields, the basic-auth username and password, the bearer token, the proxy URL, and the `path` and `set_if_not_found` of a response mapping take a variable. - A property that names a variable to write, such as `variable` of a response mapping or of `increment`, is written to and not read. - The guide with examples: object **audio** object **v1** Array\ object **id** required string **description** string **properties** object **play\_mode** Picks which of the brick’s `audios` it plays. Refused when: - A publish carries no value. - A publish carries an undeclared value. string Allowed values: all one\_next one\_random **audios** Array\ object **mode** string **tts\_properties** object **text** string **file\_properties** object **url** string **tts\_general** object **language** string **voice** string **engine** string **speed** number format: float **model** string **outputs** Array\ object **type** string **description** string **audio\_file** object **v1** Array\ object **id** required string **description** string **properties** object **url** string **outputs** Array\ object **type** string **description** string **audio\_tts** object **v1** Array\ object **id** required string **description** string **properties** object **text** string **language** string **voice** string **engine** string **model** string **outputs** Array\ object **type** string **description** string **sms** object **v1** Array\ object **id** required string **description** string **properties** Message content only. Provider, credentials, and sender identity resolve from the agent’s SMS settings at send time. object **to** Overrides the recipient; empty means the communication recipient. string **text** string **outputs** Array\ object **type** string **description** string **goal** object **v1** Array\ object **id** required string **description** string **properties** object **goal** string **outputs** Array\ object **type** string **description** string **end\_call** object **v1** Array\ object **id** required string **description** string **properties** object **signal** string **outputs** Array\ object **type** string **description** string **assignment** object **v1** Array\ object **id** required string **description** string **properties** object **variables** Array\ object **name** string **value** string **outputs** Array\ object **type** string **description** string **increment** object **v1** Array\ object **id** required string **description** string **properties** object **variables** Array\ object **variable** string **outputs** Array\ object **type** string **description** string **condition\_group** object **v1** Array\ object **id** required string **description** string **properties** object **condition** object **conditions** Array\ object **condition\_id** string **description** string **condition\_operator** How a condition joins its elements. string Allowed values: and or **elements** Array\ object **variable** string **element\_operator** How one condition element compares its variable against its value. string Allowed values: equal not\_equal greater\_than less\_than greater\_than\_equal less\_than\_equal in not\_in contains not\_contains starts\_with **value** string **outputs** Array\ object **type** string **description** string **start\_tree** object **v1** Array\ object **id** required string **description** string **properties** object **outputs** Array\ object **type** string **description** string **start\_call** object **v1** Array\ Starts the call and hands it to the `outbound_call` or the `inbound_call` brick. Replaced by `v2`. object **id** required string **description** string **properties** object **stt\_general** object **language** string **engine** string Allowed values: gsr gsr\@v2 azuresr experimental mohir soniox elevenlabs **model** string **primary\_language** string **fallback\_languages** Array\ **endpoint\_detection** Ends the caller’s turn when the recognition engine reports the end of the phrase, before the speech timeout. Rules: - A call reads it from the settings of a question. - A call reads it from the settings of an AI agent. - A call does not read it from `stt_general`. object **enabled** Switches endpoint detection on. Values: - `true`: is allowed only where the `engine` of the same settings is `soniox`. - `false`: the other values are stored and not checked. boolean **latency\_adjustment\_level** Sets the engine’s endpoint latency adjustment level, from 0 to 3. Omitting it is the same as sending 0. integer **sensitivity** Sets the engine’s endpoint sensitivity, from -1.0 to 1.0. Omitting it is the same as sending 0. number format: float **max\_delay\_ms** Sets the engine’s maximum endpoint delay in milliseconds, from 500 to 3000. Required while `enabled` is true. integer **tts\_general** object **language** string **voice** string **engine** string **speed** number format: float **model** string **outputs** Array\ object **type** string **description** string **v2** Array\ Starts the call and routes it by the call outcome. The outputs: - `outbound`: an outbound call is answered. Required. - `inbound`: an inbound call is answered. Required. - `voicemail`: an answering machine answers an outbound call. Required while `voicemail_enabled` is true. - `busy`: the line of an outbound call is busy. Required. - `unanswered`: nobody answers an outbound call. Required. Rules: - After `busy` and `unanswered` there is no call: a brick that needs the call takes its fallback output, and a brick that needs no call runs. - A scenario ends on `busy` or `unanswered` through a link to an `end` brick. - An output with no link ends the scenario. object **id** required string **description** string **properties** object **stt\_general** object **language** string **engine** string Allowed values: gsr gsr\@v2 azuresr experimental mohir soniox elevenlabs **model** string **primary\_language** string **fallback\_languages** Array\ **endpoint\_detection** Ends the caller’s turn when the recognition engine reports the end of the phrase, before the speech timeout. Rules: - A call reads it from the settings of a question. - A call reads it from the settings of an AI agent. - A call does not read it from `stt_general`. object **enabled** Switches endpoint detection on. Values: - `true`: is allowed only where the `engine` of the same settings is `soniox`. - `false`: the other values are stored and not checked. boolean **latency\_adjustment\_level** Sets the engine’s endpoint latency adjustment level, from 0 to 3. Omitting it is the same as sending 0. integer **sensitivity** Sets the engine’s endpoint sensitivity, from -1.0 to 1.0. Omitting it is the same as sending 0. number format: float **max\_delay\_ms** Sets the engine’s maximum endpoint delay in milliseconds, from 500 to 3000. Required while `enabled` is true. integer **tts\_general** object **language** string **voice** string **engine** string **speed** number format: float **model** string **voicemail\_enabled** Turns on answering machine detection for an outbound call, which then follows the `voicemail` output. Replaces the agent’s `voicemail_enabled` for this scenario. false when absent. boolean **outputs** Array\ object **type** string **description** string **outbound\_call** object **v1** Array\ object **id** required string **description** string **properties** object **is\_voicemail** boolean **outputs** Array\ object **type** string **description** string **inbound\_call** object **v1** Array\ object **id** required string **description** string **properties** object **outputs** Array\ object **type** string **description** string **end** object **v1** Array\ object **id** required string **description** string **properties** object **outputs** Array\ object **type** string **description** string **call\_transfer** object **v1** Array\ object **id** required string **description** string **properties** object **from** string **number** string **message\_to\_manager** object **mode** string **tts** object **text** string **file** object **url** string **message\_to\_client** object **mode** string **tts** object **text** string **file** object **url** string **timeout** integer **tts\_properties** object **language** string **voice** string **engine** string **model** string **sip\_header** object **sip\_headers** Array\ object **name** string **value** string **transfer\_mode** Picks how the call is handed over. Values: - `bridge`: keeps both legs on the platform. It is the default when omitted or empty. - `refer`: transfers the call with a SIP REFER. Another value is refused on publish. string **outputs** Array\ object **type** string **description** string **question** object **v1** Array\ object **id** required string **description** string **properties** object **tts\_properties** object **language** string **voice** string **engine** string **speed** number format: float **model** string **dtmf\_properties** object **dtmf\_timeout** number format: float **no\_input\_timeout** number format: float **min\_symbols** integer **max\_symbols** integer **finish\_on\_key** string **stt\_properties** object **speech\_timeout** number format: float **no\_input\_timeout** number format: float **language** string **recognition\_shift** object **direction** The direction the recognition window moves, by `duration`. string Allowed values: backward forward **duration** number format: float **engine** string Allowed values: gsr gsr\@v2 azuresr experimental mohir soniox elevenlabs **grammar\_parameter** object **parameters** Array\ object **key** string **value** string **class\_token** object **tokens** Array\ **filter** object **filters** Array\ **tokens** Array\ **intent\_properties** object **classifier** The classifier a question brick classifies against. object **id** string **version** Pins the classifier version this brick classifies against. Rules: - `0` is an ordinary version, the one a classifier is created at. - A read always states it. - On a write, omitting it is the same as sending `0`. integer **model\_id** Identifies the intent model the caller chose for this brick. Rules: - It is stored as sent. - It is returned when set. - The platform does not read it. string **llm\_properties** object **engine** string **model** string **messages** Array\ object **role** The party the chat message is attributed to. string Allowed values: system assistant user function **content** string **temperature** number format: float **provider** string **gdpr\_required** boolean **threshold** number format: float **timezone** string **recognition\_mode** string **enable\_voice\_activity\_detection** boolean **interruptible\_dialog** boolean **interruption\_shift** object **direction** The direction the recognition window moves, by `duration`. string Allowed values: backward forward **duration** number format: float **model** string **primary\_language** string **fallback\_languages** Array\ **endpoint\_detection** Ends the caller’s turn when the recognition engine reports the end of the phrase, before the speech timeout. Rules: - A call reads it from the settings of a question. - A call reads it from the settings of an AI agent. - A call does not read it from `stt_general`. object **enabled** Switches endpoint detection on. Values: - `true`: is allowed only where the `engine` of the same settings is `soniox`. - `false`: the other values are stored and not checked. boolean **latency\_adjustment\_level** Sets the engine’s endpoint latency adjustment level, from 0 to 3. Omitting it is the same as sending 0. integer **sensitivity** Sets the engine’s endpoint sensitivity, from -1.0 to 1.0. Omitting it is the same as sending 0. number format: float **max\_delay\_ms** Sets the engine’s maximum endpoint delay in milliseconds, from 500 to 3000. Required while `enabled` is true. integer **statement** object **audio** object **mode** string **tts** object **text** string **file** object **url** string **is\_interruptible** boolean **type** Picks the question shape. Values: - `closed`: branches on a match in `answer.answers`, which must then be non-empty. - `open`: branches on `valid`. Any other value is refused on publish. string **input\_mode** Picks how the reply is captured. Values: - `dtmf`: needs `dtmf_properties`. - `speech`: needs `stt_properties`. Anything else fails a publish. string **answer** object **answers** Array\ object **answer\_id** string **description** string **speech\_input** object **tokens** Array\ **mode** How the answer is matched against what the person said. string Allowed values: token-based intent-based intent-llm-based token-llm-based token-intent-llm-based **intent** object **id** string **entity** object **entities** Array\ object **type** string **variable** object **name** string **dtmf\_input** object **value** string **tag** string **fallback\_invalid** object **fallbacks** Array\ Sets one fallback of a question brick. `llm_properties` is stored only when `type` is `llm`; on any other fallback, and on one with no `type`, it is dropped on save. object **is\_repeat\_statement** boolean **audio** object **mode** string **tts** object **text** string **file** object **url** string **is\_interruptible** boolean **type** Picks what the fallback plays. Values: - `initial`: repeats the question’s own statement. - `custom`: plays the fallback’s own audio. - `llm`: generates a reply. string Allowed values: initial custom llm **llm\_properties** object **engine** string **model** string **messages** Array\ object **role** The party the chat message is attributed to. string Allowed values: system assistant user function **content** string **temperature** number format: float **provider** string **gdpr\_required** boolean **entity** object **entities** Array\ object **type** string **variable** object **name** string **fallback\_empty** object **fallbacks** Array\ Sets one fallback of a question brick. `llm_properties` is stored only when `type` is `llm`; on any other fallback, and on one with no `type`, it is dropped on save. object **is\_repeat\_statement** boolean **audio** object **mode** string **tts** object **text** string **file** object **url** string **is\_interruptible** boolean **type** Picks what the fallback plays. Values: - `initial`: repeats the question’s own statement. - `custom`: plays the fallback’s own audio. - `llm`: generates a reply. string Allowed values: initial custom llm **llm\_properties** object **engine** string **model** string **messages** Array\ object **role** The party the chat message is attributed to. string Allowed values: system assistant user function **content** string **temperature** number format: float **provider** string **gdpr\_required** boolean **entity** object **entities** Array\ object **type** string **variable** object **name** string **outputs** Array\ object **type** string **description** string **webhook** object **v1** Array\ object **id** required string **description** string **properties** object **request** required object **method** required string **url** required string **body** object **data** string **type** string **form\_values** Array\ object **name** string **value** string **authentication** object **type** string **basic** object **username** string **password** string **bearer** object **token** string **header** object **headers** Array\ object **name** string **value** string **insecure\_skip\_verify** boolean **proxy** object **url** string **attach\_call\_metadata** boolean **timeout** number format: float **options** object **async** boolean **timeout** number format: float **response\_mapping** object **variables** Array\ object **name** Names the target variable, written as a placeholder. Returned unwrapped in `variables`. string /^\\{\\{\[A-Za-z0-9\\-\_.]+\\}\\}$/ **source** Picks where the value is read from. Values: - `body`: `path` holds a JSONPath. - `header`: `path` holds the header name. string **path** string **set\_if\_not\_found** string **outputs** Array\ object **type** string **description** string **data\_mapping** object **v1** Array\ object **id** required string **description** string **properties** object **input** string **variables** Array\ object **name** string **path** string **set\_if\_not\_found** string **outputs** Array\ object **type** string **description** string **tree** object **v1** Array\ object **id** required string **description** string **properties** object **tree** object **id** string **outputs** Array\ object **type** string **description** string **end\_tree** object **v1** Array\ object **id** required string **description** string **properties** object **output** object **type** string **description** string **outputs** Array\ object **type** string **description** string **background\_audio** object **v1** Array\ object **id** required string **description** string **properties** object **audio** object **audios** Array\ object **mode** string **file\_properties** object **url** string **volume** integer **outputs** Array\ object **type** string **description** string **javascript** object **v1** Array\ object **id** required string **description** string **properties** object **id** required Names the deployed edge function version the brick runs, as its uuid. Refused when: - A publish carries an empty value. - A publish carries a value that is not a uuid. string **input\_variables** Array\ **outputs** Array\ object **type** string **description** string **warm\_up\_tts** object **v1** Array\ object **id** required string **description** string **properties** object **brick** object **bricks** Array\ object **id** string **type** string **outputs** Array\ object **type** string **description** string **business\_metric** object **v1** Array\ object **id** required string **description** string **properties** object **key** string **value** string **outputs** Array\ object **type** string **description** string **ai\_agent** object **v1** Array\ object **id** required string **description** required string **properties** object **prompts** object **restrictions** object **content** string **role** object **content** string **initial\_phrase** object **content** string **is\_interruptible** boolean **skill** object **skills** Array\ object **id** required string **name** string **function\_name** string **description** required string **parameters** object **type** string **properties** object ***key*** additional properties object **type** string **description** string **variable\_name** string **enum** Array\ **default** string **required** Array\ **additional\_properties** boolean **knowledge\_base** object **type** string **prompt** object **content** string **rag** object **document** object **ids** Array\ **number** integer **threshold** number format: float **fallbacks** object **error** object **counter** integer **empty** object **counter** integer **configuration** object **llm** object **engine** string **model** string **temperature** Sets the sampling temperature of the model, from 0 to 1. `0` or no value uses the default of the model. number format: float **max\_tokens** integer **provider** string **gdpr\_required** boolean **tts** object **language** string **voice** string **engine** string **speed** number format: float **model** string **stt** object **speech\_timeout** number format: float **no\_input\_timeout** number format: float **language** string **recognition\_shift** object **direction** The direction the recognition window moves, by `duration`. string Allowed values: backward forward **duration** number format: float **engine** string Allowed values: gsr gsr\@v2 azuresr experimental mohir soniox elevenlabs **grammar\_parameter** object **parameters** Array\ object **key** string **value** string **class\_token** object **tokens** Array\ **filter** object **filters** Array\ **tokens** Array\ **intent\_properties** object **classifier** The classifier a question brick classifies against. object **id** string **version** Pins the classifier version this brick classifies against. Rules: - `0` is an ordinary version, the one a classifier is created at. - A read always states it. - On a write, omitting it is the same as sending `0`. integer **model\_id** Identifies the intent model the caller chose for this brick. Rules: - It is stored as sent. - It is returned when set. - The platform does not read it. string **llm\_properties** object **engine** string **model** string **messages** Array\ object **role** The party the chat message is attributed to. string Allowed values: system assistant user function **content** string **temperature** number format: float **provider** string **gdpr\_required** boolean **threshold** number format: float **timezone** string **recognition\_mode** string **enable\_voice\_activity\_detection** boolean **interruptible\_dialog** boolean **interruption\_shift** object **direction** The direction the recognition window moves, by `duration`. string Allowed values: backward forward **duration** number format: float **model** string **primary\_language** string **fallback\_languages** Array\ **endpoint\_detection** Ends the caller’s turn when the recognition engine reports the end of the phrase, before the speech timeout. Rules: - A call reads it from the settings of a question. - A call reads it from the settings of an AI agent. - A call does not read it from `stt_general`. object **enabled** Switches endpoint detection on. Values: - `true`: is allowed only where the `engine` of the same settings is `soniox`. - `false`: the other values are stored and not checked. boolean **latency\_adjustment\_level** Sets the engine’s endpoint latency adjustment level, from 0 to 3. Omitting it is the same as sending 0. integer **sensitivity** Sets the engine’s endpoint sensitivity, from -1.0 to 1.0. Omitting it is the same as sending 0. number format: float **max\_delay\_ms** Sets the engine’s maximum endpoint delay in milliseconds, from 500 to 3000. Required while `enabled` is true. integer **dialog** object **context\_mode** string **max\_turns** integer **outputs** Array\ object **type** string **description** string **send\_dtmf** object **v1** Array\ object **id** required string **description** required string **properties** object **digits** string **interval** integer **duration** integer **outputs** Array\ object **type** string **description** string **recording\_setup** object **v1** Array\ object **id** required string **description** required string **properties** object **outputs** Array\ object **type** string **description** string **transcription** object **v1** Array\ object **id** required string **description** required string **properties** object **request** object **requests** Array\ object **source** object **type** Picks what is transcribed. Values: - `last_recording`: the call’s last recording is transcribed. - `url`: audio fetched from `url` is transcribed. string Allowed values: last\_recording url **url** string **engine** The engine that transcribes the source. string Allowed values: whisper **prompt** string **model** string **outputs** Array\ object **type** string **description** string **forest** object **trees** Array\ object **description** string **tree\_id** string **nodes** Array\ object **id** string **brick** object **id** string **type** string Allowed values: ai\_agent assignment audio audio\_file audio\_tts background\_audio call\_transfer condition\_group data\_mapping end end\_call end\_tree goal inbound\_call increment javascript outbound\_call question sms start\_call start\_tree transcription tree warm\_up\_tts webhook **version** string **links** Array\ object **output\_type** string **reference** object **tree\_id** string **node\_id** string **return** object **tree\_id** string **node\_id** string **position** Any of: object **x** required number format: double **y** required number format: double null **properties** object **engine\_version** Any value sent is stored as v3. string Allowed values: v3 null **created\_at** required string format: date-time ##### Example ``` { "snapshot": { "constructor": { "bricks": { "audio": { "v1": [ { "properties": { "play_mode": "all" } } ] }, "condition_group": { "v1": [ { "properties": { "condition": { "conditions": [ { "condition_operator": "and", "elements": [ { "element_operator": "equal" } ] } ] } } } ] }, "start_call": { "v1": [ { "properties": { "stt_general": { "engine": "gsr" } } } ], "v2": [ { "properties": { "stt_general": { "engine": "gsr" } } } ] }, "question": { "v1": [ { "properties": { "stt_properties": { "recognition_shift": { "direction": "backward" }, "engine": "gsr", "intent_properties": { "llm_properties": { "messages": [ { "role": "system" } ] } }, "interruption_shift": { "direction": "backward" } }, "answer": { "answers": [ { "speech_input": { "mode": "token-based" } } ] }, "fallback_invalid": { "fallbacks": [ { "type": "initial", "llm_properties": { "messages": [ { "role": "system" } ] } } ] }, "fallback_empty": { "fallbacks": [ { "type": "initial", "llm_properties": { "messages": [ { "role": "system" } ] } } ] } } } ] }, "ai_agent": { "v1": [ { "properties": { "configuration": { "stt": { "recognition_shift": { "direction": "backward" }, "engine": "gsr", "intent_properties": { "llm_properties": { "messages": [ { "role": "system" } ] } }, "interruption_shift": { "direction": "backward" } } } } } ] }, "transcription": { "v1": [ { "properties": { "request": { "requests": [ { "source": { "type": "last_recording" }, "engine": "whisper" } ] } } } ] } }, "forest": { "trees": [ { "nodes": [ { "brick": { "type": "ai_agent" } } ] } ] }, "properties": { "engine_version": "v3" } } } } ``` ### 400 Bad request Media typeapplication/json object **error** required Carries the stable lower\_snake\_case usecase code, such as `scenario_not_found`. string **code** required Carries the registered machine code, stable once assigned. The codes: - `ERRxxx`: is a generic code that follows from the status class. - `ERR001`–`ERR020`: are reserved for generic codes. - `SCN1xx` and other entity-prefixed codes: appear only inside validation details. string **message** required string **data** Carries structured detail, present only where there is structure to carry it. By failure: - A validation failure carries the topic `validation` and per-entity `errors`. - A delete conflict carries the topic `conflict`; its referencing dependents are in `agents`, `automations`, `routings`, `users` or `roles`, depending on what holds the resource. - A scenario publish refused because of its agents carries the topic `conflict`, with `agents`. - An agent change refused because of its automations carries the topic `conflict`, with `automations`. - A file none of whose rows is usable carries the topic `rows_rejected`, with `rows` and `reasons`. - Contact data past a limit of its account carries `trigger`, `field` and `params`. - A data field rename that cannot be applied carries `field` and, when a contact stops it, `contact`. - A contact number that is refused carries `reason`. object **topic** string **reason** Names why a number or a row is refused. Values: - `number_missing`: the number is missing or blank. - `number_no_digits`: the number holds no digits. - `identifier_invalid`: an alphanumeric identifier does not start with a letter or a digit. - `number_not_international`: the number is written as international and is not a valid one. - `number_not_for_country`: the number is not valid for the stated `country_code`. - `country_code_required`: the number is not international, and no `country_code` was stated to read it by. - `value_too_long`: a data value is longer than the account’s value limit in bytes. Given for a row only. - `type_mismatch`: a data value does not read as the type its field holds across the account’s contacts. Given for a row only. string Allowed values: number\_missing number\_no\_digits identifier\_invalid number\_not\_international number\_not\_for\_country country\_code\_required value\_too\_long type\_mismatch **errors** Groups the validation errors by entity. object **scenario** Array\ object **code** Carries the SCN1xx constructor validation code. string **message** string **summary** string **tree\_id** string **node\_id** string **output\_type** string **duplicate\_tree\_index** string **duplicate\_node\_index** string **property** string **invalid\_value** string **agents** Lists the agents a delete or a scenario publish was rejected for, capped at the first 20; `message` carries the total count. Array\ An agent a delete or a scenario publish was rejected for. object **id** required string **name** required string **automations** Lists the live automations referencing the resource a delete was rejected for, capped at the first 20; `message` carries the total count. Array\ A live automation that holds the resource a delete was rejected for. object **id** required string **name** required string **routings** Lists the live routings of agents that are not archived whose condition or scenario holds the resource a delete was rejected for, capped at the first 20; `message` carries the total count. Array\ A live routing of an agent that is not archived, which holds the resource a delete was rejected for. object **id** required string **name** required string **agent\_sid** required string **users** Lists the live users holding the role a delete was rejected for, capped at the first 20; `message` carries the total count. Array\ A live user that holds the role a delete was rejected for. object **id** required string **email** required string **roles** Lists the live roles inheriting the role a delete was rejected for, capped at the first 20; `message` carries the total count. Array\ A live role that inherits the role a delete was rejected for. object **id** required string **name** required string **rows** Lists the rows of the refused file, a row repeating an earlier row’s number as written counted once. integer format: int64 **reasons** How many rows of a refused file were rejected for each reason; a reason no row had is absent. object **number\_missing** The number cell is blank. integer format: int64 **number\_no\_digits** The number holds no digits. integer format: int64 **identifier\_invalid** An alphanumeric identifier does not start with a letter or a digit. integer format: int64 **number\_not\_international** The number is written as international and is not a valid one. integer format: int64 **number\_not\_for\_country** The number is not valid for the stated `country_code`. integer format: int64 **country\_code\_required** The number is not international, and no `country_code` was stated to read it by. integer format: int64 **value\_too\_long** A data cell holds a value longer than the account’s value limit in bytes. integer format: int64 **type\_mismatch** A data cell does not read as the type its field holds across the account’s contacts. integer format: int64 **trigger** Names the rule the contact data breaks. Values: - `array_item_not_scalar`: an array item is an object, an array or null. - `type_mismatch`: a value has another type than its field holds across the account’s contacts, or is an object where the field holds a value, or a value where it holds an object. string Allowed values: too\_many\_fields value\_too\_long too\_many\_array\_items array\_item\_not\_scalar type\_mismatch **field** Names the field by its path. By failure: - For a broken limit, it is the field that breaks the limit. - For too many fields, it is the first new field past the limit. - For a rename, it is the field that stops the rename. string **contact** Names the first contact whose data stops a rename; absent when the two paths alone conflict. string **params** Carries the details of the breach. By breach: - For a broken limit, it carries the numbers of the limit. - For a type mismatch, it carries the two types. - For an array item that is not a scalar, it is empty. object **limit** Reports the account’s limit. integer **current** Reports the value the data would have: the fields, the bytes or the items. integer **type** Names the type the field holds across the account’s contacts. string **got** Names the type of the new value. string **error** required One of: Refuses a request whose form is wrong. Returned when: - The body, a path parameter or a query parameter does not parse. - `Content-Encoding` names a compression the API does not accept, or the body cannot be decompressed as named. - A brick to validate names a type or a version the API does not know. - A data field path or a column name in the body is not well formed, or a key of a row’s `data` is empty or holds a dot. - A node `position` in the constructor of a scenario save carries one of `x` and `y` without the other. - The operation needs a WebSocket upgrade, and the request is not one. `message` names what failed. string Allowed values: bad\_request The credential acts for a tenant or for the platform, and the request names no account in `X-Account-Sid` (or no tenant in `X-Tenant-Sid`). string Allowed values: missing\_scope\_header Refuses the value of the scope header. Returned when: - The scope header names an account or tenant the credential does not cover. - The scope header carries a value that is not an id of that kind. string Allowed values: scope\_conflict ##### Example ``` { "data": { "reason": "number_missing", "trigger": "too_many_fields" }, "error": "bad_request" } ``` ### 401 Unauthorized Media typeapplication/json object **error** required Carries the stable lower\_snake\_case usecase code, such as `scenario_not_found`. string **code** required Carries the registered machine code, stable once assigned. The codes: - `ERRxxx`: is a generic code that follows from the status class. - `ERR001`–`ERR020`: are reserved for generic codes. - `SCN1xx` and other entity-prefixed codes: appear only inside validation details. string **message** required string **data** Carries structured detail, present only where there is structure to carry it. By failure: - A validation failure carries the topic `validation` and per-entity `errors`. - A delete conflict carries the topic `conflict`; its referencing dependents are in `agents`, `automations`, `routings`, `users` or `roles`, depending on what holds the resource. - A scenario publish refused because of its agents carries the topic `conflict`, with `agents`. - An agent change refused because of its automations carries the topic `conflict`, with `automations`. - A file none of whose rows is usable carries the topic `rows_rejected`, with `rows` and `reasons`. - Contact data past a limit of its account carries `trigger`, `field` and `params`. - A data field rename that cannot be applied carries `field` and, when a contact stops it, `contact`. - A contact number that is refused carries `reason`. object **topic** string **reason** Names why a number or a row is refused. Values: - `number_missing`: the number is missing or blank. - `number_no_digits`: the number holds no digits. - `identifier_invalid`: an alphanumeric identifier does not start with a letter or a digit. - `number_not_international`: the number is written as international and is not a valid one. - `number_not_for_country`: the number is not valid for the stated `country_code`. - `country_code_required`: the number is not international, and no `country_code` was stated to read it by. - `value_too_long`: a data value is longer than the account’s value limit in bytes. Given for a row only. - `type_mismatch`: a data value does not read as the type its field holds across the account’s contacts. Given for a row only. string Allowed values: number\_missing number\_no\_digits identifier\_invalid number\_not\_international number\_not\_for\_country country\_code\_required value\_too\_long type\_mismatch **errors** Groups the validation errors by entity. object **scenario** Array\ object **code** Carries the SCN1xx constructor validation code. string **message** string **summary** string **tree\_id** string **node\_id** string **output\_type** string **duplicate\_tree\_index** string **duplicate\_node\_index** string **property** string **invalid\_value** string **agents** Lists the agents a delete or a scenario publish was rejected for, capped at the first 20; `message` carries the total count. Array\ An agent a delete or a scenario publish was rejected for. object **id** required string **name** required string **automations** Lists the live automations referencing the resource a delete was rejected for, capped at the first 20; `message` carries the total count. Array\ A live automation that holds the resource a delete was rejected for. object **id** required string **name** required string **routings** Lists the live routings of agents that are not archived whose condition or scenario holds the resource a delete was rejected for, capped at the first 20; `message` carries the total count. Array\ A live routing of an agent that is not archived, which holds the resource a delete was rejected for. object **id** required string **name** required string **agent\_sid** required string **users** Lists the live users holding the role a delete was rejected for, capped at the first 20; `message` carries the total count. Array\ A live user that holds the role a delete was rejected for. object **id** required string **email** required string **roles** Lists the live roles inheriting the role a delete was rejected for, capped at the first 20; `message` carries the total count. Array\ A live role that inherits the role a delete was rejected for. object **id** required string **name** required string **rows** Lists the rows of the refused file, a row repeating an earlier row’s number as written counted once. integer format: int64 **reasons** How many rows of a refused file were rejected for each reason; a reason no row had is absent. object **number\_missing** The number cell is blank. integer format: int64 **number\_no\_digits** The number holds no digits. integer format: int64 **identifier\_invalid** An alphanumeric identifier does not start with a letter or a digit. integer format: int64 **number\_not\_international** The number is written as international and is not a valid one. integer format: int64 **number\_not\_for\_country** The number is not valid for the stated `country_code`. integer format: int64 **country\_code\_required** The number is not international, and no `country_code` was stated to read it by. integer format: int64 **value\_too\_long** A data cell holds a value longer than the account’s value limit in bytes. integer format: int64 **type\_mismatch** A data cell does not read as the type its field holds across the account’s contacts. integer format: int64 **trigger** Names the rule the contact data breaks. Values: - `array_item_not_scalar`: an array item is an object, an array or null. - `type_mismatch`: a value has another type than its field holds across the account’s contacts, or is an object where the field holds a value, or a value where it holds an object. string Allowed values: too\_many\_fields value\_too\_long too\_many\_array\_items array\_item\_not\_scalar type\_mismatch **field** Names the field by its path. By failure: - For a broken limit, it is the field that breaks the limit. - For too many fields, it is the first new field past the limit. - For a rename, it is the field that stops the rename. string **contact** Names the first contact whose data stops a rename; absent when the two paths alone conflict. string **params** Carries the details of the breach. By breach: - For a broken limit, it carries the numbers of the limit. - For a type mismatch, it carries the two types. - For an array item that is not a scalar, it is empty. object **limit** Reports the account’s limit. integer **current** Reports the value the data would have: the fields, the bytes or the items. integer **type** Names the type the field holds across the account’s contacts. string **got** Names the type of the new value. string **error** required One of: Refuses a request that cannot be authenticated. Returned when: - The request carries no usable credential. - The user, account or tenant behind the credential is not active. string Allowed values: unauthenticated ##### Example ``` { "data": { "reason": "number_missing", "trigger": "too_many_fields" }, "error": "unauthenticated" } ``` ### 403 Forbidden Media typeapplication/json object **error** required Carries the stable lower\_snake\_case usecase code, such as `scenario_not_found`. string **code** required Carries the registered machine code, stable once assigned. The codes: - `ERRxxx`: is a generic code that follows from the status class. - `ERR001`–`ERR020`: are reserved for generic codes. - `SCN1xx` and other entity-prefixed codes: appear only inside validation details. string **message** required string **data** Carries structured detail, present only where there is structure to carry it. By failure: - A validation failure carries the topic `validation` and per-entity `errors`. - A delete conflict carries the topic `conflict`; its referencing dependents are in `agents`, `automations`, `routings`, `users` or `roles`, depending on what holds the resource. - A scenario publish refused because of its agents carries the topic `conflict`, with `agents`. - An agent change refused because of its automations carries the topic `conflict`, with `automations`. - A file none of whose rows is usable carries the topic `rows_rejected`, with `rows` and `reasons`. - Contact data past a limit of its account carries `trigger`, `field` and `params`. - A data field rename that cannot be applied carries `field` and, when a contact stops it, `contact`. - A contact number that is refused carries `reason`. object **topic** string **reason** Names why a number or a row is refused. Values: - `number_missing`: the number is missing or blank. - `number_no_digits`: the number holds no digits. - `identifier_invalid`: an alphanumeric identifier does not start with a letter or a digit. - `number_not_international`: the number is written as international and is not a valid one. - `number_not_for_country`: the number is not valid for the stated `country_code`. - `country_code_required`: the number is not international, and no `country_code` was stated to read it by. - `value_too_long`: a data value is longer than the account’s value limit in bytes. Given for a row only. - `type_mismatch`: a data value does not read as the type its field holds across the account’s contacts. Given for a row only. string Allowed values: number\_missing number\_no\_digits identifier\_invalid number\_not\_international number\_not\_for\_country country\_code\_required value\_too\_long type\_mismatch **errors** Groups the validation errors by entity. object **scenario** Array\ object **code** Carries the SCN1xx constructor validation code. string **message** string **summary** string **tree\_id** string **node\_id** string **output\_type** string **duplicate\_tree\_index** string **duplicate\_node\_index** string **property** string **invalid\_value** string **agents** Lists the agents a delete or a scenario publish was rejected for, capped at the first 20; `message` carries the total count. Array\ An agent a delete or a scenario publish was rejected for. object **id** required string **name** required string **automations** Lists the live automations referencing the resource a delete was rejected for, capped at the first 20; `message` carries the total count. Array\ A live automation that holds the resource a delete was rejected for. object **id** required string **name** required string **routings** Lists the live routings of agents that are not archived whose condition or scenario holds the resource a delete was rejected for, capped at the first 20; `message` carries the total count. Array\ A live routing of an agent that is not archived, which holds the resource a delete was rejected for. object **id** required string **name** required string **agent\_sid** required string **users** Lists the live users holding the role a delete was rejected for, capped at the first 20; `message` carries the total count. Array\ A live user that holds the role a delete was rejected for. object **id** required string **email** required string **roles** Lists the live roles inheriting the role a delete was rejected for, capped at the first 20; `message` carries the total count. Array\ A live role that inherits the role a delete was rejected for. object **id** required string **name** required string **rows** Lists the rows of the refused file, a row repeating an earlier row’s number as written counted once. integer format: int64 **reasons** How many rows of a refused file were rejected for each reason; a reason no row had is absent. object **number\_missing** The number cell is blank. integer format: int64 **number\_no\_digits** The number holds no digits. integer format: int64 **identifier\_invalid** An alphanumeric identifier does not start with a letter or a digit. integer format: int64 **number\_not\_international** The number is written as international and is not a valid one. integer format: int64 **number\_not\_for\_country** The number is not valid for the stated `country_code`. integer format: int64 **country\_code\_required** The number is not international, and no `country_code` was stated to read it by. integer format: int64 **value\_too\_long** A data cell holds a value longer than the account’s value limit in bytes. integer format: int64 **type\_mismatch** A data cell does not read as the type its field holds across the account’s contacts. integer format: int64 **trigger** Names the rule the contact data breaks. Values: - `array_item_not_scalar`: an array item is an object, an array or null. - `type_mismatch`: a value has another type than its field holds across the account’s contacts, or is an object where the field holds a value, or a value where it holds an object. string Allowed values: too\_many\_fields value\_too\_long too\_many\_array\_items array\_item\_not\_scalar type\_mismatch **field** Names the field by its path. By failure: - For a broken limit, it is the field that breaks the limit. - For too many fields, it is the first new field past the limit. - For a rename, it is the field that stops the rename. string **contact** Names the first contact whose data stops a rename; absent when the two paths alone conflict. string **params** Carries the details of the breach. By breach: - For a broken limit, it carries the numbers of the limit. - For a type mismatch, it carries the two types. - For an array item that is not a scalar, it is empty. object **limit** Reports the account’s limit. integer **current** Reports the value the data would have: the fields, the bytes or the items. integer **type** Names the type the field holds across the account’s contacts. string **got** Names the type of the new value. string **error** required One of: The credential is valid and in scope, but the caller’s roles do not grant the permission the operation needs. string Allowed values: permission\_denied ##### Example ``` { "data": { "reason": "number_missing", "trigger": "too_many_fields" }, "error": "permission_denied" } ``` ### 404 Not found Media typeapplication/json object **error** required Carries the stable lower\_snake\_case usecase code, such as `scenario_not_found`. string **code** required Carries the registered machine code, stable once assigned. The codes: - `ERRxxx`: is a generic code that follows from the status class. - `ERR001`–`ERR020`: are reserved for generic codes. - `SCN1xx` and other entity-prefixed codes: appear only inside validation details. string **message** required string **data** Carries structured detail, present only where there is structure to carry it. By failure: - A validation failure carries the topic `validation` and per-entity `errors`. - A delete conflict carries the topic `conflict`; its referencing dependents are in `agents`, `automations`, `routings`, `users` or `roles`, depending on what holds the resource. - A scenario publish refused because of its agents carries the topic `conflict`, with `agents`. - An agent change refused because of its automations carries the topic `conflict`, with `automations`. - A file none of whose rows is usable carries the topic `rows_rejected`, with `rows` and `reasons`. - Contact data past a limit of its account carries `trigger`, `field` and `params`. - A data field rename that cannot be applied carries `field` and, when a contact stops it, `contact`. - A contact number that is refused carries `reason`. object **topic** string **reason** Names why a number or a row is refused. Values: - `number_missing`: the number is missing or blank. - `number_no_digits`: the number holds no digits. - `identifier_invalid`: an alphanumeric identifier does not start with a letter or a digit. - `number_not_international`: the number is written as international and is not a valid one. - `number_not_for_country`: the number is not valid for the stated `country_code`. - `country_code_required`: the number is not international, and no `country_code` was stated to read it by. - `value_too_long`: a data value is longer than the account’s value limit in bytes. Given for a row only. - `type_mismatch`: a data value does not read as the type its field holds across the account’s contacts. Given for a row only. string Allowed values: number\_missing number\_no\_digits identifier\_invalid number\_not\_international number\_not\_for\_country country\_code\_required value\_too\_long type\_mismatch **errors** Groups the validation errors by entity. object **scenario** Array\ object **code** Carries the SCN1xx constructor validation code. string **message** string **summary** string **tree\_id** string **node\_id** string **output\_type** string **duplicate\_tree\_index** string **duplicate\_node\_index** string **property** string **invalid\_value** string **agents** Lists the agents a delete or a scenario publish was rejected for, capped at the first 20; `message` carries the total count. Array\ An agent a delete or a scenario publish was rejected for. object **id** required string **name** required string **automations** Lists the live automations referencing the resource a delete was rejected for, capped at the first 20; `message` carries the total count. Array\ A live automation that holds the resource a delete was rejected for. object **id** required string **name** required string **routings** Lists the live routings of agents that are not archived whose condition or scenario holds the resource a delete was rejected for, capped at the first 20; `message` carries the total count. Array\ A live routing of an agent that is not archived, which holds the resource a delete was rejected for. object **id** required string **name** required string **agent\_sid** required string **users** Lists the live users holding the role a delete was rejected for, capped at the first 20; `message` carries the total count. Array\ A live user that holds the role a delete was rejected for. object **id** required string **email** required string **roles** Lists the live roles inheriting the role a delete was rejected for, capped at the first 20; `message` carries the total count. Array\ A live role that inherits the role a delete was rejected for. object **id** required string **name** required string **rows** Lists the rows of the refused file, a row repeating an earlier row’s number as written counted once. integer format: int64 **reasons** How many rows of a refused file were rejected for each reason; a reason no row had is absent. object **number\_missing** The number cell is blank. integer format: int64 **number\_no\_digits** The number holds no digits. integer format: int64 **identifier\_invalid** An alphanumeric identifier does not start with a letter or a digit. integer format: int64 **number\_not\_international** The number is written as international and is not a valid one. integer format: int64 **number\_not\_for\_country** The number is not valid for the stated `country_code`. integer format: int64 **country\_code\_required** The number is not international, and no `country_code` was stated to read it by. integer format: int64 **value\_too\_long** A data cell holds a value longer than the account’s value limit in bytes. integer format: int64 **type\_mismatch** A data cell does not read as the type its field holds across the account’s contacts. integer format: int64 **trigger** Names the rule the contact data breaks. Values: - `array_item_not_scalar`: an array item is an object, an array or null. - `type_mismatch`: a value has another type than its field holds across the account’s contacts, or is an object where the field holds a value, or a value where it holds an object. string Allowed values: too\_many\_fields value\_too\_long too\_many\_array\_items array\_item\_not\_scalar type\_mismatch **field** Names the field by its path. By failure: - For a broken limit, it is the field that breaks the limit. - For too many fields, it is the first new field past the limit. - For a rename, it is the field that stops the rename. string **contact** Names the first contact whose data stops a rename; absent when the two paths alone conflict. string **params** Carries the details of the breach. By breach: - For a broken limit, it carries the numbers of the limit. - For a type mismatch, it carries the two types. - For an array item that is not a scalar, it is empty. object **limit** Reports the account’s limit. integer **current** Reports the value the data would have: the fields, the bytes or the items. integer **type** Names the type the field holds across the account’s contacts. string **got** Names the type of the new value. string **error** required One of: Refuses an identifier that names no resource the caller can use. Returned when: - No live resource with this identifier is visible to the caller. - The resource the identifier names belongs to another account. string Allowed values: not\_found Refuses a scenario id the caller cannot see. Returned when: - No scenario with this id exists. - The scenario belongs to an account outside the caller’s tenant. - The scenario belongs to another account of the tenant and is not shared for copy. string Allowed values: scenario\_not\_found No version record of the scenario with this axis number and draft flag. string Allowed values: scenario\_version\_not\_found ##### Example ``` { "data": { "reason": "number_missing", "trigger": "too_many_fields" }, "error": "not_found" } ``` ### 500 Internal server error Media typeapplication/json object **error** required Carries the stable lower\_snake\_case usecase code, such as `scenario_not_found`. string **code** required Carries the registered machine code, stable once assigned. The codes: - `ERRxxx`: is a generic code that follows from the status class. - `ERR001`–`ERR020`: are reserved for generic codes. - `SCN1xx` and other entity-prefixed codes: appear only inside validation details. string **message** required string **data** Carries structured detail, present only where there is structure to carry it. By failure: - A validation failure carries the topic `validation` and per-entity `errors`. - A delete conflict carries the topic `conflict`; its referencing dependents are in `agents`, `automations`, `routings`, `users` or `roles`, depending on what holds the resource. - A scenario publish refused because of its agents carries the topic `conflict`, with `agents`. - An agent change refused because of its automations carries the topic `conflict`, with `automations`. - A file none of whose rows is usable carries the topic `rows_rejected`, with `rows` and `reasons`. - Contact data past a limit of its account carries `trigger`, `field` and `params`. - A data field rename that cannot be applied carries `field` and, when a contact stops it, `contact`. - A contact number that is refused carries `reason`. object **topic** string **reason** Names why a number or a row is refused. Values: - `number_missing`: the number is missing or blank. - `number_no_digits`: the number holds no digits. - `identifier_invalid`: an alphanumeric identifier does not start with a letter or a digit. - `number_not_international`: the number is written as international and is not a valid one. - `number_not_for_country`: the number is not valid for the stated `country_code`. - `country_code_required`: the number is not international, and no `country_code` was stated to read it by. - `value_too_long`: a data value is longer than the account’s value limit in bytes. Given for a row only. - `type_mismatch`: a data value does not read as the type its field holds across the account’s contacts. Given for a row only. string Allowed values: number\_missing number\_no\_digits identifier\_invalid number\_not\_international number\_not\_for\_country country\_code\_required value\_too\_long type\_mismatch **errors** Groups the validation errors by entity. object **scenario** Array\ object **code** Carries the SCN1xx constructor validation code. string **message** string **summary** string **tree\_id** string **node\_id** string **output\_type** string **duplicate\_tree\_index** string **duplicate\_node\_index** string **property** string **invalid\_value** string **agents** Lists the agents a delete or a scenario publish was rejected for, capped at the first 20; `message` carries the total count. Array\ An agent a delete or a scenario publish was rejected for. object **id** required string **name** required string **automations** Lists the live automations referencing the resource a delete was rejected for, capped at the first 20; `message` carries the total count. Array\ A live automation that holds the resource a delete was rejected for. object **id** required string **name** required string **routings** Lists the live routings of agents that are not archived whose condition or scenario holds the resource a delete was rejected for, capped at the first 20; `message` carries the total count. Array\ A live routing of an agent that is not archived, which holds the resource a delete was rejected for. object **id** required string **name** required string **agent\_sid** required string **users** Lists the live users holding the role a delete was rejected for, capped at the first 20; `message` carries the total count. Array\ A live user that holds the role a delete was rejected for. object **id** required string **email** required string **roles** Lists the live roles inheriting the role a delete was rejected for, capped at the first 20; `message` carries the total count. Array\ A live role that inherits the role a delete was rejected for. object **id** required string **name** required string **rows** Lists the rows of the refused file, a row repeating an earlier row’s number as written counted once. integer format: int64 **reasons** How many rows of a refused file were rejected for each reason; a reason no row had is absent. object **number\_missing** The number cell is blank. integer format: int64 **number\_no\_digits** The number holds no digits. integer format: int64 **identifier\_invalid** An alphanumeric identifier does not start with a letter or a digit. integer format: int64 **number\_not\_international** The number is written as international and is not a valid one. integer format: int64 **number\_not\_for\_country** The number is not valid for the stated `country_code`. integer format: int64 **country\_code\_required** The number is not international, and no `country_code` was stated to read it by. integer format: int64 **value\_too\_long** A data cell holds a value longer than the account’s value limit in bytes. integer format: int64 **type\_mismatch** A data cell does not read as the type its field holds across the account’s contacts. integer format: int64 **trigger** Names the rule the contact data breaks. Values: - `array_item_not_scalar`: an array item is an object, an array or null. - `type_mismatch`: a value has another type than its field holds across the account’s contacts, or is an object where the field holds a value, or a value where it holds an object. string Allowed values: too\_many\_fields value\_too\_long too\_many\_array\_items array\_item\_not\_scalar type\_mismatch **field** Names the field by its path. By failure: - For a broken limit, it is the field that breaks the limit. - For too many fields, it is the first new field past the limit. - For a rename, it is the field that stops the rename. string **contact** Names the first contact whose data stops a rename; absent when the two paths alone conflict. string **params** Carries the details of the breach. By breach: - For a broken limit, it carries the numbers of the limit. - For a type mismatch, it carries the two types. - For an array item that is not a scalar, it is empty. object **limit** Reports the account’s limit. integer **current** Reports the value the data would have: the fields, the bytes or the items. integer **type** Names the type the field holds across the account’s contacts. string **got** Names the type of the new value. string ##### Example ``` { "data": { "reason": "number_missing", "trigger": "too_many_fields" } } ``` ## Error codes | Status | Error | Meaning | | ------ | ---------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | 400 | `bad_request` | Refuses a request whose form is wrong. Returned when: - The body, a path parameter or a query parameter does not parse. - `Content-Encoding` names a compression the API does not accept, or the body cannot be decompressed as named. - A brick to validate names a type or a version the API does not know. - A data field path or a column name in the body is not well formed, or a key of a row's `data` is empty or holds a dot. - A node `position` in the constructor of a scenario save carries one of `x` and `y` without the other. - The operation needs a WebSocket upgrade, and the request is not one. `message` names what failed. | | 400 | `missing_scope_header` | The credential acts for a tenant or for the platform, and the request names no account in `X-Account-Sid` (or no tenant in `X-Tenant-Sid`). | | 400 | `scope_conflict` | Refuses the value of the scope header. Returned when: - The scope header names an account or tenant the credential does not cover. - The scope header carries a value that is not an id of that kind. | | 401 | `unauthenticated` | Refuses a request that cannot be authenticated. Returned when: - The request carries no usable credential. - The user, account or tenant behind the credential is not active. | | 403 | `permission_denied` | The credential is valid and in scope, but the caller's roles do not grant the permission the operation needs. | | 404 | `not_found` | Refuses an identifier that names no resource the caller can use. Returned when: - No live resource with this identifier is visible to the caller. - The resource the identifier names belongs to another account. | | 404 | `scenario_not_found` | Refuses a scenario id the caller cannot see. Returned when: - No scenario with this id exists. - The scenario belongs to an account outside the caller's tenant. - The scenario belongs to another account of the tenant and is not shared for copy. | | 404 | `scenario_version_not_found` | No version record of the scenario with this axis number and draft flag. |