OAuth Server
Dynamic client registration
Register a client dynamically (RFC 7591). Available only when Dynamic Client Registration is enabled on the app. Public but rate-limited by IP. Redirect URIs are validated against the app’s allowlist.
POST
/
v1
/
session
/
oauth
/
register
Dynamic client registration
curl --request POST \
--url https://{appId}.session.prelude.dev/v1/session/oauth/register \
--header 'Content-Type: application/json' \
--data '
{
"client_name": "<string>",
"redirect_uris": [
"<string>"
],
"scope": "<string>",
"grant_types": [
"<string>"
],
"response_types": [
"<string>"
],
"token_endpoint_auth_method": "<string>"
}
'import requests
url = "https://{appId}.session.prelude.dev/v1/session/oauth/register"
payload = {
"client_name": "<string>",
"redirect_uris": ["<string>"],
"scope": "<string>",
"grant_types": ["<string>"],
"response_types": ["<string>"],
"token_endpoint_auth_method": "<string>"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
client_name: '<string>',
redirect_uris: ['<string>'],
scope: '<string>',
grant_types: ['<string>'],
response_types: ['<string>'],
token_endpoint_auth_method: '<string>'
})
};
fetch('https://{appId}.session.prelude.dev/v1/session/oauth/register', 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://{appId}.session.prelude.dev/v1/session/oauth/register",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'client_name' => '<string>',
'redirect_uris' => [
'<string>'
],
'scope' => '<string>',
'grant_types' => [
'<string>'
],
'response_types' => [
'<string>'
],
'token_endpoint_auth_method' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$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://{appId}.session.prelude.dev/v1/session/oauth/register"
payload := strings.NewReader("{\n \"client_name\": \"<string>\",\n \"redirect_uris\": [\n \"<string>\"\n ],\n \"scope\": \"<string>\",\n \"grant_types\": [\n \"<string>\"\n ],\n \"response_types\": [\n \"<string>\"\n ],\n \"token_endpoint_auth_method\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://{appId}.session.prelude.dev/v1/session/oauth/register")
.header("Content-Type", "application/json")
.body("{\n \"client_name\": \"<string>\",\n \"redirect_uris\": [\n \"<string>\"\n ],\n \"scope\": \"<string>\",\n \"grant_types\": [\n \"<string>\"\n ],\n \"response_types\": [\n \"<string>\"\n ],\n \"token_endpoint_auth_method\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://{appId}.session.prelude.dev/v1/session/oauth/register")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"client_name\": \"<string>\",\n \"redirect_uris\": [\n \"<string>\"\n ],\n \"scope\": \"<string>\",\n \"grant_types\": [\n \"<string>\"\n ],\n \"response_types\": [\n \"<string>\"\n ],\n \"token_endpoint_auth_method\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"client_id": "<string>",
"client_id_issued_at": 123,
"client_name": "<string>",
"redirect_uris": [
"<string>"
],
"token_endpoint_auth_method": "<string>",
"scope": "<string>",
"grant_types": [
"<string>"
],
"response_types": [
"<string>"
]
}{
"error": "<string>",
"error_description": "<string>"
}{
"error": "<string>",
"error_description": "<string>"
}Body
application/json
RFC 7591 dynamic client registration request.
Example:
"Example MCP client"
Example:
["https://claude.ai/api/mcp/auth_callback"]
Space-delimited requested scopes.
Example:
"mcp:read"
Example:
["authorization_code"]
Example:
["code"]
Example:
"none"
Response
Created
RFC 7591 client information response.
Example:
"oac_01jqebhswje1ka1z7ahr9rfsgt"
Example:
1718000000
Example:
"Example MCP client"
Example:
["https://claude.ai/api/mcp/auth_callback"]
Example:
"none"
Example:
"mcp:read"
Example:
["authorization_code"]
Example:
["code"]
Previous
Token requestExchange an authorization `code` (with its PKCE `code_verifier`) for
tokens, or rotate a session with `grant_type=refresh_token`
(RFC 6749 §4.1.3 and §6). Public client — no client authentication
(`token_endpoint_auth_method` is `none`). The request body is
`application/x-www-form-urlencoded`.
Next
⌘I
Dynamic client registration
curl --request POST \
--url https://{appId}.session.prelude.dev/v1/session/oauth/register \
--header 'Content-Type: application/json' \
--data '
{
"client_name": "<string>",
"redirect_uris": [
"<string>"
],
"scope": "<string>",
"grant_types": [
"<string>"
],
"response_types": [
"<string>"
],
"token_endpoint_auth_method": "<string>"
}
'import requests
url = "https://{appId}.session.prelude.dev/v1/session/oauth/register"
payload = {
"client_name": "<string>",
"redirect_uris": ["<string>"],
"scope": "<string>",
"grant_types": ["<string>"],
"response_types": ["<string>"],
"token_endpoint_auth_method": "<string>"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
client_name: '<string>',
redirect_uris: ['<string>'],
scope: '<string>',
grant_types: ['<string>'],
response_types: ['<string>'],
token_endpoint_auth_method: '<string>'
})
};
fetch('https://{appId}.session.prelude.dev/v1/session/oauth/register', 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://{appId}.session.prelude.dev/v1/session/oauth/register",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'client_name' => '<string>',
'redirect_uris' => [
'<string>'
],
'scope' => '<string>',
'grant_types' => [
'<string>'
],
'response_types' => [
'<string>'
],
'token_endpoint_auth_method' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$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://{appId}.session.prelude.dev/v1/session/oauth/register"
payload := strings.NewReader("{\n \"client_name\": \"<string>\",\n \"redirect_uris\": [\n \"<string>\"\n ],\n \"scope\": \"<string>\",\n \"grant_types\": [\n \"<string>\"\n ],\n \"response_types\": [\n \"<string>\"\n ],\n \"token_endpoint_auth_method\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://{appId}.session.prelude.dev/v1/session/oauth/register")
.header("Content-Type", "application/json")
.body("{\n \"client_name\": \"<string>\",\n \"redirect_uris\": [\n \"<string>\"\n ],\n \"scope\": \"<string>\",\n \"grant_types\": [\n \"<string>\"\n ],\n \"response_types\": [\n \"<string>\"\n ],\n \"token_endpoint_auth_method\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://{appId}.session.prelude.dev/v1/session/oauth/register")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"client_name\": \"<string>\",\n \"redirect_uris\": [\n \"<string>\"\n ],\n \"scope\": \"<string>\",\n \"grant_types\": [\n \"<string>\"\n ],\n \"response_types\": [\n \"<string>\"\n ],\n \"token_endpoint_auth_method\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"client_id": "<string>",
"client_id_issued_at": 123,
"client_name": "<string>",
"redirect_uris": [
"<string>"
],
"token_endpoint_auth_method": "<string>",
"scope": "<string>",
"grant_types": [
"<string>"
],
"response_types": [
"<string>"
]
}{
"error": "<string>",
"error_description": "<string>"
}{
"error": "<string>",
"error_description": "<string>"
}