GuildPreview
GuildPreview ⇐ Base
Represents the preview for a guild.
Kind: global class
Extends: Base
- GuildPreview ⇐
Base
- new GuildPreview(data, client)
- .fetch() ⇒
Promise.<GuildPreview>
- .iconURL(options) ⇒
string
- .splashURL([options]) ⇒
string
- .discoverySplashURL([options]) ⇒
string
new GuildPreview(data, client)
Param | Type | Description |
---|---|---|
data | Object | The data for the guild preview |
client | Client | The instantiating client |
guildPreview.fetch() ⇒ Promise.<GuildPreview>
Fetches the previewed guild
Kind: instance method of GuildPreview
guildPreview.iconURL(options) ⇒ string
Returns the URL of the guild’s icon
Kind: instance method of GuildPreview
Returns: string
- The URL of the guild’s icon or null if no icon is available
Param | Type | Description |
---|---|---|
options | Object | Options for the icon URL |
options.dynamic | boolean | Whether the icon should be dynamically generated |
options.size | number | The size of the icon in pixels |
options.format | string | The format of the icon (e.g. “png” or “jpeg”) |
guildPreview.splashURL([options]) ⇒ string
Returns the URL for the guild splash image.
Kind: instance method of GuildPreview
Returns: string
- The URL for the guild splash image or null if no splash image is available.
Param | Type | Default | Description |
---|---|---|---|
[options] | Object | Options for the splash image. | |
[options.dynamic] | boolean | false | Whether to generate a dynamic or static image. |
[options.size] | number | The size of the image in pixels. | |
[options.format] | string | The format of the image (e.g. “webp”, “png”, etc.). |
guildPreview.discoverySplashURL([options]) ⇒ string
Returns the URL for the guild discovery splash image.
Kind: instance method of GuildPreview
Returns: string
- The URL for the guild discovery splash image or null if no discovery splash image is available.
Param | Type | Default | Description |
---|---|---|---|
[options] | Object | Options for the discovery splash image. | |
[options.dynamic] | boolean | false | Whether to generate a dynamic or static image. |
[options.size] | number | The size of the image in pixels. | |
[options.format] | string | The format of the image (e.g. “webp”, “png”, etc.). |