Sometimes you need to interact with your Application or its data outside of Airkit. Application APIs at its core, are a way to build custom API endpoints and interact with Airkit from external systems, leveraging the available data operations to create Journeys, modify existing Journeys, validate data, or even read data from AirData.
An App API is a powerful method for integrating Airkit with other applications and services. It is how you can create a custom REST endpoints that are defined by you, through the use of combining and adding data operations together. With App APIs, you are able to create either a GET request or a POST request and can also configure your endpoint path, path parameters, and query parameters.
For a guide on how to build an App API, see Building an App API.
If the App API requires Authentication and should not be publicly available, a token must be created. For this you will need an API key that can be generated from the Console (API > Tokens):
Make sure to safely store the generated token at that moment since it will not be retrievable after the window is closed. If the API key is lost, you can delete the API key and create a new one.
Once the token has been created in the Console, go to Settings and add the API Key in API Key Filtering.
This will make it appear under Authentication in Triggers > App APIs .
When using an App API to redirect to a URL it is recommended to use the
302 response status code instead of
301s are cached by the browser which may result in unintended behavior.
Data passed as a request payload for App APIs have a maximum size of 5mb.
Updated 5 days ago
Interested in integrating other systems with Airkit and triggering off a journey with an HTTP request? Check out the tutorial below.