API call

TL;DR: Make an API call to a 3rd party, customize request headers, method and body.

Making HTTPs calls is one of the most popular actions that a web server does. In todays world, where almost everything is *.as-a-service, you find yourself integrating with many other platforms, usually by using an SDK or by making an HTTP call to a specific endpoint.

The HTTP request state allows you to make a request to a certain endpoint, using certain headers and a certain request body.

The system also supports injecting a continuation URL, for cases where your flow needs to receive a webhook in order to continue its execution from this exact state. We will dive deeper into this usecase in the Continuation URL for Webhooks section.

Basic Configuration

An HTTP call configuration consists of the following parts:

  1. Endpoint and HTTP method

  2. Request headers

  3. Request body

Every field in the configuration can either have a static value (for example, 123), or a dynamic secret value (for example $((secrets.MY_SECRET_KEY))). If, for example, a secret is used for the endpoint field - the actual endpoint URL would be injected during runtime from the secrets store, based on the execution environment. So if the flow was being executed in the TESTING environment, and for this environment the secret MY_SECRET_KEY has a value of https://test.com, then during runtime a request will be made to https://test.com.

Configuring endpoint

Similar to flow, you can configure headers and request body.

To see a list of all injectable special values, see 'Injectable Values'.

Continuation URL for Webhooks

It is possible for a state to behave in a webhook-dependant manner. This can be done the same way as described in 'Webhooks'.