Integrations
OAuth
The OAuth 2.1 authorization server: the token endpoint (client credentials, authorization code with PKCE, refresh token, JWT bearer grant), consent, and discovery metadata and keys.
Token endpoint
POST/api/v1/oauth/token
OAuth 2.1 token endpoint: client credentials, authorization code with PKCE, refresh token, JWT bearer grant
RFC 6749 §5.2 errors, with the CS-* code as error_description: invalid_client (CS-AUTH-0007), invalid_grant (CS-AUTH-0014: a code or refresh token unknown, spent, expired or not this client's, a wrong PKCE verifier or redirect URI, an assertion with a bad signature, audience or lifetime; CS-AUTH-0005: the member has not consented to the JWT integration), invalid_scope (CS-AUTH-0006), unsupported_grant_type.
AuthNone (public)
Request body
Content type application/json · required
client_idstringclient_secretstringscopestringcodestringauthorization_code
redirect_uristringauthorization_code: the URI the code was issued to
code_verifierstringauthorization_code: the PKCE verifier
refresh_tokenstringrefresh_token: rotated on every use; one spent twice revokes its family
assertionstringThe JWT bearer grant's signed assertion
Returns
200 with a TokenResponse object.
curl
curl -X POST https://sign.example.com/api/v1/oauth/token \
-u "$CLIENT_ID:$CLIENT_SECRET" \
-d grant_type=client_credentials \
-d scope="envelopes:read envelopes:write"TypeScript
import { OpenSeal } from "@openseal/sdk";
const os = new OpenSeal({ baseUrl: "https://sign.example.com" });
const token = await os.token({
clientId: process.env.CLIENT_ID,
clientSecret: process.env.CLIENT_SECRET,
grant_type: "client_credentials",
scope: "envelopes:read envelopes:write",
});Python
import os
from openseal import OpenSeal
client = OpenSeal("https://sign.example.com")
token = client.token(
client_id=os.environ["CLIENT_ID"],
client_secret=os.environ["CLIENT_SECRET"],
grant_type="client_credentials",
scope="envelopes:read envelopes:write",
){
"access_token": "eyJhbGciOiJFUzI1NiJ9.example.signature",
"token_type": "Bearer",
"expires_in": 1,
"scope": "envelopes:read",
"refresh_token": "osr_example"
}Errors this can answer
| Status | Code | When |
|---|---|---|
| 400 / 422 | CS-API-0001 | Malformed request: a parameter or member is missing, unknown or out of range; errors[] points at it |
| 413 | CS-API-0006 | The request body is over its limit |
| 415 | CS-API-0007 | The body is not application/json |
| 429 | CS-API-0003 | Rate limited: wait for Retry-After seconds |
Every error is an RFC 9457 problem with a stable code and a request_id; see Errors.
Authorization server metadata
GET/.well-known/oauth-authorization-server
OAuth authorization server metadata (RFC 8414)
AuthNone (public)
Returns
200 with application/json.
curl
curl https://sign.example.com/.well-known/oauth-authorization-serverTypeScript
import { OpenSeal } from "@openseal/sdk";
const os = new OpenSeal({ baseUrl: "https://sign.example.com" });
const data = await os.oauthMetadata();Python
import os
from openseal import OpenSeal
client = OpenSeal("https://sign.example.com")
data = client.oauth_metadata(){}Errors this can answer
| Status | Code | When |
|---|---|---|
| 429 | CS-API-0003 | Rate limited: wait for Retry-After seconds |
Every error is an RFC 9457 problem with a stable code and a request_id; see Errors.
Authorization endpoint
GET/api/v1/oauth/authorize
Authorization endpoint: hands the request to the web app's consent screen
303 to /app.html#/authorize?<the same query>; the screen signs the member in if needed, reads the checked request and posts the answer. Nothing is checked or recorded here.
AuthNone (public)
Returns
303 To the consent screen with no body.
curl
curl https://sign.example.com/api/v1/oauth/authorizeTypeScript
import { OpenSeal } from "@openseal/sdk";
const os = new OpenSeal({ baseUrl: "https://sign.example.com" });
const data = await os.authorizeRedirect();Python
import os
from openseal import OpenSeal
client = OpenSeal("https://sign.example.com")
data = client.authorize_redirect()No JSON body.
Errors this can answer
| Status | Code | When |
|---|---|---|
| 429 | CS-API-0003 | Rate limited: wait for Retry-After seconds |
Every error is an RFC 9457 problem with a stable code and a request_id; see Errors.
Answer a consent request
POST/api/v1/oauth/authorize
The member's answer to an authorization request
A staff session only (422 at /credential otherwise). allow records the member's consent (widening a live one) and answers the redirect with a one-time code (ten minutes), state and iss; deny answers it with error=access_denied. Refusals are problems at the request's member (/client_id, /redirect_uri, /response_type, /code_challenge, /scope, /state, /decision), never a redirect to an unregistered URI.
AuthAPI key or OAuth access token (Authorization: Bearer), or a staff session; any signed-in caller
Request body
Content type application/json · required
One of the client's registered redirect URIs, exactly
Space-separated; each within the client's scopes and the member's own
statestringdecisionstringPOSTonly
Returns
200 with application/json.
curl
curl -X POST https://sign.example.com/api/v1/oauth/authorize \
-H "Authorization: Bearer $OPENSEAL_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"response_type": "code",
"client_id": "0193948f-e603-7f61-8dc0-36b5c596dc09",
"redirect_uri": "https://app.example.com/openseal/callback",
"scope": "envelopes:read",
"state": "af0ifjsldkj",
"code_challenge": "examplexxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"code_challenge_method": "S256",
"decision": "allow"
}'TypeScript
import { OpenSeal } from "@openseal/sdk";
const os = new OpenSeal({ baseUrl: "https://sign.example.com", apiKey: process.env.OPENSEAL_API_KEY });
const result = await os.authorize({
body: {
"response_type": "code",
"client_id": "0193948f-e603-7f61-8dc0-36b5c596dc09",
"redirect_uri": "https://app.example.com/openseal/callback",
"scope": "envelopes:read",
"state": "af0ifjsldkj",
"code_challenge": "examplexxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"code_challenge_method": "S256",
"decision": "allow"
},
});Python
import os
from openseal import OpenSeal
client = OpenSeal("https://sign.example.com", api_key=os.environ["OPENSEAL_API_KEY"])
result = client.authorize(
body={
"response_type": "code",
"client_id": "0193948f-e603-7f61-8dc0-36b5c596dc09",
"redirect_uri": "https://app.example.com/openseal/callback",
"scope": "envelopes:read",
"state": "af0ifjsldkj",
"code_challenge": "examplexxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"code_challenge_method": "S256",
"decision": "allow",
},
){
"redirect_to": "https://app.example.com/openseal/callback"
}Errors this can answer
| Status | Code | When |
|---|---|---|
| 400 / 422 | CS-API-0001 | Malformed request: a parameter or member is missing, unknown or out of range; errors[] points at it |
| 401 | CS-AUTH-0001 | No credential, or one that is expired or revoked (CS-AUTH-0002) |
| 413 | CS-API-0006 | The request body is over its limit |
| 415 | CS-API-0007 | The body is not application/json |
| 429 | CS-API-0003 | Rate limited: wait for Retry-After seconds |
Every error is an RFC 9457 problem with a stable code and a request_id; see Errors.
Check an authorization request
GET/api/v1/oauth/authorize/request
An authorization request, checked, for the consent screen to show
The query of GET /oauth/authorize, checked against the client and the signed-in member as POST /oauth/authorize checks it; answers the client's name and the scopes asked.
AuthAPI key or OAuth access token (Authorization: Bearer), or a staff session; any signed-in caller
Query parameters
statestring
Returns
200 with application/json.
curl
curl https://sign.example.com/api/v1/oauth/authorize/request?response_type=example&client_id=0193948f-e603-7f61-8dc0-36b5c596dc09&redirect_uri=https://app.example.com/openseal/callback&scope=envelopes:read&code_challenge=example&code_challenge_method=example \
-H "Authorization: Bearer $OPENSEAL_API_KEY"TypeScript
import { OpenSeal } from "@openseal/sdk";
const os = new OpenSeal({ baseUrl: "https://sign.example.com", apiKey: process.env.OPENSEAL_API_KEY });
const data = await os.authorizeRequest({
response_type: "example",
client_id: "0193948f-e603-7f61-8dc0-36b5c596dc09",
redirect_uri: "https://app.example.com/openseal/callback",
scope: "envelopes:read",
code_challenge: "example",
code_challenge_method: "example",
});Python
import os
from openseal import OpenSeal
client = OpenSeal("https://sign.example.com", api_key=os.environ["OPENSEAL_API_KEY"])
data = client.authorize_request(
response_type="example",
client_id="0193948f-e603-7f61-8dc0-36b5c596dc09",
redirect_uri="https://app.example.com/openseal/callback",
scope="envelopes:read",
code_challenge="example",
code_challenge_method="example",
){
"client": {
"id": "01932958-d416-7d08-8aa5-a472d7b50903",
"name": "Example Signer",
"kind": "template"
},
"scopes": [
"envelopes:read"
],
"redirect_uri": "https://app.example.com/openseal/callback"
}Errors this can answer
| Status | Code | When |
|---|---|---|
| 400 / 422 | CS-API-0001 | Malformed request: a parameter or member is missing, unknown or out of range; errors[] points at it |
| 401 | CS-AUTH-0001 | No credential, or one that is expired or revoked (CS-AUTH-0002) |
| 429 | CS-API-0003 | Rate limited: wait for Retry-After seconds |
Every error is an RFC 9457 problem with a stable code and a request_id; see Errors.
List consents
GET/api/v1/oauth/consents
The apps the caller let act as them
AuthAPI key or OAuth access token (Authorization: Bearer), or a staff session; any signed-in caller
Returns
200 with application/json.
curl
curl https://sign.example.com/api/v1/oauth/consents \
-H "Authorization: Bearer $OPENSEAL_API_KEY"TypeScript
import { OpenSeal } from "@openseal/sdk";
const os = new OpenSeal({ baseUrl: "https://sign.example.com", apiKey: process.env.OPENSEAL_API_KEY });
const data = await os.listConsents();Python
import os
from openseal import OpenSeal
client = OpenSeal("https://sign.example.com", api_key=os.environ["OPENSEAL_API_KEY"])
data = client.list_consents(){
"items": [
{
"id": "01931242-3e04-782f-83e8-1cb1d2323066",
"client": {
"id": "01931242-3e04-782f-83e8-1cb1d2323066",
"name": "Example Signer"
},
"scopes": [
"envelopes:read"
],
"granted_at": "2026-11-20T09:30:00Z"
}
]
}Errors this can answer
| Status | Code | When |
|---|---|---|
| 401 | CS-AUTH-0001 | No credential, or one that is expired or revoked (CS-AUTH-0002) |
| 429 | CS-API-0003 | Rate limited: wait for Retry-After seconds |
Every error is an RFC 9457 problem with a stable code and a request_id; see Errors.
Revoke consent
DELETE/api/v1/oauth/consents/{id}
Withdraw a consent: its refresh tokens stop at once, its access tokens on their next request
AuthAPI key or OAuth access token (Authorization: Bearer), or a staff session; any signed-in caller
Path parameters
Returns
204 Withdrawn with no body.
curl
curl -X DELETE https://sign.example.com/api/v1/oauth/consents/01931242-3e04-782f-83e8-1cb1d2323066 \
-H "Authorization: Bearer $OPENSEAL_API_KEY"TypeScript
import { OpenSeal } from "@openseal/sdk";
const os = new OpenSeal({ baseUrl: "https://sign.example.com", apiKey: process.env.OPENSEAL_API_KEY });
const result = await os.revokeConsent({
id: "01931242-3e04-782f-83e8-1cb1d2323066",
});Python
import os
from openseal import OpenSeal
client = OpenSeal("https://sign.example.com", api_key=os.environ["OPENSEAL_API_KEY"])
result = client.revoke_consent(
id="01931242-3e04-782f-83e8-1cb1d2323066",
)No body.
Errors this can answer
| Status | Code | When |
|---|---|---|
| 400 / 422 | CS-API-0001 | Malformed request: a parameter or member is missing, unknown or out of range; errors[] points at it |
| 401 | CS-AUTH-0001 | No credential, or one that is expired or revoked (CS-AUTH-0002) |
| 404 | CS-API-0002 | No such object, or one of another account (answered alike) |
| 429 | CS-API-0003 | Rate limited: wait for Retry-After seconds |
Every error is an RFC 9457 problem with a stable code and a request_id; see Errors.
JSON Web Key Set
GET/.well-known/jwks.json
Keys that verify access tokens
AuthNone (public)
Returns
200 with a Jwks object.
curl
curl https://sign.example.com/.well-known/jwks.jsonTypeScript
import { OpenSeal } from "@openseal/sdk";
const os = new OpenSeal({ baseUrl: "https://sign.example.com" });
const data = await os.jwks();Python
import os
from openseal import OpenSeal
client = OpenSeal("https://sign.example.com")
data = client.jwks(){
"keys": [
{}
]
}Errors this can answer
| Status | Code | When |
|---|---|---|
| 429 | CS-API-0003 | Rate limited: wait for Retry-After seconds |
Every error is an RFC 9457 problem with a stable code and a request_id; see Errors.