Get the current integration
Returns the integration that owns the API key, with its scopes and its product.
GET /v1/me
Use cases
- Check that a new API key works.
- Show which integration and which key a program uses.
- Read the scopes of the integration before a call.
Authentication
Send an API key. This endpoint requires no scope, so an integration without any scopes can call it. See Authentication.
Request
Headers
| Header | Required | Description |
|---|---|---|
Authorization | Yes | The word Bearer, a space and the API key. |
Response
The answer has the status 200.
| Field | Type | Description |
|---|---|---|
org | object | The organization that owns the integration. See Org. |
integration | object | The integration that owns the API key. See Integration. |
key | object | The API key of the request. See Key. |
scopes | array of strings | Every scope of the integration. A write scope adds the read scope of the same resource, so both are in the list. See Scopes. |
Org
| Field | Type | Description |
|---|---|---|
id | string | The ID of the organization. |
name | string | The name of the organization. |
Integration
| Field | Type | Description |
|---|---|---|
id | string | The ID of the integration. |
name | string | The name of the integration. |
product_id | string or null | The ID of the product that the integration is limited to. It is null when the integration can reach every product. See Product. |
Key
| Field | Type | Description |
|---|---|---|
id | string | The ID of the key. |
name | string | The name of the key. |
expires_at | string or null | The time when the key expires. It is null when the key does not expire. |
Errors
| Status | Reason | Description |
|---|---|---|
| 401 | An API key is required. | The request has no Authorization header, the header is empty, or the header does not use the Bearer scheme. |
| 401 | The API key is not valid. | No integration has this key. |
| 401 | The API key has expired. | The expiry date of the key has passed. |
| 429 | There are too many requests. Try again later. | See Rate limits. |
See Errors.
Example
curl https://api.seatify.dev/v1/me \
-H "Authorization: Bearer $SEATIFY_API_KEY"The answer:
{
"org": {
"id": "<org id>",
"name": "Northwind Software"
},
"integration": {
"id": "<integration id>",
"name": "Zapier",
"product_id": "<product id>"
},
"key": {
"id": "<key id>",
"name": "production",
"expires_at": null
},
"scopes": [
"policies:read",
"licenses:read",
"licenses:write",
"customers:read",
"customers:write"
]
}