Appearance
Reset API user credentials
Reset the API user credentials. This will invalidate all existing API keys and generate a new one.
| POST | /users/{id}/reset-api-credentials |
Path parameters
| Name | Type | Description | Required |
|---|---|---|---|
id | string | Id of the target user | ✅ |
Response schema
{}
// API key ID
apiKeyId: string;// API key secret
apiKeySecret: string;Examples
bash
curl \
-X POST \
-H "Content-Type: application/json" \
-H "Authorization: Bearer {jwt}" \
"$API_BASE_URL/users/{id}/reset-api-credentials"ts
const url = "<base-url>/users/{id}/reset-api-credentials";
const headers = {
"Content-Type": "application/json",
Authorization: "Bearer <jwt>"
};
fetch(url, { headers, method: "POST" }).then(res => {
console.log(res)
});python
import requests
url = "<base-url>/users/{id}/reset-api-credentials"
headers = {
"Content-Type": "application/json",
"Authorization": "Bearer <jwt>"
}
print(requests.post(url, headers=headers))