Skip to main content

How to configure an HTTP request in Tines

Configuring an HTTP request action

Written by Fergal Collins
Updated this week

This article will guide you through configuring an HTTP request action, detailing the three main components and walking through an example of retrieving cat pictures using an API.

Key components of an HTTP request

There are three main components to be aware of when configuring an http request:

  • URL endpoint: This is the service you are reaching out to, essentially asking that service to perform some kind of task.

  • Method: This determines the specific action you want the service to perform.

    • POST is used to ask the service to do something on your behalf, such as asking slack to send a message.

    • GET is used for retrieving information, such as getting all of the slack channels in an environment.

    • PATCH: Is used to send data to perform a partial update on existing data, such as updating only a user's phone number in a directory.

    • PUT: Is used to send data to replace an entire existing data record, such as replacing all the details of a contact record in a service.

    • DELETE: Is used to remove data, such as permanently deleting a specific message from a chat service or a user account.

  • Payload: This includes any additional criteria on how you make the request, such as specifying that you want the first 10 users in a slack channel, or all the users.

Example: Retrieving cat pictures

To demonstrate a simple configuration, we will reach out to a service to get random cat pictures. Here is a video of this example with the steps involved below:

Steps involved

  • Rename the action: Rename the http request action to "get cat picks".

  • Configure the URL endpoint:

  • Set the method: Since the request is trying to get information, switch the method to GET.

  • Remove the payload: Delete the payload since it is not needed for this request.

  • Run the request: Hit run to execute the configuration.

  • View the result:

    • Once the run is successful, locate the "get cat picks" action in the events section.

    • Expand the three dots, then expand the three dots for "body," and then expand the three dots once more.

    • The result will provide an id, a URL, a width, and a height.

    • Copy the URL and open it to view the cat picture.

This example shows how simple it can be to configure your first http request.

Note that as requests become more complicated (e.g., requesting the service to delete.

👉 For a more detailed description of HTTP requests see here.

Did this answer your question?