Skip to content
Documentation menu

Token

The identity of the token and its workspace.

Current token and workspace#

GET/me

No scope required

Returns the token used (name, prefix, scopes, expiration), the workspace it is bound to, its plan and the request limit per minute. No scope is required: any valid token can call this route, which makes it the reference connection test.

Responses

200 OK

FieldTypeDescription
datarequiredobject
Nested fields and variants
FieldTypeDescription
data.tokenrequiredobject
data.token.idrequiredstring (ulid)
data.token.namerequiredstring
data.token.prefixrequiredstring

Beginning of the token, never its value.

data.token.scopesrequiredarray
data.token.scopes[]requiredstring

Permission of a token. A write scope also grants the read scope of its family: the token stores both (short_links:write grants short_links:read, and likewise for qr_codes and link_pages).

Values: short_links:read, short_links:write, qr_codes:read, qr_codes:write, link_pages:read, link_pages:write, analytics:read, webhooks:manage

data.token.expires_atrequiredstring (date-time) | null

null: never expires.

data.workspacerequiredobject
data.workspace.idrequiredstring (ulid)
data.workspace.namerequiredstring
data.workspace.planrequiredstring

Key of the workspace's plan.

data.rate_limitrequiredobject
data.rate_limit.per_minuterequiredinteger | null

Requests per minute per token; null: unlimited by contract. All of the workspace's tokens combined get twice that.

Errors All codes

  • 401

    Token missing, unknown, expired or revoked (code: invalid_token). Also returned when the token's creator has left the workspace. Rejections are counted per IP (30 per minute): beyond that, 429.

  • 402

    The workspace's plan does not include API access (feature: api.access), or the requested plan entitlement is missing or its quota is reached: plan_required, quota_reached or plan_restricted (resource read-only after a downgrade).

  • 429

    Limit reached (code: rate_limited): per token, for all of the workspace's tokens combined, or a route's own limit (QR code export, POST /webhooks, PATCH /webhooks/{webhook} with url, POST /webhooks/{webhook}/test, …/resend). Wait Retry-After seconds. The X-RateLimit-* headers are present; X-RateLimit-Reset follows the limiter whose X-RateLimit-Remaining is the lowest.

curl -sS "https://api.hyllo.fr/api/public/v1/me" \
  -H "Authorization: Bearer $HYLLO_API_TOKEN" \
  -H "Accept: application/json"

Response example

{
  "data": {
    "token": {
      "id": "01ARZ3NDEKTSV4RRFFQ69G5FAV",
      "name": "string",
      "prefix": "hyl_a1b2c3d4",
      "scopes": [
        "short_links:read"
      ],
      "expires_at": "2026-01-01T00:00:00Z"
    },
    "workspace": {
      "id": "01ARZ3NDEKTSV4RRFFQ69G5FAV",
      "name": "string",
      "plan": "pro"
    },
    "rate_limit": {
      "per_minute": 1
    }
  }
}

Schemas

Me
FieldTypeDescription
tokenrequiredobject
workspacerequiredobject
rate_limitrequiredobject
Nested fields and variants
FieldTypeDescription
token.idrequiredstring (ulid)
token.namerequiredstring
token.prefixrequiredstring

Beginning of the token, never its value.

token.scopesrequiredarray
token.scopes[]requiredstring

Permission of a token. A write scope also grants the read scope of its family: the token stores both (short_links:write grants short_links:read, and likewise for qr_codes and link_pages).

Values: short_links:read, short_links:write, qr_codes:read, qr_codes:write, link_pages:read, link_pages:write, analytics:read, webhooks:manage

token.expires_atrequiredstring (date-time) | null

null: never expires.

workspace.idrequiredstring (ulid)
workspace.namerequiredstring
workspace.planrequiredstring

Key of the workspace's plan.

rate_limit.per_minuterequiredinteger | null

Requests per minute per token; null: unlimited by contract. All of the workspace's tokens combined get twice that.