You can automatically populate your code deployments or system configuration changes in Quanta.

These events can be created automatically via our API. The best way to use them is to include a call to our API in your code deployment scripts and in your configuration management tool if applicable.

How the API works

Our API is called via a simple HTTP call on the URL "https://app.quanta.io/api/events/push", the parameters to be filled in are the following:

Authentication and token generation

You will also need to specify an API token to authenticate the request. This token can be generated in the "Integrations" section of your site settings in QUANTA. You also have the option to add a custom icon.

This token will have to be

Examples of use

Here is an example of a request with cURL that adds a code deployment event with the message "version 42.0". Note the presence of the "Content-Type" header which is essential for our API to take into account the request:

curl -L -m 10 -X POST -d '{"type": "code_deploy", "content": "version 42.0"}' -H 'Content-Type: application/json' -H 'Authorization: Token 78e64233e09d3d8ec7bf73c4d9ea8a8851badbd216' <https://app.quanta.io/api/events/push>

If you want to integrate events via another service that does not allow POST requests, you can also use the API via a GET request. For example, the following command adds a generic ("custom") event using cURL:

curl -L -m 10 <https://app.quanta.io/api/events/push?content=bonjour&type=custom&auth_token=78e64233e09d3d8ec7bf73c4d9ea8a8851badbd216>

Our API will return an HTTP code 200 in case of success and a code 5xx or 4xx in case of error. The response will contain a JSON content with the field "error" in case of error or "success" in case of success.

<aside> 💡 In the 2 commands above, the -m option of cURL allows you to set a timeout to 10 seconds so that your scripts are not blocked in case of a possible unavailability of our API.

</aside>