CreateRestManagerOptions
Documentation / @discordeno/rest / CreateRestManagerOptions
Interface: CreateRestManagerOptions
Defined in: rest/src/types.ts:159
Properties
applicationId?
optionalapplicationId:BigString
Defined in: rest/src/types.ts:166
For old bots that have a different bot id and application id.
Default
bot id from token
events?
optionalevents:Partial<RestManagerEvents>
Defined in: rest/src/types.ts:208
Events for the rest manager
logger?
optionallogger:Pick<{ },"debug"|"info"|"warn"|"error"|"fatal">
Defined in: rest/src/types.ts:206
The logger that the rest manager will use
Default
logger // The logger exported by @discordeno/utils
proxy?
optionalproxy:object
Defined in: rest/src/types.ts:168
Configuration when using a proxy.
authorization?
optionalauthorization:string
The authorization header value to attach when sending requests to the proxy.
authorizationHeader?
optionalauthorizationHeader:string
The authorization header name to use when sending requests to the proxy
Remarks
If the header name is set to authorization, it will override any authorization that is given even if
the requests uses OAuth2 Bearer tokens / Basic tokens
Default
"authorization" // For compatibility purposes
baseUrl
baseUrl:
string
The base url to connect to. If you create a proxy rest, that url would go here. IT SHOULD NOT END WITH A /
Default
https://discord.com/api
updateBearerTokenEndpoint?
optionalupdateBearerTokenEndpoint:string
The endpoint to use in the rest proxy to update the bearer tokens
Remarks
Should not include a / in the start
This value is actually required if you want to use updateTokenQueues
token
token:
string
Defined in: rest/src/types.ts:161
The bot token which will be used to make requests.
version?
optionalversion:ApiVersions
Defined in: rest/src/types.ts:201
The api versions which can be used to make requests.
Default
10