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

# Create a Webhook Endpoint

Creates a webhook endpoint. Provide the public HTTPS URL Charge should call and the event types to deliver.

<RequestExample>
  ```bash cURL theme={null}
  curl -X POST https://api.chargeapi.co/v1/webhook_endpoints \
    -H "Authorization: Bearer ch_sk_test_..." \
    --json '{
    "enabled_events": [
      "report.succeeded"
    ],
    "url": "https://example.com/webhook/endpoint"
  }'
  ```
</RequestExample>

<ResponseExample>
  ```json Response theme={null}
  {
      "id": "wh_9AXfWD8JdB9RKQiX4Q5dO9YlkSllYkAh",
      "object": "webhook_endpoint",
      "api_version": "2026-03-01",
      "application": null,
      "created": "2026-04-01T00:34:42.679Z",
      "description": null,
      "enabled_events": ["report.succeeded", "reservation.confirmed"],
      "livemode": false,
      "metadata": {},
      "secret": "whsec_JXEBYs1mbO4jcAwl9jqdmAkyJdFF5M1s",
      "status": "enabled",
      "url": "https://example.com/webhook/endpoint"
  }
  ```
</ResponseExample>

## Parameters

<ParamField body="enabled_events" type="array of string" required>
  List of event types to subscribe to.
</ParamField>

<ParamField body="url" type="string" required>
  Public HTTPS URL that will receive webhook POSTs.
</ParamField>

## More parameters

<ParamField body="api_version" type="string">
  Override the default API version for this endpoint.
</ParamField>

<ParamField body="description" type="string">
  Optional description for your own reference.
</ParamField>

<ParamField body="metadata" type="object">
  Set of key-value pairs that you can attach to an object.
</ParamField>

## Returns

Returns the created webhook endpoint.
