Skip to main content

avatarUrl

@discordeno/botDocs


Documentation / @discordeno/bot / avatarUrl

Function: avatarUrl()

avatarUrl(userId, discriminator, options?): string

Builds a URL to a user's avatar stored in the Discord CDN.

Parameters

userId: BigString

The ID of the user to get the avatar of.

discriminator: string

The user's discriminator. (4-digit tag after the hashtag.)

options?

The parameters for the building of the URL.

options.avatar?: undefined | BigString

options.format?: ImageFormat

options.size?: ImageSize

Returns

string

The link to the resource.

Defined in

packages/utils/dist/types/images.d.ts:20