# Transform

### Description

The Transform processor allows for configuring advanced conditional transformation rules on incoming telemetry.

### Supported Types

| Metrics | Logs | Traces |
| ------- | ---- | ------ |
| ✓       | ✓    | ✓      |

### Configuration Table

<table><thead><tr><th width="248.23046875">Parameter</th><th width="125.31640625">Type</th><th width="234.5">Default</th><th width="373.4453125">Description</th></tr></thead><tbody><tr><td>telemetry_type*</td><td><code>enum</code></td><td><code>Logs</code></td><td>Specifies the type of telemetry to which transformation statements are applied. One of <code>Logs</code> , <code>Metrics</code> , or <code>Traces</code></td></tr><tr><td>statements</td><td><code>strings</code></td><td></td><td>The <a href="https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/pkg/ottl#opentelemetry-transformation-language">OTTL</a> statements to execute on matching telemetry. The statements are executed in order from top to bottom.</td></tr><tr><td>conditions</td><td><code>strings</code></td><td></td><td>OTTL conditions to determine if statements should run. If any condition evaluates to true on a given log, metric, or trace, the OTTL statements will be executed on that telemetry. Individual statements may still add their own <code>where</code> clauses.</td></tr><tr><td>error_mode*</td><td><code>enum</code></td><td><code>ignore</code></td><td>One of <code>ignore</code> , <code>silent</code> , or <code>propagate</code> .<br>Determines how error handling will be performed during processing. <code>Ignore</code> will ignore errors, log the error, and continue processing. <code>Silent</code> will ignore errors without logging them, and continue processing. <code>Propagate</code> will halt processing when an error occurs and return errors up the pipeline.</td></tr><tr><td>metrics_context</td><td><code>enum</code></td><td><code>datapoint</code></td><td>Either <code>datapoint</code> or <code>metric</code> .<br>This determines the context at which the transform statements are executed on metrics.<br>Read about OTTL contexts here.</td></tr><tr><td>traces_context</td><td><code>enum</code></td><td><code>span</code></td><td>Either <code>span</code> or <code>spanevent</code> .<br>This determines the context at which the transform statements are executed on traces.<br>Read about OTTL contexts here.</td></tr></tbody></table>

<mark style="color:red;">\*</mark>*<mark style="color:red;">required field</mark>*

### Basic Example Configuration

Below is an example of a basic Transform processor configuration using multiple statements and one condition.

**Standalone Processor**

```
apiVersion: bindplane.observiq.com/v1
kind: Processor
spec:
    parameters:
        - name: telemetry_type
          value: Logs
        - name: statements
          value:
            - set(attributes["myNewFieldKey"], "myNewFieldValue")
            - delete_key(attributes, "myUnwantedKey")
        - name: conditions
          value:
            - attributes["service.name"] = "my-service-name"
        - name: error_mode
          value: ignore
```


---

# 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.bindplane.com/integrations/processors/transform.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.
