Added rpc files
This commit is contained in:
parent
83efa2c6e8
commit
bb7571f6b8
3 changed files with 38 additions and 0 deletions
33
rpc/common.ts
Normal file
33
rpc/common.ts
Normal file
|
@ -0,0 +1,33 @@
|
|||
/**
|
||||
* https://discord.com/developers/docs/topics/opcodes-and-status-codes#rpc-rpc-error-codes
|
||||
*/
|
||||
export enum RPCErrorCodes {
|
||||
UnknownError = 1000,
|
||||
InvalidPayload = 4000,
|
||||
InvalidCommand = 4002,
|
||||
InvalidGuild,
|
||||
InvalidEvent,
|
||||
InvalidChannel,
|
||||
InvalidPermissions,
|
||||
InvalidClientId,
|
||||
InvalidOrigin,
|
||||
InvalidToken,
|
||||
InvalidUser,
|
||||
OAuth2Error = 5000,
|
||||
SelectChannelTimedOut,
|
||||
GetGuildTimedOut,
|
||||
SelectVoiceForceRequired,
|
||||
CaptureShortcutAlreadyListening,
|
||||
}
|
||||
|
||||
/**
|
||||
* https://discord.com/developers/docs/topics/opcodes-and-status-codes#rpc-rpc-close-event-codes
|
||||
*/
|
||||
export enum RPCCloseEventCodes {
|
||||
InvalidClientId = 4000,
|
||||
InvalidOrigin,
|
||||
RateLimited,
|
||||
TokenRevoked,
|
||||
InvalidVersion,
|
||||
InvalidEncoding,
|
||||
}
|
4
rpc/index.ts
Normal file
4
rpc/index.ts
Normal file
|
@ -0,0 +1,4 @@
|
|||
// This file exports all the types available in the recommended API version
|
||||
// Thereby, things MAY break in the future. Try sticking to imports from a specific version
|
||||
|
||||
export * from './v9';
|
1
rpc/v9.ts
Normal file
1
rpc/v9.ts
Normal file
|
@ -0,0 +1 @@
|
|||
export * from './common';
|
Loading…
Reference in a new issue