How to add authentication to my rasa webhook

Hi, I am using rasa 2.x

I currently hit at POST request to: https://10.21.33.43:8080/webhooks/rest/webhook

with body: {"message":"Hi"}

And I get a json response:

[

    {

        "recipient_id": "default",

        "text": "Hello! I am a bot."

    }

]

I want that this request should not be catered until user is authenticated. Can I add user authentication (based on tokens) and use the tokens to access this URL and only then display results?

Also, what is the signinficance of “recipient_id” in the response? How I can use it or change it?

@stephens Do you have any thoughts on this?

The id is a unique user id. For authentication look at the docs here and this post by @souvikg10

@stephens This you gave for rasa open source. Need it for rasa x. I have enabled Rest in configuration.yml and using rasa webhooks for api call. Need authentication here.

Sorry, can’t help with Rasa X

@stephens np. thanks