> ## Documentation Index
> Fetch the complete documentation index at: https://docs.storytime.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Identity

<Columns cols={2}>
  <Column>
    ### GET /v1/whoami

    Returns the identity resolved from your API key. Useful to confirm a key works end-to-end (authentication + rate limiting) with no other dependencies — a good first call when setting up an integration.

    <ResponseField name="keyId" type="string" default="Identifier of the API key used">
      Identifier of the API key used
    </ResponseField>

    <ResponseField name="brandId" type="string">
      The brand the key belongs to 
    </ResponseField>

    <ResponseField name="scopes" type="array [string]">
      Scopes granted to the key
    </ResponseField>
  </Column>

  <Column>
    ```shellscript /v1/whoami wrap theme={null}
    curl -sS https://api.storytime.io/v1/whoami \
      -H "Authorization: Bearer pk_live_xxxxxxxxxxxxxxxxxxxxxxxx"
    ```

    ```json 200 wrap theme={null}
    {
      "ok": true,
      "keyId": "k_9f8c…",
      "brandId": "abe7e83f-e57c-4e12-babe-612eef793f3d",
      "scopes": ["campaigns:read", "campaigns:write", "analytics:read"]
    }
    ```

    ```json 401 wrap theme={null}
    { 
        "ok": false,
        "code": "UNAUTHORIZED",
        "message": "Missing or invalid API key" 
    }
    ```
  </Column>
</Columns>
