Oauth Revoke
curl --request POST \
--url https://api.member.dev/oauth/revoke \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.member.dev/oauth/revoke"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.member.dev/oauth/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://api.member.dev/oauth/revoke",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.member.dev/oauth/revoke"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.member.dev/oauth/revoke")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.member.dev/oauth/revoke")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_bodyoauth
Oauth Revoke
Token Revocation Endpoint (RFC 7009).
Accepts a token (access or refresh) via application/x-www-form-urlencoded. Optional token_type_hint is accepted but not required.
SECURITY:
- Confidential clients MUST authenticate via client_secret_basic (RFC 7009 §2.1). Missing or wrong secret → 401 invalid_client.
- The presented token’s RS256 signature is VERIFIED before any revocation state changes (a forged token can never blacklist a victim’s jti). Token ownership is enforced — a client may only revoke a token issued to IT.
- For a valid, owned, unknown, or forged token the response is 200 with an empty body (RFC 7009 §2.2 — no info leak about token existence/ownership).
- Revoking a refresh token also drops the entire Valkey refresh family so sibling tokens (stolen copies) are immediately dead.
- A genuine STORAGE/infra failure during the blacklist or family write is NOT swallowed — it propagates as a 5xx so we never report a false “revoked” 200.
This is an OAuth2 standard endpoint — NOT JSON:API.
POST
/
oauth
/
revoke
Oauth Revoke
curl --request POST \
--url https://api.member.dev/oauth/revoke \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.member.dev/oauth/revoke"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.member.dev/oauth/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://api.member.dev/oauth/revoke",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.member.dev/oauth/revoke"
req, _ := http.NewRequest("POST", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.member.dev/oauth/revoke")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.member.dev/oauth/revoke")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_bodyAuthorizations
Send platform JWTs, contact JWTs, or team API keys as Authorization: Bearer <token>.
Response
200 - application/vnd.api+json
Successful Response