You can use triggers to apply situational logic to your automations in Tines. You can trigger actions based on:
If conditions are met
Example: Successful request is made to an API service
If conditions are not met
Example: Checking if a user has not clicked on a link that acknowledges that they just attempted to log in.
One of the most common strategies for using triggers is looking at the HTTP status code of an API request. Whenever we connect to different services, there is a chance that the request we made was incorrect, or maybe the service is currently unavailable due to some issues on their end.
These HTTP status codes are three-digit numbers that the server sends to your web browser or client application to provide information about the status of a requested HTTP resource. These codes help communicate whether a request was successful, encountered an error, or requires further action.
Here are some common HTTP status codes you may encounter as a beginner:
This status code indicates that the request was successful and the server has returned the requested resource. It is the most common status code you'll encounter when everything works as expected.
This status code indicates that the requested resource could not be found on the server. It typically means the URL or endpoint you are trying to access does not exist.
500internal server error:
This status code indicates an error on the server's side while processing the request. It's a generic error message that doesn't provide specific details about the problem. It could be due to a misconfiguration or a bug in the server-side code.
These status codes indicate that the requested resource has been moved to a different location. The browser or client application should typically follow the redirect and make a new request to the provided URL.
This status code indicates that the server cannot process the request due to malformed syntax or invalid parameters. It usually occurs when there is an issue with the structure of the request itself.
This status code indicates that the server understands the request, but the client cannot access the requested resource. It could be due to insufficient privileges or authentication requirements.
It's important to note that HTTP status codes range from 1xx to 5xx, with each range representing a different category of responses. Familiarizing yourself with these codes will help you understand the outcome of your requests and troubleshoot any issues that may arise.
Follow the steps below to configure a trigger
Aside from being able to configure our own HTTP requests from scratch, we can also leverage our action templates to reduce time around configurations. These preconfigured actions make it so all of the baseline requirements for the request are already configured. In certain cases, you'll find that you need to add in credentials.
These action templates are located on the left panel at the bottom under templates.
After you go into the templates, you can then select a tool to see all of the preconfigured actions. These make it much quicker to get tools you love connected in Tines.
In addition to being able to have preconfigured HTTP request actions for external services, we also have a range of techniques that have been captured in the internal section. These include examples of REGEX, trigger examples, date examples, and more.