Flochat
API DocumentsWebsiteLog in
  • Start Here
    • Welcome 👋
    • Getting Support
    • FAQ's
    • Pricing Plans
  • GETTING STARTED GUIDE
    • Introduction
    • Set your goals
    • Building your chatbot
    • Maintain success
  • CHATBOT GUIDE FOR BEGINNERS
    • Introduction
    • What is a chatbot
    • Channels
    • Benefits & importance
    • Use cases
  • PLATFORM
    • Introduction
      • Change Password
      • Forgot Password
      • Getting Started Checklist
      • Platform Overview
      • Workspaces & Members
      • Integrations
        • Stripe
        • PayPal
        • Cloudinary
        • Shopify
        • Facebook Business
        • Calendly
        • Slack
        • Google Sheets
        • Data Store
        • Twilio
        • Signalwire
        • Email (SMTP / Gmail)
        • MailChimp
        • VideoSdk
      • Ecommerce
        • Setup Ecommerce
        • Use Ecommerce in the Flow
    • Connect to Channels
    • Website Chat
    • WhatsApp + 360Dialog
    • Email Templates
    • WhatsApp Cloud
  • Flow Builder
    • Flow builder overview
    • Field variable
    • Steps
      • Steps
      • Question step
      • Variable Operation
      • JSON Operation
      • External Request
      • Send Notification
      • Condition Step
      • Split Step
      • Go To Step
    • Sub Flows
      • Sub Flow
      • Workflow
      • Function Flow
  • Artificial Intelligence
    • OpenAI | ChatGPT
      • Connect OpenAI
      • Chat with AI Basics
      • What are Functions
        • Functions in Flows
        • Capturing Data
        • Generate function with AI
        • Combine chat completions & Functions
      • What are Embeddings
        • Create Embeddings
        • Add Embeds to your Flow
        • Error Handling
        • Combine Embeddings with Functions
    • GitBook Lens AI
  • Mini Apps
    • Stealth Seminar
  • Users
    • Live Chat
    • Bot Users
  • Bot Automation
    • Keywords
    • Sequences
    • Triggers
    • Comment Keywords
  • Contents
    • Custom Fields
    • Tags
    • One Time Notification (Facebook)
    • Personas
    • Menus
    • Customer Feedback (Facebook)
  • Tools
    • Error Logs
    • Testers
    • Admins
    • Multi Languages
    • Inbound Webooks
  • Broadcasting
    • Broadcasts
  • Developers
    • Chatbot API
  • BETA LAUNCH
    • Day One
Powered by GitBook
On this page
  • URL Params
  • Headers
  • Authorization
  • Body
  • Testing
  1. Flow Builder
  2. Steps

External Request

PreviousJSON OperationNextSend Notification

Last updated 2 years ago

With external requests, you can call APIs from other third parties or your own server to request data, submit data and etc.

In an Action step, find "External Request" in "Advance Actions" and click "Add your request" then start editing it:

  1. choose a request type such as GET, POST, etc

  2. paste your request URL / endpoint

  3. adjust "URL parameters", "Headers", "Body" or "Authorization" section if needed. e.g. setup API key

  4. click "Test" and area 5 will show in the "Response" section with a response code

  5. click on "Response Headers" to expand the header for more details and the received data is in blue

  6. choose which part of the data you need by clicking the circle on the left-side accordingly

  7. after clicking area 6, the JSON path for the selected data is automatically shown here. $ means the whole JSON.

  8. choose which custom field to store the data. You can create a new field here by typing in a field name and clicking it in the drop-down. Click the "Add" button to add to the mapping list

  9. finally, the mapping shows in area 9. Add as many mapping as needed and click "Save".

Make sure you provide testing data for any one of the fields/variables in the settings before you use the Test button.

URL Params

In the above screenshot, we can see that there is a URL parameter in the endpoint called "user_name". Remember to copy the endpoint down and provide a testing value.

Alternatively, you can use the URL Params sections for the same result.

Headers

Same as URL Params, put your key name first, then insert the variable and provide a testing value.

Authorization

Alternatively, put the token in the Authorization section. It's going to be less error-prone (sometimes people just forgot the "Bear " in front of the token).

Moreover, for Basic Auth, simply put your username and password value and the system will do the base64 encoding for you.

Body

To include a file itself in the parameters, use multipart/form-data:

x-www-for-urlencoded works just like URL Params or Headers section.

Instead of listing all the payloads in x-www-form-urlencoded, you can also paste the example payload in raw JSON:

On the left-hand side, Body Content, paste or write your JSON first, when you insert a variable, the Test body content shows on the right side immediately. It's to specify a testing JSON value.

Click on Copy from body content to copy the whole JSON structure. All the variables will be replaced by {{variable_name}}. Remove the placeholder and put your testing values.

Testing

Once you are ready, click on the Test button next to the URL endpoint or in the Response section.

Besides the tips about how to map data above, you might also want to save the values in the response header for later use. Simply expand the header, click on a value in the header and the JSON path to it shows automatically there.