Custom channel rasa

I’m trying to create a custom channel in rasa. My credentials file is:



  url: "http://localhost:5002/api"

My channel file is in the rasa main directory:

from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
from __future__ import unicode_literals

import logging

from flask import Blueprint, request, jsonify

from import UserMessage
from import CollectingOutputChannel
from import HttpInputComponent
from import InputChannel

logger = logging.getLogger(__name__)

class ChannelInputChannel(InputChannel):
    """A simple web bot that listens on a url and responds."""

    def name(self) -> Text:
        return "channel_input_channel"

    def blueprint(self, on_new_message):
        custom_webhook = Blueprint('custom_webhook', __name__) 

I’m getting this error:

Exception: Failed to find input channel class for 'ChannelInputChannel'. Unknown input channel. Check your credentials configuration to make sure the mentioned channel is not misspelled. If you are creating your own channel, make sure it is a proper name of a class in a module.

What should I do?

What’s the name of the python file. Typically, you’d place this in a sub-directory like the example which would be in ./mypackage/ with an in the mypackage directory.


I’m facing the same problem, I’ve created a new channel for WhatsApp and created a file in the same directory of credentials.yml

|__ credentials.yml


you suggest making it like this: `

|__ mypackage/


Am I right?