Skip to main content
POST
/
webhook_endpoints
/
{webhook_endpoint}
Update a webhook subscription
curl --request POST \
  --url https://api.chargeapi.co/v1/webhook_endpoints/{webhook_endpoint} \
  --header 'Content-Type: application/json' \
  --data '{
  "description": "My production webhooks"
}'
{
  "id": null,
  "object": null,
  "api_version": null,
  "application": null,
  "created": null,
  "description": null,
  "enabled_events": [
    null
  ],
  "livemode": null,
  "metadata": null,
  "secret": null,
  "status": null,
  "url": null
}

Path Parameters

webhook_endpoint
string
required

ID of the webhook endpoint to update.

Body

application/json
description
string

New description for the endpoint.

enabled_events
string[]

Full list of event types to subscribe to. Passing an empty array clears all events.

Minimum length: 1
status
enum<string>

Enable or disable delivery of events.

Available options:
enabled,
disabled

Response

Returns the updated Webhook Endpoint object. Raises an error if the webhook ID is invalid.

id
string

Unique identifier for the webhook endpoint object.

Example:

null

object
string

String representing the object’s type. Always webhook_endpoint.

Example:

null

api_version
string | null

API version this webhook endpoint is configured to receive. Defaults to the account's version if null.

Example:

null

application
string | null

ID of the application associated with this webhook, if applicable.

Example:

null

created
integer

Time at which the webhook endpoint was created.

Example:

null

description
string | null

An optional description for the webhook endpoint.

Example:

null

enabled_events
string[]

List of event types that will trigger this webhook endpoint.

livemode
boolean

Indicates whether this webhook endpoint is operating in live or test mode.

Example:

null

metadata
object

Set of key-value pairs for attaching custom structured data to the webhook endpoint.

Example:

null

secret
string

Secret used to sign webhook payloads sent to this endpoint.

Example:

null

status
enum<string>

Current status of the webhook endpoint.

Available options:
enabled,
disabled
Example:

null

url
string<uri>

The URL that will receive the webhook POST requests.

Example:

null