HTTP
An HTTP connector sends data to an API endpoint of your system.
Configuration
The configuration describes how Send AI calls your API:
- Method: The method is POST, PUT or PATCH. POST is the default.
- Base URL: The base URL is the address of your API, such as
https://api.example.com. Choosing the connector in an action or a notification fills in the endpoint with it, which you then complete. - Request timeout: The request timeout is how many seconds Send AI waits for an answer. It is at least 30 seconds, which is also the default.
- Content Type: The content type sets the
Content-Typeheader: JSON (the default), XML, Form Data or Multipart Form. The body itself is the data of the export, so for XML, shape the data with a data transformation first. - GZIP compression: GZIP compression sends export bodies compressed. It is off by default and does not apply to notifications.
- Headers: Headers are added to every request, such as an API key your system expects.
Authentication
Authentication Method chooses how Send AI proves who it is:
- No Auth: No Auth sends no
Authorizationheader. Use it when your API takes a key in a header of its own, and add that header under Headers. - Bearer Token: A fixed token. See Bearer token.
- OAuth 2.0: A token from your authorization server. See OAuth 2.0.
- Custom Auth Request: A token from a token endpoint of your own. See Custom authentication.
The endpoint
The endpoint is set where the connector is used, per environment. An export endpoint can hold variables that are filled in for each document, such as {{upload_id}}, {{task_id}} and {{project_id}}.
Answers
A request succeeds when your endpoint answers with a 2xx status. Any other answer fails, with "Connector failed with message:" followed by the body of the answer. When no answer comes within the timeout, the message is "Connector endpoint not responding". Send AI does not retry by itself. See Deliveries.