To add a REST Endpoint Integration you will need to collect:
- The URL of the endpoint you want to connect to.
- Whether the endpoint requires authentication.
- The method by which you want to call the endpoint (either
- If there is body you would like to include with the endpoint request when the integration is tested for connectivity.
For the example below, we’re going to call a REST endpoint with Slack to post a message. We’re using Slack as it is a common and easy to follow example - however, if you want to integration with Slack, we recommend using the Slack Integration instead.
Adding a REST Endpoint Integration
To add a REST Endpoint integration, navigate to Control > Integrations.
Click the Add Integration button from the Integrations page
Choose REST Endpoint.
Fill in the relevant fields..Note:
UpGuard provides the flexibility of choosing different types of request and authentication methods. UpGuard can handle both GET and POST requests. It is also possible to specify authentication methods.
For Basic Auth, the UpGuard equivalent of
curl --user username:password https://... is
For Authorization Header, the UpGuard equivalent of
curl -H 'Authorization: Token token="1234"' https://... is
Click Done to finish creating the integration. As part of the creation process, the REST endpoint will be called to confirm the details are correct. In the case of the Slack web hook we’ve used here, you should receive a message in Slack. See below for more details.
Check that REST Endpoint Integration is set up correctly
Navigate to Control > Integrations.
The REST endpoint should be available in the list of integrations.
You will also have the message posted to the REST Endpoint. In this case, there will be a slack message.
Now that you have a REST Endpoint integration set up, you can use it as the basis for an action trigger when a particular type of event occurs. For more inforation on setting up event actions for a REST Endpoint, please view our guide on REST Endpoint Actions.