Add Web-API Card

Overview

Web-API is a type of card in conversational flows that allows you to send data you've collected during the flow to an external app or server by using HTTP methods like POST and GET. The response data received from the target is being saved in the current flow as Dynamic Parameters and you are able to use that data in the next steps of your conversational flow.

Create Web-API card

  1. In the Flows Editor, in the New Card sidebar, click on Web-API option.
290290
  1. In the Web-API window:
    1. In the Url box, type the <URL target of your Web-API request>.
    2. Click on the desired method - Post or Get.
426426

🚧

Note:

If you're using the Post method you will have the option to send customized JSON body content.

  1. In the text editor section, click on the {⋯} icon.
419419
  1. Select the desired Parameters to insert into your request body content.
  2. In the Action on Web-API request success/failure drop down, click on the desired option.
424424
  1. Click on the desired option in the drop downs according to the action needs.

📘

Tip:

You can click on Test to send a test request to the target URL.

🚧

Note:

If you send a test Post request, you will have to fill a sample data that will replace the parameters that are in use in your JSON body content.

537537

Optional Steps

These steps are meant for securing requests to your systems. For more information read here

  1. Click on Advanced settings.
  2. Click on New Header to include request headers in your request.
  3. In the Header's Value box, click on the {⋯} icon.
419419
  1. Select the desired Parameters.

Example Card

Let's say you have the mail of the customer and you want to get some additional data such as userId and name of the customer from your API. This is how your card would like at the end:

437437