Source: https://atomicwork.docs.pageloop.ai/product/enterprise-workflows/actions-and-integrations/http-request-actions

# HTTP request actions

An HTTP request action lets a workflow call another system’s API directly, so you can perform data updates and operations that would otherwise mean logging into that system by hand. Without it, you might have to go and manually remove an employee’s data from every system they’re a part of once they leave. It’s a simple operation with an HTTP request action.

[Learn more about knowing when to use an HTTP request vs a Call API action](/product/enterprise-workflows/actions-and-integrations/use-call-api-actions-in-workflows)

## What you need

- The **link to the API documentation** of the app you want to send requests to

- The **subdomain (if any) used to access your account**. A lot of apps give you a subdomain when you sign up for an account, like <https://mycompany.bamboohr.com>.

- The **authentication mechanism**. The other app needs to know who has authorized the requests Atomicwork is sending on your behalf. Some apps don’t need an authentication mechanism. Some apps need an API key, and others require you to send your username and password every time. So please make sure to look this up in the documentation.

- The **API URL** to which you’ll be sending your requests. This is usually in the documentation as well. For example, the API URL to use for BambooHR is: [https://api.bamboohr.com/api/gateway.php/{companyDomain}/v1/employees/{id}/](https://api.bamboohr.com/api/gateway.php/%7BcompanyDomain%7D/v1/employees/%7Bid%7D/)

## Setting up credentials

HTTP request actions authenticate using saved credentials from the credential store. You can add credentials while creating the action, or manage them ahead of time at **Settings > Organization > Security > Credential store**. Atomicwork supports three authentication types: API key, username/password, and no authentication.

We’d recommend saving credentials with descriptive names and setting allowed hosts on each one to prevent accidental misuse. For the full details on creating, managing, and rotating credentials, see [Managing credentials](/product/platform-administration/governance/managing-credentials).

> \[!NOTE]
> These credentials are used when Atomicwork calls _out_ to another system. They’re separate from your **public API token** (**Settings > My account > Credential store**), which authenticates calls made _in_ to Atomicwork’s own API.

## Add an HTTP request action to a workflow

- Go to **Settings > Enterprise automation > Workflow library**. Select **Organization** to apply this across the organization, or select a workspace to apply it to that workspace only.

- Create a new workflow or choose the workflow you want to edit.

- Click **Add action** and select **Make an HTTP request**.

- Enter the URL to which the receiving app would like us to send information. Make sure to include the subdomain if there is one.

- Choose the operation you’d like us to perform i.e. the Request Method, next to the URL.

  1. POST sends new data to the app

  2. GET receives data from an app

  3. PUT is used to send an update. PUT is what you should use when you want to update _all_ the fields of an employee.

  4. PATCH is for when you want to update only _certain_ fields

  5. DELETE is for when you want to delete data

- Choose the credentials you’d like us to use.

- **Headers**: Some APIs require you to send particular headers along with requests, typically to provide more metadata about the operation you are performing like cached resource details or content type. You can add these in the **Headers** textbox.

- **Body**: Atomicwork supports JSON formatting for body content.

We’d recommend you build and test your request out on a platform like Postman before adding it as an action here. We’d also recommend you go through [their comprehensive getting started guide](https://learning.postman.com/docs/sending-requests/requests/) if you encounter some obstacles.

You can use the output of an action (we call this [a data pill](/product/enterprise-workflows/design-better-workflows/data-pills-in-workflow-actions)) as input for other actions.
