Generated from Postwind commit a19b2e4 OpenAPI 0.1.0 synced

Keys HTTP API

GET/api/v1/admin/keys

list_admin_keys

Lists the admin keys in id order, at most 100 per call, the bootstrap key and revoked and expired ones included.

Call it
to find an admin key’s id or to review full access.
Needs
an admin key.
Returns
items (id, name, prefix, dates; never a key string) and next_cursor: pass it as cursor for the next page; null on the last page. The same as GET /api/v1/admin/keys.

Arguments

  • object
  • cursorstring | null

    next_cursor of the previous page; leave it out for the first.

  • limitinteger · int64 | null

    Page size, 1 to 100; default 50.

    1–100

No other arguments are accepted.

Result

The result comes back as structuredContent, with the same JSON as a text block.

  • object · all fields required
  • itemsarray of ApiKey

    In id order; revoked and expired keys included.

    10 fields
    • ApiKey object · all fields required
    • created_atstring · date-time
    • expires_atstring · date-time | null

      null: never.

    • idstring · uuid

      What revoking the key takes.

    • The kind of an API key.

      admin Everything, projects and admin keys included.

      project One project, within its scopes.

    • last_used_atstring · date-time | null

      When the key was last used; null: not recorded yet.

    • namestring
    • prefixstring

      The public part of the key string, pw_<adm|prj>_<prefix>_...: how to tell which key a client holds.

    • project_idstring · uuid | null

      The key’s project; null for an admin key.

    • revoked_atstring · date-time | null

      When the key was revoked; null while it is not.

    • scopesarray of KeyScope

      What the key may do; every scope for an admin key.

  • next_cursorstring | null

    Pass as cursor for the next page; null on the last page.

Definitions

ApiKey

An API key, without its secret (list_api_keys, list_admin_keys).

  • object · all fields required
  • created_atstring · date-time
  • expires_atstring · date-time | null

    null: never.

  • idstring · uuid

    What revoking the key takes.

  • The kind of an API key.

    admin Everything, projects and admin keys included.

    project One project, within its scopes.

  • last_used_atstring · date-time | null

    When the key was last used; null: not recorded yet.

  • namestring
  • prefixstring

    The public part of the key string, pw_<adm|prj>_<prefix>_...: how to tell which key a client holds.

  • project_idstring · uuid | null

    The key’s project; null for an admin key.

  • revoked_atstring · date-time | null

    When the key was revoked; null while it is not.

  • scopesarray of KeyScope

    What the key may do; every scope for an admin key.

KeyKind

The kind of an API key.

string · enum

admin Everything, projects and admin keys included.

project One project, within its scopes.

KeyScope

A right of a project key. An admin key has all of them.

string · enum

  • read
  • write
  • send
  • keys

Errors

A failed call answers isError: true with a code from the same table as the HTTP API, and detail. How tools report errors

HTTP API

The same operation over HTTP: GET /api/v1/admin/keys