---
title: "TransformEventWithPlaybook"
method: POST
path: "/v1.1/test/transform_event_with_playbook"
tags: ["ControlService"]
---

# TransformEventWithPlaybook

`POST /v1.1/test/transform_event_with_playbook`

Receives a playbook and input event and returns the transformed output.

## Request body

- ProtobufControlpbV1TransformEventWithPlaybookRequest
  - `inputEvent` union — The event payload to transform through the playbook. Can be the original client event or intermediate output from a prior transform step. Use original_event to provide the unmodified client event when input_event has been transformed and may be missing metadata fields.
    - object, nullable
    - GoogleProtobufStruct
      - `fields` object, nullable — Unordered map of dynamically typed values.
  - `originalEvent` union — The unmodified client event. Used to derive event name for playbook stanza matching. When omitted, event identifiers are extracted from input_event.
    - object, nullable
    - GoogleProtobufStruct
      - `fields` object, nullable — Unordered map of dynamically typed values.
  - `pipelineFilter` union — PipelineFilter is optional and would run prior to the Playbook
    - object, nullable
    - ProtobufStreamingpbV1PipelineFilter
      - `byLua` union — Will filter any event when the value of the LUA expression returns true If there is an error with the LUA filter the event will NOT be dropped
        - object, nullable
        - ProtobufStreamingpbV1FilterOpLua
          - `body` string
  - `playbook` union — Playbook is optional, but one of either playbook or pipeline_filter required. Both is also valid.
    - object, nullable
    - ProtobufStreamingpbV1Playbook
      - `author` string — Deprecated fields keeping for JSON/YAML backwards compatibility vs. setting reserved fields
      - `default` union
        - object, nullable
        - ProtobufStreamingpbV1Stanza
          - `enrichments` union[], nullable
            - union
              - …
          - `expressions` union[], nullable
            - union
              - …
          - `filters` union[], nullable
            - union
              - …
          - `mappings` union[], nullable
            - union
              - …
          - `spreadings` union[], nullable
            - union
              - …
      - `eventSpecific` object, nullable
      - `global` union
        - object, nullable
        - ProtobufStreamingpbV1Stanza
          - `enrichments` union[], nullable
            - union
              - …
          - `expressions` union[], nullable
            - union
              - …
          - `filters` union[], nullable
            - union
              - …
          - `mappings` union[], nullable
            - union
              - …
          - `spreadings` union[], nullable
            - union
              - …
      - `modes` string[], nullable
      - `params` union[], nullable
        - union
          - object, nullable
          - ProtobufStreamingpbV1Parameter
            - `defaultValue` string
            - `description` string
            - `exampleValue` string
            - `isOptional` boolean
            - `isSensitive` boolean
            - `name` string
      - `version` string

## Response `200`

OK

- ProtobufControlpbV1TransformEventWithPlaybookResponse
  - `outputEvent` union
    - object, nullable
    - GoogleProtobufStruct
      - `fields` object, nullable — Unordered map of dynamically typed values.

## Other responses

- `4XX` — Something is wrong with your request such as missing or invalid data. Correct your request and try again.
- `5XX` — Internal server error. Try again later or reach out to MetaRouter support.

---

[API](https://skmtc.net/metarouter/apis/control-api.md) · [All operations](https://skmtc.net/metarouter/apis/control-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/metarouter/control-api/versions/5afc05bfaaa2/schema)
