OAuth Clients
OAuth client endpoints manage the applications that can use Aero2 as an identity provider. When you register a client, you get a client_id and client_secret that the application uses to authenticate with Aero2's token endpoint. Clients belong to the application determined by the subdomain.
Returns all registered OAuth clients.
{
"clients": [
{
"id": "client-uuid",
"client_id": "my-app",
"name": "My Application",
"redirect_uris": [
"https://app.example.com/callback"
],
"created_at": "2026-01-15T08:00:00Z"
}
]
}Registers a new OAuth client. Returns the client secret (only shown once).
| Parameter | Type | Description |
|---|---|---|
| name* body | string | Human-readable client name |
| redirect_uris* body | string[] | Allowed redirect URIs |
{
"name": "My Application",
"redirect_uris": [
"https://app.example.com/callback"
]
}{
"id": "client-uuid",
"client_id": "generated-client-id",
"client_secret": "generated-secret-shown-once",
"name": "My Application",
"redirect_uris": [
"https://app.example.com/callback"
]
}Returns details of a specific OAuth client (secret is not included).
| Parameter | Type | Description |
|---|---|---|
| id* path | string | Client ID |
{
"id": "client-uuid",
"client_id": "my-app",
"name": "My Application",
"redirect_uris": [
"https://app.example.com/callback"
],
"created_at": "2026-01-15T08:00:00Z"
}Updates an OAuth client's configuration.
| Parameter | Type | Description |
|---|---|---|
| id* path | string | Client ID |
| name body | string | Client name |
| redirect_uris body | string[] | Allowed redirect URIs |
{
"name": "My Updated App",
"redirect_uris": [
"https://app.example.com/callback",
"https://staging.example.com/callback"
]
}{
"message": "Client updated"
}Deletes an OAuth client and revokes all associated grants.
| Parameter | Type | Description |
|---|---|---|
| id* path | string | Client ID |
{
"message": "Client deleted"
}Generates a new client secret. The old secret is immediately invalidated. The new secret is only shown once.
| Parameter | Type | Description |
|---|---|---|
| id* path | string | Client ID |
{
"client_secret": "new-secret-shown-once"
}Returns all user grants (authorizations) for a specific client.
| Parameter | Type | Description |
|---|---|---|
| id* path | string | Client ID |
{
"grants": [
{
"id": "grant-uuid",
"user_id": "user-uuid",
"user_email": "jane@example.com",
"scopes": "openid profile email",
"created_at": "2026-02-01T10:00:00Z"
}
]
}Revokes all user grants for a specific client. Users will need to re-authorize.
| Parameter | Type | Description |
|---|---|---|
| id* path | string | Client ID |
{
"message": "All grants revoked",
"revoked_count": 5
}