JSON schema for channelData v3 response model

Description of the JSON schema for channelData v3 response model

General conventions

  • Properties corresponding to the response model can be general (applicable for all channels) or specific for TV channels. In order to identify the type(s) of each property, regarding the abovementioned classification, the following symbols will be used in the JSON schemas:
Types of properties Tags in JSOn schemas
General property (applicable for all channels) No tag in description
Specific property for TV channels
Currently: Movistar Plus, Movistar Home, STB
Tag [TV] in description
  • The mandatory parameters are included in the field required of each property in the corresponding JSON files.

JSON schema for channelData v3 response model

{
    "$schema": "http://json-schema.org/schema#",
    "$id": "resource:/aura-models/channel-data/3.1.0/response/channeldata-3.1.0-response.schema#",
    "$ref": "#/definitions/aura/bot/3.1.0/response/ResponseChannelData",
    "$version": "3.1.0",
    "definitions": {
        "aura": {
            "bot": {
                "3.1.0": {
                    "response": {
                        "ResponseChannelData": {
                            "type": "object",
                            "additionalProperties": false,
                            "properties": {
                                "intentResult": {
                                    "description": "Information about the intent and entities recognized by Aura.",
                                    "$ref": "#/definitions/aura/bot/3.1.0/response/IntentResult"
                                },
                                "actions": {
                                    "description": "Array of Actions, the actions available for this Aura response. It contains both general sub-properties and specific ones.",
                                    "type": "array",
                                    "items": {
                                        "$ref": "#/definitions/aura/bot/3.1.0/response/Action"
                                    }
                                },
                                "status": {
                                    "description": "Object describing the status of the request sent to the Aura bot instance.",
                                    "$ref": "#/definitions/aura/bot/3.1.0/response/Status"
                                },
                                "version": {
                                    "description": "This property encodes the version of the Aura Request - Response Semantic Model being used, so the structural dependencies and semantics of the data provided can be properly managed (e.g, 0.1, 0.2, 0.3, 1.0.0, 2.0.0, 3, 4, etc). Semantic versioning 2.0.0. (https://semver.org/) is used.",
                                    "type": "string",
                                    "pattern": "^[0-9]+(\\.[0-9]+){0,2}$"
                                },
                                "correlator": {
                                    "description": "This property contains an UUID (https://en.wikipedia.org/wiki/Universally_unique_identifier) uniquely identifying the concrete request sent through the channel. This unique identifier is of great help when doing cross system analysis, as a way to correlate the actions executed by distinct elements of the whole system associated to the fulfilment of the same request.In case the correlator property is not provided, the Aura bot will generate one and pass it over in any interaction with any external component.",
                                    "type": "string",
                                    "format": "uuid"
                                },
                                "payload": {
                                    "description": "Channel data payload information. This property can be used by an external component to aura-bot in order to send information for the enrichment of the request. Information is sent that does not correspond to the bot-framework communication model, but that aura-bot and certain dialogs use to complete processing. Currently it is used by components interacting with the bot through Aura bridge, but it could is used by any component.",
                                    "type": "object"
                                }
                            },
                            "title": "ChannelData"
                        },
                        "IntentResult": {
                            "type": "object",
                            "additionalProperties": false,
                            "properties": {
                                "name": {
                                    "description": "Intent name (the intent recognized, processed and resolved by Aura), such as STB_ACTION.PLAY_ON_TV or MEDIA.SEARCH.",
                                    "type": "string"
                                },
                                "entities": {
                                    "description": "Array of simplified entities detected by Aura (it may be empty)",
                                    "type": "array",
                                    "items": {
                                        "$ref": "#/definitions/aura/bot/3.1.0/response/SimplifyEntity"
                                    }
                                }
                            },
                            "required": [
                                "name"
                            ],
                            "title": "IntentResult"
                        },
                        "SimplifyEntity": {
                            "type": "object",
                            "additionalProperties": false,
                            "properties": {
                                "entity": {
                                    "description": "This property includes the value of the entity sent on behalf of the Telefónica client interacting with the Aura bot instance.",
                                    "type": "string"
                                },
                                "type": {
                                    "description": "This property includes the type of the entity sent on behalf of the Telefónica client interacting with the Aura bot instance. The format used by this property is the following one: ent.<entityType>",
                                    "type": "string"
                                }
                            },
                            "required": [
                                "entity",
                                "type"
                            ],
                            "title": "SimplifyEntity"
                        },
                        "Action": {
                            "type": "object",
                            "additionalProperties": false,
                            "properties": {
                                "name": {
                                    "description": "Action to be performed. Some values that this property can take are: 'CALL', 'SOUND'.",
                                    "type": "string"
                                },
                                "target": {
                                    "description": "Target for the action, such as 'stb'. If the action should be executed by the device used by the user to interact with Aura, the value should be 'channel'. The STB team should consider the value 'stb' and 'channel' indistinctly.",
                                    "type": "string"
                                },
                                "params": {
                                    "description": "An object with the required params for the action.",
                                    "oneOf": [
                                        {
                                            "type": "object"
                                        }
                                    ]
                                },
                                "postBack": {
                                    "description": "Action to be performed by the channel once the action is completed. Depending on the result, independent actions could be executed. This property may contain 2 possible exclusive properties: 'ok', containing auraCommand type properties; 'error', containing auraCommand type properties.",
                                    "$ref": "#/definitions/aura/bot/3.1.0/response/PostBack"
                                }
                            },
                            "required": [
                                "name",
                                "target"
                            ],
                            "title": "Action"
                        },
                        "PostBack": {
                            "type": "object",
                            "additionalProperties": false,
                            "properties": {
                                "ok": {
                                    "description": "Contains the command to send to Aura if the actions finalized without errors.",
                                    "$ref": "#/definitions/aura/bot/3.1.0/response/AuraCommand"
                                },
                                "error": {
                                    "description": "Contains the command to send to Aura if the actions finalized with errors.",
                                    "$ref": "#/definitions/aura/bot/3.1.0/response/AuraCommand"
                                }
                            },
                            "title": "PostBack"
                        },
                        "AuraCommand": {
                            "type": "object",
                            "additionalProperties": false,
                            "properties": {
                                "type": {
                                    "description": "Type of Aura command sent on behalf of the Telefónica client interacting with the Aura bot instance. The possible values of this property are:\n - 'intent': This type of Aura command is associated to sending an already known user intention.\n - 'suggestion': This type of Aura command is dedicated to send the suggestions provided by Aura Bot. The command must be returned as it was sent, without any change.\n - 'notification': this type of Aura command is associated to an intent generated by a notification sent by Aura Notifications System.\n - 'operation': this type of Aura command is associated to intents which need an already running dialog context in Aura. It is something like a sub-dialog within a main one.\n - 'text': this type of Aura command is intended for setting a given text in the value of the command. The result will be the same as setting the string as the text of the request.\n - 'event': this type of Aura command contains an event that happened in the channel and that must be informed to Aura bot so it can be handled properly, stored  in the context or kpis, for example.",
                                    "type": "string",
                                    "enum": [
                                        "intent",
                                        "suggestion",
                                        "notification",
                                        "operation",
                                        "text",
                                        "event"
                                    ]
                                },
                                "value": {
                                    "description": "This property includes the data needed to execute the command. Its content depends on the type of Aura command.",
                                    "anyOf": [
                                        {
                                            "$ref": "#/definitions/aura/bot/3.1.0/response/SuggestionValue"
                                        },
                                        {
                                            "$ref": "#/definitions/aura/bot/3.1.0/response/NotificationValue"
                                        },
                                        {
                                            "$ref": "#/definitions/aura/bot/3.1.0/response/EventValue"
                                        },
                                        {
                                            "type": "string"
                                        }
                                    ]
                                },
                                "utm": {
                                    "description": "It shows the exact interface element that was used by the user to launch the auraCommand.",
                                    "$ref": "#/definitions/aura/bot/3.1.0/response/Utm"
                                }
                            },
                            "required": [
                                "type",
                                "value"
                            ],
                            "title": "AuraCommand",
                            "allOf": [
                                {
                                    "if": {
                                        "properties": {
                                            "type": {
                                                "pattern": "intent|suggestion|operation"
                                            }
                                        }
                                    },
                                    "then": {
                                        "properties": {
                                            "value": {
                                                "$ref": "#/definitions/aura/bot/3.1.0/response/SuggestionValue"
                                            }
                                        }
                                    }
                                },
                                {
                                    "if": {
                                        "properties": {
                                            "type": {
                                                "const": "notification"
                                            }
                                        }
                                    },
                                    "then": {
                                        "properties": {
                                            "value": {
                                                "$ref": "#/definitions/aura/bot/3.1.0/response/NotificationValue"
                                            }
                                        }
                                    }
                                },
                                {
                                    "if": {
                                        "properties": {
                                            "type": {
                                                "const": "text"
                                            }
                                        }
                                    },
                                    "then": {
                                        "properties": {
                                            "value": {
                                                "type": "string"
                                            }
                                        }
                                    }
                                },
                                {
                                    "if": {
                                        "properties": {
                                            "type": {
                                                "const": "event"
                                            }
                                        }
                                    },
                                    "then": {
                                        "properties": {
                                            "value": {
                                                "$ref": "#/definitions/aura/bot/3.1.0/response/EventValue"
                                            }
                                        }
                                    }
                                }
                            ]
                        },
                        "SuggestionValue": {
                            "type": "object",
                            "additionalProperties": false,
                            "properties": {
                                "intent": {
                                    "description": "This property includes the Aura intention reference which will determine the Aura dialog to execute. The format of this property is: intent.<libraryId>.<intentId>. In case the prefix 'intent.' is not included in the value of this property, it will be included by default.",
                                    "type": "string"
                                },
                                "entities": {
                                    "description": "This property includes an array of additional information the Aura bot instance needs to properly accomplish the intent of the Telefónica client. Every entity is a JSON object including 2 properties: 'type':  this property includes a string stating the type of entity; 'entity': this property includes a string stating the value of the entity.",
                                    "type": "array",
                                    "items": {
                                        "$ref": "#/definitions/aura/bot/3.1.0/response/Entity"
                                    }
                                }
                            },
                            "required": [
                                "intent"
                            ],
                            "title": "SuggestionValue"
                        },
                        "NotificationValue": {
                            "type": "object",
                            "additionalProperties": false,
                            "properties": {
                                "action": {
                                    "description": "This property includes the Aura intention reference informing of which dialog is executed to accomplish the Telefónica client intent. The format of this property is: <libraryId>.<intentId>. As with the rest of intents, the Aura bot instance will add by default the prefix 'intent.' to resolve it.",
                                    "type": "string"
                                },
                                "notificationData": {
                                    "description": "This property includes detailed information about the notification being sent to the Telefónica client. The data sent will let Aura predict unusual behavior in clients billing, balance or data consumption. Depending on the action, the data included in this property will be one of the payloads defined in the aura-insights-events API (https://developers.baikalplatform.com/apis/aura-bot-events/)",
                                    "type": "object"
                                }
                            },
                            "required": [
                                "action",
                                "notificationData"
                            ],
                            "title": "NotificationValue"
                        },
                        "EventValue": {
                            "type": "object",
                            "additionalProperties": false,
                            "properties": {
                                "intent": {
                                    "description": "This property includes the Aura intention reference informing which dialog is executed to accomplish the Telefónica client intent. The format of this property is: <libraryId>.<intentId>. In case the prefix 'intent.' is not included in the value of this property, it will be included by default.",
                                    "type": "string"
                                },
                                "entities": {
                                    "description": "This property includes an array of additional information the Aura bot instance needs to properly accomplish the intent of the Telefónica client. Every entity is a JSON object including 2 properties: 'type':  this property includes a string stating the type of entity; 'entity': this property includes a string stating the value of the entity.",
                                    "type": "array",
                                    "items": {
                                        "$ref": "#/definitions/aura/bot/3.1.0/response/Entity"
                                    }
                                },
                                "text": {
                                    "description": "User utterance.",
                                    "type": "string"
                                },
                                "type": {
                                    "description": "Event type: local-grammar.",
                                    "type": "string"
                                },
                                "payload": {
                                    "description": "Specific per event type.",
                                    "type": "object"
                                }
                            },
                            "required": [
                                "type"
                            ],
                            "title": "EventValue"
                        },
                        "Utm": {
                            "type": "object",
                            "additionalProperties": false,
                            "properties": {
                                "source": {
                                    "description": "It identifies which site sent the traffic. Please, use the channel name.",
                                    "type": "string"
                                },
                                "medium": {
                                    "description": "It identifies what type of link was used, such as cost per click or email.",
                                    "type": "string"
                                },
                                "campaign": {
                                    "description": "It identifies a specific product promotion or strategic campaign.",
                                    "type": "string"
                                },
                                "term": {
                                    "description": "It identifies search terms.",
                                    "type": "string"
                                },
                                "content": {
                                    "description": "It identifies what was specifically clicked to bring the user to the site, such as a banner ad or a text link.",
                                    "type": "string"
                                }
                            },
                            "required": [
                                "source"
                            ],
                            "title": "Utm"
                        },
                        "Entity": {
                            "type": "object",
                            "additionalProperties": false,
                            "properties": {
                                "canon": {
                                    "description": " This property includes the canonical form of the entity sent on behalf of the Telefónica client interacting with the Aura bot instance.",
                                    "type": "string"
                                },
                                "endIndex": {
                                    "description": "Index at which this entity ends in the original user message.",
                                    "type": "number"
                                },
                                "entity": {
                                    "description": "This property includes the value of the entity sent on behalf of the Telefónica client interacting with the Aura bot instance.",
                                    "type": "string"
                                },
                                "label": {
                                    "description": "This property includes an internally used descriptive tag of the entity sent on behalf of the Telefónica client interacting with the Aura bot instance.",
                                    "type": "string"
                                },
                                "score": {
                                    "description": "This property includes the accuracy (in per 1 units) of the recognized entity sent on behalf of the Telefónica client interacting with the Aura bot instance. In the case of Aura commands this value should be 1 since in this case fully recognized intentions are sent.",
                                    "type": "number"
                                },
                                "startIndex": {
                                    "description": "The index at which this entity starts in the original user message.",
                                    "type": "number"
                                },
                                "type": {
                                    "description": "This property includes the type of the entity sent on behalf of the Telefónica client interacting with the Aura bot instance. The format used by this property is the following one: ent.<entityType>",
                                    "type": "string"
                                }
                            },
                            "required": [
                                "canon",
                                "entity",
                                "score",
                                "type"
                            ],
                            "title": "Entity"
                        },
                        "Status": {
                            "type": "object",
                            "additionalProperties": false,
                            "properties": {
                                "code": {
                                    "description": "Internal Aura status code. Get more info in @telefonica/aura-models, within the path src/channel-data/status/aura-status-codes-v3.ts",
                                    "type": "string"
                                },
                                "message": {
                                    "description": "Descriptive text with additional information.",
                                    "type": "string"
                                },
                                "params": {
                                    "description": "Extended information about the status, it may be empty or not sent. If exists, it will contain extra params needed to handle programmatically the status properly.",
                                    "type": "object"
                                }
                            },
                            "required": [
                                "code",
                                "message"
                            ],
                            "title": "Status"
                        }
                    }
                }
            }
        }
    }
}