Amplitude Event Types API

Operations for managing event types

OpenAPI Specification

amplitude-event-types-api-openapi.yml Raw ↑
openapi: 3.1.0
info:
  title: Amplitude Attribution Annotations Event Types API
  description: The Amplitude Attribution API allows developers to send attribution campaign events to Amplitude from ad networks, attribution providers, or custom marketing tools. It associates users with the campaigns, channels, and creatives that drove their acquisition or re-engagement. This API is used to enrich Amplitude user profiles with marketing attribution data for campaign performance analysis and ROI measurement.
  version: '2'
  contact:
    name: Amplitude Support
    url: https://amplitude.com/contact
  termsOfService: https://amplitude.com/terms
servers:
- url: https://api2.amplitude.com
  description: Amplitude US Production Server
- url: https://api.eu.amplitude.com
  description: Amplitude EU Production Server
security: []
tags:
- name: Event Types
  description: Operations for managing event types
paths:
  /api/2/taxonomy/event:
    get:
      operationId: listEventTypes
      summary: Amplitude List All Event Types
      description: Retrieve all event types in the project. Optionally include deleted event types using the showDeleted parameter.
      tags:
      - Event Types
      parameters:
      - name: showDeleted
        in: query
        description: When true, include deleted event types in the response.
        schema:
          type: boolean
          default: false
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/EventTypeListResponse'
              examples:
                listEventTypes200Example:
                  summary: Default listEventTypes 200 response
                  x-microcks-default: true
                  value:
                    data:
                    - example_value
        '401':
          description: Unauthorized
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
    post:
      operationId: createEventType
      summary: Amplitude Create an Event Type
      description: Create a new event type in the tracking plan. This is for planning purposes and does not affect event ingestion.
      tags:
      - Event Types
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              required:
              - event_type
              properties:
                event_type:
                  type: string
                  description: The name of the event type.
                category:
                  type: string
                  description: The category to assign the event type to.
                description:
                  type: string
                  description: A description of the event type.
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SuccessResponse'
              examples:
                createEventType200Example:
                  summary: Default createEventType 200 response
                  x-microcks-default: true
                  value:
                    success: true
        '400':
          description: Bad request
        '401':
          description: Unauthorized
        '409':
          description: Event type already exists
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
  /api/2/taxonomy/event/{event_type}:
    get:
      operationId: getEventType
      summary: Amplitude Get an Event Type
      description: Retrieve a single event type by its name.
      tags:
      - Event Types
      parameters:
      - $ref: '#/components/parameters/eventType'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/EventType'
              examples:
                getEventType200Example:
                  summary: Default getEventType 200 response
                  x-microcks-default: true
                  value:
                    event_type: standard
                    category:
                      id: {}
                      name: {}
                    description: Example description text
        '401':
          description: Unauthorized
        '404':
          description: Event type not found
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
    put:
      operationId: updateEventType
      summary: Amplitude Update an Event Type
      description: Update an existing event type's metadata such as description or category assignment.
      tags:
      - Event Types
      parameters:
      - $ref: '#/components/parameters/eventType'
      requestBody:
        required: true
        content:
          application/x-www-form-urlencoded:
            schema:
              type: object
              properties:
                new_event_type:
                  type: string
                  description: The new name for the event type.
                category:
                  type: string
                  description: The category to assign the event type to.
                description:
                  type: string
                  description: An updated description of the event type.
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SuccessResponse'
              examples:
                updateEventType200Example:
                  summary: Default updateEventType 200 response
                  x-microcks-default: true
                  value:
                    success: true
        '401':
          description: Unauthorized
        '404':
          description: Event type not found
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
    delete:
      operationId: deleteEventType
      summary: Amplitude Delete an Event Type
      description: Delete a planned event type. This is intended for removing event types that have not yet received data. Deleting an event type that has received data does not remove the data.
      tags:
      - Event Types
      parameters:
      - $ref: '#/components/parameters/eventType'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SuccessResponse'
              examples:
                deleteEventType200Example:
                  summary: Default deleteEventType 200 response
                  x-microcks-default: true
                  value:
                    success: true
        '401':
          description: Unauthorized
        '404':
          description: Event type not found
      x-microcks-operation:
        delay: 0
        dispatcher: FALLBACK
components:
  schemas:
    EventType:
      type: object
      properties:
        event_type:
          type: string
          description: The name of the event type.
        category:
          $ref: '#/components/schemas/Category'
        description:
          type: string
          description: A description of the event type.
    Category:
      type: object
      properties:
        id:
          type: integer
          description: The unique identifier of the category.
        name:
          type: string
          description: The name of the category.
    SuccessResponse:
      type: object
      properties:
        success:
          type: boolean
          description: Whether the operation was successful.
    EventTypeListResponse:
      type: object
      properties:
        data:
          type: array
          description: Array of event types.
          items:
            $ref: '#/components/schemas/EventType'
  parameters:
    eventType:
      name: event_type
      in: path
      required: true
      description: The name of the event type.
      schema:
        type: string
externalDocs:
  description: Amplitude Attribution API Documentation
  url: https://amplitude.com/docs/apis/analytics/attribution