Concord - C Discord API library
A Discord API wrapper library written in C
|
Events sent over the Gateway socket to the client. More...
Typedefs | |
typedef enum discord_event_scheduler | discord_event_scheduler_t |
return value of discord_set_event_scheduler() callback More... | |
typedef enum discord_event_scheduler(* | discord_ev_scheduler) (struct discord *client, const char data[], size_t size, enum discord_gateway_events event) |
Event Handling Mode callback. More... | |
Functions | |
void | discord_set_event_scheduler (struct discord *client, discord_ev_scheduler callback) |
Provides control over Discord event's callback scheduler. More... | |
void | discord_add_intents (struct discord *client, uint64_t code) |
Subscribe to Discord Events. More... | |
void | discord_remove_intents (struct discord *client, uint64_t code) |
Unsubscribe from Discord Events. More... | |
void | discord_set_prefix (struct discord *client, const char prefix[]) |
Set a mandatory prefix before commands. More... | |
void | discord_set_on_command (struct discord *client, char *command, void(*callback)(struct discord *client, const struct discord_message *event)) |
Set command/callback pair. More... | |
void | discord_set_on_commands (struct discord *client, char *const commands[], int amount, void(*callback)(struct discord *client, const struct discord_message *event)) |
Set a variadic series of NULL terminated commands to a callback. More... | |
void | discord_set_next_wakeup (struct discord *client, int64_t delay) |
Set the time for wakeup function to be called. More... | |
void | discord_set_on_wakeup (struct discord *client, void(*callback)(struct discord *client)) |
Triggered at a arbitrary interval value set at discord_set_next_wakeup() More... | |
void | discord_set_on_idle (struct discord *client, void(*callback)(struct discord *client)) |
Triggers when idle. More... | |
void | discord_set_on_cycle (struct discord *client, void(*callback)(struct discord *client)) |
Triggers once per event-loop cycle. More... | |
void | discord_set_on_ready (struct discord *client, void(*callback)(struct discord *client, const struct discord_ready *event)) |
Triggers when the client session is ready. More... | |
void | discord_set_on_application_command_permissions_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_application_command_permissions *event)) |
Triggers when an application command permission is updated. More... | |
void | discord_set_on_auto_moderation_rule_create (struct discord *client, void(*callback)(struct discord *client, const struct discord_auto_moderation_rule *event)) |
Triggers when an auto moderation rule is created. More... | |
void | discord_set_on_auto_moderation_rule_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_auto_moderation_rule *event)) |
Triggers when an auto moderation rule is updated. More... | |
void | discord_set_on_auto_moderation_rule_delete (struct discord *client, void(*callback)(struct discord *client, const struct discord_auto_moderation_rule *event)) |
Triggers when an auto moderation rule is deleted. More... | |
void | discord_set_on_auto_moderation_action_execution (struct discord *client, void(*callback)(struct discord *client, const struct discord_auto_moderation_action_execution *event)) |
Triggers when an auto moderation rule is triggered and an execution is executed (e.g a message was blocked) More... | |
void | discord_set_on_channel_create (struct discord *client, void(*callback)(struct discord *client, const struct discord_channel *event)) |
Triggers when a channel is created. More... | |
void | discord_set_on_channel_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_channel *event)) |
Triggers when a channel is updated. More... | |
void | discord_set_on_channel_delete (struct discord *client, void(*callback)(struct discord *client, const struct discord_channel *event)) |
Triggers when a channel is deleted. More... | |
void | discord_set_on_channel_pins_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_channel_pins_update *event)) |
Triggers when a channel pin is updated. More... | |
void | discord_set_on_thread_create (struct discord *client, void(*callback)(struct discord *client, const struct discord_channel *event)) |
Triggers when a thread is created. More... | |
void | discord_set_on_thread_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_channel *event)) |
Triggers when a thread is updated. More... | |
void | discord_set_on_thread_delete (struct discord *client, void(*callback)(struct discord *client, const struct discord_channel *event)) |
Triggers when a thread is deleted. More... | |
void | discord_set_on_thread_list_sync (struct discord *client, void(*callback)(struct discord *client, const struct discord_thread_list_sync *event)) |
Triggers when the current user gains access to a channel. More... | |
void | discord_set_on_thread_member_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_thread_member *event)) |
Triggers when a thread the bot is in gets updated. More... | |
void | discord_set_on_thread_members_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_thread_members_update *event)) |
Triggers when someone is added or removed from a thread. More... | |
void | discord_set_on_guild_create (struct discord *client, void(*callback)(struct discord *client, const struct discord_guild *event)) |
Triggers when a guild is created. More... | |
void | discord_set_on_guild_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_guild *event)) |
Triggers when a guild is updated. More... | |
void | discord_set_on_guild_delete (struct discord *client, void(*callback)(struct discord *client, const struct discord_guild *event)) |
Triggers when a guild is deleted. More... | |
void | discord_set_on_guild_ban_add (struct discord *client, void(*callback)(struct discord *client, const struct discord_guild_ban_add *event)) |
Triggers when a user is banned from a guild. More... | |
void | discord_set_on_guild_ban_remove (struct discord *client, void(*callback)(struct discord *client, const struct discord_guild_ban_remove *event)) |
Triggers when a user is unbanned from a guild. More... | |
void | discord_set_on_guild_emojis_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_guild_emojis_update *event)) |
Triggers when a guild emojis are updated. More... | |
void | discord_set_on_guild_stickers_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_guild_stickers_update *event)) |
Triggers when a guild stickers are updated. More... | |
void | discord_set_on_guild_integrations_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_guild_integrations_update *event)) |
Triggers when a guild integrations are updated. More... | |
void | discord_set_on_guild_member_add (struct discord *client, void(*callback)(struct discord *client, const struct discord_guild_member *event)) |
Triggers when a guild member is added. More... | |
void | discord_set_on_guild_member_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_guild_member_update *event)) |
Triggers when a guild member is updated. More... | |
void | discord_set_on_guild_member_remove (struct discord *client, void(*callback)(struct discord *client, const struct discord_guild_member_remove *event)) |
Triggers when a guild member is removed. More... | |
void | discord_set_on_guild_members_chunk (struct discord *client, void(*callback)(struct discord *client, const struct discord_guild_members_chunk *event)) |
Triggers in response to discord_request_guild_members() More... | |
void | discord_set_on_guild_role_create (struct discord *client, void(*callback)(struct discord *client, const struct discord_guild_role_create *event)) |
Triggers when a guild role is created. More... | |
void | discord_set_on_guild_role_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_guild_role_update *event)) |
Triggers when a guild role is updated. More... | |
void | discord_set_on_guild_role_delete (struct discord *client, void(*callback)(struct discord *client, const struct discord_guild_role_delete *event)) |
Triggers when a guild role is deleted. More... | |
void | discord_set_on_guild_scheduled_event_create (struct discord *client, void(*callback)(struct discord *client, const struct discord_guild_scheduled_event *event)) |
Triggers when a guild scheduled event is created. More... | |
void | discord_set_on_guild_scheduled_event_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_guild_scheduled_event *event)) |
Triggers when a guild scheduled event is updated. More... | |
void | discord_set_on_guild_scheduled_event_delete (struct discord *client, void(*callback)(struct discord *client, const struct discord_guild_scheduled_event *event)) |
Triggers when a guild scheduled event is deleted. More... | |
void | discord_set_on_guild_scheduled_event_user_add (struct discord *client, void(*callback)(struct discord *client, const struct discord_guild_scheduled_event_user_add *event)) |
Triggers when a user subscribes to a guild scheduled event. More... | |
void | discord_set_on_guild_scheduled_event_user_remove (struct discord *client, void(*callback)(struct discord *client, const struct discord_guild_scheduled_event_user_remove *event)) |
Triggers when a user unsubscribes from a guild scheduled event. More... | |
void | discord_set_on_integration_create (struct discord *client, void(*callback)(struct discord *client, const struct discord_integration *event)) |
Triggers when a guild integration is created. More... | |
void | discord_set_on_integration_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_integration *event)) |
Triggers when a guild integration is updated. More... | |
void | discord_set_on_integration_delete (struct discord *client, void(*callback)(struct discord *client, const struct discord_integration_delete *event)) |
Triggers when a guild integration is deleted. More... | |
void | discord_set_on_interaction_create (struct discord *client, void(*callback)(struct discord *client, const struct discord_interaction *event)) |
Triggers when user has used an interaction, such as an application command. More... | |
void | discord_set_on_invite_create (struct discord *client, void(*callback)(struct discord *client, const struct discord_invite_create *event)) |
Triggers when an invite to a channel has been created. More... | |
void | discord_set_on_invite_delete (struct discord *client, void(*callback)(struct discord *client, const struct discord_invite_delete *event)) |
Triggers when an invite to a channel has been deleted. More... | |
void | discord_set_on_message_create (struct discord *client, void(*callback)(struct discord *client, const struct discord_message *event)) |
Triggers when a message is created. More... | |
void | discord_set_on_message_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_message *event)) |
Triggers when a message is updated. More... | |
void | discord_set_on_message_delete (struct discord *client, void(*callback)(struct discord *client, const struct discord_message_delete *event)) |
Triggers when a message is deleted. More... | |
void | discord_set_on_message_delete_bulk (struct discord *client, void(*callback)(struct discord *client, const struct discord_message_delete_bulk *event)) |
Triggers when messages are deleted in bulk. More... | |
void | discord_set_on_message_reaction_add (struct discord *client, void(*callback)(struct discord *client, const struct discord_message_reaction_add *event)) |
Triggers when a message reaction is added. More... | |
void | discord_set_on_message_reaction_remove (struct discord *client, void(*callback)(struct discord *client, const struct discord_message_reaction_remove *event)) |
Triggers when a message reaction is removed. More... | |
void | discord_set_on_message_reaction_remove_all (struct discord *client, void(*callback)(struct discord *client, const struct discord_message_reaction_remove_all *event)) |
Triggers when all message reactions are removed. More... | |
void | discord_set_on_message_reaction_remove_emoji (struct discord *client, void(*callback)(struct discord *client, const struct discord_message_reaction_remove_emoji *event)) |
Triggers when all instances of a particular reaction from some message is removed. More... | |
void | discord_set_on_presence_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_presence_update *event)) |
Triggers when user presence is updated. More... | |
void | discord_set_on_stage_instance_create (struct discord *client, void(*callback)(struct discord *client, const struct discord_stage_instance *event)) |
Triggers when a stage instance is created. More... | |
void | discord_set_on_stage_instance_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_stage_instance *event)) |
Triggers when a stage instance is updated. More... | |
void | discord_set_on_stage_instance_delete (struct discord *client, void(*callback)(struct discord *client, const struct discord_stage_instance *event)) |
Triggers when a stage instance is deleted. More... | |
void | discord_set_on_typing_start (struct discord *client, void(*callback)(struct discord *client, const struct discord_typing_start *event)) |
Triggers when user starts typing in a channel. More... | |
void | discord_set_on_user_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_user *event)) |
Triggers when properties about a user changed. More... | |
void | discord_set_on_voice_state_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_voice_state *event)) |
Triggers when a voice state is updated. More... | |
void | discord_set_on_voice_server_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_voice_server_update *event)) |
Triggers when voice server is updated. More... | |
void | discord_set_on_webhooks_update (struct discord *client, void(*callback)(struct discord *client, const struct discord_webhooks_update *event)) |
Triggers when guild channel has been created, updated or deleted. More... | |
Events sent over the Gateway socket to the client.
typedef enum discord_event_scheduler discord_event_scheduler_t |
return value of discord_set_event_scheduler() callback
typedef enum discord_event_scheduler(* discord_ev_scheduler) (struct discord *client, const char data[], size_t size, enum discord_gateway_events event) |
Event Handling Mode callback.
A very important callback that enables the user with a fine-grained control of how each event is handled: blocking, non-blocking or ignored
Discord Gateway's events.
return value of discord_set_event_scheduler() callback
Enumerator | |
---|---|
DISCORD_EVENT_IGNORE | this event has been handled |
DISCORD_EVENT_MAIN_THREAD | handle this event in main thread |
DISCORD_EVENT_WORKER_THREAD | handle this event in a worker thread
|
void discord_set_event_scheduler | ( | struct discord * | client, |
discord_ev_scheduler | callback | ||
) |
Provides control over Discord event's callback scheduler.
Allows the user to scan the preliminary raw JSON event payload, and control whether it should trigger callbacks
client | the client created_with discord_init() |
fn | the function that will be executed |
void discord_add_intents | ( | struct discord * | client, |
uint64_t | code | ||
) |
Subscribe to Discord Events.
client | the client created with discord_init() |
code | the intents opcode, can be set as a bitmask operation |
void discord_remove_intents | ( | struct discord * | client, |
uint64_t | code | ||
) |
Unsubscribe from Discord Events.
client | the client created with discord_init() |
code | the intents opcode, can be set as bitmask operation Ex: 1 << 0 | 1 << 1 | 1 << 4 |
void discord_set_prefix | ( | struct discord * | client, |
const char | prefix[] | ||
) |
Set a mandatory prefix before commands.
Example: If 'help' is a command and '!' prefix is set, the command will only be validated if '!help' is sent
client | the client created with discord_init() |
prefix | the mandatory command prefix |
void discord_set_on_command | ( | struct discord * | client, |
char * | command, | ||
void(*)(struct discord *client, const struct discord_message *event) | callback | ||
) |
Set command/callback pair.
The callback is triggered when a user types the assigned command in a chat visible to the client
client | the client created with discord_init() |
command | the command to trigger the callback |
callback | the callback to be triggered on event |
void discord_set_on_commands | ( | struct discord * | client, |
char *const | commands[], | ||
int | amount, | ||
void(*)(struct discord *client, const struct discord_message *event) | callback | ||
) |
Set a variadic series of NULL terminated commands to a callback.
The callback is triggered when a user types one of the assigned commands in a chat visble to the client
client | the client created with discord_init() |
commands | array of commands to trigger the callback |
amount | amount of commands provided |
callback | the callback to be triggered on event |
void discord_set_next_wakeup | ( | struct discord * | client, |
int64_t | delay | ||
) |
Set the time for wakeup function to be called.
delay | time to delay in milliseconds, or -1 to disable |
Triggered at a arbitrary interval value set at discord_set_next_wakeup()
client | the client created with discord_init() |
callback | the callback to be triggered on event |
Triggers when idle.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
Triggers once per event-loop cycle.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_ready | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_ready *event) | callback | ||
) |
Triggers when the client session is ready.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_application_command_permissions_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_application_command_permissions *event) | callback | ||
) |
Triggers when an application command permission is updated.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_auto_moderation_rule_create | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_auto_moderation_rule *event) | callback | ||
) |
Triggers when an auto moderation rule is created.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_auto_moderation_rule_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_auto_moderation_rule *event) | callback | ||
) |
Triggers when an auto moderation rule is updated.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_auto_moderation_rule_delete | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_auto_moderation_rule *event) | callback | ||
) |
Triggers when an auto moderation rule is deleted.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_auto_moderation_action_execution | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_auto_moderation_action_execution *event) | callback | ||
) |
Triggers when an auto moderation rule is triggered and an execution is executed (e.g a message was blocked)
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_channel_create | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_channel *event) | callback | ||
) |
Triggers when a channel is created.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_channel_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_channel *event) | callback | ||
) |
Triggers when a channel is updated.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_channel_delete | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_channel *event) | callback | ||
) |
Triggers when a channel is deleted.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_channel_pins_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_channel_pins_update *event) | callback | ||
) |
Triggers when a channel pin is updated.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_thread_create | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_channel *event) | callback | ||
) |
Triggers when a thread is created.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_thread_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_channel *event) | callback | ||
) |
Triggers when a thread is updated.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_thread_delete | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_channel *event) | callback | ||
) |
Triggers when a thread is deleted.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_thread_list_sync | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_thread_list_sync *event) | callback | ||
) |
Triggers when the current user gains access to a channel.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_thread_member_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_thread_member *event) | callback | ||
) |
Triggers when a thread the bot is in gets updated.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_thread_members_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_thread_members_update *event) | callback | ||
) |
Triggers when someone is added or removed from a thread.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_guild_create | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_guild *event) | callback | ||
) |
Triggers when a guild is created.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_guild_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_guild *event) | callback | ||
) |
Triggers when a guild is updated.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_guild_delete | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_guild *event) | callback | ||
) |
Triggers when a guild is deleted.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_guild_ban_add | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_guild_ban_add *event) | callback | ||
) |
Triggers when a user is banned from a guild.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_guild_ban_remove | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_guild_ban_remove *event) | callback | ||
) |
Triggers when a user is unbanned from a guild.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_guild_emojis_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_guild_emojis_update *event) | callback | ||
) |
Triggers when a guild emojis are updated.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_guild_stickers_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_guild_stickers_update *event) | callback | ||
) |
Triggers when a guild stickers are updated.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_guild_integrations_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_guild_integrations_update *event) | callback | ||
) |
Triggers when a guild integrations are updated.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_guild_member_add | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_guild_member *event) | callback | ||
) |
Triggers when a guild member is added.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_guild_member_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_guild_member_update *event) | callback | ||
) |
Triggers when a guild member is updated.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_guild_member_remove | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_guild_member_remove *event) | callback | ||
) |
Triggers when a guild member is removed.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_guild_members_chunk | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_guild_members_chunk *event) | callback | ||
) |
Triggers in response to discord_request_guild_members()
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_guild_role_create | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_guild_role_create *event) | callback | ||
) |
Triggers when a guild role is created.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_guild_role_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_guild_role_update *event) | callback | ||
) |
Triggers when a guild role is updated.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_guild_role_delete | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_guild_role_delete *event) | callback | ||
) |
Triggers when a guild role is deleted.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_guild_scheduled_event_create | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_guild_scheduled_event *event) | callback | ||
) |
Triggers when a guild scheduled event is created.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_guild_scheduled_event_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_guild_scheduled_event *event) | callback | ||
) |
Triggers when a guild scheduled event is updated.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_guild_scheduled_event_delete | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_guild_scheduled_event *event) | callback | ||
) |
Triggers when a guild scheduled event is deleted.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_guild_scheduled_event_user_add | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_guild_scheduled_event_user_add *event) | callback | ||
) |
Triggers when a user subscribes to a guild scheduled event.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_guild_scheduled_event_user_remove | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_guild_scheduled_event_user_remove *event) | callback | ||
) |
Triggers when a user unsubscribes from a guild scheduled event.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_integration_create | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_integration *event) | callback | ||
) |
Triggers when a guild integration is created.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_integration_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_integration *event) | callback | ||
) |
Triggers when a guild integration is updated.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_integration_delete | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_integration_delete *event) | callback | ||
) |
Triggers when a guild integration is deleted.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_interaction_create | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_interaction *event) | callback | ||
) |
Triggers when user has used an interaction, such as an application command.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_invite_create | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_invite_create *event) | callback | ||
) |
Triggers when an invite to a channel has been created.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_invite_delete | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_invite_delete *event) | callback | ||
) |
Triggers when an invite to a channel has been deleted.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_message_create | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_message *event) | callback | ||
) |
Triggers when a message is created.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_message_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_message *event) | callback | ||
) |
Triggers when a message is updated.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_message_delete | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_message_delete *event) | callback | ||
) |
Triggers when a message is deleted.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_message_delete_bulk | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_message_delete_bulk *event) | callback | ||
) |
Triggers when messages are deleted in bulk.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_message_reaction_add | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_message_reaction_add *event) | callback | ||
) |
Triggers when a message reaction is added.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_message_reaction_remove | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_message_reaction_remove *event) | callback | ||
) |
Triggers when a message reaction is removed.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_message_reaction_remove_all | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_message_reaction_remove_all *event) | callback | ||
) |
Triggers when all message reactions are removed.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_message_reaction_remove_emoji | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_message_reaction_remove_emoji *event) | callback | ||
) |
Triggers when all instances of a particular reaction from some message is removed.
Triggers when all instances of a particular reaction is removed from a message
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_presence_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_presence_update *event) | callback | ||
) |
Triggers when user presence is updated.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_stage_instance_create | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_stage_instance *event) | callback | ||
) |
Triggers when a stage instance is created.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_stage_instance_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_stage_instance *event) | callback | ||
) |
Triggers when a stage instance is updated.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_stage_instance_delete | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_stage_instance *event) | callback | ||
) |
Triggers when a stage instance is deleted.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_typing_start | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_typing_start *event) | callback | ||
) |
Triggers when user starts typing in a channel.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_user_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_user *event) | callback | ||
) |
Triggers when properties about a user changed.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_voice_state_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_voice_state *event) | callback | ||
) |
Triggers when a voice state is updated.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_voice_server_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_voice_server_update *event) | callback | ||
) |
Triggers when voice server is updated.
client | the client created with discord_init() |
callback | the callback to be triggered on event |
void discord_set_on_webhooks_update | ( | struct discord * | client, |
void(*)(struct discord *client, const struct discord_webhooks_update *event) | callback | ||
) |
Triggers when guild channel has been created, updated or deleted.
client | the client created with discord_init() |
callback | the callback to be triggered on event |