Jovo Properties

Jovo properties are reserved variables that part of the Jovo this object.

Introduction

The Jovo context object (also referenced as this) includes many properties that are instantiated with each request.

In the this context, you can access them like this:

this.$propertyName;

// Example: $request
this.$request;

The properties can be grouped into RIDR, input, and context properties.

RIDR Properties

Jovo app execution follows the RIDR lifecycle that includes four steps: request, interpretation, dialogue & logic, response.

Each of the steps result in a Jovo property: $request, $input, $output, $response.

$request

The $request property contains all information about a request. It is the result of the first step of the RIDR lifecycle.

this.$request;

$input

The $input property contains structured data that is derived from a request. For example, speech recognition (ASR) and natural language understanding (NLU) data. It is the result of the second step of the RIDR lifecycle.

this.$input;

Learn more about the $input property here.

$output

The $output array contains one or more structured output templates that are later turned into one or more native platform responses. It is the result of executing a handler and the third step of the RIDR lifecycle.

this.$output;

Learn more about the $output array here.

$response

The $response property contains the native response that gets sent back to the platform. It is the result of the fourth step of the RIDR lifecycle.

this.$response;

Input Properties

Alongside $input, there are additional properties that contain interpreted information about the user's request.

The properties include $entities and $route.

$entities

The $entities property contains entities as part of the structured input.

this.$entities;

$route

The $route property is the result of the routing process.

this.$route;

Learn more about routing here.

Context Properties

Context properties contain information that was not explicitly stated by the user, but rather information accompanying the request.

The properties include $data, $session, $user, $device, and $history.

$data

The $data property allows you to store data for the current request.

this.$data;

Learn more about request data here.

$session

The $session property contains data and features about the current session.

this.$session;

One of the most used features of $session is to write and access session data:

this.$session.data.key = value;

Learn more about session data here.

$state

The $state property is the state stack that gets built as part of the routing and state management.

this.$state;

Learn more about the $state stack here.

$user

The $user property contains data and features about the specific user interacting with the app.

this.$user;

One of the most used features of $user is to write and access data that is persisted in a user database:

this.$user.data.key = value;

Learn more user data here.

$device

The $device property contains data and features about the specific device the user is interacting with.

this.$device;

Learn more about the $device property here.

$history

The $history property contains data about previous user interactions.

this.$history;

Learn more about the $history property here.

$server

The $server property contains data and features about the server requests and responses.

this.$server;

Learn more about the $server property here.