---
title: c JSONata
description: Available connectors
documentId: ipaas-jsonata
locale: en-US
---

The [**JSONata**](https://camel.apache.org/components/4.10.x/jsonata-component.html) component allows you to process and transform JSON data using the JSONata query language. It enables complex operations such as filtering, transformation, and data aggregation.

**URI Syntax**: `jsonata:resourceUri`

## Main fields

*Path parameters*

| **Name** | **Description** | **Default** | **Type** |
|----------|------------------|------------|----------|
| `resourceUri` (producer)| (required) Path to the resource. You can prefix with: classpath, file, http, ref or bean.  | — | String |

*Query parameters*

| **Name** | **Description** | **Default** | **Type** |
|----------|------------------|------------|----------|
|`contentCache` (producer)  |Defines whether to use resource content cache or not.                  | true    | Boolean |
|`inputType` (producer)    |Specifies whether the input should be Jackson JsonNode or a JSON String. |Jackson  | JsonataInputOutputType |
|`outputType` (producer)   |Specifies whether the output should be Jackson JsonNode or a JSON String.| Jackson | JsonataInputOutputType |

## Example

<Steps>
<Step>
The flow starts with a POST request.
</Step>
<Step>
Then, the request content is transformed using a JSONata expression stored in the `expression.jsonata` file. The parameters indicate that:
   - Transformation results can be cached (`contentCache: true`).
   - The input type for transformation is a JSON string (`inputType: JsonString`).
   - The output type will also be a JSON string (`outputType: JsonString`).
</Step>
<Step>
The result is logged.
</Step>
</Steps>

```yaml
- from:
    uri: rest:post:hello
    steps:
      - to:
          uri: jsonata:classpath:expression.jsonata
          parameters:
            contentCache: true
            inputType: JsonString
            outputType: JsonString
      - to: "log:info"
```

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

### cURL

```
curl --location --request POST 'https://sensedia-integration-camel-poc.f6g7h8i9j0.integrations-tst.sensedia-eng.com/hello' \
--header 'Content-Type: application/json' \
--data-raw '{
    "Account": {
        "Account Name": "Firefly",
        "Order": [
            {
                "OrderID": "order103",
                "Product": [
                    {
                        "Product Name": "Bowler Hat",
                        "ProductID": 858383,
                        "SKU": "0406654608",
                        "Description": {
                            "Colour": "Purple",
                            "Width": 300,
                            "Height": 200,
                            "Depth": 210,
                            "Weight": 0.75
                        },
                        "Price": 34.45,
                        "Quantity": 2
                    }
                ]
            }
        ]
    }
}'
```

### Result

```
sensedia-integration-camel-poc-00001-deployment-5d46bd9c7dp8xr4 integration 2024-03-06 13:07:06,321 INFO  [info] (executor-thread-1) Exchange[ExchangePattern: InOut, BodyType: String, Body: {"Product price":34.45}]
```
