.rest

Type: RestManager

.addMemberToGroup(groupId:

string

,

userId:

string

)

Type: Promise<never>

Add member to group

.addReactionEmote(channelId:

string

,

contentId:

string

,

emoteId:

number

)

Type: Promise<never>

Add a reaction emote

.assignRoleToMember(serverId:

string

,

userId:

string

,

roleId:

number

)

Type: Promise<never>

Assign role to member

.awardMemberXP(serverId:

string

,

userId:

string

,

amount:

number

)

Type: Promise<RESTPostUserXpResult>

Award XP to a member

.awardRoleXP(serverId:

string

,

roleId:

string

,

amount:

number

)

Type: Promise<RESTPostRoleXpResult>

Award XP to a role

.banMember(serverId:

string

,

userId:

string

)

Ban a member from a server

.completeListItem(channelId:

string

,

itemId:

string

)

Type: Promise<never>

.createCalendarEvent(channelId:

string

,

options:RESTPostCalendarEventBody)

Create a calendar event.

.createChannel(data:RESTPostChannelsBody)

Type: Promise<RESTPostChannelsResult>

Create a channel

.createChannelMessage(channelId:

string

,

content:RESTPostChannelMessagesBody)

Send a message to a channel

.createDoc(channelId:

string

,

options:RESTPostDocsBody)

Type: Promise<RESTPostDocsResult>

Create a doc.

.createForumTopic(channelId:

string

,

options:RESTPostForumTopicBody)

Create a topic in a forum

.createListItem(channelId:

string

,

options:RESTPostListItemBody)

Type: Promise<RESTPostListItemResult>

Create a list item.

.createWebhook(serverId:

string

,

options:RESTPostServerWebhooksBody)

Create a webhook

.deleteCalendarEvent(channelId:

string

,

calendarEventId:

number

)

Type: Promise<never>

Delete a calendar event.

.deleteCalendarEventRvsp(channelId:

string

,

calendarEventId:

number

,

userId:

string

)

Type: Promise<never>

Delete an rsvp user from a calendar event

.deleteChannel(channelId:

string

)

Type: Promise<never>

Delete a channel

.deleteChannelMessage(channelId:

string

,

messageId:

string

)

Type: Promise<never>

Delete a channel message.

.deleteDoc(channelId:

string

,

docId:

number

)

Type: Promise<never>

Delete a doc from a channel.

.deleteForumTopic(channelId:

string

,

forumThreadId:

string

)

Type: Promise<never>

Delete a topic in a forum

.deleteListItem(channelId:

string

,

itemId:

string

)

Type: Promise<never>

Delete list item

.deleteMemberNickname(serverId:

string

,

userId:

string

)

Type: Promise<never>

Delete a member's nickname

.deleteReactionEmote(channelId:

string

,

contentId:

string

,

emoteId:

number

)

Type: Promise<never>

Delete a reaction emote

.deleteWebhook(serverId:

string

,

webhookId:

string

)

Type: Promise<never>

Delete a webhook

.getCalendarEvent(channelId:

string

,

calendarEventId:

number

)

Get a single calendar event.

.getCalendarEventRsvp(channelId:

string

,

calendarEventId:

number

,

userId:

string

)

Get a single rsvp from a calendar event

.getCalendarEventRsvps(channelId:

string

,

calendarEventId:

number

)

Get rsvps from a calendar event

.getCalendarEvents(channelId:

string

,

options:RESTGetCalendarEventsBody)

Get all calendar events in a specific channel.

.getChannel(channelId:

string

)

Type: Promise<RESTPostChannelsResult>

Fetch a channel

.getChannelMessage(channelId:

string

,

messageId:

string

)

Get details for a specific chat message from a chat channel.

.getChannelMessages(channelId:

string

,

options:RESTGetChannelMessagesQuery)

Get a list of the latest 50 messages from a channel.

.getDoc(channelId:

string

,

docId:

number

)

Type: Promise<RESTGetDocResult>

Get a doc from a channel.

