segment Transformations API

Operations for managing transformations that modify event data before it reaches destinations.

Operations 5

GET /transformations List transformations #
POST /transformations Create transformation #
GET /transformations/{transformationId} Get transformation #
PATCH /transformations/{transformationId} Update transformation #
DELETE /transformations/{transformationId} Delete transformation #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/segment-transformations-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

segment-transformations-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Segment Public Transformations API
  description: The Segment Public API allows developers to programmatically manage Segment workspaces and their resources. It supports full CRUD operations for sources, destinations, warehouses, tracking plans, functions, transformations, and catalog entries. The API follows REST conventions with standard HTTP methods and predictable resource-oriented URLs. It is available for Team and Business tier customers and is the recommended API going forward, replacing the older Config API.
  version: 1.0.0
  contact:
    name: Segment Support
    url: https://segment.com/help/
  termsOfService: https://segment.com/legal/terms/
servers:
- url: https://api.segmentapis.com
  description: Production Server
security:
- bearerAuth: []
tags:
- name: Transformations
  description: Operations for managing transformations that modify event data before it reaches destinations.
paths:
  /transformations:
    get:
      operationId: listTransformations
      summary: List transformations
      description: Returns a list of all transformations in the workspace. Requires the Protocols feature to be enabled.
      tags:
      - Transformations
      parameters:
      - $ref: '#/components/parameters/PaginationCursor'
      - $ref: '#/components/parameters/PaginationCount'
      responses:
        '200':
          description: Transformations retrieved successfully.
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: object
                    properties:
                      transformations:
                        type: array
                        items:
                          $ref: '#/components/schemas/Transformation'
                      pagination:
                        $ref: '#/components/schemas/Pagination'
        '401':
          $ref: '#/components/responses/Unauthorized'
    post:
      operationId: createTransformation
      summary: Create transformation
      description: Creates a new transformation in the workspace.
      tags:
      - Transformations
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
              - name
              - sourceId
              properties:
                name:
                  type: string
                  description: The name of the transformation.
                sourceId:
                  type: string
                  description: The ID of the source to apply the transformation to.
                destinationMetadataId:
                  type: string
                  description: The ID of the destination metadata if destination-scoped.
                enabled:
                  type: boolean
                  description: Whether the transformation is enabled.
                if:
                  type: string
                  description: FQL condition that determines when the transformation runs.
                newEventName:
                  type: string
                  description: New event name to rename the event to.
                propertyRenames:
                  type: array
                  description: List of property renames to apply.
                  items:
                    type: object
                    properties:
                      oldName:
                        type: string
                        description: The original property name.
                      newName:
                        type: string
                        description: The new property name.
                propertyValueTransformations:
                  type: array
                  description: List of property value transformations to apply.
                  items:
                    type: object
                    properties:
                      propertyPaths:
                        type: array
                        items:
                          type: string
                        description: The property paths to transform.
                      propertyValue:
                        type: string
                        description: The new value.
      responses:
        '200':
          description: Transformation created successfully.
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: object
                    properties:
                      transformation:
                        $ref: '#/components/schemas/Transformation'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
  /transformations/{transformationId}:
    get:
      operationId: getTransformation
      summary: Get transformation
      description: Returns a single transformation by its ID.
      tags:
      - Transformations
      parameters:
      - $ref: '#/components/parameters/TransformationId'
      responses:
        '200':
          description: Transformation retrieved successfully.
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: object
                    properties:
                      transformation:
                        $ref: '#/components/schemas/Transformation'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
    patch:
      operationId: updateTransformation
      summary: Update transformation
      description: Updates an existing transformation with the provided changes.
      tags:
      - Transformations
      parameters:
      - $ref: '#/components/parameters/TransformationId'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  description: Updated name.
                enabled:
                  type: boolean
                  description: Whether the transformation is enabled.
                if:
                  type: string
                  description: Updated FQL condition.
                newEventName:
                  type: string
                  description: Updated new event name.
      responses:
        '200':
          description: Transformation updated successfully.
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: object
                    properties:
                      transformation:
                        $ref: '#/components/schemas/Transformation'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
    delete:
      operationId: deleteTransformation
      summary: Delete transformation
      description: Deletes a transformation from the workspace.
      tags:
      - Transformations
      parameters:
      - $ref: '#/components/parameters/TransformationId'
      responses:
        '200':
          description: Transformation deleted successfully.
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: object
                    properties:
                      status:
                        type: string
                        description: Status of the delete operation.
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
components:
  responses:
    BadRequest:
      description: The request was invalid or malformed.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    NotFound:
      description: The requested resource was not found.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Unauthorized:
      description: Authentication credentials were missing or invalid.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  schemas:
    Error:
      type: object
      properties:
        errors:
          type: array
          items:
            type: object
            properties:
              type:
                type: string
                description: The error type.
              message:
                type: string
                description: A human-readable error message.
              field:
                type: string
                description: The field that caused the error, if applicable.
              data:
                type: object
                description: Additional error data.
                additionalProperties: true
    Pagination:
      type: object
      properties:
        current:
          type: string
          description: Cursor pointing to the current page.
        next:
          type: string
          description: Cursor pointing to the next page. Null if no more pages.
        totalEntries:
          type: integer
          description: Total number of entries across all pages.
    Transformation:
      type: object
      properties:
        id:
          type: string
          description: The unique identifier of the transformation.
        name:
          type: string
          description: The name of the transformation.
        sourceId:
          type: string
          description: The ID of the source this transformation applies to.
        destinationMetadataId:
          type: string
          description: The destination metadata ID if destination-scoped.
        enabled:
          type: boolean
          description: Whether the transformation is enabled.
        if:
          type: string
          description: The FQL condition that determines when the transformation runs.
        newEventName:
          type: string
          description: The new event name if renaming.
        propertyRenames:
          type: array
          description: Property renames applied by this transformation.
          items:
            type: object
            properties:
              oldName:
                type: string
                description: The original property name.
              newName:
                type: string
                description: The new property name.
        propertyValueTransformations:
          type: array
          description: Property value transformations applied.
          items:
            type: object
            properties:
              propertyPaths:
                type: array
                items:
                  type: string
                description: The property paths to transform.
              propertyValue:
                type: string
                description: The new value.
  parameters:
    PaginationCount:
      name: pagination[count]
      in: query
      description: Number of items to return per page.
      schema:
        type: integer
        minimum: 1
        maximum: 200
        default: 10
    PaginationCursor:
      name: pagination[cursor]
      in: query
      description: Cursor for pagination. Use the cursor returned in a previous response to fetch the next page.
      schema:
        type: string
    TransformationId:
      name: transformationId
      in: path
      required: true
      description: The unique identifier of the transformation.
      schema:
        type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: Segment Public API access token. Generate tokens from the Segment workspace settings.
externalDocs:
  description: Segment Public API Documentation
  url: https://docs.segmentapis.com/