User API Keys
internal

Create user API key

Changed on
post/api/v1/user-api-keys

Request

  • Base URL
    https://app.scanopy.net
  • URL
    https://app.scanopy.net/api/v1/user-api-keys
  • Auth
    API key in cookie session_id

Request body

expires_atstring date-time nullable

When this record stops being valid.

is_enabledboolean

Whether the key may still be used. Disabled keys are rejected.

keystring required

The stored key. Returned redacted except on creation and rotation.

last_usedstring date-time nullable required

When this key was last used to authenticate.

namestring required

Human-facing name for this key.

organization_idstring uuid required

The organization that owns this record.

permissions'Owner' | 'Admin' | 'Member' | 'Viewer'
site_idsstring[]

Site IDs this key has access to (hydrated from junction table)

tagsstring[] required

Tags assigned to this entity.

user_idstring uuid required

User the key acts on behalf of.

created_atstring date-time required

When this record was first created.

idstring uuid required

Server-assigned unique identifier.

updated_atstring date-time required

When this record was last modified.

Response

API key created

errorstring nullable

Not sent on a successful response. Failure messages arrive in an ApiErrorResponse.

successboolean required

Always true on a successful response.

Example response

{
  "meta": {
    "api_version": 1,
    "server_version": "0.19.4"
  }
}

Changes