Concord - C Discord API library
A Discord API wrapper library written in C
discord_gateway_session Struct Reference

The handle for storing the Discord Gateway session. More...

#include <discord-internal.h>

Collaboration diagram for discord_gateway_session:
[legend]

Data Fields

bool is_ready
 
char id [64]
 
int shards
 
char base_url [256]
 
char resume_url [256]
 
struct discord_session_start_limit start_limit
 
int concurrent
 
int event_count
 
unsigned status
 
struct {
   bool   enable
 
   int   attempt
 
   int   limit
 
retry
 

Detailed Description

The handle for storing the Discord Gateway session.

Field Documentation

◆ is_ready

bool discord_gateway_session::is_ready

whether client is ready to start sending/receiving events

◆ id

char discord_gateway_session::id[64]

session id for resuming lost connections

◆ shards

int discord_gateway_session::shards

amount of shards being used by this session

◆ base_url

char discord_gateway_session::base_url[256]

the session base url

◆ resume_url

char discord_gateway_session::resume_url[256]

the base url for resuming

◆ start_limit

struct discord_session_start_limit discord_gateway_session::start_limit

session limits

◆ concurrent

int discord_gateway_session::concurrent

active concurrent sessions

◆ event_count

int discord_gateway_session::event_count

event counter to avoid reaching limit of 120 events per 60 sec

◆ status

unsigned discord_gateway_session::status

◆ enable

bool discord_gateway_session::enable

will attempt reconnecting if true

◆ attempt

int discord_gateway_session::attempt

current retry attempt (resets to 0 when succesful)

◆ limit

int discord_gateway_session::limit

max amount of retries before giving up

◆ 

struct { ... } discord_gateway_session::retry

retry connection structure


The documentation for this struct was generated from the following file: