Interface ClientOptions

Hierarchy

  • ClientOptions

Properties

ForceDisableREST?: boolean

NOT RECOMMENDED, CAN BREAK THINGS

REST methods are used to communicate with the Guilded by sending requests. This feature was included in previous TouchGuild versions but we've changed how we manage REST requests.

Forcing disabling REST methods may crash the library when receiving events, reorganizing cache hierarchy, which means that they are used internally, you can still disable those methods by setting this boolean to true, be aware that it isn't recommended.

Default Value

false

RESTOptions?: RESTOptions

REST Options are used for REST requests. You can change some properties there. This includes some properties like the baseURL and much more.

collectionLimits?: {
    announcementComments?: number;
    announcements?: number;
    calendarComments?: number;
    docComments?: number;
    docs?: number;
    messages?: number;
    scheduledEvents?: number;
    scheduledEventsRSVPS?: number;
    threadComments?: number;
    threads?: number;
}

Type declaration

  • Optional announcementComments?: number
  • Optional announcements?: number
  • Optional calendarComments?: number
  • Optional docComments?: number
  • Optional docs?: number
  • Optional messages?: number
  • Optional scheduledEvents?: number
  • Optional scheduledEventsRSVPS?: number
  • Optional threadComments?: number
  • Optional threads?: number
connectionMessage?: boolean

This boolean is used to enable or disable the > Connection established. message when connection is successfully established.

token: string

The bot's bearer token, needed to connect to the bot.

waitForCaching?: boolean

If true, will wait for caching before emitting the event.

This will increase the event emit latency, but ensure that you receive the cached items in time.

By disabling this, you reduce latency between you & Guilded, and won't receive cached items in time.

Default

true