According to the error message you provided, the webhook response that you return from your webhook service is the following:
[{
"fulfillment_response": {
"messages": [{
"text": "text here"
}],
"merge_behavior": "REPLACE"
}
}]
The text field under “messages” should have a text response which should contain an array of text messages to return to the user.
An example of a webhook response is as follows:
{
“fulfillment_response”: {
“messages”: [{
“text”: {
“text”: [
“text here”
]
}
}],
“merge_behavior”: “REPLACE”
}
}
For more information on Webhook Response, see here: https://cloud.google.com/dialogflow/cx/docs/reference/rpc/google.cloud.dialogflow.cx.v3beta1#webhookresponse