The key owner’s profile photo
GET/api/v1/account/avatar
- Access
- API key
- Permission
account:read
Read the API key owner’s own avatar
Bearer API key only, account:read scope, shared account rate budget (60/minute). No user selector. Banned/deleted accounts and stopped keys cannot read bytes, including conditional requests. Uses the same protected bounded writes as profile avatars and rechecks the active owner, key, scope, expiry and current avatar before every write. An absent avatar or obsolete revision returns 404 AVATAR_UNAVAILABLE. HEAD has no body; Range is ignored. Clients may explicitly retain only the current revision locally; HTTP/shared caches must not store the response.
Example request
curl "https://lac.pics/api/v1/account/avatar" \
-H "Authorization: Bearer lac_api_YOUR_KEY"Parameters
Query
revisionintegerThe revision the edit is based on:
revisionfromGET /pastes/{id}.0–2,147,483,647
Headers
If-None-Matchstring
Responses
- 200The owner’s normalized 256×256 WebP.
string · binary - 304Matching ETag, after the same authorization and current-avatar checks; no body.
- 400Invalid revision.
- 403SCOPE_REQUIRED: account:read is required.
- 413JSON body exceeds 1 MB before authentication; upload and quota limits may also refuse this operation.
- 429RATE_LIMITED: shared account rate budget.
- 500Unexpected server failure.
Error codes
| Code | Status | Message |
|---|---|---|
BEARER_REQUIRED | 401 | A Bearer key is required. |
ACCOUNT_UNAVAILABLE | 404 | The account is unavailable. |
AVATAR_UNAVAILABLE | 404 | The avatar is unavailable. |
AVATAR_BUSY | 503 | Avatar processing is busy. Try again shortly. |
Answers of any method with a key (an invalid or expired key, a missing permission, too many requests) are in Errors.