Webhook event
api_key.rolled
A key was rolled; data.object is the old key, now with an end time.
- Type
api_key.rolled- The object it carries
- the
api_keyobject - Subscribe with
api_key.rolled,api_key.*or*
Example payload
The body of the request your endpoint receives, shown here over several lines. On the wire it is compact JSON; check its signature over the bytes exactly as they arrive.
Example payload
{
"id": "evt_vg45r14f64n51jsr60xqjeng",
"object": "event",
"livemode": true,
"created": "2026-09-03T09:50:00.000Z",
"type": "api_key.rolled",
"api_version": "2026-10-11",
"data": {
"object": {
"id": "key_6e3gg2c6ea176xxdek2nar6v",
"object": "api_key",
"livemode": true,
"created": "2026-09-03T09:50:00.000Z",
"name": "Shop backend",
"type": "restricted",
"prefix": "sk_live_",
"last4": "x9Tq",
"scopes": [
"checkout_sessions:write",
"orders:read",
"refunds:write",
"events:read"
],
"allowed_ips": [],
"status": "rolling",
"api_version": "2026-10-11",
"created_by": {
"type": "member",
"id": "mem_ceh1wpzdrpk13cnpcjy9w0fa"
},
"last_used_at": "2026-10-12T09:30:00.000Z",
"expires_at": "2026-10-13T12:00:00.000Z",
"rolled_from": null
},
"previous_attributes": {
"status": "active",
"expires_at": null
}
},
"request": {
"id": null,
"idempotency_key": null
},
"pending_webhooks": 1
}Fields of data.object
| Field | In this example |
|---|---|
id | "key_ |
object | "api_key" |
livemode | true |
created | "2026-09-03T09: |
name | "Shop backend" |
type | "restricted" |
prefix | "sk_live_" |
last4 | "x9Tq" |
scopes | A list of 4 items |
allowed_ips | A list of 0 items |
status | "rolling" |
api_version | "2026-10-11" |
created_by | An object with type, id |
last_used_at | "2026-10-12T09: |
expires_at | "2026-10-13T12: |
rolled_from | null |
What each field means is on the page of the api_key object. data.previous_attributes holds the old values of exactly the fields that changed: here status, expires_at.
Endpoints behind it
Calls that change merchant, team and keys. An event is also sent when a payer, the network, a timer or a person in the dashboard causes the change; the sentence above says which.