Users
Upload avatar
Upload a new profile picture for the authenticated user.
PUT /users/me/avatar
Uploads a new profile picture and returns the updated profile. The request is multipart/form-data with a single file field.
Authentication: Bearer token · Permission:
account:write · Rate limit: 10 / 5 minRequest body
multipart/form-data
file
file required
The image to upload. Must be an image type (
image/*) and at most 5 MB.Request
curl -X PUT https://api.twominutereports.com/v1/users/me/avatar \
-H "Authorization: Bearer tmrc_live_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" \
-F "file=@/path/to/avatar.png"
Response
Returns the updated user object with the new avatarUrl.
{
"success": true,
"data": {
"id": "0190f8a1-2b3c-7d4e-8f90-1a2b3c4d5e6f",
"name": "Ada Lovelace",
"email": "[email protected]",
"avatarUrl": "https://assets.gox.ai/tmr/avatars/0190f8a1.png",
"preferences": {
"appearance": "light",
"notifications": {
"email": { "billing": true, "productUpdates": true, "promotional": false }
}
},
"createdAt": "2026-01-12T08:15:00.000Z"
}
}
Returned when no file is sent or the file is not an image.
{
"success": false,
"error": { "code": "BAD_REQUEST", "message": "Only image files are allowed" }
}
{
"success": false,
"error": { "code": "PAYLOAD_TOO_LARGE", "message": "Request body is too large" }
}
{
"success": false,
"error": { "code": "TOO_MANY_REQUESTS", "message": "Too many requests — please slow down and try again later" }
}