-
Notifications
You must be signed in to change notification settings - Fork 22
REST API
Xatkit exposes information about a running bot through a REST API. This page details the different endpoints, expected parameters, and response examples.
Lists all the monitoring information. Note: this method does not support pagination yet (see this issue), so the response may be big for long-running applications.
GET /analytics/monitoring
[
{
"sessionId": "72f8fa90-8d3e-4804-b00d-5612a95fb644",
"entries": [
{
"timestamp": 1573750605388,
"utterance": "How are you?",
"intent": "HowAreYou",
"confidence": 1.0
},
{
"timestamp": 1573750623741,
"utterance": "Here is something you won't understand!",
"intent": "Default_Fallback_Intent",
"confidence": 1.0
},
{
"timestamp": 1573750630281,
"utterance": "I knew it",
"intent": "Default_Fallback_Intent",
"confidence": 1.0
}
],
"matchedUtteranceCount": 1,
"unmatchedUtteranceCount": 2
}
]
Note: the timestamp
fields contain timestamps in milliseconds.
Lists the monitoring information corresponding to the provided sessionId
.
GET /analytics/monitoring/session?sessionId=id
Name | Type | Description |
---|---|---|
sessionId |
string |
Mandatory: the identifier of the Xatkit session to retrieve the information from |
{
"sessionId": "72f8fa90-8d3e-4804-b00d-5612a95fb644",
"entries": [
{
"timestamp": 1573750605388,
"utterance": "How are you?",
"intent": "HowAreYou",
"confidence": 1.0
},
{
"timestamp": 1573750623741,
"utterance": "Here is something you won't understand!",
"intent": "Default_Fallback_Intent",
"confidence": 1.0
},
{
"timestamp": 1573750630281,
"utterance": "I knew it",
"intent": "Default_Fallback_Intent",
"confidence": 1.0
}
],
"matchedUtteranceCount": 1,
"unmatchedUtteranceCount": 2
}
Note: the timestamp
fields contain timestamps in milliseconds.
Lists all the user inputs that haven't been successfully translated into intents.
GET /analytics/monitoring/unmatched
[
{
"sessionId": "72f8fa90-8d3e-4804-b00d-5612a95fb644",
"timestamp": 1573750623741,
"utterance": "Here is something you won't understand!"
},
{
"sessionId": "72f8fa90-8d3e-4804-b00d-5612a95fb644",
"timestamp": 1573750630281,
"utterance": "I knew it"
}
]
Note: the timestamp
fields contain timestamps in milliseconds.
Lists all the user inputs that have been successfully translated into intents.
GET /analytics/monitoring/matched
[
{
"sessionId": "72f8fa90-8d3e-4804-b00d-5612a95fb644",
"timestamp": 1573750605388,
"utterance": "How are you?",
"intent": "HowAreYou",
"confidence": 1.0
}
]
Note: the timestamp
fields contain timestamps in milliseconds.
Returns a set of session-level statistics (e.g. average time/session, average number of matched inputs/session, etc).
GET /analytics/monitoring/sessions/stats
{
"averageMatchedUtteranceCount": 1.0,
"averageUnmatchedUtteranceCount": 2.0,
"averageSessionTime": 43.246
}
Note: the averageSessionTime
field represents the average session time in seconds.
- Getting Started
- Configuring your bot
- Integrating an Intent Recognition Provider
- Adding a bot to your website
- Deploying on Slack
- Basic concepts
- Intents and Entities
- States, Transitions, and Context
- Default and Local Fallbacks
- Core Library