OAuth
List and manage OAuth grants
Retrieve a list of OAuth grants
GET /oauth/grants
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
limit | integer | no | Number of items to return. |
after | string | no | Return items after this cursor. |
before | string | no | Return items before this cursor. |
Example
curl -X GET "$SESAMESEND_URL/oauth/grants" \
-H "Authorization: Bearer $OPENSEND_API_KEY"Responses
| Status | Description |
|---|---|
200 | OK |
{
"object": "list",
"has_more": false,
"data": [
{
"id": "string",
"client_id": "string",
"scopes": [
"string"
],
"created_at": "2023-10-06 23:47:56.678+00",
"revoked_at": "2023-10-06 23:47:56.678+00",
"revoked_reason": null,
"client": {
"name": "string",
"logo_uri": null
}
}
]
}Revoke an OAuth grant
DELETE /oauth/grants/{oauth_grant_id}
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
oauth_grant_id | string | yes | The OAuth grant ID. |
Example
curl -X DELETE "$SESAMESEND_URL/oauth/grants/<oauth_grant_id>" \
-H "Authorization: Bearer $OPENSEND_API_KEY"Responses
| Status | Description |
|---|---|
200 | OK |
{
"object": "oauth_grant",
"id": "string",
"revoked_at": "2023-10-06T23:47:56.678Z",
"revoked_reason": "string"
}