English
English
Appearance
English
English
Appearance
https://api.repliz.com/public/oauth/revokeDisconnects your app from a user, for example when they sign out of your app. Part of Login with Repliz.
client_id and client_secret, in the body or as Basic Auth (Authorization: Basic Base64(client_id:client_secret)). A public app sends only client_id.application/x-www-form-urlencoded or application/json| Field | Type | Required | Description |
|---|---|---|---|
token | string | Yes | A refresh token or an access token of the connection. |
token_type_hint | string | No | refresh_token or access_token, when you know which one token is. |
client_id | string | Yes | Client ID of your app. Can go in the Basic Authorization header instead. |
client_secret | string | Confidential apps | Client secret of your app. Can go in the Basic Authorization header instead. |
Either token ends the whole connection: the refresh token stops working and access tokens are refused right away, even before their hour is up. The app shows up in the user's Setting → Connected Apps until it's revoked, and the user can disconnect it there too.
curl -X POST "https://api.repliz.com/public/oauth/revoke" \
-u "YOUR_CLIENT_ID:YOUR_CLIENT_SECRET" \
-d token=YOUR_REFRESH_TOKEN \
-d token_type_hint=refresh_tokenimport axios from 'axios';
await axios.post(
'https://api.repliz.com/public/oauth/revoke',
new URLSearchParams({
token: 'YOUR_REFRESH_TOKEN',
token_type_hint: 'refresh_token',
client_id: 'YOUR_CLIENT_ID',
client_secret: 'YOUR_CLIENT_SECRET',
}),
);await fetch('https://api.repliz.com/public/oauth/revoke', {
method: 'POST',
body: new URLSearchParams({
token: 'YOUR_REFRESH_TOKEN',
client_id: 'YOUR_CLIENT_ID',
client_secret: 'YOUR_CLIENT_SECRET',
}),
});{}{
"error": "invalid_client",
"error_description": "invalid client_secret"
}The answer is 200 also when the token was already invalid or belongs to another app, so a sign-out can always go ahead.