Change a key's default payer mode
curl --request PATCH \
--url https://api.floprouter.com/v1/auth/keys/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"payer": "credit"
}
'const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({payer: 'credit'})
};
fetch('https://api.floprouter.com/v1/auth/keys/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.floprouter.com/v1/auth/keys/{id}"
payload = { "payer": "credit" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text){
"id": "key_03182966a7c7",
"prefix": "fr_CrOS",
"name": "e2e t-grant-user",
"payer_mode": "grant",
"created_at": "2026-11-24T02:41:38.000Z",
"last_used_at": "2026-11-24T03:09:16.000Z",
"revoked": false,
"revoked_at": null
}{
"error": {
"code": 400,
"message": "each message needs a role of system, developer, user or assistant (tool messages are not supported)",
"metadata": {
"reason": "invalid_message"
}
}
}{
"error": {
"code": 401,
"message": "a wallet API key is required (Authorization: Bearer fr_...); see POST /v1/auth/challenge",
"metadata": {
"reason": "unauthorized"
}
}
}{
"error": {
"code": 404,
"message": "no such session",
"metadata": {
"reason": "session_not_found"
}
}
}Auth
Change a key's default payer mode
PATCH
/
v1
/
auth
/
keys
/
{id}
Change a key's default payer mode
curl --request PATCH \
--url https://api.floprouter.com/v1/auth/keys/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"payer": "credit"
}
'const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({payer: 'credit'})
};
fetch('https://api.floprouter.com/v1/auth/keys/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.floprouter.com/v1/auth/keys/{id}"
payload = { "payer": "credit" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text){
"id": "key_03182966a7c7",
"prefix": "fr_CrOS",
"name": "e2e t-grant-user",
"payer_mode": "grant",
"created_at": "2026-11-24T02:41:38.000Z",
"last_used_at": "2026-11-24T03:09:16.000Z",
"revoked": false,
"revoked_at": null
}{
"error": {
"code": 400,
"message": "each message needs a role of system, developer, user or assistant (tool messages are not supported)",
"metadata": {
"reason": "invalid_message"
}
}
}{
"error": {
"code": 401,
"message": "a wallet API key is required (Authorization: Bearer fr_...); see POST /v1/auth/challenge",
"metadata": {
"reason": "unauthorized"
}
}
}{
"error": {
"code": 404,
"message": "no such session",
"metadata": {
"reason": "session_not_found"
}
}
}