Custom rest channel with channel-specific responses?

Hello, I wonder how it is possible to use the “channel-specific” responses in combination with a custom rest channel. My case is that I want to connect a Mycroft assistant skill (uses rest webhook) with a Rasa chatbot. When I talk via Mycroft to Rasa, the Rasa bot should return Mycroft-specific responses.

So far, I understand how I can create a custom rest INPUT channel, but building the corresponding output is not clear to me. Could anyone point me in the right direction or has an example code?

From the docs:

Make sure the value of the channel key matches the value returned by the name() method of your input channel.

Hi, I double checked that already. Its both “mycroft” (lowcase). I tought that the channel-specific response depends on the output channel name which would make more sense to me too as the response is an output.

Can you show me your custom connector?

I attached the file: (5.7 KB) It is a copy of the REST connector with a minor change. The file also contains the curl command I used to send a message to a local Rasa server. The responses look like this (I used trial and error for the channel name to fix the issue). The bot answers to the curl command with [{"recipient_id":"default","text":"Hello."}]

  - text: "Hello from the custom channel"
    channel: "mycroft"
  - text: "Hello from the custom channel2"
    channel: "queue"
  - text: Hello.
1 Like

This is weird, you’re implementing everything correctly (I think) :confused: