Api.ai integratoin

(bill@commongood.center) #1

I’m having a hell of a time getting api.ai integrated. I’m utilizing the pre-built agent “Jokes” form api.ai.

QUESTIONS:

  1. Do I utilize “https://api.api.ai/v1/query” or “https://api.dialogflow.com/v1/” in the Request URL field (since they switched their domain to dialogflow)?

  2. Here’s the json from dialogflow (below). Out of this, what do I put in the data key popup under “Make an http request”…I’ve tried these variation and still can’t get a response:
    {{make_a_http_request.data__result__fulfillment__speech}}
    {{make_a_http_request.data__result__fulfillment__speech__message}}
    {{make_a_http_request.data__fulfillment__speech}}
    {{make_a_http_request.data__fulfillment__speech__message}}

If someone could just create a video tutorial, that’d be awesome. I think it’d help a lot of people out. Thanks for your help.

{
“id”: “79719441-c9f2-4023-994c-86624ffc314d”,
“timestamp”: “2017-11-29T21:42:21.704Z”,
“lang”: “en”,
“result”: {
“source”: “agent”,
“resolvedQuery”: “Hi”,
“action”: “input.welcome”,
“actionIncomplete”: false,
“parameters”: {},
“contexts”: [],
“metadata”: {
“intentId”: “779540ba-45f9-4204-868a-f87e53247eb6”,
“webhookUsed”: “false”,
“webhookForSlotFillingUsed”: “false”,
“intentName”: “Default Welcome Intent”
},
“fulfillment”: {
“speech”: “Hello! I’ve got some jokes for you. Would you like to hear one?”,
“messages”: [
{
“type”: “simple_response”,
“platform”: “google”,
“textToSpeech”: “Hi! Want to hear a joke?”
},
{
“type”: “suggestion_chips”,
“platform”: “google”,
“suggestions”: [
{
“title”: “Tell me a joke”
}
]
},
{
“type”: 0,
“speech”: “Hello! I’ve got some jokes for you. Would you like to hear one?”
}
]
},
“score”: 1
},
“status”: {
“code”: 200,
“errorType”: “success”,
“webhookTimedOut”: false
},
“sessionId”: “4a76cd67-9f36-4348-a33b-8dbddbd07da7”
}

(Daniel Beckett) #2

@habicht

Not sure if you’ve seen it already but there’s a tutorial for Using Flow XO with API.AI that might be able to help here.

(bill@commongood.center) #3

Yes. But it isn’t as straightforward for non-coders. I can’t seem to get a response from api.ai

(bill@commongood.center) #4

Here’s the images from from XO flow and dialogflow:

1 Like
(Thallyson Dias) #5

i have a same configuration, my API + FlowXO dont workds too…

A video tutorial would be excellent

(Daniel Beckett) #6

Hi @Thallyson_Dias

If you’re still having trouble getting this to work please email support@flowxo.com and we’ll help out from there :relaxed:

Please include a share of your flow in the email - this can be found by clicking on the ‘private’ button near the top right corner when editing the flow.

Thanks,
Dan

1 Like
(Thallyson Dias) #7

Thanks Daniel,
i go prepare this email! <3