v2

latestOpenAPI 3.1.12026-07-2613060964.2 KB

Get Schema

Fetch the JSON schema corresponding to a slug.

get/v1/{workspace}/schema/{schema_slug}/

Path parameters

workspacestring required

Workspace slug (staging, production, etc.)

schema_slugstring required

Unique identifier of the schema

Query parameters

mode'draft' | 'live'

Mode to fetch schema (draft or live). By default, draft schema is returned.

Response

Successfully retrieved schema object

slugstring

Unique identifier for the schema

namestring

Human-readable name of the schema

descriptionstring nullable

Description of the schema

status'draft' | 'live'

Status of returned schema. By default, draft version is returned. You can set mode=live to fetch the live schema.

hashstring

Git-like hash for version tracking

json_schemaobject nullable

Structure of the workflow or event payload. Follows standard json schema specification. You can link this schema to a workflow or event to validate their input payload in API response. Same schema can be linked to multiple workflows and events.

created_atstring date-time

When the schema was created

updated_atstring date-time

When the schema was last updated

committed_atstring date-time nullable

When the schema was last committed. Only available for live schema.

commit_messagestring nullable

Last commit message. Only available for live schema.

Example response

{
  "slug": "new-order-placed",
  "name": "Order Placed Event",
  "description": "Schema for order placement action",
  "status": "draft",
  "hash": "382b707d4b1f8999a1xxxxxxxx",
  "json_schema": {
    "type": "object",
    "$schema": "https://json-schema.org/draft/2020-12/schema",
    "required": [
      "order_id",
      "amount"
    ],
    "properties": {
      "order_id": {
        "type": "string"
      },
      "amount": {
        "type": "string"
      }
    },
    "additionalProperties": true
  },
  "created_at": "2025-08-27T09:30:57.945326Z",
  "updated_at": "2025-08-29T15:37:37.650177Z",
  "committed_at": null,
  "commit_message": null
}