ClientUser
Extends
Constructors
new ClientUser(client, data, application)
1new ClientUser(2 client: UsingClient,3 data: APIUser,4 application: Pick<APIApplication, "id" | "flags">): ClientUser
Parameters
Parameter | Type |
---|---|
client | UsingClient |
data | APIUser |
application | Pick <APIApplication , "id" | "flags" > |
Returns
Overrides
Source
seyfert/src/structures/ClientUser.ts:7
Properties
Property | Modifier | Type | Overrides | Inherited from |
---|---|---|---|---|
accentColor | public | undefined | null | number | User .accentColor | User .accentColor |
application | public | Pick <APIApplication , "id" | "flags" > | - | - |
avatar | public | null | string | User .avatar | User .avatar |
avatarDecoration | public | undefined | null | string | User .avatarDecoration | User .avatarDecoration |
banner | public | undefined | null | string | User .banner | User .banner |
bot | public | boolean | User .bot | User .bot |
client | readonly | UsingClient | User .client | User .client |
discriminator | public | string | User .discriminator | User .discriminator |
email | public | undefined | null | string | User .email | User .email |
flags | public | undefined | UserFlags | User .flags | User .flags |
globalName | public | null | string | User .globalName | User .globalName |
id | public | string | User .id | User .id |
locale | public | undefined | string | User .locale | User .locale |
mfaEnabled | public | undefined | boolean | User .mfaEnabled | User .mfaEnabled |
premiumType | public | undefined | UserPremiumType | User .premiumType | User .premiumType |
publicFlags | public | undefined | UserFlags | User .publicFlags | User .publicFlags |
system | public | undefined | boolean | User .system | User .system |
username | public | string | User .username | User .username |
verified | public | undefined | boolean | User .verified | User .verified |
Accessors
createdAt
1get createdAt(): Date
createdAt gets the creation Date instace of the current object.
Returns
Date
Source
seyfert/src/structures/extra/DiscordBase.ts:27
createdTimestamp
1get createdTimestamp(): number
Create a timestamp for the current object.
Returns
number
Source
seyfert/src/structures/extra/DiscordBase.ts:20
name
1get name(): string
Returns
string
Source
seyfert/src/structures/User.ts:14
tag
1get tag(): string
Returns
string
Source
seyfert/src/structures/User.ts:10
Methods
avatarDecorationURL()
1avatarDecorationURL(options?: CDNUrlOptions): undefined | string
Parameters
Parameter | Type |
---|---|
options ? | CDNUrlOptions |
Returns
undefined
| string
Inherited from
Source
seyfert/src/structures/User.ts:43
avatarURL()
1avatarURL(options?: CDNUrlOptions): string
Parameters
Parameter | Type |
---|---|
options ? | CDNUrlOptions |
Returns
string
Inherited from
Source
seyfert/src/structures/User.ts:36
bannerURL()
1bannerURL(options?: CDNUrlOptions): undefined | string
Parameters
Parameter | Type |
---|---|
options ? | CDNUrlOptions |
Returns
undefined
| string
Inherited from
Source
seyfert/src/structures/User.ts:48
dm()
1dm(force: boolean): Promise<DMChannel>
Open a DM with the user
Parameters
Parameter | Type | Default value |
---|---|---|
force | boolean | false |
Returns
Promise
<DMChannel
>
Inherited from
Source
seyfert/src/structures/User.ts:28
edit()
1edit(body: RESTPatchAPICurrentUserJSONBody): Promise<ClientUser>
Parameters
Parameter | Type |
---|---|
body | RESTPatchAPICurrentUserJSONBody |
Returns
Promise
<ClientUser
>
Source
seyfert/src/structures/ClientUser.ts:20
fetch()
1fetch(): Promise<ClientUser>
Fetch user
Returns
Promise
<ClientUser
>
Overrides
Source
seyfert/src/structures/ClientUser.ts:15
presence()
1presence(): ReturnCache<undefined | Omit<GatewayPresenceUpdate, "user"> & Object & Object>
Returns
ReturnCache
<undefined
| Omit
<GatewayPresenceUpdate
, "user"
> & Object
& Object
>
Inherited from
Source
seyfert/src/structures/User.ts:53
toString()
1toString(): string
Returns
string
Inherited from
Source
seyfert/src/structures/User.ts:57
write()
1write(body: Omit<RESTPostAPIChannelMessageJSONBody, "components" | "embeds" | "poll"> & SendResolverProps): Promise<Message>
Parameters
Parameter | Type |
---|---|
body | Omit <RESTPostAPIChannelMessageJSONBody , "components" | "embeds" | "poll" > & SendResolverProps |
Returns
Promise
<Message
>