Configuring a JSON request

In the table, you'll find the basic building blocks available for configuring your request.

Name JSON data type Description Example values
authentication object The type of authentication used with requests
{"type": "basic"}
method

(required)

string The HTTP method used for requests
GET, POST, PUT, PATCH, DELETE
headers object Set of key-value pairs for defining request header names and their values

You can use the available authentication data as well as contact and event data in dynamic runtime placeholders.

{"Accept": "application/json"}
{"x-api-key": "{authentications.api-key}"}
{"x-contact-event": "{contact.direction}-{contact.channel_type}-{event}"}
params object Set of key-value pairs for defining request query parameter names and their values

You can use the available contact and event data as dynamic runtime data placeholders.

{"event": "{event}"}
{"filter": "source='{contact.source}'"}
body object

Set of key-value pairs for defining the request JSON body

Supports nesting, which means values can also be specified as other JSON objects of varying depth

Note:

This object only applies to request methods POST, PUT, and PATCH.

You can use the available contact and event data as dynamic runtime data placeholders.

{"contact": "{contact}"}
{"message": "Your message {contact.id} to {contact.destination} has been received."}
condition string

Scriptable condition for controlling whether a request should be triggered

The value of the condition is evaluated at runtime.

For more information, see Using conditions.

contact.get_priority() <= 50
timeout number or string Connection and read timeout in seconds
14.5
Default: 10
proxy string The HTTP proxy server used with the requests

Auto-detect (default):

auto

Explicit:

<proxy-address>

Bypass:

no
block boolean

Whether requests should be handled in a blocking manner regardless of the associated response handling instructions

This means by having the calling code wait for response data to be received before continuing with its execution flow.

true, false
Default: false
verify boolean

Whether SSL certificates for HTTPS requests will be verified

By default, SSL verification is enabled.

true, false
Default: true