Class: Application

Application

Represents an OAuth2 Application.

Constructor

(abstract) new Application()

Source:

Members

(readonly) createdAt :Date

The time the app was created at
Type:
  • Date
Source:

(readonly) createdTimestamp :number

The timestamp the app was created at
Type:
  • number
Source:

description :string

The app's description
Type:
  • string
Source:

icon :string

The app's icon hash
Type:
  • string
Source:

id :Snowflake

The ID of the app
Type:
Source:

name :string

The name of the app
Type:
  • string
Source:

Methods

coverImage(optionsopt) → {string}

A link to this application's cover image.
Parameters:
Name Type Attributes Default Description
options ImageURLOptions <optional>
{} Options for the Image URL
Source:
Returns:
URL to the cover image
Type
string

fetchAssets() → {Promise.<Array.<ApplicationAsset>>}

Gets the clients rich presence assets.
Source:
Returns:
Type
Promise.<Array.<ApplicationAsset>>

iconURL(optionsopt) → {string}

A link to the application's icon.
Parameters:
Name Type Attributes Default Description
options ImageURLOptions <optional>
{} Options for the Image URL
Source:
Returns:
URL to the icon
Type
string

toString() → {string}

When concatenated with a string, this automatically returns the application's name instead of the Oauth2Application object.
Source:
Returns:
Type
string
Example
// Logs: Application name: My App
console.log(`Application name: ${application}`);