Revoke a token
curl --request POST \
--url https://app.sideshift.app/api/oauth/v1/revoke \
--header 'Authorization: Basic <encoded-value>' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data token=rt_9f8e... \
--data token_type_hint=refresh_tokenimport requests
url = "https://app.sideshift.app/api/oauth/v1/revoke"
payload = {
"token": "rt_9f8e...",
"token_type_hint": "refresh_token"
}
headers = {
"Authorization": "Basic <encoded-value>",
"Content-Type": "application/x-www-form-urlencoded"
}
response = requests.post(url, data=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
Authorization: 'Basic <encoded-value>',
'Content-Type': 'application/x-www-form-urlencoded'
},
body: new URLSearchParams({token: 'rt_9f8e...', token_type_hint: 'refresh_token'})
};
fetch('https://app.sideshift.app/api/oauth/v1/revoke', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.sideshift.app/api/oauth/v1/revoke",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "token=rt_9f8e...&token_type_hint=refresh_token",
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>",
"Content-Type: application/x-www-form-urlencoded"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://app.sideshift.app/api/oauth/v1/revoke"
payload := strings.NewReader("token=rt_9f8e...&token_type_hint=refresh_token")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Basic <encoded-value>")
req.Header.Add("Content-Type", "application/x-www-form-urlencoded")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://app.sideshift.app/api/oauth/v1/revoke")
.header("Authorization", "Basic <encoded-value>")
.header("Content-Type", "application/x-www-form-urlencoded")
.body("token=rt_9f8e...&token_type_hint=refresh_token")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.sideshift.app/api/oauth/v1/revoke")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Basic <encoded-value>'
request["Content-Type"] = 'application/x-www-form-urlencoded'
request.body = "token=rt_9f8e...&token_type_hint=refresh_token"
response = http.request(request)
puts response.read_body{}{
"error": "invalid_client",
"error_description": "Client authentication failed"
}{
"error": "temporarily_unavailable",
"error_description": "Rate limit exceeded"
}Revoke a token
RFC 7009 revocation. Revoking a refresh token revokes its whole family; revoking an access token adds its jti to the denylist. Always 200 for a well-formed authenticated request, even if the token is unknown (no existence oracle).
POST
/
revoke
Revoke a token
curl --request POST \
--url https://app.sideshift.app/api/oauth/v1/revoke \
--header 'Authorization: Basic <encoded-value>' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data token=rt_9f8e... \
--data token_type_hint=refresh_tokenimport requests
url = "https://app.sideshift.app/api/oauth/v1/revoke"
payload = {
"token": "rt_9f8e...",
"token_type_hint": "refresh_token"
}
headers = {
"Authorization": "Basic <encoded-value>",
"Content-Type": "application/x-www-form-urlencoded"
}
response = requests.post(url, data=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
Authorization: 'Basic <encoded-value>',
'Content-Type': 'application/x-www-form-urlencoded'
},
body: new URLSearchParams({token: 'rt_9f8e...', token_type_hint: 'refresh_token'})
};
fetch('https://app.sideshift.app/api/oauth/v1/revoke', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.sideshift.app/api/oauth/v1/revoke",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "token=rt_9f8e...&token_type_hint=refresh_token",
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>",
"Content-Type: application/x-www-form-urlencoded"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://app.sideshift.app/api/oauth/v1/revoke"
payload := strings.NewReader("token=rt_9f8e...&token_type_hint=refresh_token")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Basic <encoded-value>")
req.Header.Add("Content-Type", "application/x-www-form-urlencoded")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://app.sideshift.app/api/oauth/v1/revoke")
.header("Authorization", "Basic <encoded-value>")
.header("Content-Type", "application/x-www-form-urlencoded")
.body("token=rt_9f8e...&token_type_hint=refresh_token")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.sideshift.app/api/oauth/v1/revoke")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Basic <encoded-value>'
request["Content-Type"] = 'application/x-www-form-urlencoded'
request.body = "token=rt_9f8e...&token_type_hint=refresh_token"
response = http.request(request)
puts response.read_body{}{
"error": "invalid_client",
"error_description": "Client authentication failed"
}{
"error": "temporarily_unavailable",
"error_description": "Rate limit exceeded"
}Authorizations
Confidential-client authentication at the token/revoke endpoints — HTTP Basic client_id:client_secret (or the equivalent client_secret_post body params). Public (PKCE) clients send only client_id and use no scheme.
Body
application/x-www-form-urlencoded
Response
Acknowledged (empty body).
The response is of type object.
⌘I