# Http Request

Sends an HTTP request to a third-party app's REST API endpoint.

If you need to send or retrieve data from a third-party service that ReplyCX doesn’t natively integrate with, you can use the HTTP Request action block.

This allows you to call an API endpoint and perform GET, POST, or PUT operations.

![](/files/SnxKmaTjVUzLUMejPYjp)

### **Methods:**

Choose the method of your API endpoint you want to invoke. Replycx supports:

* GET
* POST
* PUT

### **Endpoint URL:**

You must enter the full URL, starting with HTTP or HTTPS.

You can also include variables in the URL by typing '#', as some APIs pass all necessary details within the URL instead of using headers.

`https://api.weatherapi.com/v1/current.json key={ key value } =#city#`

Here in the above URL #city# is the variable that has been used

#### **Headers:**

Add authentication data to the HTTP request. Commonly used for bearer token based authentication.

#### **Body:**

Add the necessary details you want to include in your request.

You can send information in two ways:

#### **Raw:**

It is normal JSON format in which the request needs to be passed.

![](/files/adkFixoscvS6apJGbrZq)

#### **Form:**

It allows you to map the fields. You can either provide static value or map the variables.

![](/files/F4rtWS6aWy3XAfAMoIFq)

#### **Response:**

Saves the response received from the API.

![](/files/R0Te4HLLYFzIY2m3eQYs)

Here we can select the variable in which we want to save the response.

### **Testing API:**

After setting up your API request, click the 'Test the API' button to view the response received.

![](/files/Ml7dJmncQ9sxe5Z6u3ms)


---

# 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://help.reply.cx/action-blocks/http-request.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.
