Dashboard
APISubscription Bot Webhook Creation API
api.botsubscription.com
GET/v1/endpoint
AuthenticationBearer
Token
Stays in this tab. Required for this endpoint — the value below is what gets sent.
Examples
curl --request GET \
  --url https://api.botsubscription.com/v1/endpoint \
  --header 'Authorization: Bearer sk_live_•••'

Create a Subscription Bot Webhook

Register a new endpoint to receive real-time event notifications from your subscription bot. When payments complete, memberships change, or other events occur, BotSubscription sends HTTP POST requests to your specified URL with event details and a signature for verification.

POST/v2/projects/{project_id}/integrations/webhooks

Authorization

Bearer API KeyRequired

API key access: Use an unrestricted project API key for payment, membership, and subscription event feeds. Restricted project keys cannot create these feeds; webhooks:create alone does not grant project-wide event access. A request with no readable events returns 401 UNAUTHORIZED.

Each project is capped at 10 webhook endpoints; the endpoint returns 409 when that limit is reached, and also rejects a second endpoint that reuses an existing URL with 409. The secret is returned only on creation—store it immediately to verify incoming signatures.

Retries: save the first successful response. A completed request made with Idempotency-Key cannot replay its signing secret and returns 409 IDEMPOTENCY_RESPONSE_NOT_REPLAYABLE. Reconcile registration state before starting another creation attempt.

Register endpoints with HTTPS, including during development. Localhost, loopback, private and reserved addresses are blocked, including hostnames resolving to them. See webhook receiver requirements.

Path Parameters

project_idstringrequired

The unique identifier of the project.

Request Body

urlstringrequired

The final, publicly reachable HTTPS URL for webhook events. Redirects are not followed.

eventsstring[]

Optional 1–64 exact event names or family selectors. For example payment-request.completed or subscription.*. Omit to subscribe to every event family available to the key.

Choose subscription bot events

Use exact names to receive a single event, such as payment-request.completed or subscription.renewal-held. Family selectors payment-request.*, membership.*, and subscription.* include their registered events. Duplicate selectors are removed before saving.

Unknown selectors and an empty array return 422 VALIDATION_ERROR. Selecting events unavailable to the creator returns 401 UNAUTHORIZED and creates nothing. webhook.test is a diagnostic event and cannot be selected.

The creator's event access is captured when registering the endpoint. Later permission changes do not stop the feed; delete the endpoint to stop delivery. Previously registered HTTP URLs no longer receive events. Delete them and register the final HTTPS address.

Last updated: