> ## Documentation Index
> Fetch the complete documentation index at: https://docs.ensync.cloud/llms.txt
> Use this file to discover all available pages before exploring further.

# Create Event Definition

> Creates a new event definition

### Body Parameters

<ParamField body="name" type="string" required>
  Event name (e.g., `order/created`, `payment/completed`)
</ParamField>

<ParamField body="payload" type="object" required>
  Event payload schema defining expected fields and types
</ParamField>

<RequestExample>
  ```bash cURL theme={null}
  curl -X POST "https://config.gms.ensync.cloud/v1/event" \
    -H "X-API-KEY: your-api-key" \
    -H "Content-Type: application/json" \
    -d '{
      "name": "order/created",
      "payload": {
        "orderId": "string",
        "amount": "number",
        "customerId": "string",
        "items": "array"
      }
    }'
  ```
</RequestExample>

<ResponseExample>
  ```json theme={null}
  {
    "message": "Event definition created successfully"
  }
  ```
</ResponseExample>
