Typescript (SDK)
import { Autumn } from 'autumn-js'
const autumn = new Autumn()
const result = await autumn.keys.revoke({
customerId: "cus_123",
});from autumn_sdk import Autumn
autumn = Autumn(secret_key="am_sk_test...")
res = autumn.keys.revoke(customer_id="cus_123")curl --request POST \
--url https://api.useautumn.com/v1/keys.revoke \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'x-api-version: <x-api-version>' \
--data '
{
"customer_id": "cus_123"
}
'{
"revoked": true
}
Authorization
Revoke
Revokes every outstanding token (access and refresh) for a customer. Authenticated with your secret key. New tokens can be issued afterwards with keys.mint.
POST
/
v1
/
keys.revoke
Typescript (SDK)
import { Autumn } from 'autumn-js'
const autumn = new Autumn()
const result = await autumn.keys.revoke({
customerId: "cus_123",
});from autumn_sdk import Autumn
autumn = Autumn(secret_key="am_sk_test...")
res = autumn.keys.revoke(customer_id="cus_123")curl --request POST \
--url https://api.useautumn.com/v1/keys.revoke \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'x-api-version: <x-api-version>' \
--data '
{
"customer_id": "cus_123"
}
'{
"revoked": true
}
Revokes every outstanding token — access and refresh — for a customer. Authenticated with your secret key. Issue new tokens afterwards with
keys.mint.await autumn.keys.revoke({ customerId: "cus_123" });
curl -X POST "https://api.useautumn.com/v1/keys.revoke" \
-H "Authorization: Bearer am_sk_live_..." \
-H "Content-Type: application/json" \
-d '{ "customer_id": "cus_123" }'
Body Parameters
Response
{
"revoked": true
}
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Headers
Body
application/json
The customer whose tokens (every outstanding access + refresh token) should be revoked.
Response
200 - application/json
OK