Skip to content

Update user avatar

PUT
/users/me/avatar
curl --request PUT \
--url https://api.muninx.com/users/me/avatar \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: multipart/form-data' \
--form avatar=@file

Uploads the authenticated user’s global avatar as JPEG, PNG, or WebP. The image must be no larger than 5 MB and no dimension may exceed 4000 px. Variants are stored at avatars/global/<email>/versions/{size}.webp.

Media type multipart/form-data
object
avatar
required

JPEG, PNG, or WebP image file.

string format: binary

OK

Media type application/json

Map of avatar size in pixels to the uploaded avatar URL or storage location.

object
key
additional properties
string
Example
{
"64": "https://cdn.example.com/avatars/global/[email protected]/versions/64.webp",
"128": "https://cdn.example.com/avatars/global/[email protected]/versions/128.webp",
"256": "https://cdn.example.com/avatars/global/[email protected]/versions/256.webp"
}

RFC 9457 problem details

Media type application/problem+json

RFC 9457 problem details.

object
type
string format: uri
title
string
status
integer format: int32
detail
string
instance
string format: uri
key
additional properties
any
Example generated
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"instance": "https://example.com"
}

RFC 9457 problem details

Media type application/problem+json

RFC 9457 problem details.

object
type
string format: uri
title
string
status
integer format: int32
detail
string
instance
string format: uri
key
additional properties
any
Example generated
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"instance": "https://example.com"
}

RFC 9457 problem details

Media type application/problem+json

RFC 9457 problem details.

object
type
string format: uri
title
string
status
integer format: int32
detail
string
instance
string format: uri
key
additional properties
any
Example generated
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"instance": "https://example.com"
}

RFC 9457 problem details

Media type application/problem+json

RFC 9457 problem details.

object
type
string format: uri
title
string
status
integer format: int32
detail
string
instance
string format: uri
key
additional properties
any
Example generated
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"instance": "https://example.com"
}