{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/aura-historia-com/json-schema/aura-historia-com-admin-access-token-collection-data-schema.json",
  "title": "AdminAccessTokenCollectionData",
  "description": "Cursor-paginated, secret-free access-token metadata for an administrator's explicit target user.\n`searchAfter` is a `[created RFC3339 timestamp, AccessToken ID]` cursor and is omitted\nwhen the current page is terminal. The cursor timestamp is not returned as item metadata.\nThis schema intentionally has no raw token, masked token, short-token, or token-hash property.\n",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/aura-historia-com-user-account-api-openapi.yml#/components/schemas/AdminAccessTokenCollectionData",
  "type": "object",
  "required": [
    "items",
    "size"
  ],
  "properties": {
    "items": {
      "type": "array",
      "description": "Access-token metadata returned for the target user, including expired and current tokens.",
      "items": {
        "$ref": "#/$defs/AdminAccessTokenData"
      }
    },
    "size": {
      "type": "integer",
      "format": "int64",
      "minimum": 0,
      "maximum": 100,
      "description": "Number of items returned in the current page."
    },
    "searchAfter": {
      "type": [
        "array",
        "null"
      ],
      "minItems": 2,
      "maxItems": 2,
      "items": {
        "type": "string"
      },
      "description": "`[created RFC3339 timestamp, AccessToken ID]` cursor for the next page, omitted when no more results are available."
    }
  },
  "$defs": {
    "AccessTokenScopeData": {
      "type": "string",
      "enum": [
        "auctions:read",
        "auctions:write",
        "listing-sources:read",
        "parties:read",
        "parties:write",
        "partnership-applications:read",
        "partnership-applications:write",
        "partnerships:read",
        "partnerships:write",
        "admin-overview:read",
        "search-filters:read",
        "notifications:read",
        "notifications:write",
        "product-listings:read",
        "product-listings:write",
        "listing-sources:write",
        "users:read",
        "users:write",
        "access-tokens:read",
        "access-tokens:write",
        "search-filters:write",
        "watchlist:read",
        "watchlist:write"
      ],
      "description": "Aura Historia access-token and OAuth scope string.\nThe value is one of the capabilities supported by the canonical access-token and OAuth flows.\n"
    },
    "AdminAccessTokenData": {
      "type": "object",
      "description": "Secret-free Aura Historia access-token metadata returned by the admin target-user listing.\nThe representation contains no raw token, masked token, short-token, or token-hash value.\n`expires` is omitted when the token has no expiration and is returned for both expired and current tokens.\n",
      "required": [
        "userId",
        "accessTokenId",
        "name",
        "scopes",
        "origin"
      ],
      "properties": {
        "userId": {
          "type": "string",
          "description": "Explicit target user who owns the access token."
        },
        "accessTokenId": {
          "type": "string",
          "description": "Unique identifier of the access token."
        },
        "name": {
          "type": "string",
          "maxLength": 128,
          "description": "User-defined display name of the access token."
        },
        "scopes": {
          "type": "array",
          "uniqueItems": true,
          "description": "Granted access-token scopes.",
          "items": {
            "$ref": "#/$defs/AccessTokenScopeData"
          }
        },
        "origin": {
          "type": "string",
          "description": "Origin recorded by the canonical access-token model."
        },
        "expires": {
          "type": [
            "string",
            "null"
          ],
          "format": "date-time",
          "description": "Optional RFC3339 expiration timestamp; expired and current tokens are both listed."
        }
      }
    }
  }
}