.getDocs(channelId:

string

)

Type: Promise<RESTGetDocsResult>

Get the docs from a channel.

.getForumTopic(channelId:

string

,

forumThreadId:

string

)

Get a topic in a forum

.getForumTopics(channelId:

string

,

options:RESTGetForumTopicsQuery)

Get all topics in a forum

.getListItem(channelId:

string

,

itemId:

string

)

Type: Promise<RESTGetListItemResult>

Get list item

.getListItems(channelId:

string

)

Type: Promise<RESTGetListItemsResult>

Get list items

Type: Promise<RESTGetUserResult>

.getMember(serverId:

string

,

userId:

string

)

Type: Promise<RESTGetMemberResult>

.getMemberBan(serverId:

string

,

userId:

string

)

Type: Promise<RESTGetMemberBanResult>

Retrieve a ban from a server

.getMemberBans(serverId:

string

)

Get all bans in a server

.getMemberRoles(serverId:

string

,

userId:

string

)

Get a list of the roles assigned to a member using the id of the member.

.getMembers(serverId:

string

)

Type: Promise<RESTGetMembersResult>

.getServer(serverId:

string

)

Type: Promise<RESTGetServerResult>

Get a server

.getWebhook(serverId:

string

,

webhookId:

string

)

Get a webhook

.getWebhooks(serverId:

string

,

channelId:

string

)

Get a server's webhooks

.kickMember(serverId:

string

,

userId:

string

)

Type: Promise<never>

.lockForumTopic(channelId:

string

,

forumThreadId:

string

)

Type: Promise<never>

Lock a topic in a forum

.pinForumTopic(channelId:

string

,

forumThreadId:

string

)

Type: Promise<never>

Pin a topic in a forum

.removeMemberFromGroup(groupId:

string

,

userId:

string

)

Type: Promise<never>

Remove member from group

.removeRoleFromMember(serverId:

string

,

userId:

string

,

roleId:

number

)

Type: Promise<never>

Remove role to member

.unbanMember(serverId:

string

,

userId:

string

)

Type: Promise<never>

Unban a member from a server

.uncompleteListItem(channelId:

string

,

itemId:

string

)

Type: Promise<never>

.unlockForumTopic(channelId:

string

,

forumThreadId:

string

)

Type: Promise<never>

Unlock a topic in a forum

.unpinForumTopic(channelId:

string

,

forumThreadId:

string

)

Type: Promise<never>

Pin a topic in a forum

.updateCalendarEvent(channelId:

string

,

calendarEventId:

number

,

options:RESTPatchCalendarEventBody)

Update an existing calendar event.

.updateCalendarEventRsvpMany(channelId:

string

,

calendarEventId:

number

,

options:RESTPatchCalendarEventRsvpManyBody)

Type: Promise<never>

Update many rsvps from a calendar event

.updateCalendarEventRvsp(channelId:

string

,

calendarEventId:

number

,

userId:

string

,

options:RESTPatchCalendarEventRsvpBody)

Update an rsvp user from a calendar event

.updateChannel(channelId:

string

,

data:RESTPatchChannelBody)

Type: Promise<RESTPostChannelsResult>

Update a channel

.updateChannelMessage(channelId:

string

,

messageId:

string

,

options:RESTPutChannelMessageBody)

Update a channel message.

.updateDoc(channelId:

string

,

docId:

number

,

options:RESTPutDocBody)

Type: Promise<RESTPutDocResult>

Update a doc

.updateForumTopic(channelId:

string

,

forumThreadId:

string

,

options:RESTPatchForumTopicBody)

Update a topic in a forum

.updateListItem(channelId:

string

,

itemId:

string

,

options:RESTPutListItemBody)

Type: Promise<RESTPutListItemResult>

Update list item

.updateMemberNickname(serverId:

string

,

userId:

string

,

nickname:

string

)

Update a member's nickname.

.updateWebhook(serverId:

string

,

webhookId:

string

,

options:RESTPutServerWebhookBody)

Update a webhook