# HTTP Request (API)

<figure><img src="/files/kS2P3fj2jNZa359OSka5" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/xWWt8O9Z8ex7Tf4fnPKN" alt=""><figcaption></figcaption></figure>

## Description

**What it does:** This node enhances your workflows by allowing you to connect to external APIs (Application Programming Interfaces). Think of APIs as bridges connecting different software systems.

**When to use it?** If your workflow needs to connect with other web services, like retrieving info from a website, the HTTP Request node helps integrate it seamlessly.

## Component settings

| Parameter Name | Description                                                                                                                |
| -------------- | -------------------------------------------------------------------------------------------------------------------------- |
| Method         | <p>Choose the method</p><p><br>Options: </p><ul><li>GET</li><li>POST </li><li>PUTCH</li><li>PATCH</li><li>DELETE</li></ul> |
| URL            | Input the URL (Endpoint Link)                                                                                              |
| Header         | <p>Input the header of API, including:</p><ul><li>Key : Value</li></ul><p></p>                                             |
| Parameters     | <p>Input the Parameter of API, including:</p><ul><li>Key : Value</li></ul>                                                 |
| Payload (Body) | <p></p><p>Input the Payload of API, including:</p><ul><li>Key : Value</li></ul>                                            |

## Advanced configurations

**Failure handling strategy** lets you decide what happens if your HTTP Request runs into a problem.&#x20;

<figure><img src="/files/xW5opsfSRVpq5VM9A5u5" alt=""><figcaption></figcaption></figure>

You’ve got a few options:

* **Stop flow** – If something goes wrong, the workflow stops right here.
* **Skip** – If this request fails, just move on and keep the workflow going.
* **Retry** – Give it another shot! You can set how many times to retry and how long to wait between each try.
  * Max retry attempts:
    * Min: 1
    * Max: 3
  * Delay between retries (seconds):&#x20;
    * Min: 1
    * Max: 5

<mark style="color:red;">If all retries fail, the flow will stop at this HTTP Request node.</mark>

## Example

**Input**

<figure><img src="/files/38imnHw8VpTnY0pPRLk7" alt=""><figcaption></figcaption></figure>

**Output**

<figure><img src="/files/h43y0LDnQa0lpvwg0qIQ" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.diaflow.io/workflow-builder/nodes/built-in-tools/http-request-api.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
