---
title: "Fetch an agent avatar image"
method: GET
path: "/api/v1/files/{file}/avatar"
---

# Fetch an agent avatar image

`GET /api/v1/files/{file}/avatar`

Returns the raw image bytes for an agent's profile picture identified by `file`.
This endpoint is designed for integration partners (such as Slack) that fetch
avatar URLs via plain GET requests without bearer token support. Authorization
is performed via a short, stable capability `token` rather than an HTTP header.

The `token` is an HMAC-based capability tied to the file ID. It does not expire,
but it is invalidated when the agent's profile picture is replaced or the agent is
deleted — shared caches may continue serving the old image until the
`Cache-Control` max-age of one hour elapses. The endpoint never redirects to
a signed storage URL; bytes are served inline so behavior is consistent across
storage backends.

All failure modes — invalid file ID, invalid token, file not currently referenced
as an agent avatar — return a uniform `404` to avoid acting as an existence oracle.

## Path parameters

- `file` string, required

## Query parameters

- `token` string, required

## Response `200`

Raw image bytes of the agent avatar, served with the file's original content type.

## Other responses

- `404` — Not found

---

[API](https://skmtc.net/archastro/apis/archastro-platform-api.md) · [All operations](https://skmtc.net/archastro/apis/archastro-platform-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/archastro/archastro-platform-api/versions/a8772b442f86/schema)
