Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Table of Contents
minLevel1
maxLevel76
outlinefalse
styledefault
typelist
printabletrue

...

Inbound webhook is a powerful tool to receive data from anywhere to the chatbot through a POST request.

...

Info

Limitation - Each bot has up to 5 inbound webhooks, the rate limits is 500 request per 24 hours.

Create Inbound Webhook

It's available in almost all channels, in your flow builder, go Tools - Inbound Webhooks:

...

There are 2 ways to get an example JSON:

  1. manually type/paste it here

  2. listen to a real-time data from a live test

Values to Identify a User

...

This is the process of how the system identifies a user:

  1. check user_ns

    • if there is a valid user_ns, user found.

    • if not, next step

  2. check phone / email

    • if we can find a user by the phone or email, user found.

    • if not, next step

  3. verify phone

    • no user matched in the system, is the phone a valid number?

    • if yes, user profile created.

    • if not, webhook won't be processed

Mapping Area

The mapping list shows which value should be stored in which custom field. When you get a sample JSON in the above area, click on Preview Payload to get a mapping tool.

...

Every single request is saved in Logs. Click on a record to see the received JSON data.

Inbound Webhook Limitation

By default, inbound webhook request limits is 500 request per 24 hours. You can see the limits from the screenshot below:

...

If you have exceed the limits, you do have the option to upgrade to more request per day, here is a list of the option you have:

  • 500/day - Included   ~~   15K requests/per month

  • 1000/day - $20 per month   ~~   30K requests/per month

  • 2000/day - $40 per month   ~~   60K requests/per month

  • 3000/day - $60 per month   ~~   90K requests/per month

  • 4000/day - $80 per month   ~~   120K requests/per month

  • 5000/day - $100 per month   ~~   150K requests/per month

  • 10000/day - $200 per month   ~~   300K requests/per month

You can subscribe from the link below:

https://buy.stripe.com/00g9BJ6GLcLugvKbIV

The link is $20 per month per unit, If you need 1000 request per day, just select the quantity 1;

If you need 2000 request per day, just select the quantity 2, etc

...

After the payment, you need to provide your payment receipt and your flowNS to UChat support email at ticket@uchat.com.au

Here is how you can find your flowNS,

Go to “All bots” in UChat dashboard, and then find the bot you want to increase the inbound webhook request limits, and then click the dropdown, you will find the flowNS.

...

Video Tutorial

...

How to debug inbound webhook max request error

First of all, if you are not receiving the data in the inbound webhook, or you can’t find the data in the logs, it’s highly possible that you reached the max daily request limits.

Here is how you can test it.

You can send the request to the inbound webhook from Postman or UChat external request, and then you can find the below information in the header:

...

As you can see, there is rate-limit-remaining, if it’s 0, that means you already reached the rate limits, you should upgrade for more limits.

Demo: Booking Confirmation

...

We can see that this time it run without error because we activated the webhook and used a real phone number. Go to Logs and we can see a new user profile is created successfully.

On the user side:

...

...

FAQ

Inbound webhook don’t works on your partner custom domain?

In cases where the inbound webhooks under your Partner custom domain stop working, while under Uchat domain they are working correctly.

The issue could be inside your cloudflare settings.

Sometimes Cloudflare automatically detects requests to your domain and term them as attacks from bots. This blocks the requests coming to these inbound webhooks for a certain interval of time.

In order to avoid this, Go to your settings inside your Cloudflare dashboard, under the security tab, turn off “Bot Fight Mode”.

Image Added

This will help you stop classifying requests made to your webhooks as bot attacks and your inbound webhooks will start working again

Note: Another reason webhooks can stop working is hitting their daily threshold. So always check to make sure the limits arent being maxed out