API reference Account
Get the key's workspace
Returns the workspace a key acts in, the key's scopes, its creator's role and whether money fields are visible.
GET
/api/v1/public/meUse this to check a key before you build on it. No scope beyond read is needed.
Response
workspace.idstringWorkspace UUID.
workspace.namestringWorkspace name.
workspace.slugstringWorkspace slug.
authstringapi_key, or session when called with a signed-in session token.keyobject | nullThe key, or
null for a session.key.idstringKey UUID.
key.namestringThe name given at creation.
key.prefixstringThe first 12 characters of the key.
key.scopesarrayAny of
read, write, read:money.rolestringThe creator's current role slug:
admin, manager (Creative Manager), creator (Editor) or editor (Agency).revenue_visiblebooleanWhether money fields are returned to this key.
Example request
curl https://api.pipory.com/api/v1/public/me \
-H "Authorization: Bearer pip_your_key"
Example response
{
"workspace": {
"id": "0b5e7d1a-3c2f-4e8b-9a6d-1f2e3d4c5b6a",
"name": "Acme Watches",
"slug": "acme-watches"
},
"auth": "api_key",
"key": {
"id": "7c9e2b4d-1a3f-4b5c-8d6e-9f0a1b2c3d4e",
"name": "Zapier",
"prefix": "pip_Q2x8mKpL",
"scopes": ["read", "write"]
},
"role": "admin",
"revenue_visible": false
}
Errors
| Status | Code | Meaning |
|---|---|---|
401 | invalid_api_key | Missing, unknown, revoked or expired key |
403 | upgrade_required | The workspace is not on a paid plan |
429 | rate_limited | Over the key's rate limit |