---
title: t REST
description: Available triggers
documentId: ipaas-rest-trigger
locale: en-US
---

The [**REST**](https://camel.apache.org/components/4.10.x/rest-component.html) component allows you to create and manage RESTful endpoints, facilitating communication between applications via the HTTP protocol. It enables the definition of routes that respond to HTTP requests (such as `GET`, `POST`, `PUT`, and `DELETE`), processing data, invoking services, and handling information.

**URI Syntax**: `rest:method:path:uriTemplate`

### Main fields

*Path parameters*

| **Name** | **Description** | **Default** | **Type** |
|----------|---------------|------------|----------|
| `method` (common) | (required) HTTP method to use. Possible values: `get`, `post`, `put`, `delete`, `patch`, `head`, `trace`, `connect`, `options`. | — | String |
| `path` (common)   | (required) Base path. Can use `*` as a suffix to allow HTTP route wildcard matching. | — | String |
| `uriTemplate` (common) | The URI template. | — | String |


### Example

<Steps>
<Step>
The flow starts with a POST request to the `/buscar-pedido` endpoint. 
</Step>
<Step>
Then, the flow returns simulated data from the `setBody` EIP.  
</Step>
<Step>
Finally, it logs the data.
</Step>
</Steps>

```yaml
- from:
    uri: rest:post:buscar-pedido
    steps:
      - setBody:
          expression:
            constant:
              expression: |-
                {
                            "pedidoId": "PED-12345",
                            "cliente": "João Silva",
                            "itens": [
                              {
                                "produto": "Notebook",
                                "quantidade": 1,
                                "valorUnitario": 3500.00
                              },
                              {
                                "produto": "Mouse sem fio",
                                "quantidade": 2,
                                "valorUnitario": 120.00
                              }
                            ],
                            "valorTotal": 3740.00
                          }
      - log:
          message: ${body}
```

![](https://creative-ball-51b3fc85c0.media.strapiapp.com/rest_trigger_008a2c3294.png)

### Result

![](https://creative-ball-51b3fc85c0.media.strapiapp.com/rest_trigger_result_2ec3500d02.png)
