This adapter displays all the types of answers and outputs available in the Chatbot SDK.
This is intended for development purposes only. You can use it to see the design changes that apply to every type of answer and output.
This adapter blocks the Inbenta API call.
If you want to use these adapters "as is" in production environments, you must copy and use them from your servers.
The user can ask for the following outputs:
multipleChoiceQuestion
.In the following code you have mocked up several types of answers, to see the full adapter, please refer to Github DemoMessages Adapter
Since there are several configurations available in the build method: Configurations, Inbenta recommends that you build the same configuration as the one used in your project.
DateTime
in every answer.<!DOCTYPE html>
<html>
<head>
<title>Demo</title>
<script src="https://sdk.inbenta.io/chatbot/1/inbenta-chatbot-sdk.js"></script>
<script src="messages-demo-adapter.js"></script>
<script>
var authorization = {
domainKey:"<example_domain_key>",
inbentaKey:"<example_inbenta_key>"
}
const config = {
showDateTime: true,
ratingOptions: [
{
id: 1,
label: 'yes',
comment: false
},
{
id: 2,
label: 'no',
comment: true
}
],
adapters: [messagesDemoAdapter]
};
InbentaChatbotSDK.buildWithDomainCredentials(authorization, config)
</script>
</head>