Event Schemas

Update an event schema

Update an event schema and add new attributes and dimensions

Once an event schema is activated, you cannot update or delete existing attributes and dimensions however you can add new attributes and dimensions and update event schema description. operationId: updateEventSchema

patch/event_schema/{event_schema_name}

Path parameters

event_schema_namestring required
Example:rides

Request body

descriptionstring

Description of the event

filterFieldsstring[]

List of fields that can be used for filtering in usage meter

eventIdTemplatestring

Template used to generate event id based on event payload

Example request

{
  "attributes": [
    {
      "name": "distance",
      "defaultUnit": "kms"
    }
  ],
  "dimensions": [
    {
      "name": "city"
    }
  ]
}

Response

Response for Create and Get event schema requests

namestring required

Name of the event. Must be unique for an organization.

descriptionstring

Description of the event

versioninteger required

Version of event schema

status'DRAFT' | 'ACTIVE' | 'INACTIVE' | 'ARCHIVED'

Status of event schema

  • DRAFT - Schema is in draft state
  • ACTIVE - Schema is currently active
  • INACTIVE - Schema is currently inactive
  • ARCHIVED - Older version of event schema
filterFieldsstring[]
eventIdTemplatestring

Template used to generate event id based on event payload

eventLevelRevenueboolean
createdAtstring date-time
updatedAtstring date-time

Example response

{
  "version": 1,
  "status": "DRAFT",
  "attributes": [
    {
      "name": "distance",
      "defaultUnit": "kms"
    }
  ],
  "dimensions": [
    {
      "name": "city"
    }
  ]
}

Changes

Changed in 4 of the 34 revisions of this API.55

    • added the new optional request property

      new-optional-request-property

    • added the optional property to the response with the status

      response-optional-property-added

    • added the new optional request property

      new-optional-request-property

    • added the optional property to the response with the status

      response-optional-property-added

    This revision also has 3 changes that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog

    • added the optional property to the response with the status

      response-optional-property-added

    • removed the request property

      request-property-removed

    • removed the request property

      request-property-removed

    • removed the optional property from the response with the status

      response-optional-property-removed

    • removed the optional property from the response with the status

      response-optional-property-removed

    • removed the optional property from the response with the status

      response-optional-property-removed

    This revision also has 74 changes that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog