Skip to main content
PATCH
/
api
/
v3
/
admin
/
webhook_endpoints
/
{id}
/
disable
Spree Admin SDK
import { createAdminClient } from '@spree/admin-sdk'

const client = createAdminClient({
  baseUrl: 'https://your-store.com',
  secretKey: 'sk_xxx',
})

// Pause an endpoint without deleting it. The optional `reason` is shown next
// to the disabled indicator in the admin.
const endpoint = await client.webhookEndpoints.disable('whe_xxx', {
  reason: 'Investigating elevated 5xx rate',
})
{
  "id": "whe_UkLWZg9DAJ",
  "name": "Order pipeline",
  "url": "https://shop.example.com/webhooks/orders",
  "active": false,
  "subscriptions": [
    "order.created",
    "order.completed",
    "product.created"
  ],
  "disabled_reason": "Investigating",
  "created_at": "2026-06-05T13:13:17.803Z",
  "updated_at": "2026-06-05T13:13:18.094Z",
  "disabled_at": "2026-06-05T13:13:18.094Z",
  "secret_key": null,
  "last_delivery_at": null,
  "recent_delivery_count": 0,
  "recent_failure_count": 0,
  "total_delivery_count": 0,
  "successful_delivery_count": 0,
  "failed_delivery_count": 0
}

Authorizations

x-spree-api-key
string
header
required

Secret API key for admin access

Authorization
string
header
required

JWT token for admin user authentication

Headers

x-spree-api-key
string
required
Authorization
string
required

Bearer token for admin authentication

Path Parameters

id
string
required

Webhook endpoint ID

Body

application/json
reason
string
Example:

"Investigating elevated 5xx rate"

Response

200 - application/json

webhook endpoint disabled