@neontechspace/fluxerly 1000.0.0-nightly.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +833 -0
- package/LICENSE +201 -0
- package/README.md +129 -0
- package/agents/AGENTS.md +195 -0
- package/dist/api/default/application.d.ts +34 -0
- package/dist/api/default/application.d.ts.map +1 -0
- package/dist/api/default/application.js +2 -0
- package/dist/api/default/application.js.map +1 -0
- package/dist/api/default/attachments.d.ts +89 -0
- package/dist/api/default/attachments.d.ts.map +1 -0
- package/dist/api/default/attachments.js +2 -0
- package/dist/api/default/attachments.js.map +1 -0
- package/dist/api/default/audit-logs.d.ts +48 -0
- package/dist/api/default/audit-logs.d.ts.map +1 -0
- package/dist/api/default/audit-logs.js +2 -0
- package/dist/api/default/audit-logs.js.map +1 -0
- package/dist/api/default/bot.d.ts +200 -0
- package/dist/api/default/bot.d.ts.map +1 -0
- package/dist/api/default/bot.js +309 -0
- package/dist/api/default/bot.js.map +1 -0
- package/dist/api/default/cache.d.ts +105 -0
- package/dist/api/default/cache.d.ts.map +1 -0
- package/dist/api/default/cache.js +2 -0
- package/dist/api/default/cache.js.map +1 -0
- package/dist/api/default/channels.d.ts +249 -0
- package/dist/api/default/channels.d.ts.map +1 -0
- package/dist/api/default/channels.js +2 -0
- package/dist/api/default/channels.js.map +1 -0
- package/dist/api/default/client.d.ts +528 -0
- package/dist/api/default/client.d.ts.map +1 -0
- package/dist/api/default/client.js +301 -0
- package/dist/api/default/client.js.map +1 -0
- package/dist/api/default/collectors.d.ts +76 -0
- package/dist/api/default/collectors.d.ts.map +1 -0
- package/dist/api/default/collectors.js +2 -0
- package/dist/api/default/collectors.js.map +1 -0
- package/dist/api/default/commands.d.ts +91 -0
- package/dist/api/default/commands.d.ts.map +1 -0
- package/dist/api/default/commands.js +92 -0
- package/dist/api/default/commands.js.map +1 -0
- package/dist/api/default/direct-messages.d.ts +111 -0
- package/dist/api/default/direct-messages.d.ts.map +1 -0
- package/dist/api/default/direct-messages.js +2 -0
- package/dist/api/default/direct-messages.js.map +1 -0
- package/dist/api/default/discovery.d.ts +76 -0
- package/dist/api/default/discovery.d.ts.map +1 -0
- package/dist/api/default/discovery.js +2 -0
- package/dist/api/default/discovery.js.map +1 -0
- package/dist/api/default/emojis.d.ts +88 -0
- package/dist/api/default/emojis.d.ts.map +1 -0
- package/dist/api/default/emojis.js +2 -0
- package/dist/api/default/emojis.js.map +1 -0
- package/dist/api/default/events.d.ts +127 -0
- package/dist/api/default/events.d.ts.map +1 -0
- package/dist/api/default/events.js +2 -0
- package/dist/api/default/events.js.map +1 -0
- package/dist/api/default/gateway.d.ts +62 -0
- package/dist/api/default/gateway.d.ts.map +1 -0
- package/dist/api/default/gateway.js +2 -0
- package/dist/api/default/gateway.js.map +1 -0
- package/dist/api/default/guards.d.ts +87 -0
- package/dist/api/default/guards.d.ts.map +1 -0
- package/dist/api/default/guards.js +78 -0
- package/dist/api/default/guards.js.map +1 -0
- package/dist/api/default/guilds.d.ts +230 -0
- package/dist/api/default/guilds.d.ts.map +1 -0
- package/dist/api/default/guilds.js +2 -0
- package/dist/api/default/guilds.js.map +1 -0
- package/dist/api/default/helpers.d.ts +79 -0
- package/dist/api/default/helpers.d.ts.map +1 -0
- package/dist/api/default/helpers.js +79 -0
- package/dist/api/default/helpers.js.map +1 -0
- package/dist/api/default/instance.d.ts +47 -0
- package/dist/api/default/instance.d.ts.map +1 -0
- package/dist/api/default/instance.js +2 -0
- package/dist/api/default/instance.js.map +1 -0
- package/dist/api/default/invites.d.ts +57 -0
- package/dist/api/default/invites.d.ts.map +1 -0
- package/dist/api/default/invites.js +2 -0
- package/dist/api/default/invites.js.map +1 -0
- package/dist/api/default/logging.d.ts +37 -0
- package/dist/api/default/logging.d.ts.map +1 -0
- package/dist/api/default/logging.js +2 -0
- package/dist/api/default/logging.js.map +1 -0
- package/dist/api/default/members.d.ts +442 -0
- package/dist/api/default/members.d.ts.map +1 -0
- package/dist/api/default/members.js +2 -0
- package/dist/api/default/members.js.map +1 -0
- package/dist/api/default/messages.d.ts +898 -0
- package/dist/api/default/messages.d.ts.map +1 -0
- package/dist/api/default/messages.js +2 -0
- package/dist/api/default/messages.js.map +1 -0
- package/dist/api/default/oauth.d.ts +168 -0
- package/dist/api/default/oauth.d.ts.map +1 -0
- package/dist/api/default/oauth.js +84 -0
- package/dist/api/default/oauth.js.map +1 -0
- package/dist/api/default/permissions.d.ts +44 -0
- package/dist/api/default/permissions.d.ts.map +1 -0
- package/dist/api/default/permissions.js +2 -0
- package/dist/api/default/permissions.js.map +1 -0
- package/dist/api/default/presence.d.ts +88 -0
- package/dist/api/default/presence.d.ts.map +1 -0
- package/dist/api/default/presence.js +2 -0
- package/dist/api/default/presence.js.map +1 -0
- package/dist/api/default/rest.d.ts +28 -0
- package/dist/api/default/rest.d.ts.map +1 -0
- package/dist/api/default/rest.js +2 -0
- package/dist/api/default/rest.js.map +1 -0
- package/dist/api/default/results.d.ts +31 -0
- package/dist/api/default/results.d.ts.map +1 -0
- package/dist/api/default/results.js +14 -0
- package/dist/api/default/results.js.map +1 -0
- package/dist/api/default/roles.d.ts +119 -0
- package/dist/api/default/roles.d.ts.map +1 -0
- package/dist/api/default/roles.js +2 -0
- package/dist/api/default/roles.js.map +1 -0
- package/dist/api/default/stickers.d.ts +92 -0
- package/dist/api/default/stickers.d.ts.map +1 -0
- package/dist/api/default/stickers.js +2 -0
- package/dist/api/default/stickers.js.map +1 -0
- package/dist/api/default/supervisor.d.ts +51 -0
- package/dist/api/default/supervisor.d.ts.map +1 -0
- package/dist/api/default/supervisor.js +53 -0
- package/dist/api/default/supervisor.js.map +1 -0
- package/dist/api/default/threads.d.ts +158 -0
- package/dist/api/default/threads.d.ts.map +1 -0
- package/dist/api/default/threads.js +2 -0
- package/dist/api/default/threads.js.map +1 -0
- package/dist/api/default/users.d.ts +73 -0
- package/dist/api/default/users.d.ts.map +1 -0
- package/dist/api/default/users.js +2 -0
- package/dist/api/default/users.js.map +1 -0
- package/dist/api/default/webhook-client.d.ts +149 -0
- package/dist/api/default/webhook-client.d.ts.map +1 -0
- package/dist/api/default/webhook-client.js +69 -0
- package/dist/api/default/webhook-client.js.map +1 -0
- package/dist/api/default/webhooks.d.ts +62 -0
- package/dist/api/default/webhooks.d.ts.map +1 -0
- package/dist/api/default/webhooks.js +2 -0
- package/dist/api/default/webhooks.js.map +1 -0
- package/dist/api/effect/application.d.ts +29 -0
- package/dist/api/effect/application.d.ts.map +1 -0
- package/dist/api/effect/application.js +2 -0
- package/dist/api/effect/application.js.map +1 -0
- package/dist/api/effect/attachments.d.ts +84 -0
- package/dist/api/effect/attachments.d.ts.map +1 -0
- package/dist/api/effect/attachments.js +2 -0
- package/dist/api/effect/attachments.js.map +1 -0
- package/dist/api/effect/audit-logs.d.ts +42 -0
- package/dist/api/effect/audit-logs.d.ts.map +1 -0
- package/dist/api/effect/audit-logs.js +2 -0
- package/dist/api/effect/audit-logs.js.map +1 -0
- package/dist/api/effect/bot.d.ts +233 -0
- package/dist/api/effect/bot.d.ts.map +1 -0
- package/dist/api/effect/bot.js +230 -0
- package/dist/api/effect/bot.js.map +1 -0
- package/dist/api/effect/cache.d.ts +103 -0
- package/dist/api/effect/cache.d.ts.map +1 -0
- package/dist/api/effect/cache.js +2 -0
- package/dist/api/effect/cache.js.map +1 -0
- package/dist/api/effect/channels.d.ts +231 -0
- package/dist/api/effect/channels.d.ts.map +1 -0
- package/dist/api/effect/channels.js +2 -0
- package/dist/api/effect/channels.js.map +1 -0
- package/dist/api/effect/client.d.ts +622 -0
- package/dist/api/effect/client.d.ts.map +1 -0
- package/dist/api/effect/client.js +191 -0
- package/dist/api/effect/client.js.map +1 -0
- package/dist/api/effect/collectors.d.ts +90 -0
- package/dist/api/effect/collectors.d.ts.map +1 -0
- package/dist/api/effect/collectors.js +2 -0
- package/dist/api/effect/collectors.js.map +1 -0
- package/dist/api/effect/commands.d.ts +86 -0
- package/dist/api/effect/commands.d.ts.map +1 -0
- package/dist/api/effect/commands.js +87 -0
- package/dist/api/effect/commands.js.map +1 -0
- package/dist/api/effect/direct-messages.d.ts +102 -0
- package/dist/api/effect/direct-messages.d.ts.map +1 -0
- package/dist/api/effect/direct-messages.js +2 -0
- package/dist/api/effect/direct-messages.js.map +1 -0
- package/dist/api/effect/discovery.d.ts +68 -0
- package/dist/api/effect/discovery.d.ts.map +1 -0
- package/dist/api/effect/discovery.js +2 -0
- package/dist/api/effect/discovery.js.map +1 -0
- package/dist/api/effect/emojis.d.ts +77 -0
- package/dist/api/effect/emojis.d.ts.map +1 -0
- package/dist/api/effect/emojis.js +2 -0
- package/dist/api/effect/emojis.js.map +1 -0
- package/dist/api/effect/events.d.ts +78 -0
- package/dist/api/effect/events.d.ts.map +1 -0
- package/dist/api/effect/events.js +12 -0
- package/dist/api/effect/events.js.map +1 -0
- package/dist/api/effect/failures.d.ts +14 -0
- package/dist/api/effect/failures.d.ts.map +1 -0
- package/dist/api/effect/failures.js +2 -0
- package/dist/api/effect/failures.js.map +1 -0
- package/dist/api/effect/gateway.d.ts +63 -0
- package/dist/api/effect/gateway.d.ts.map +1 -0
- package/dist/api/effect/gateway.js +2 -0
- package/dist/api/effect/gateway.js.map +1 -0
- package/dist/api/effect/guards.d.ts +91 -0
- package/dist/api/effect/guards.d.ts.map +1 -0
- package/dist/api/effect/guards.js +94 -0
- package/dist/api/effect/guards.js.map +1 -0
- package/dist/api/effect/guilds.d.ts +221 -0
- package/dist/api/effect/guilds.d.ts.map +1 -0
- package/dist/api/effect/guilds.js +2 -0
- package/dist/api/effect/guilds.js.map +1 -0
- package/dist/api/effect/helpers.d.ts +300 -0
- package/dist/api/effect/helpers.d.ts.map +1 -0
- package/dist/api/effect/helpers.js +156 -0
- package/dist/api/effect/helpers.js.map +1 -0
- package/dist/api/effect/hierarchy.d.ts +26 -0
- package/dist/api/effect/hierarchy.d.ts.map +1 -0
- package/dist/api/effect/hierarchy.js +26 -0
- package/dist/api/effect/hierarchy.js.map +1 -0
- package/dist/api/effect/instance.d.ts +46 -0
- package/dist/api/effect/instance.d.ts.map +1 -0
- package/dist/api/effect/instance.js +8 -0
- package/dist/api/effect/instance.js.map +1 -0
- package/dist/api/effect/invites.d.ts +49 -0
- package/dist/api/effect/invites.d.ts.map +1 -0
- package/dist/api/effect/invites.js +2 -0
- package/dist/api/effect/invites.js.map +1 -0
- package/dist/api/effect/logging.d.ts +37 -0
- package/dist/api/effect/logging.d.ts.map +1 -0
- package/dist/api/effect/logging.js +2 -0
- package/dist/api/effect/logging.js.map +1 -0
- package/dist/api/effect/members.d.ts +433 -0
- package/dist/api/effect/members.d.ts.map +1 -0
- package/dist/api/effect/members.js +2 -0
- package/dist/api/effect/members.js.map +1 -0
- package/dist/api/effect/messages.d.ts +877 -0
- package/dist/api/effect/messages.d.ts.map +1 -0
- package/dist/api/effect/messages.js +2 -0
- package/dist/api/effect/messages.js.map +1 -0
- package/dist/api/effect/oauth.d.ts +148 -0
- package/dist/api/effect/oauth.d.ts.map +1 -0
- package/dist/api/effect/oauth.js +51 -0
- package/dist/api/effect/oauth.js.map +1 -0
- package/dist/api/effect/permissions.d.ts +41 -0
- package/dist/api/effect/permissions.d.ts.map +1 -0
- package/dist/api/effect/permissions.js +2 -0
- package/dist/api/effect/permissions.js.map +1 -0
- package/dist/api/effect/presence.d.ts +83 -0
- package/dist/api/effect/presence.d.ts.map +1 -0
- package/dist/api/effect/presence.js +2 -0
- package/dist/api/effect/presence.js.map +1 -0
- package/dist/api/effect/rest.d.ts +27 -0
- package/dist/api/effect/rest.d.ts.map +1 -0
- package/dist/api/effect/rest.js +2 -0
- package/dist/api/effect/rest.js.map +1 -0
- package/dist/api/effect/roles.d.ts +104 -0
- package/dist/api/effect/roles.d.ts.map +1 -0
- package/dist/api/effect/roles.js +2 -0
- package/dist/api/effect/roles.js.map +1 -0
- package/dist/api/effect/service.d.ts +76 -0
- package/dist/api/effect/service.d.ts.map +1 -0
- package/dist/api/effect/service.js +79 -0
- package/dist/api/effect/service.js.map +1 -0
- package/dist/api/effect/stickers.d.ts +81 -0
- package/dist/api/effect/stickers.d.ts.map +1 -0
- package/dist/api/effect/stickers.js +2 -0
- package/dist/api/effect/stickers.js.map +1 -0
- package/dist/api/effect/supervisor.d.ts +56 -0
- package/dist/api/effect/supervisor.d.ts.map +1 -0
- package/dist/api/effect/supervisor.js +58 -0
- package/dist/api/effect/supervisor.js.map +1 -0
- package/dist/api/effect/threads.d.ts +154 -0
- package/dist/api/effect/threads.d.ts.map +1 -0
- package/dist/api/effect/threads.js +2 -0
- package/dist/api/effect/threads.js.map +1 -0
- package/dist/api/effect/users.d.ts +62 -0
- package/dist/api/effect/users.d.ts.map +1 -0
- package/dist/api/effect/users.js +2 -0
- package/dist/api/effect/users.js.map +1 -0
- package/dist/api/effect/webhook-client.d.ts +140 -0
- package/dist/api/effect/webhook-client.d.ts.map +1 -0
- package/dist/api/effect/webhook-client.js +50 -0
- package/dist/api/effect/webhook-client.js.map +1 -0
- package/dist/api/effect/webhooks.d.ts +54 -0
- package/dist/api/effect/webhooks.d.ts.map +1 -0
- package/dist/api/effect/webhooks.js +2 -0
- package/dist/api/effect/webhooks.js.map +1 -0
- package/dist/api-errors.d.ts +609 -0
- package/dist/api-errors.d.ts.map +1 -0
- package/dist/api-errors.js +589 -0
- package/dist/api-errors.js.map +1 -0
- package/dist/application.d.ts +85 -0
- package/dist/application.d.ts.map +1 -0
- package/dist/application.js +44 -0
- package/dist/application.js.map +1 -0
- package/dist/assets.d.ts +197 -0
- package/dist/assets.d.ts.map +1 -0
- package/dist/assets.js +419 -0
- package/dist/assets.js.map +1 -0
- package/dist/attachments.d.ts +400 -0
- package/dist/attachments.d.ts.map +1 -0
- package/dist/attachments.js +88 -0
- package/dist/attachments.js.map +1 -0
- package/dist/audit-logs.d.ts +292 -0
- package/dist/audit-logs.d.ts.map +1 -0
- package/dist/audit-logs.js +46 -0
- package/dist/audit-logs.js.map +1 -0
- package/dist/bot-runner.d.ts +69 -0
- package/dist/bot-runner.d.ts.map +1 -0
- package/dist/bot-runner.js +41 -0
- package/dist/bot-runner.js.map +1 -0
- package/dist/builders.d.ts +153 -0
- package/dist/builders.d.ts.map +1 -0
- package/dist/builders.js +326 -0
- package/dist/builders.js.map +1 -0
- package/dist/cache.d.ts +187 -0
- package/dist/cache.d.ts.map +1 -0
- package/dist/cache.js +2 -0
- package/dist/cache.js.map +1 -0
- package/dist/channels.d.ts +903 -0
- package/dist/channels.d.ts.map +1 -0
- package/dist/channels.js +125 -0
- package/dist/channels.js.map +1 -0
- package/dist/cli.d.ts +9 -0
- package/dist/cli.d.ts.map +1 -0
- package/dist/cli.js +65 -0
- package/dist/cli.js.map +1 -0
- package/dist/client.d.ts +645 -0
- package/dist/client.d.ts.map +1 -0
- package/dist/client.js +2 -0
- package/dist/client.js.map +1 -0
- package/dist/collectors.d.ts +205 -0
- package/dist/collectors.d.ts.map +1 -0
- package/dist/collectors.js +71 -0
- package/dist/collectors.js.map +1 -0
- package/dist/colors.d.ts +55 -0
- package/dist/colors.d.ts.map +1 -0
- package/dist/colors.js +40 -0
- package/dist/colors.js.map +1 -0
- package/dist/command-arguments.d.ts +353 -0
- package/dist/command-arguments.d.ts.map +1 -0
- package/dist/command-arguments.js +2 -0
- package/dist/command-arguments.js.map +1 -0
- package/dist/command-help.d.ts +54 -0
- package/dist/command-help.d.ts.map +1 -0
- package/dist/command-help.js +2 -0
- package/dist/command-help.js.map +1 -0
- package/dist/commands.d.ts +328 -0
- package/dist/commands.d.ts.map +1 -0
- package/dist/commands.js +62 -0
- package/dist/commands.js.map +1 -0
- package/dist/counts.d.ts +124 -0
- package/dist/counts.d.ts.map +1 -0
- package/dist/counts.js +52 -0
- package/dist/counts.js.map +1 -0
- package/dist/default-commands.d.ts +400 -0
- package/dist/default-commands.d.ts.map +1 -0
- package/dist/default-commands.js +488 -0
- package/dist/default-commands.js.map +1 -0
- package/dist/default-supervisor.d.ts +111 -0
- package/dist/default-supervisor.d.ts.map +1 -0
- package/dist/default-supervisor.js +277 -0
- package/dist/default-supervisor.js.map +1 -0
- package/dist/discovery.d.ts +223 -0
- package/dist/discovery.d.ts.map +1 -0
- package/dist/discovery.js +18 -0
- package/dist/discovery.js.map +1 -0
- package/dist/effect-testing.d.ts +388 -0
- package/dist/effect-testing.d.ts.map +1 -0
- package/dist/effect-testing.js +261 -0
- package/dist/effect-testing.js.map +1 -0
- package/dist/effect.d.ts +220 -0
- package/dist/effect.d.ts.map +1 -0
- package/dist/effect.js +101 -0
- package/dist/effect.js.map +1 -0
- package/dist/embeds.d.ts +243 -0
- package/dist/embeds.d.ts.map +1 -0
- package/dist/embeds.js +2 -0
- package/dist/embeds.js.map +1 -0
- package/dist/error-tools.d.ts +101 -0
- package/dist/error-tools.d.ts.map +1 -0
- package/dist/error-tools.js +125 -0
- package/dist/error-tools.js.map +1 -0
- package/dist/errors.d.ts +386 -0
- package/dist/errors.d.ts.map +1 -0
- package/dist/errors.js +440 -0
- package/dist/errors.js.map +1 -0
- package/dist/events.d.ts +798 -0
- package/dist/events.d.ts.map +1 -0
- package/dist/events.js +2 -0
- package/dist/events.js.map +1 -0
- package/dist/expressions.d.ts +188 -0
- package/dist/expressions.d.ts.map +1 -0
- package/dist/expressions.js +2 -0
- package/dist/expressions.js.map +1 -0
- package/dist/failures.d.ts +53 -0
- package/dist/failures.d.ts.map +1 -0
- package/dist/failures.js +2 -0
- package/dist/failures.js.map +1 -0
- package/dist/gateway.d.ts +48 -0
- package/dist/gateway.d.ts.map +1 -0
- package/dist/gateway.js +60 -0
- package/dist/gateway.js.map +1 -0
- package/dist/guilds.d.ts +923 -0
- package/dist/guilds.d.ts.map +1 -0
- package/dist/guilds.js +204 -0
- package/dist/guilds.js.map +1 -0
- package/dist/helpers.d.ts +423 -0
- package/dist/helpers.d.ts.map +1 -0
- package/dist/helpers.js +434 -0
- package/dist/helpers.js.map +1 -0
- package/dist/index.d.ts +228 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +109 -0
- package/dist/index.js.map +1 -0
- package/dist/input-validation.d.ts +51 -0
- package/dist/input-validation.d.ts.map +1 -0
- package/dist/input-validation.js +34 -0
- package/dist/input-validation.js.map +1 -0
- package/dist/instance.d.ts +101 -0
- package/dist/instance.d.ts.map +1 -0
- package/dist/instance.js +2 -0
- package/dist/instance.js.map +1 -0
- package/dist/internal/agents-section.d.ts +22 -0
- package/dist/internal/agents-section.d.ts.map +1 -0
- package/dist/internal/agents-section.js +101 -0
- package/dist/internal/agents-section.js.map +1 -0
- package/dist/internal/application.d.ts +16 -0
- package/dist/internal/application.d.ts.map +1 -0
- package/dist/internal/application.js +33 -0
- package/dist/internal/application.js.map +1 -0
- package/dist/internal/attachment-refresh.d.ts +18 -0
- package/dist/internal/attachment-refresh.d.ts.map +1 -0
- package/dist/internal/attachment-refresh.js +39 -0
- package/dist/internal/attachment-refresh.js.map +1 -0
- package/dist/internal/attachments.d.ts +45 -0
- package/dist/internal/attachments.d.ts.map +1 -0
- package/dist/internal/attachments.js +230 -0
- package/dist/internal/attachments.js.map +1 -0
- package/dist/internal/audit-logs.d.ts +13 -0
- package/dist/internal/audit-logs.d.ts.map +1 -0
- package/dist/internal/audit-logs.js +295 -0
- package/dist/internal/audit-logs.js.map +1 -0
- package/dist/internal/audit.d.ts +12 -0
- package/dist/internal/audit.d.ts.map +1 -0
- package/dist/internal/audit.js +22 -0
- package/dist/internal/audit.js.map +1 -0
- package/dist/internal/binding/default-adapters.d.ts +22 -0
- package/dist/internal/binding/default-adapters.d.ts.map +1 -0
- package/dist/internal/binding/default-adapters.js +304 -0
- package/dist/internal/binding/default-adapters.js.map +1 -0
- package/dist/internal/binding/default.d.ts +45 -0
- package/dist/internal/binding/default.d.ts.map +1 -0
- package/dist/internal/binding/default.js +86 -0
- package/dist/internal/binding/default.js.map +1 -0
- package/dist/internal/binding/execute.d.ts +51 -0
- package/dist/internal/binding/execute.d.ts.map +1 -0
- package/dist/internal/binding/execute.js +123 -0
- package/dist/internal/binding/execute.js.map +1 -0
- package/dist/internal/binding/native-adapters.d.ts +23 -0
- package/dist/internal/binding/native-adapters.d.ts.map +1 -0
- package/dist/internal/binding/native-adapters.js +90 -0
- package/dist/internal/binding/native-adapters.js.map +1 -0
- package/dist/internal/binding/native.d.ts +41 -0
- package/dist/internal/binding/native.d.ts.map +1 -0
- package/dist/internal/binding/native.js +34 -0
- package/dist/internal/binding/native.js.map +1 -0
- package/dist/internal/binding/operations.d.ts +361 -0
- package/dist/internal/binding/operations.d.ts.map +1 -0
- package/dist/internal/binding/operations.js +272 -0
- package/dist/internal/binding/operations.js.map +1 -0
- package/dist/internal/bot-runner.d.ts +65 -0
- package/dist/internal/bot-runner.d.ts.map +1 -0
- package/dist/internal/bot-runner.js +363 -0
- package/dist/internal/bot-runner.js.map +1 -0
- package/dist/internal/cache-changes.d.ts +43 -0
- package/dist/internal/cache-changes.d.ts.map +1 -0
- package/dist/internal/cache-changes.js +320 -0
- package/dist/internal/cache-changes.js.map +1 -0
- package/dist/internal/cache.d.ts +57 -0
- package/dist/internal/cache.d.ts.map +1 -0
- package/dist/internal/cache.js +318 -0
- package/dist/internal/cache.js.map +1 -0
- package/dist/internal/calls.d.ts +16 -0
- package/dist/internal/calls.d.ts.map +1 -0
- package/dist/internal/calls.js +108 -0
- package/dist/internal/calls.js.map +1 -0
- package/dist/internal/channel-cache.d.ts +69 -0
- package/dist/internal/channel-cache.d.ts.map +1 -0
- package/dist/internal/channel-cache.js +413 -0
- package/dist/internal/channel-cache.js.map +1 -0
- package/dist/internal/channel-decode.d.ts +44 -0
- package/dist/internal/channel-decode.d.ts.map +1 -0
- package/dist/internal/channel-decode.js +377 -0
- package/dist/internal/channel-decode.js.map +1 -0
- package/dist/internal/channels.d.ts +60 -0
- package/dist/internal/channels.d.ts.map +1 -0
- package/dist/internal/channels.js +605 -0
- package/dist/internal/channels.js.map +1 -0
- package/dist/internal/client/backoff.d.ts +42 -0
- package/dist/internal/client/backoff.d.ts.map +1 -0
- package/dist/internal/client/backoff.js +36 -0
- package/dist/internal/client/backoff.js.map +1 -0
- package/dist/internal/client/configuration-fields.d.ts +14 -0
- package/dist/internal/client/configuration-fields.d.ts.map +1 -0
- package/dist/internal/client/configuration-fields.js +11 -0
- package/dist/internal/client/configuration-fields.js.map +1 -0
- package/dist/internal/client/drain.d.ts +33 -0
- package/dist/internal/client/drain.d.ts.map +1 -0
- package/dist/internal/client/drain.js +109 -0
- package/dist/internal/client/drain.js.map +1 -0
- package/dist/internal/client/intake.d.ts +27 -0
- package/dist/internal/client/intake.d.ts.map +1 -0
- package/dist/internal/client/intake.js +198 -0
- package/dist/internal/client/intake.js.map +1 -0
- package/dist/internal/client/lifetime.d.ts +35 -0
- package/dist/internal/client/lifetime.d.ts.map +1 -0
- package/dist/internal/client/lifetime.js +109 -0
- package/dist/internal/client/lifetime.js.map +1 -0
- package/dist/internal/client/shard-loop.d.ts +93 -0
- package/dist/internal/client/shard-loop.d.ts.map +1 -0
- package/dist/internal/client/shard-loop.js +452 -0
- package/dist/internal/client/shard-loop.js.map +1 -0
- package/dist/internal/client-registry.d.ts +26 -0
- package/dist/internal/client-registry.d.ts.map +1 -0
- package/dist/internal/client-registry.js +11 -0
- package/dist/internal/client-registry.js.map +1 -0
- package/dist/internal/client.d.ts +189 -0
- package/dist/internal/client.d.ts.map +1 -0
- package/dist/internal/client.js +1935 -0
- package/dist/internal/client.js.map +1 -0
- package/dist/internal/clock.d.ts +9 -0
- package/dist/internal/clock.d.ts.map +1 -0
- package/dist/internal/clock.js +5 -0
- package/dist/internal/clock.js.map +1 -0
- package/dist/internal/code-catalogue.d.ts +712 -0
- package/dist/internal/code-catalogue.d.ts.map +1 -0
- package/dist/internal/code-catalogue.js +655 -0
- package/dist/internal/code-catalogue.js.map +1 -0
- package/dist/internal/collector.d.ts +34 -0
- package/dist/internal/collector.d.ts.map +1 -0
- package/dist/internal/collector.js +400 -0
- package/dist/internal/collector.js.map +1 -0
- package/dist/internal/command-arguments.d.ts +29 -0
- package/dist/internal/command-arguments.d.ts.map +1 -0
- package/dist/internal/command-arguments.js +484 -0
- package/dist/internal/command-arguments.js.map +1 -0
- package/dist/internal/command-guards.d.ts +57 -0
- package/dist/internal/command-guards.d.ts.map +1 -0
- package/dist/internal/command-guards.js +81 -0
- package/dist/internal/command-guards.js.map +1 -0
- package/dist/internal/command-help.d.ts +15 -0
- package/dist/internal/command-help.d.ts.map +1 -0
- package/dist/internal/command-help.js +121 -0
- package/dist/internal/command-help.js.map +1 -0
- package/dist/internal/commands.d.ts +212 -0
- package/dist/internal/commands.d.ts.map +1 -0
- package/dist/internal/commands.js +1004 -0
- package/dist/internal/commands.js.map +1 -0
- package/dist/internal/configuration.d.ts +86 -0
- package/dist/internal/configuration.d.ts.map +1 -0
- package/dist/internal/configuration.js +401 -0
- package/dist/internal/configuration.js.map +1 -0
- package/dist/internal/counts.d.ts +33 -0
- package/dist/internal/counts.d.ts.map +1 -0
- package/dist/internal/counts.js +348 -0
- package/dist/internal/counts.js.map +1 -0
- package/dist/internal/decode/primitives.d.ts +30 -0
- package/dist/internal/decode/primitives.d.ts.map +1 -0
- package/dist/internal/decode/primitives.js +56 -0
- package/dist/internal/decode/primitives.js.map +1 -0
- package/dist/internal/decode/timestamp.d.ts +13 -0
- package/dist/internal/decode/timestamp.d.ts.map +1 -0
- package/dist/internal/decode/timestamp.js +27 -0
- package/dist/internal/decode/timestamp.js.map +1 -0
- package/dist/internal/decode/trace.d.ts +11 -0
- package/dist/internal/decode/trace.d.ts.map +1 -0
- package/dist/internal/decode/trace.js +69 -0
- package/dist/internal/decode/trace.js.map +1 -0
- package/dist/internal/defects.d.ts +48 -0
- package/dist/internal/defects.d.ts.map +1 -0
- package/dist/internal/defects.js +100 -0
- package/dist/internal/defects.js.map +1 -0
- package/dist/internal/effect-failures.d.ts +12 -0
- package/dist/internal/effect-failures.d.ts.map +1 -0
- package/dist/internal/effect-failures.js +45 -0
- package/dist/internal/effect-failures.js.map +1 -0
- package/dist/internal/embeds.d.ts +12 -0
- package/dist/internal/embeds.d.ts.map +1 -0
- package/dist/internal/embeds.js +308 -0
- package/dist/internal/embeds.js.map +1 -0
- package/dist/internal/events.d.ts +156 -0
- package/dist/internal/events.d.ts.map +1 -0
- package/dist/internal/events.js +1071 -0
- package/dist/internal/events.js.map +1 -0
- package/dist/internal/expiry-queue.d.ts +42 -0
- package/dist/internal/expiry-queue.d.ts.map +1 -0
- package/dist/internal/expiry-queue.js +138 -0
- package/dist/internal/expiry-queue.js.map +1 -0
- package/dist/internal/expressions.d.ts +35 -0
- package/dist/internal/expressions.d.ts.map +1 -0
- package/dist/internal/expressions.js +311 -0
- package/dist/internal/expressions.js.map +1 -0
- package/dist/internal/failures.d.ts +107 -0
- package/dist/internal/failures.d.ts.map +1 -0
- package/dist/internal/failures.js +416 -0
- package/dist/internal/failures.js.map +1 -0
- package/dist/internal/field-text.d.ts +10 -0
- package/dist/internal/field-text.d.ts.map +1 -0
- package/dist/internal/field-text.js +37 -0
- package/dist/internal/field-text.js.map +1 -0
- package/dist/internal/gateway/commands.d.ts +92 -0
- package/dist/internal/gateway/commands.d.ts.map +1 -0
- package/dist/internal/gateway/commands.js +223 -0
- package/dist/internal/gateway/commands.js.map +1 -0
- package/dist/internal/gateway/dispatch-table.d.ts +42 -0
- package/dist/internal/gateway/dispatch-table.d.ts.map +1 -0
- package/dist/internal/gateway/dispatch-table.js +288 -0
- package/dist/internal/gateway/dispatch-table.js.map +1 -0
- package/dist/internal/gateway/event-dispatches.d.ts +97 -0
- package/dist/internal/gateway/event-dispatches.d.ts.map +1 -0
- package/dist/internal/gateway/event-dispatches.js +172 -0
- package/dist/internal/gateway/event-dispatches.js.map +1 -0
- package/dist/internal/gateway/frames.d.ts +45 -0
- package/dist/internal/gateway/frames.d.ts.map +1 -0
- package/dist/internal/gateway/frames.js +121 -0
- package/dist/internal/gateway/frames.js.map +1 -0
- package/dist/internal/gateway/options.d.ts +24 -0
- package/dist/internal/gateway/options.d.ts.map +1 -0
- package/dist/internal/gateway/options.js +103 -0
- package/dist/internal/gateway/options.js.map +1 -0
- package/dist/internal/gateway/session.d.ts +104 -0
- package/dist/internal/gateway/session.d.ts.map +1 -0
- package/dist/internal/gateway/session.js +420 -0
- package/dist/internal/gateway/session.js.map +1 -0
- package/dist/internal/gateway-requests.d.ts +10 -0
- package/dist/internal/gateway-requests.d.ts.map +1 -0
- package/dist/internal/gateway-requests.js +26 -0
- package/dist/internal/gateway-requests.js.map +1 -0
- package/dist/internal/gateway.d.ts +19 -0
- package/dist/internal/gateway.d.ts.map +1 -0
- package/dist/internal/gateway.js +11 -0
- package/dist/internal/gateway.js.map +1 -0
- package/dist/internal/guild-cache.d.ts +69 -0
- package/dist/internal/guild-cache.d.ts.map +1 -0
- package/dist/internal/guild-cache.js +402 -0
- package/dist/internal/guild-cache.js.map +1 -0
- package/dist/internal/guild-discovery.d.ts +15 -0
- package/dist/internal/guild-discovery.d.ts.map +1 -0
- package/dist/internal/guild-discovery.js +258 -0
- package/dist/internal/guild-discovery.js.map +1 -0
- package/dist/internal/guild-lifecycle.d.ts +18 -0
- package/dist/internal/guild-lifecycle.d.ts.map +1 -0
- package/dist/internal/guild-lifecycle.js +119 -0
- package/dist/internal/guild-lifecycle.js.map +1 -0
- package/dist/internal/guild-settings.d.ts +11 -0
- package/dist/internal/guild-settings.d.ts.map +1 -0
- package/dist/internal/guild-settings.js +150 -0
- package/dist/internal/guild-settings.js.map +1 -0
- package/dist/internal/guilds.d.ts +94 -0
- package/dist/internal/guilds.d.ts.map +1 -0
- package/dist/internal/guilds.js +785 -0
- package/dist/internal/guilds.js.map +1 -0
- package/dist/internal/init-command.d.ts +54 -0
- package/dist/internal/init-command.d.ts.map +1 -0
- package/dist/internal/init-command.js +248 -0
- package/dist/internal/init-command.js.map +1 -0
- package/dist/internal/instance.d.ts +69 -0
- package/dist/internal/instance.d.ts.map +1 -0
- package/dist/internal/instance.js +455 -0
- package/dist/internal/instance.js.map +1 -0
- package/dist/internal/invalid-callback-return.d.ts +3 -0
- package/dist/internal/invalid-callback-return.d.ts.map +1 -0
- package/dist/internal/invalid-callback-return.js +26 -0
- package/dist/internal/invalid-callback-return.js.map +1 -0
- package/dist/internal/invites.d.ts +19 -0
- package/dist/internal/invites.d.ts.map +1 -0
- package/dist/internal/invites.js +182 -0
- package/dist/internal/invites.js.map +1 -0
- package/dist/internal/logging.d.ts +129 -0
- package/dist/internal/logging.d.ts.map +1 -0
- package/dist/internal/logging.js +868 -0
- package/dist/internal/logging.js.map +1 -0
- package/dist/internal/logical-scheduler.d.ts +27 -0
- package/dist/internal/logical-scheduler.d.ts.map +1 -0
- package/dist/internal/logical-scheduler.js +102 -0
- package/dist/internal/logical-scheduler.js.map +1 -0
- package/dist/internal/masking.d.ts +13 -0
- package/dist/internal/masking.d.ts.map +1 -0
- package/dist/internal/masking.js +235 -0
- package/dist/internal/masking.js.map +1 -0
- package/dist/internal/member-chunks.d.ts +96 -0
- package/dist/internal/member-chunks.d.ts.map +1 -0
- package/dist/internal/member-chunks.js +557 -0
- package/dist/internal/member-chunks.js.map +1 -0
- package/dist/internal/member-search-workflow.d.ts +19 -0
- package/dist/internal/member-search-workflow.d.ts.map +1 -0
- package/dist/internal/member-search-workflow.js +143 -0
- package/dist/internal/member-search-workflow.js.map +1 -0
- package/dist/internal/member-search.d.ts +20 -0
- package/dist/internal/member-search.d.ts.map +1 -0
- package/dist/internal/member-search.js +201 -0
- package/dist/internal/member-search.js.map +1 -0
- package/dist/internal/message-cleanup.d.ts +9 -0
- package/dist/internal/message-cleanup.d.ts.map +1 -0
- package/dist/internal/message-cleanup.js +368 -0
- package/dist/internal/message-cleanup.js.map +1 -0
- package/dist/internal/message-fields.d.ts +9 -0
- package/dist/internal/message-fields.d.ts.map +1 -0
- package/dist/internal/message-fields.js +55 -0
- package/dist/internal/message-fields.js.map +1 -0
- package/dist/internal/message-search-workflow.d.ts +14 -0
- package/dist/internal/message-search-workflow.d.ts.map +1 -0
- package/dist/internal/message-search-workflow.js +101 -0
- package/dist/internal/message-search-workflow.js.map +1 -0
- package/dist/internal/message-search.d.ts +19 -0
- package/dist/internal/message-search.d.ts.map +1 -0
- package/dist/internal/message-search.js +317 -0
- package/dist/internal/message-search.js.map +1 -0
- package/dist/internal/message.d.ts +34 -0
- package/dist/internal/message.d.ts.map +1 -0
- package/dist/internal/message.js +723 -0
- package/dist/internal/message.js.map +1 -0
- package/dist/internal/metrics.d.ts +16 -0
- package/dist/internal/metrics.d.ts.map +1 -0
- package/dist/internal/metrics.js +49 -0
- package/dist/internal/metrics.js.map +1 -0
- package/dist/internal/moderation.d.ts +20 -0
- package/dist/internal/moderation.d.ts.map +1 -0
- package/dist/internal/moderation.js +219 -0
- package/dist/internal/moderation.js.map +1 -0
- package/dist/internal/multipart.d.ts +10 -0
- package/dist/internal/multipart.d.ts.map +1 -0
- package/dist/internal/multipart.js +156 -0
- package/dist/internal/multipart.js.map +1 -0
- package/dist/internal/node-version.d.ts +10 -0
- package/dist/internal/node-version.d.ts.map +1 -0
- package/dist/internal/node-version.js +21 -0
- package/dist/internal/node-version.js.map +1 -0
- package/dist/internal/oauth.d.ts +29 -0
- package/dist/internal/oauth.d.ts.map +1 -0
- package/dist/internal/oauth.js +721 -0
- package/dist/internal/oauth.js.map +1 -0
- package/dist/internal/observer.d.ts +21 -0
- package/dist/internal/observer.d.ts.map +1 -0
- package/dist/internal/observer.js +48 -0
- package/dist/internal/observer.js.map +1 -0
- package/dist/internal/operation-signal.d.ts +9 -0
- package/dist/internal/operation-signal.d.ts.map +1 -0
- package/dist/internal/operation-signal.js +19 -0
- package/dist/internal/operation-signal.js.map +1 -0
- package/dist/internal/pagination.d.ts +67 -0
- package/dist/internal/pagination.d.ts.map +1 -0
- package/dist/internal/pagination.js +306 -0
- package/dist/internal/pagination.js.map +1 -0
- package/dist/internal/permission-requirements.d.ts +34 -0
- package/dist/internal/permission-requirements.d.ts.map +1 -0
- package/dist/internal/permission-requirements.js +204 -0
- package/dist/internal/permission-requirements.js.map +1 -0
- package/dist/internal/permissions.d.ts +28 -0
- package/dist/internal/permissions.d.ts.map +1 -0
- package/dist/internal/permissions.js +314 -0
- package/dist/internal/permissions.js.map +1 -0
- package/dist/internal/pins.d.ts +24 -0
- package/dist/internal/pins.d.ts.map +1 -0
- package/dist/internal/pins.js +83 -0
- package/dist/internal/pins.js.map +1 -0
- package/dist/internal/presence.d.ts +101 -0
- package/dist/internal/presence.d.ts.map +1 -0
- package/dist/internal/presence.js +581 -0
- package/dist/internal/presence.js.map +1 -0
- package/dist/internal/protocol/gateway.d.ts +116 -0
- package/dist/internal/protocol/gateway.d.ts.map +1 -0
- package/dist/internal/protocol/gateway.js +258 -0
- package/dist/internal/protocol/gateway.js.map +1 -0
- package/dist/internal/rate-limit-templates.d.ts +2 -0
- package/dist/internal/rate-limit-templates.d.ts.map +1 -0
- package/dist/internal/rate-limit-templates.js +132 -0
- package/dist/internal/rate-limit-templates.js.map +1 -0
- package/dist/internal/rate-limits.d.ts +32 -0
- package/dist/internal/rate-limits.d.ts.map +1 -0
- package/dist/internal/rate-limits.js +306 -0
- package/dist/internal/rate-limits.js.map +1 -0
- package/dist/internal/reaction-collector.d.ts +39 -0
- package/dist/internal/reaction-collector.d.ts.map +1 -0
- package/dist/internal/reaction-collector.js +441 -0
- package/dist/internal/reaction-collector.js.map +1 -0
- package/dist/internal/reaction-pages.d.ts +18 -0
- package/dist/internal/reaction-pages.d.ts.map +1 -0
- package/dist/internal/reaction-pages.js +213 -0
- package/dist/internal/reaction-pages.js.map +1 -0
- package/dist/internal/reactions.d.ts +30 -0
- package/dist/internal/reactions.d.ts.map +1 -0
- package/dist/internal/reactions.js +160 -0
- package/dist/internal/reactions.js.map +1 -0
- package/dist/internal/rejection-scope.d.ts +25 -0
- package/dist/internal/rejection-scope.d.ts.map +1 -0
- package/dist/internal/rejection-scope.js +103 -0
- package/dist/internal/rejection-scope.js.map +1 -0
- package/dist/internal/response-json.d.ts +12 -0
- package/dist/internal/response-json.d.ts.map +1 -0
- package/dist/internal/response-json.js +74 -0
- package/dist/internal/response-json.js.map +1 -0
- package/dist/internal/rest/admission.d.ts +77 -0
- package/dist/internal/rest/admission.d.ts.map +1 -0
- package/dist/internal/rest/admission.js +178 -0
- package/dist/internal/rest/admission.js.map +1 -0
- package/dist/internal/rest/attempt.d.ts +124 -0
- package/dist/internal/rest/attempt.d.ts.map +1 -0
- package/dist/internal/rest/attempt.js +410 -0
- package/dist/internal/rest/attempt.js.map +1 -0
- package/dist/internal/rest/classify.d.ts +93 -0
- package/dist/internal/rest/classify.d.ts.map +1 -0
- package/dist/internal/rest/classify.js +304 -0
- package/dist/internal/rest/classify.js.map +1 -0
- package/dist/internal/rest/download.d.ts +66 -0
- package/dist/internal/rest/download.d.ts.map +1 -0
- package/dist/internal/rest/download.js +552 -0
- package/dist/internal/rest/download.js.map +1 -0
- package/dist/internal/rest/options.d.ts +42 -0
- package/dist/internal/rest/options.d.ts.map +1 -0
- package/dist/internal/rest/options.js +99 -0
- package/dist/internal/rest/options.js.map +1 -0
- package/dist/internal/rest/owner.d.ts +154 -0
- package/dist/internal/rest/owner.d.ts.map +1 -0
- package/dist/internal/rest/owner.js +1292 -0
- package/dist/internal/rest/owner.js.map +1 -0
- package/dist/internal/rest/request.d.ts +31 -0
- package/dist/internal/rest/request.d.ts.map +1 -0
- package/dist/internal/rest/request.js +227 -0
- package/dist/internal/rest/request.js.map +1 -0
- package/dist/internal/rest.d.ts +10 -0
- package/dist/internal/rest.d.ts.map +1 -0
- package/dist/internal/rest.js +9 -0
- package/dist/internal/rest.js.map +1 -0
- package/dist/internal/retention-age.d.ts +11 -0
- package/dist/internal/retention-age.d.ts.map +1 -0
- package/dist/internal/retention-age.js +29 -0
- package/dist/internal/retention-age.js.map +1 -0
- package/dist/internal/role-hierarchy-workflow.d.ts +15 -0
- package/dist/internal/role-hierarchy-workflow.d.ts.map +1 -0
- package/dist/internal/role-hierarchy-workflow.js +122 -0
- package/dist/internal/role-hierarchy-workflow.js.map +1 -0
- package/dist/internal/role-hierarchy.d.ts +11 -0
- package/dist/internal/role-hierarchy.d.ts.map +1 -0
- package/dist/internal/role-hierarchy.js +87 -0
- package/dist/internal/role-hierarchy.js.map +1 -0
- package/dist/internal/scheduled-tasks.d.ts +46 -0
- package/dist/internal/scheduled-tasks.d.ts.map +1 -0
- package/dist/internal/scheduled-tasks.js +190 -0
- package/dist/internal/scheduled-tasks.js.map +1 -0
- package/dist/internal/sharding.d.ts +62 -0
- package/dist/internal/sharding.d.ts.map +1 -0
- package/dist/internal/sharding.js +205 -0
- package/dist/internal/sharding.js.map +1 -0
- package/dist/internal/starter-project.d.ts +27 -0
- package/dist/internal/starter-project.d.ts.map +1 -0
- package/dist/internal/starter-project.js +224 -0
- package/dist/internal/starter-project.js.map +1 -0
- package/dist/internal/suggest.d.ts +12 -0
- package/dist/internal/suggest.d.ts.map +1 -0
- package/dist/internal/suggest.js +51 -0
- package/dist/internal/suggest.js.map +1 -0
- package/dist/internal/supervisor.d.ts +95 -0
- package/dist/internal/supervisor.d.ts.map +1 -0
- package/dist/internal/supervisor.js +1829 -0
- package/dist/internal/supervisor.js.map +1 -0
- package/dist/internal/testing/discovery.d.ts +24 -0
- package/dist/internal/testing/discovery.d.ts.map +1 -0
- package/dist/internal/testing/discovery.js +22 -0
- package/dist/internal/testing/discovery.js.map +1 -0
- package/dist/internal/testing/errors.d.ts +43 -0
- package/dist/internal/testing/errors.d.ts.map +1 -0
- package/dist/internal/testing/errors.js +63 -0
- package/dist/internal/testing/errors.js.map +1 -0
- package/dist/internal/testing/fixtures.d.ts +477 -0
- package/dist/internal/testing/fixtures.d.ts.map +1 -0
- package/dist/internal/testing/fixtures.js +233 -0
- package/dist/internal/testing/fixtures.js.map +1 -0
- package/dist/internal/testing/gateway.d.ts +51 -0
- package/dist/internal/testing/gateway.d.ts.map +1 -0
- package/dist/internal/testing/gateway.js +265 -0
- package/dist/internal/testing/gateway.js.map +1 -0
- package/dist/internal/testing/harness.d.ts +60 -0
- package/dist/internal/testing/harness.d.ts.map +1 -0
- package/dist/internal/testing/harness.js +280 -0
- package/dist/internal/testing/harness.js.map +1 -0
- package/dist/internal/testing/http.d.ts +31 -0
- package/dist/internal/testing/http.d.ts.map +1 -0
- package/dist/internal/testing/http.js +347 -0
- package/dist/internal/testing/http.js.map +1 -0
- package/dist/internal/testing/types.d.ts +222 -0
- package/dist/internal/testing/types.d.ts.map +1 -0
- package/dist/internal/testing/types.js +2 -0
- package/dist/internal/testing/types.js.map +1 -0
- package/dist/internal/testing/wait.d.ts +16 -0
- package/dist/internal/testing/wait.d.ts.map +1 -0
- package/dist/internal/testing/wait.js +55 -0
- package/dist/internal/testing/wait.js.map +1 -0
- package/dist/internal/thread-events.d.ts +40 -0
- package/dist/internal/thread-events.d.ts.map +1 -0
- package/dist/internal/thread-events.js +121 -0
- package/dist/internal/thread-events.js.map +1 -0
- package/dist/internal/threads.d.ts +47 -0
- package/dist/internal/threads.d.ts.map +1 -0
- package/dist/internal/threads.js +587 -0
- package/dist/internal/threads.js.map +1 -0
- package/dist/internal/transfer-source.d.ts +29 -0
- package/dist/internal/transfer-source.d.ts.map +1 -0
- package/dist/internal/transfer-source.js +347 -0
- package/dist/internal/transfer-source.js.map +1 -0
- package/dist/internal/transport/http.d.ts +12 -0
- package/dist/internal/transport/http.d.ts.map +1 -0
- package/dist/internal/transport/http.js +44 -0
- package/dist/internal/transport/http.js.map +1 -0
- package/dist/internal/transport/index.d.ts +21 -0
- package/dist/internal/transport/index.d.ts.map +1 -0
- package/dist/internal/transport/index.js +15 -0
- package/dist/internal/transport/index.js.map +1 -0
- package/dist/internal/transport/socket.d.ts +51 -0
- package/dist/internal/transport/socket.d.ts.map +1 -0
- package/dist/internal/transport/socket.js +27 -0
- package/dist/internal/transport/socket.js.map +1 -0
- package/dist/internal/transport/user-agent.d.ts +7 -0
- package/dist/internal/transport/user-agent.d.ts.map +1 -0
- package/dist/internal/transport/user-agent.js +42 -0
- package/dist/internal/transport/user-agent.js.map +1 -0
- package/dist/internal/uploads.d.ts +23 -0
- package/dist/internal/uploads.d.ts.map +1 -0
- package/dist/internal/uploads.js +89 -0
- package/dist/internal/uploads.js.map +1 -0
- package/dist/internal/user-cache.d.ts +50 -0
- package/dist/internal/user-cache.d.ts.map +1 -0
- package/dist/internal/user-cache.js +273 -0
- package/dist/internal/user-cache.js.map +1 -0
- package/dist/internal/users.d.ts +41 -0
- package/dist/internal/users.d.ts.map +1 -0
- package/dist/internal/users.js +333 -0
- package/dist/internal/users.js.map +1 -0
- package/dist/internal/vanity-url.d.ts +11 -0
- package/dist/internal/vanity-url.d.ts.map +1 -0
- package/dist/internal/vanity-url.js +58 -0
- package/dist/internal/vanity-url.js.map +1 -0
- package/dist/internal/webhooks.d.ts +58 -0
- package/dist/internal/webhooks.d.ts.map +1 -0
- package/dist/internal/webhooks.js +490 -0
- package/dist/internal/webhooks.js.map +1 -0
- package/dist/invites.d.ts +86 -0
- package/dist/invites.d.ts.map +1 -0
- package/dist/invites.js +2 -0
- package/dist/invites.js.map +1 -0
- package/dist/logging.d.ts +228 -0
- package/dist/logging.d.ts.map +1 -0
- package/dist/logging.js +2 -0
- package/dist/logging.js.map +1 -0
- package/dist/member-chunks.d.ts +145 -0
- package/dist/member-chunks.d.ts.map +1 -0
- package/dist/member-chunks.js +68 -0
- package/dist/member-chunks.js.map +1 -0
- package/dist/member-search.d.ts +140 -0
- package/dist/member-search.d.ts.map +1 -0
- package/dist/member-search.js +14 -0
- package/dist/member-search.js.map +1 -0
- package/dist/message-cleanup.d.ts +227 -0
- package/dist/message-cleanup.d.ts.map +1 -0
- package/dist/message-cleanup.js +101 -0
- package/dist/message-cleanup.js.map +1 -0
- package/dist/message-errors.d.ts +172 -0
- package/dist/message-errors.d.ts.map +1 -0
- package/dist/message-errors.js +173 -0
- package/dist/message-errors.js.map +1 -0
- package/dist/message-search.d.ts +201 -0
- package/dist/message-search.d.ts.map +1 -0
- package/dist/message-search.js +2 -0
- package/dist/message-search.js.map +1 -0
- package/dist/messages.d.ts +694 -0
- package/dist/messages.d.ts.map +1 -0
- package/dist/messages.js +37 -0
- package/dist/messages.js.map +1 -0
- package/dist/native-commands.d.ts +451 -0
- package/dist/native-commands.d.ts.map +1 -0
- package/dist/native-commands.js +432 -0
- package/dist/native-commands.js.map +1 -0
- package/dist/native-supervisor.d.ts +125 -0
- package/dist/native-supervisor.d.ts.map +1 -0
- package/dist/native-supervisor.js +126 -0
- package/dist/native-supervisor.js.map +1 -0
- package/dist/oauth.d.ts +298 -0
- package/dist/oauth.d.ts.map +1 -0
- package/dist/oauth.js +128 -0
- package/dist/oauth.js.map +1 -0
- package/dist/observer.d.ts +111 -0
- package/dist/observer.d.ts.map +1 -0
- package/dist/observer.js +2 -0
- package/dist/observer.js.map +1 -0
- package/dist/pagination.d.ts +117 -0
- package/dist/pagination.d.ts.map +1 -0
- package/dist/pagination.js +61 -0
- package/dist/pagination.js.map +1 -0
- package/dist/permissions.d.ts +73 -0
- package/dist/permissions.d.ts.map +1 -0
- package/dist/permissions.js +2 -0
- package/dist/permissions.js.map +1 -0
- package/dist/pins.d.ts +62 -0
- package/dist/pins.d.ts.map +1 -0
- package/dist/pins.js +2 -0
- package/dist/pins.js.map +1 -0
- package/dist/presence.d.ts +84 -0
- package/dist/presence.d.ts.map +1 -0
- package/dist/presence.js +46 -0
- package/dist/presence.js.map +1 -0
- package/dist/reaction-pages.d.ts +99 -0
- package/dist/reaction-pages.d.ts.map +1 -0
- package/dist/reaction-pages.js +2 -0
- package/dist/reaction-pages.js.map +1 -0
- package/dist/reactions.d.ts +118 -0
- package/dist/reactions.d.ts.map +1 -0
- package/dist/reactions.js +2 -0
- package/dist/reactions.js.map +1 -0
- package/dist/rest.d.ts +260 -0
- package/dist/rest.d.ts.map +1 -0
- package/dist/rest.js +46 -0
- package/dist/rest.js.map +1 -0
- package/dist/role-hierarchy.d.ts +81 -0
- package/dist/role-hierarchy.d.ts.map +1 -0
- package/dist/role-hierarchy.js +53 -0
- package/dist/role-hierarchy.js.map +1 -0
- package/dist/sharding.d.ts +219 -0
- package/dist/sharding.d.ts.map +1 -0
- package/dist/sharding.js +86 -0
- package/dist/sharding.js.map +1 -0
- package/dist/supervisor.d.ts +392 -0
- package/dist/supervisor.d.ts.map +1 -0
- package/dist/supervisor.js +101 -0
- package/dist/supervisor.js.map +1 -0
- package/dist/testing.d.ts +258 -0
- package/dist/testing.d.ts.map +1 -0
- package/dist/testing.js +202 -0
- package/dist/testing.js.map +1 -0
- package/dist/text.d.ts +38 -0
- package/dist/text.d.ts.map +1 -0
- package/dist/text.js +46 -0
- package/dist/text.js.map +1 -0
- package/dist/threads.d.ts +258 -0
- package/dist/threads.d.ts.map +1 -0
- package/dist/threads.js +2 -0
- package/dist/threads.js.map +1 -0
- package/dist/users.d.ts +204 -0
- package/dist/users.d.ts.map +1 -0
- package/dist/users.js +44 -0
- package/dist/users.js.map +1 -0
- package/dist/webhooks.d.ts +423 -0
- package/dist/webhooks.d.ts.map +1 -0
- package/dist/webhooks.js +68 -0
- package/dist/webhooks.js.map +1 -0
- package/esm-only.cjs +3 -0
- package/examples/starter/bot-effect.ts +17 -0
- package/examples/starter/bot.js +13 -0
- package/examples/starter/bot.ts +13 -0
- package/package.json +82 -0
- package/src/api/default/application.ts +40 -0
- package/src/api/default/attachments.ts +106 -0
- package/src/api/default/audit-logs.ts +58 -0
- package/src/api/default/bot.ts +586 -0
- package/src/api/default/cache.ts +106 -0
- package/src/api/default/channels.ts +317 -0
- package/src/api/default/client.ts +829 -0
- package/src/api/default/collectors.ts +81 -0
- package/src/api/default/commands.ts +92 -0
- package/src/api/default/direct-messages.ts +143 -0
- package/src/api/default/discovery.ts +103 -0
- package/src/api/default/emojis.ts +125 -0
- package/src/api/default/events.ts +144 -0
- package/src/api/default/gateway.ts +67 -0
- package/src/api/default/guards.ts +173 -0
- package/src/api/default/guilds.ts +271 -0
- package/src/api/default/helpers.ts +97 -0
- package/src/api/default/instance.ts +49 -0
- package/src/api/default/invites.ts +73 -0
- package/src/api/default/logging.ts +37 -0
- package/src/api/default/members.ts +550 -0
- package/src/api/default/messages.ts +1053 -0
- package/src/api/default/oauth.ts +293 -0
- package/src/api/default/permissions.ts +47 -0
- package/src/api/default/presence.ts +88 -0
- package/src/api/default/rest.ts +30 -0
- package/src/api/default/results.ts +44 -0
- package/src/api/default/roles.ts +154 -0
- package/src/api/default/stickers.ts +129 -0
- package/src/api/default/supervisor.ts +53 -0
- package/src/api/default/threads.ts +233 -0
- package/src/api/default/users.ts +82 -0
- package/src/api/default/webhook-client.ts +266 -0
- package/src/api/default/webhooks.ts +89 -0
- package/src/api/effect/application.ts +29 -0
- package/src/api/effect/attachments.ts +100 -0
- package/src/api/effect/audit-logs.ts +50 -0
- package/src/api/effect/bot.ts +546 -0
- package/src/api/effect/cache.ts +110 -0
- package/src/api/effect/channels.ts +293 -0
- package/src/api/effect/client.ts +792 -0
- package/src/api/effect/collectors.ts +103 -0
- package/src/api/effect/commands.ts +87 -0
- package/src/api/effect/direct-messages.ts +119 -0
- package/src/api/effect/discovery.ts +87 -0
- package/src/api/effect/emojis.ts +108 -0
- package/src/api/effect/events.ts +92 -0
- package/src/api/effect/failures.ts +14 -0
- package/src/api/effect/gateway.ts +63 -0
- package/src/api/effect/guards.ts +194 -0
- package/src/api/effect/guilds.ts +247 -0
- package/src/api/effect/helpers.ts +359 -0
- package/src/api/effect/hierarchy.ts +26 -0
- package/src/api/effect/instance.ts +50 -0
- package/src/api/effect/invites.ts +59 -0
- package/src/api/effect/logging.ts +37 -0
- package/src/api/effect/members.ts +521 -0
- package/src/api/effect/messages.ts +1003 -0
- package/src/api/effect/oauth.ts +208 -0
- package/src/api/effect/permissions.ts +44 -0
- package/src/api/effect/presence.ts +83 -0
- package/src/api/effect/rest.ts +27 -0
- package/src/api/effect/roles.ts +136 -0
- package/src/api/effect/service.ts +104 -0
- package/src/api/effect/stickers.ts +112 -0
- package/src/api/effect/supervisor.ts +58 -0
- package/src/api/effect/threads.ts +221 -0
- package/src/api/effect/users.ts +66 -0
- package/src/api/effect/webhook-client.ts +206 -0
- package/src/api/effect/webhooks.ts +75 -0
- package/src/api-errors.ts +985 -0
- package/src/application.ts +103 -0
- package/src/assets.ts +731 -0
- package/src/attachments.ts +469 -0
- package/src/audit-logs.ts +355 -0
- package/src/bot-runner.ts +91 -0
- package/src/builders.ts +390 -0
- package/src/cache.ts +190 -0
- package/src/channels.ts +1051 -0
- package/src/cli.ts +60 -0
- package/src/client.ts +663 -0
- package/src/collectors.ts +248 -0
- package/src/colors.ts +91 -0
- package/src/command-arguments.ts +432 -0
- package/src/command-help.ts +55 -0
- package/src/commands.ts +403 -0
- package/src/counts.ts +160 -0
- package/src/default-commands.ts +1147 -0
- package/src/default-supervisor.ts +484 -0
- package/src/discovery.ts +241 -0
- package/src/effect-testing.ts +603 -0
- package/src/effect.ts +751 -0
- package/src/embeds.ts +253 -0
- package/src/error-tools.ts +191 -0
- package/src/errors.ts +849 -0
- package/src/events.ts +830 -0
- package/src/expressions.ts +198 -0
- package/src/failures.ts +55 -0
- package/src/gateway.ts +86 -0
- package/src/guilds.ts +1108 -0
- package/src/helpers.ts +836 -0
- package/src/index.ts +796 -0
- package/src/input-validation.ts +94 -0
- package/src/instance.ts +111 -0
- package/src/internal/agents-section.ts +114 -0
- package/src/internal/application.ts +51 -0
- package/src/internal/attachment-refresh.ts +57 -0
- package/src/internal/attachments.ts +313 -0
- package/src/internal/audit-logs.ts +336 -0
- package/src/internal/audit.ts +33 -0
- package/src/internal/binding/default-adapters.ts +482 -0
- package/src/internal/binding/default.ts +155 -0
- package/src/internal/binding/execute.ts +221 -0
- package/src/internal/binding/native-adapters.ts +199 -0
- package/src/internal/binding/native.ts +72 -0
- package/src/internal/binding/operations.ts +1171 -0
- package/src/internal/bot-runner.ts +480 -0
- package/src/internal/cache-changes.ts +363 -0
- package/src/internal/cache.ts +323 -0
- package/src/internal/calls.ts +119 -0
- package/src/internal/channel-cache.ts +435 -0
- package/src/internal/channel-decode.ts +399 -0
- package/src/internal/channels.ts +874 -0
- package/src/internal/client/backoff.ts +69 -0
- package/src/internal/client/configuration-fields.ts +18 -0
- package/src/internal/client/drain.ts +150 -0
- package/src/internal/client/intake.ts +228 -0
- package/src/internal/client/lifetime.ts +165 -0
- package/src/internal/client/shard-loop.ts +586 -0
- package/src/internal/client-registry.ts +35 -0
- package/src/internal/client.ts +2448 -0
- package/src/internal/clock.ts +11 -0
- package/src/internal/code-catalogue.ts +739 -0
- package/src/internal/collector.ts +452 -0
- package/src/internal/command-arguments.ts +585 -0
- package/src/internal/command-guards.ts +96 -0
- package/src/internal/command-help.ts +156 -0
- package/src/internal/commands.ts +1319 -0
- package/src/internal/configuration.ts +529 -0
- package/src/internal/counts.ts +471 -0
- package/src/internal/decode/primitives.ts +67 -0
- package/src/internal/decode/timestamp.ts +29 -0
- package/src/internal/decode/trace.ts +65 -0
- package/src/internal/defects.ts +115 -0
- package/src/internal/effect-failures.ts +65 -0
- package/src/internal/embeds.ts +355 -0
- package/src/internal/events.ts +1345 -0
- package/src/internal/expiry-queue.ts +148 -0
- package/src/internal/expressions.ts +415 -0
- package/src/internal/failures.ts +492 -0
- package/src/internal/field-text.ts +40 -0
- package/src/internal/gateway/commands.ts +328 -0
- package/src/internal/gateway/dispatch-table.ts +383 -0
- package/src/internal/gateway/event-dispatches.ts +201 -0
- package/src/internal/gateway/frames.ts +176 -0
- package/src/internal/gateway/options.ts +144 -0
- package/src/internal/gateway/session.ts +625 -0
- package/src/internal/gateway-requests.ts +26 -0
- package/src/internal/gateway.ts +22 -0
- package/src/internal/guild-cache.ts +424 -0
- package/src/internal/guild-discovery.ts +332 -0
- package/src/internal/guild-lifecycle.ts +128 -0
- package/src/internal/guild-settings.ts +209 -0
- package/src/internal/guilds.ts +949 -0
- package/src/internal/init-command.ts +305 -0
- package/src/internal/instance.ts +645 -0
- package/src/internal/invalid-callback-return.ts +28 -0
- package/src/internal/invites.ts +234 -0
- package/src/internal/logging.ts +1007 -0
- package/src/internal/logical-scheduler.ts +139 -0
- package/src/internal/masking.ts +224 -0
- package/src/internal/member-chunks.ts +649 -0
- package/src/internal/member-search-workflow.ts +237 -0
- package/src/internal/member-search.ts +272 -0
- package/src/internal/message-cleanup.ts +515 -0
- package/src/internal/message-fields.ts +71 -0
- package/src/internal/message-search-workflow.ts +166 -0
- package/src/internal/message-search.ts +476 -0
- package/src/internal/message.ts +879 -0
- package/src/internal/metrics.ts +55 -0
- package/src/internal/moderation.ts +288 -0
- package/src/internal/multipart.ts +171 -0
- package/src/internal/node-version.ts +22 -0
- package/src/internal/oauth.ts +1146 -0
- package/src/internal/observer.ts +62 -0
- package/src/internal/operation-signal.ts +26 -0
- package/src/internal/pagination.ts +494 -0
- package/src/internal/permission-requirements.ts +359 -0
- package/src/internal/permissions.ts +417 -0
- package/src/internal/pins.ts +115 -0
- package/src/internal/presence.ts +745 -0
- package/src/internal/protocol/gateway.ts +299 -0
- package/src/internal/rate-limit-templates.ts +138 -0
- package/src/internal/rate-limits.ts +346 -0
- package/src/internal/reaction-collector.ts +499 -0
- package/src/internal/reaction-pages.ts +260 -0
- package/src/internal/reactions.ts +174 -0
- package/src/internal/rejection-scope.ts +119 -0
- package/src/internal/response-json.ts +76 -0
- package/src/internal/rest/admission.ts +210 -0
- package/src/internal/rest/attempt.ts +617 -0
- package/src/internal/rest/classify.ts +391 -0
- package/src/internal/rest/download.ts +658 -0
- package/src/internal/rest/options.ts +145 -0
- package/src/internal/rest/owner.ts +1828 -0
- package/src/internal/rest/request.ts +289 -0
- package/src/internal/rest.ts +9 -0
- package/src/internal/retention-age.ts +33 -0
- package/src/internal/role-hierarchy-workflow.ts +150 -0
- package/src/internal/role-hierarchy.ts +93 -0
- package/src/internal/scheduled-tasks.ts +217 -0
- package/src/internal/sharding.ts +270 -0
- package/src/internal/starter-project.ts +251 -0
- package/src/internal/suggest.ts +50 -0
- package/src/internal/supervisor.ts +2253 -0
- package/src/internal/testing/discovery.ts +23 -0
- package/src/internal/testing/errors.ts +67 -0
- package/src/internal/testing/fixtures.ts +714 -0
- package/src/internal/testing/gateway.ts +305 -0
- package/src/internal/testing/harness.ts +328 -0
- package/src/internal/testing/http.ts +395 -0
- package/src/internal/testing/types.ts +240 -0
- package/src/internal/testing/wait.ts +63 -0
- package/src/internal/thread-events.ts +128 -0
- package/src/internal/threads.ts +718 -0
- package/src/internal/transfer-source.ts +359 -0
- package/src/internal/transport/http.ts +46 -0
- package/src/internal/transport/index.ts +23 -0
- package/src/internal/transport/socket.ts +71 -0
- package/src/internal/transport/user-agent.ts +46 -0
- package/src/internal/uploads.ts +111 -0
- package/src/internal/user-cache.ts +294 -0
- package/src/internal/users.ts +402 -0
- package/src/internal/vanity-url.ts +80 -0
- package/src/internal/webhooks.ts +690 -0
- package/src/invites.ts +87 -0
- package/src/logging.ts +247 -0
- package/src/member-chunks.ts +195 -0
- package/src/member-search.ts +152 -0
- package/src/message-cleanup.ts +308 -0
- package/src/message-errors.ts +245 -0
- package/src/message-search.ts +213 -0
- package/src/messages.ts +768 -0
- package/src/native-commands.ts +1249 -0
- package/src/native-supervisor.ts +345 -0
- package/src/oauth.ts +413 -0
- package/src/observer.ts +118 -0
- package/src/pagination.ts +172 -0
- package/src/permissions.ts +74 -0
- package/src/pins.ts +65 -0
- package/src/presence.ts +124 -0
- package/src/reaction-pages.ts +106 -0
- package/src/reactions.ts +126 -0
- package/src/rest.ts +282 -0
- package/src/role-hierarchy.ts +127 -0
- package/src/sharding.ts +272 -0
- package/src/supervisor.ts +460 -0
- package/src/testing.ts +424 -0
- package/src/text.ts +76 -0
- package/src/threads.ts +274 -0
- package/src/users.ts +237 -0
- package/src/webhooks.ts +512 -0
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
import * as Effect from "effect/Effect"
|
|
2
|
+
import type {
|
|
3
|
+
ReactionCollectorOptions as SharedReactionCollectorOptions,
|
|
4
|
+
ReactionCollectorResult,
|
|
5
|
+
CollectorOptions as SharedCollectorOptions,
|
|
6
|
+
CollectorResult,
|
|
7
|
+
CollectorFailure,
|
|
8
|
+
} from "#sdk/collectors"
|
|
9
|
+
import type { Message, MessageCore } from "#sdk/messages"
|
|
10
|
+
|
|
11
|
+
/** Choose reaction collection limits and an optional callback for each accepted addition.
|
|
12
|
+
* The callback executes with the services available when collection is registered
|
|
13
|
+
*
|
|
14
|
+
* @category Events and collectors
|
|
15
|
+
*/
|
|
16
|
+
export interface ReactionCollectorOptions<E = never, R = never> extends SharedReactionCollectorOptions {
|
|
17
|
+
/** Run once per accepted addition, sequentially, before continuing collection.
|
|
18
|
+
* Failures and defects while active fail collection with CollectorError handler, whose cause is the original failure or defect.
|
|
19
|
+
* The failure is also reported to the client-level onError with kind collector, the message IDs and the full Cause, or logged at Error.
|
|
20
|
+
* Stop, timeout, idle completion, scope closure, recovery and shutdown interrupt active work and await its finalizers.
|
|
21
|
+
* Uninterruptible work can delay closure. Do not await this collector's completion inside its handler.
|
|
22
|
+
* Already-dispatched effects are not rolled back. Callbacks are never retried
|
|
23
|
+
*/
|
|
24
|
+
readonly onReaction?: (reaction: import("#sdk/reactions").MessageReaction) => Effect.Effect<unknown, E, R>
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
/** Choose message collection limits and an optional callback for each accepted message.
|
|
28
|
+
* The callback executes with the services available when collection is registered
|
|
29
|
+
*
|
|
30
|
+
* @category Events and collectors
|
|
31
|
+
*/
|
|
32
|
+
export interface CollectorOptions<
|
|
33
|
+
E = never,
|
|
34
|
+
R = never,
|
|
35
|
+
M extends MessageCore = Message,
|
|
36
|
+
> extends SharedCollectorOptions<M> {
|
|
37
|
+
/** Run once per accepted message ID, sequentially, after filtering and stored-byte limit checks.
|
|
38
|
+
* Failures and defects while active fail collection with CollectorError handler, whose cause is the original failure or defect.
|
|
39
|
+
* The failure is also reported to the client-level onError with kind collector, the message IDs and the full Cause, or logged at Error.
|
|
40
|
+
* Stop, timeout, idle completion, scope closure, recovery and shutdown interrupt active work and await its finalizers.
|
|
41
|
+
* Uninterruptible work can delay closure. Do not await this collector's completion or client shutdown inside its handler.
|
|
42
|
+
* Already-dispatched effects are not rolled back. Callbacks are never retried
|
|
43
|
+
*/
|
|
44
|
+
readonly onMessage?: (message: M) => Effect.Effect<unknown, E, R>
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
/** A running message collector registered in a Scope.
|
|
48
|
+
* Use close to end collection and result to receive its result after cleanup
|
|
49
|
+
*
|
|
50
|
+
* @category Events and collectors
|
|
51
|
+
*/
|
|
52
|
+
export interface Collector<M extends MessageCore = Message> {
|
|
53
|
+
/**
|
|
54
|
+
* Stop accepting messages now, keeping accepted messages for a successful partial result.
|
|
55
|
+
* Repeated calls preserve whichever terminal outcome was recorded first.
|
|
56
|
+
* Use result to await callback cleanup and read the collection
|
|
57
|
+
*
|
|
58
|
+
* @remarks
|
|
59
|
+
* Stops collection when the Effect executes
|
|
60
|
+
*/
|
|
61
|
+
close(): Effect.Effect<void>
|
|
62
|
+
/**
|
|
63
|
+
* Wait for the final frozen collection result after timer, queue, filter, listener and callback cleanup.
|
|
64
|
+
* Idle, timeout or stop can succeed with no messages or a partial collection.
|
|
65
|
+
* Collection cancellation, filter or callback failure, overflow, gateway loss and client closure fail without partial messages.
|
|
66
|
+
* Multiple or later waiters receive the same collection outcome.
|
|
67
|
+
* Cancelling this wait affects only the waiter, not collection.
|
|
68
|
+
* Keeping the handle or successful result keeps its message snapshots in memory
|
|
69
|
+
*
|
|
70
|
+
* @remarks
|
|
71
|
+
* Defects keep their Cause
|
|
72
|
+
*/
|
|
73
|
+
result(): Effect.Effect<CollectorResult<M>, CollectorFailure>
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
/** A running reaction collector registered in a Scope.
|
|
77
|
+
* Use close to end collection and result to receive its result after cleanup
|
|
78
|
+
*
|
|
79
|
+
* @category Events and collectors
|
|
80
|
+
*/
|
|
81
|
+
export interface ReactionCollector {
|
|
82
|
+
/**
|
|
83
|
+
* Stop accepting additions now and keep accepted observations for a successful partial result.
|
|
84
|
+
* Repeated calls preserve the first recorded outcome.
|
|
85
|
+
* Use result to await callback cleanup and read the observations
|
|
86
|
+
*
|
|
87
|
+
* @remarks
|
|
88
|
+
* Stops collection when the Effect executes
|
|
89
|
+
*/
|
|
90
|
+
close(): Effect.Effect<void>
|
|
91
|
+
/**
|
|
92
|
+
* Wait for the final frozen reaction result after queue, timer, filter, listener and callback cleanup.
|
|
93
|
+
* Idle, timeout or stop can succeed with empty or partial observations.
|
|
94
|
+
* Collection cancellation, filter or callback failure, overflow, gateway loss and client shutdown fail without partial observations.
|
|
95
|
+
* Multiple or later waiters receive the same outcome.
|
|
96
|
+
* Cancelling this wait affects only the waiter, not collection.
|
|
97
|
+
* Keeping the handle or successful result retains its snapshots in memory
|
|
98
|
+
*
|
|
99
|
+
* @remarks
|
|
100
|
+
* Defects keep their Cause
|
|
101
|
+
*/
|
|
102
|
+
result(): Effect.Effect<ReactionCollectorResult, CollectorFailure>
|
|
103
|
+
}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
import { nativeCommands } from "#sdk/native-commands"
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Define text commands, parse their arguments and attach them to an existing client.
|
|
5
|
+
* The simplest route is runBot's commands option. Creation, registration and help return their result directly and
|
|
6
|
+
* throw ConfigurationError for misuse, so a misconfigured router fails at startup.
|
|
7
|
+
* Commands listen through one bounded messageCreate subscription in the caller's Scope when attach executes.
|
|
8
|
+
* The router does not connect the client or create a separate SDK runtime.
|
|
9
|
+
* Guards, cooldown keys, unmatched feedback and handler Effects remain application-owned, with built-in `guards` for common checks.
|
|
10
|
+
* The router does not retry failures, and it replies on its own only when `onReject: "reply"` is selected.
|
|
11
|
+
* Groups optionally organize command paths and help pages.
|
|
12
|
+
* Flat commands remain independent, and each protected command still needs its own guard
|
|
13
|
+
*
|
|
14
|
+
* @example
|
|
15
|
+
* ```ts
|
|
16
|
+
* import { commands, type Client } from "@neontechspace/fluxerly/effect"
|
|
17
|
+
* export function commandGroupExample(client: Client) {
|
|
18
|
+
* return commands
|
|
19
|
+
* .create({ prefix: "!" })
|
|
20
|
+
* .registerGroup({ name: "tools", aliases: ["t"] })
|
|
21
|
+
* .register({ name: "ping", execute: ({ reply }) => reply("Pong") }, { group: ["tools"] })
|
|
22
|
+
* .attach(client)
|
|
23
|
+
* }
|
|
24
|
+
* ```
|
|
25
|
+
*
|
|
26
|
+
* @example
|
|
27
|
+
* ```ts
|
|
28
|
+
* import { Effect } from "effect"
|
|
29
|
+
* import { commands, type Client } from "@neontechspace/fluxerly/effect"
|
|
30
|
+
*
|
|
31
|
+
* export const installPing = (client: Client) =>
|
|
32
|
+
* commands
|
|
33
|
+
* .create({
|
|
34
|
+
* prefix: "!",
|
|
35
|
+
* parse: commands.parseQuoted,
|
|
36
|
+
* onUnmatched: ({ reply }, unmatched) => {
|
|
37
|
+
* if (unmatched._tag !== "CommandUnknownName") return Effect.void
|
|
38
|
+
* const hint = unmatched.suggestion === undefined ? "" : `. Closest known command: ${unmatched.suggestion}`
|
|
39
|
+
* return reply(`Unknown command: ${unmatched.name}${hint}`)
|
|
40
|
+
* },
|
|
41
|
+
* })
|
|
42
|
+
* .register({ name: "ping", execute: ({ reply }) => reply("Pong") })
|
|
43
|
+
* .attach(client)
|
|
44
|
+
* ```
|
|
45
|
+
* Argument schemas are optional definitions of the values a command expects.
|
|
46
|
+
* Guards see raw input first. Conversion failures give rejection feedback without consuming a cooldown.
|
|
47
|
+
* The execute callback receives inferred frozen values alongside unchanged args
|
|
48
|
+
*
|
|
49
|
+
* @example
|
|
50
|
+
* ```ts
|
|
51
|
+
* import { commands, type Client } from "@neontechspace/fluxerly/effect"
|
|
52
|
+
*
|
|
53
|
+
* export function typedCommandExample(client: Client) {
|
|
54
|
+
* return commands
|
|
55
|
+
* .create({ prefix: "!", parse: commands.parseQuoted, onReject: "reply" })
|
|
56
|
+
* .register({
|
|
57
|
+
* name: "repeat",
|
|
58
|
+
* arguments: {
|
|
59
|
+
* mode: { type: "choice", choices: ["fast", "slow"] },
|
|
60
|
+
* count: { type: "integer", min: 1, max: 5, default: 1 },
|
|
61
|
+
* note: { type: "text", optional: true, rest: true },
|
|
62
|
+
* },
|
|
63
|
+
* cooldown: { durationMs: 10_000, per: "user" },
|
|
64
|
+
* execute: ({ reply, values }) => reply(`${values.count} / ${values.mode} / ${values.note ?? "No note"}`),
|
|
65
|
+
* })
|
|
66
|
+
* .attach(client)
|
|
67
|
+
* }
|
|
68
|
+
* ```
|
|
69
|
+
*
|
|
70
|
+
* @example
|
|
71
|
+
* ```ts
|
|
72
|
+
* import { Effect } from "effect"
|
|
73
|
+
* import { type Client, type NativePrefixCommandRouter } from "@neontechspace/fluxerly/effect"
|
|
74
|
+
*
|
|
75
|
+
* export function commandHelpExample(client: Client, router: NativePrefixCommandRouter, channelId: string) {
|
|
76
|
+
* const pages = router.help({ prefix: "!", maxLength: 1_000, include: (command) => command.name !== "admin" })
|
|
77
|
+
* // Visibility is not authorization. Each command still needs its own policy
|
|
78
|
+
* return Effect.forEach(pages, (content) => client.messages.send(channelId, { content, allowedMentions: {} }), {
|
|
79
|
+
* discard: true,
|
|
80
|
+
* })
|
|
81
|
+
* // Earlier pages remain sent if a later send fails or is interrupted. No retries occur
|
|
82
|
+
* }
|
|
83
|
+
* ```
|
|
84
|
+
*
|
|
85
|
+
* @category Commands
|
|
86
|
+
*/
|
|
87
|
+
export const commands = nativeCommands
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
import type {
|
|
2
|
+
DirectMessageChannel,
|
|
3
|
+
DirectMessageGroupEdit,
|
|
4
|
+
DirectMessageLatestMessages,
|
|
5
|
+
UserOperationFailure,
|
|
6
|
+
UserOperationOptions,
|
|
7
|
+
} from "#sdk/users"
|
|
8
|
+
import type * as Effect from "effect/Effect"
|
|
9
|
+
import type { SendError } from "#sdk/message-errors"
|
|
10
|
+
import type { Message, MessageCore, ReplyInput, SendOptions } from "#sdk/messages"
|
|
11
|
+
|
|
12
|
+
/** Open private conversations, send messages or manage existing groups.
|
|
13
|
+
* Methods return Effects with the client's default deadline (rest.defaultTimeoutMs, 30,000 ms unless configured) and at most two eligible transient read retries.
|
|
14
|
+
* Writes retry only confirmed rate-limit rejection, never an unknown outcome. No gateway connection is required.
|
|
15
|
+
* Cancellation and unexpected faults remain in Cause rather than becoming UserOperationError
|
|
16
|
+
*
|
|
17
|
+
* @category Users and DMs
|
|
18
|
+
*/
|
|
19
|
+
export interface DirectMessages<M extends MessageCore = Message> {
|
|
20
|
+
/**
|
|
21
|
+
* Open or reopen a one-to-one conversation with a user, then send a message.
|
|
22
|
+
* A plain string sends only that text, as shorthand for `{ content }`.
|
|
23
|
+
* The whole operation uses one deadline, and mentions are disabled by default.
|
|
24
|
+
* Message metadata and data bytes are prepared before opening the conversation.
|
|
25
|
+
* File and stream sources are captured, not copied, and read later when uploads start, using messages.send's size, upload-budget and cleanup rules.
|
|
26
|
+
* An inline multipart 429 does not replay file or stream sources.
|
|
27
|
+
* MessageError with outcome notDispatched does not mean opening the conversation was undone.
|
|
28
|
+
* A send with an unknown outcome is never repeated automatically.
|
|
29
|
+
* The opened conversation is cached under the same conditions as open.
|
|
30
|
+
* Reply references are not accepted here.
|
|
31
|
+
* Use messages.reply with an existing channel and message reference
|
|
32
|
+
*
|
|
33
|
+
* @example
|
|
34
|
+
* ```ts
|
|
35
|
+
* import { Effect } from "effect"
|
|
36
|
+
* import type { Client } from "@neontechspace/fluxerly/effect"
|
|
37
|
+
* export const notifyUserExample = (client: Client, userId: string) => Effect.gen(function* () {
|
|
38
|
+
* const user = yield* client.users.fetch(userId)
|
|
39
|
+
* return yield* client.directMessages.send(user.id, { content: `Hello ${user.displayName ?? user.username}` })
|
|
40
|
+
* })
|
|
41
|
+
* ```
|
|
42
|
+
*/
|
|
43
|
+
send(userId: string, input: ReplyInput | string, options?: SendOptions): Effect.Effect<M, SendError>
|
|
44
|
+
/**
|
|
45
|
+
* Look up a private channel in the optional cache using its decimal ID, without a request.
|
|
46
|
+
* A hit may be stale and becomes more recently used without extending its age.
|
|
47
|
+
* A miss produces undefined.
|
|
48
|
+
* An invalid ID is misuse: The default API throws UserOperationError with reason input and the native API dies with it.
|
|
49
|
+
* A closing or closed client has no cache, so the result is undefined
|
|
50
|
+
*/
|
|
51
|
+
get(id: string): Effect.Effect<DirectMessageChannel | undefined>
|
|
52
|
+
/**
|
|
53
|
+
* Open or reopen a one-to-one conversation with the selected user.
|
|
54
|
+
* The result is a private channel, not proof a message can be delivered.
|
|
55
|
+
* Privacy checks can still prevent sending after opening succeeds.
|
|
56
|
+
* With the direct-message cache enabled, the channel ID is unknown until the response arrives, so some concurrent direct-message cache changes keep the result out of the cache.
|
|
57
|
+
* Examples are a directMessages.fetch call and a direct-message update event
|
|
58
|
+
*/
|
|
59
|
+
open(userId: string, options?: UserOperationOptions): Effect.Effect<DirectMessageChannel, UserOperationFailure>
|
|
60
|
+
/**
|
|
61
|
+
* Fetch a private channel by decimal ID.
|
|
62
|
+
* A community-channel response is rejected as invalid.
|
|
63
|
+
* With the direct-message cache enabled, a concurrent fetch of another private channel ID does not keep this result from being stored, unless more than 256 private channel IDs are in flight at once
|
|
64
|
+
*/
|
|
65
|
+
fetch(id: string, options?: UserOperationOptions): Effect.Effect<DirectMessageChannel, UserOperationFailure>
|
|
66
|
+
/**
|
|
67
|
+
* Fetch this bot's currently open one-to-one and group conversations.
|
|
68
|
+
* Personal notes are excluded.
|
|
69
|
+
* The list is neither an atomic snapshot nor complete message history.
|
|
70
|
+
* Enabled cache replacement is skipped when a later targeted request or channel observation conflicts
|
|
71
|
+
*/
|
|
72
|
+
fetchAll(options?: UserOperationOptions): Effect.Effect<readonly DirectMessageChannel[], UserOperationFailure>
|
|
73
|
+
/**
|
|
74
|
+
* Fetch the latest messages for 1–100 selected, distinct private channel IDs through Fluxer's batch endpoint.
|
|
75
|
+
* IDs are copied by index when execution starts.
|
|
76
|
+
* This does not enumerate conversations or fill a cache.
|
|
77
|
+
* A null entry does not prove an empty channel or denied access.
|
|
78
|
+
* The omittedChannelIds field separately lists requested IDs that Fluxer did not return.
|
|
79
|
+
* Do not treat omission as null, an empty channel or denied access.
|
|
80
|
+
* The batch uses POST and is not retried after a dispatched failure with an unknown outcome, even though it reads data
|
|
81
|
+
*/
|
|
82
|
+
fetchLatestMessages(
|
|
83
|
+
channelIds: readonly string[],
|
|
84
|
+
options?: UserOperationOptions,
|
|
85
|
+
): Effect.Effect<DirectMessageLatestMessages<M>, UserOperationFailure>
|
|
86
|
+
/**
|
|
87
|
+
* Change supplied settings of an existing group conversation.
|
|
88
|
+
* A null name clears it, and omitted fields remain unchanged.
|
|
89
|
+
* Fluxer enforces member and owner permissions.
|
|
90
|
+
* A failed response does not guarantee rollback.
|
|
91
|
+
* Enabled cache invalidation normally stays scoped to this conversation.
|
|
92
|
+
* A cache-wide conflict check can also prevent older in-flight results from being stored
|
|
93
|
+
*/
|
|
94
|
+
editGroup(
|
|
95
|
+
id: string,
|
|
96
|
+
input: DirectMessageGroupEdit,
|
|
97
|
+
options?: UserOperationOptions,
|
|
98
|
+
): Effect.Effect<DirectMessageChannel, UserOperationFailure>
|
|
99
|
+
/**
|
|
100
|
+
* Close a one-to-one conversation for this bot, or leave a group conversation.
|
|
101
|
+
* Another recipient's conversation is not erased.
|
|
102
|
+
* If the group owner leaves, ownership may transfer.
|
|
103
|
+
* Enabled cache invalidation normally stays scoped to this conversation.
|
|
104
|
+
* A cache-wide conflict check can also prevent older in-flight results from being stored
|
|
105
|
+
*/
|
|
106
|
+
close(id: string, options?: UserOperationOptions): Effect.Effect<void, UserOperationFailure>
|
|
107
|
+
/**
|
|
108
|
+
* Remove a group recipient as owner, or remove the bot itself.
|
|
109
|
+
* This does not request deletion of that user's messages.
|
|
110
|
+
* If the last recipient leaves, Fluxer deletes the group.
|
|
111
|
+
* Enabled cache invalidation normally stays scoped to this conversation.
|
|
112
|
+
* A cache-wide conflict check can also prevent older in-flight results from being stored
|
|
113
|
+
*/
|
|
114
|
+
removeRecipient(
|
|
115
|
+
id: string,
|
|
116
|
+
userId: string,
|
|
117
|
+
options?: UserOperationOptions,
|
|
118
|
+
): Effect.Effect<void, UserOperationFailure>
|
|
119
|
+
}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
import type {
|
|
2
|
+
DiscoveryApplication,
|
|
3
|
+
DiscoveryApplicationInput,
|
|
4
|
+
DiscoveryApplicationEdit,
|
|
5
|
+
DiscoveryCategory,
|
|
6
|
+
DiscoverySearchPage,
|
|
7
|
+
DiscoverySearchQuery,
|
|
8
|
+
DiscoveryStatus,
|
|
9
|
+
} from "#sdk/discovery"
|
|
10
|
+
import type * as Effect from "effect/Effect"
|
|
11
|
+
import type { GuildOperationFailure, GuildOperationOptions } from "#sdk/guilds"
|
|
12
|
+
|
|
13
|
+
/** Search Fluxer's public community directory or manage a community's listing application.
|
|
14
|
+
* This is separate from instance endpoint discovery. HTTP requests share guild limits and directory data is not cached.
|
|
15
|
+
* Effects start when executed and can be run again, using the caller's services without requiring gateway readiness. The total deadline defaults to the client's rest.defaultTimeoutMs, 30,000 ms unless configured.
|
|
16
|
+
* Reads retry transient transport and HTTP 500/502/503/504 failures at most twice. Writes retry only confirmed 429 rejections.
|
|
17
|
+
* Input, HTTP and malformed-response failures use GuildOperationError. Closing clients use ClientClosedError.
|
|
18
|
+
* Interruption waits for owned cleanup. Defects retain Cause.
|
|
19
|
+
* Application writes may publish or unpublish a listing, invalidate guild snapshots and cannot promise rollback.
|
|
20
|
+
* There is no hidden eligibility read, automatic resubmission, review approval or directory-joining operation
|
|
21
|
+
*
|
|
22
|
+
* @category Guilds and members
|
|
23
|
+
*/
|
|
24
|
+
export interface Discovery {
|
|
25
|
+
/**
|
|
26
|
+
* Fetch one page from the current public community directory.
|
|
27
|
+
* The limit option defaults to 24, and offset defaults to 0.
|
|
28
|
+
* Pages can change between reads, so offset-based scans are not a stable snapshot.
|
|
29
|
+
* This neither joins a community nor caches its directory entry, and needs no gateway connection.
|
|
30
|
+
* Eligible read failures are retried as described for this namespace
|
|
31
|
+
*/
|
|
32
|
+
search(
|
|
33
|
+
query?: DiscoverySearchQuery,
|
|
34
|
+
options?: GuildOperationOptions,
|
|
35
|
+
): Effect.Effect<DiscoverySearchPage, GuildOperationFailure>
|
|
36
|
+
/**
|
|
37
|
+
* Fetch a community's current directory eligibility and application state.
|
|
38
|
+
* Use a decimal guild ID with ManageGuild permission.
|
|
39
|
+
* A result with eligible false can mean discovery is disabled or the member threshold is unmet, without distinguishing them.
|
|
40
|
+
* Eligibility can change before application.
|
|
41
|
+
* Reviewed or removed applications include their available reasons
|
|
42
|
+
*/
|
|
43
|
+
fetchStatus(guildId: string, options?: GuildOperationOptions): Effect.Effect<DiscoveryStatus, GuildOperationFailure>
|
|
44
|
+
/**
|
|
45
|
+
* Fetch directory category IDs and Fluxer's category labels in provider order.
|
|
46
|
+
* This requires an authenticated client, not membership of a particular community or ManageGuild.
|
|
47
|
+
* No category copy is kept
|
|
48
|
+
*/
|
|
49
|
+
fetchCategories(options?: GuildOperationOptions): Effect.Effect<readonly DiscoveryCategory[], GuildOperationFailure>
|
|
50
|
+
/**
|
|
51
|
+
* Submit a community's application to the public directory.
|
|
52
|
+
* ManageGuild, enabled discovery and current Fluxer eligibility are required.
|
|
53
|
+
* An existing pending or approved application fails remotely.
|
|
54
|
+
* Eligible verified or partnered communities may be approved immediately.
|
|
55
|
+
* The returned stored application does not guarantee approval or search visibility.
|
|
56
|
+
* An unknown outcome may already have submitted or published the listing.
|
|
57
|
+
* Check fetchStatus before trying again
|
|
58
|
+
*/
|
|
59
|
+
apply(
|
|
60
|
+
guildId: string,
|
|
61
|
+
input: DiscoveryApplicationInput,
|
|
62
|
+
options?: GuildOperationOptions,
|
|
63
|
+
): Effect.Effect<DiscoveryApplication, GuildOperationFailure>
|
|
64
|
+
/**
|
|
65
|
+
* Change supplied fields of a pending or approved directory application.
|
|
66
|
+
* ManageGuild and enabled discovery are required.
|
|
67
|
+
* At least one field must be supplied, and omitted fields remain unchanged.
|
|
68
|
+
* Tags use the input type's normalization and replacement rules.
|
|
69
|
+
* No old application is fetched or merged automatically.
|
|
70
|
+
* Updates to an approved listing can become public, while search-index updates can lag or partially fail
|
|
71
|
+
*/
|
|
72
|
+
edit(
|
|
73
|
+
guildId: string,
|
|
74
|
+
input: DiscoveryApplicationEdit,
|
|
75
|
+
options?: GuildOperationOptions,
|
|
76
|
+
): Effect.Effect<DiscoveryApplication, GuildOperationFailure>
|
|
77
|
+
/**
|
|
78
|
+
* Withdraw a pending application or remove an approved directory listing.
|
|
79
|
+
* ManageGuild and enabled discovery are required.
|
|
80
|
+
* HTTP 204 succeeds with no value.
|
|
81
|
+
* A missing application is a remote error, not an assumed successful no-op.
|
|
82
|
+
* Fluxer removes the application record and may separately remove its feature or search entry.
|
|
83
|
+
* The community and its members remain, and the prior application is not restored.
|
|
84
|
+
* An unknown or partial outcome needs remote inspection and may require operator recovery, not blind replay
|
|
85
|
+
*/
|
|
86
|
+
withdraw(guildId: string, options?: GuildOperationOptions): Effect.Effect<void, GuildOperationFailure>
|
|
87
|
+
}
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
import type {
|
|
2
|
+
GuildEmoji,
|
|
3
|
+
ExpressionReference,
|
|
4
|
+
ExpressionMetadata,
|
|
5
|
+
ExpressionSourceGuild,
|
|
6
|
+
EmojiCreate,
|
|
7
|
+
EmojiEdit,
|
|
8
|
+
ExpressionBatch,
|
|
9
|
+
ExpressionDeleteOptions,
|
|
10
|
+
} from "#sdk/expressions"
|
|
11
|
+
import type * as Effect from "effect/Effect"
|
|
12
|
+
import type { GuildOperationFailure, GuildOperationOptions, ModerationOptions } from "#sdk/guilds"
|
|
13
|
+
|
|
14
|
+
/** Read, upload, rename, clone or delete custom emoji.
|
|
15
|
+
* Methods return Effects and share guild HTTP concurrency limits, deadlines and GuildOperationError failures.
|
|
16
|
+
* Reads retry eligible transient failures at most twice. Writes retry only confirmed 429 rejections.
|
|
17
|
+
* Input, permission, 404 and malformed responses do not retry. Unknown outcomes may leave writes applied.
|
|
18
|
+
* Effects start when executed, use the caller's services and await cleanup on interruption. Defects remain in Cause.
|
|
19
|
+
* Closing clients fail with ClientClosedError. Snapshots are frozen and HTTP success is not gateway acknowledgement
|
|
20
|
+
*
|
|
21
|
+
* @category Emoji and stickers
|
|
22
|
+
*/
|
|
23
|
+
export interface Emojis {
|
|
24
|
+
/**
|
|
25
|
+
* Look up cached emoji metadata using decimal guildId and id, without an HTTP request.
|
|
26
|
+
* The result is undefined when caching is disabled or the entry is absent, expired or invalidated by a conflicting change.
|
|
27
|
+
* A hit becomes more recently used without extending expiry.
|
|
28
|
+
* An invalid ID is misuse: The default API throws GuildOperationError with reason input and the native API dies with it.
|
|
29
|
+
* A closing or closed client has no cache, so the result is undefined
|
|
30
|
+
*/
|
|
31
|
+
get(target: ExpressionReference): Effect.Effect<GuildEmoji | undefined>
|
|
32
|
+
/**
|
|
33
|
+
* Fetch a community's emoji list in Fluxer's order, without pagination.
|
|
34
|
+
* The list can change after the response and is not an ongoing completeness guarantee.
|
|
35
|
+
* An enabled metadata cache can retain results, but not image bytes or creator accounts
|
|
36
|
+
*/
|
|
37
|
+
fetchAll(
|
|
38
|
+
guildId: string,
|
|
39
|
+
options?: GuildOperationOptions,
|
|
40
|
+
): Effect.Effect<readonly GuildEmoji[], GuildOperationFailure>
|
|
41
|
+
/**
|
|
42
|
+
* Fetch minimal emoji metadata by decimal ID, without requiring source-community membership.
|
|
43
|
+
* This read does not populate the cache
|
|
44
|
+
*/
|
|
45
|
+
fetchMetadata(id: string, options?: GuildOperationOptions): Effect.Effect<ExpressionMetadata, GuildOperationFailure>
|
|
46
|
+
/**
|
|
47
|
+
* Fetch the public presentation of the community that owns a custom emoji with this decimal ID: Its ID, name, icon hash and badges.
|
|
48
|
+
* Fluxer answers when the source community is discoverable or the bot is a member of it.
|
|
49
|
+
* A private source community the bot is not in, an unavailable community or an unknown emoji fails with GuildOperationError
|
|
50
|
+
* whose apiError.code is unknownResource, without revealing which case applies.
|
|
51
|
+
* This read does not populate the cache, and the result does not update when the community changes
|
|
52
|
+
*/
|
|
53
|
+
fetchSource(
|
|
54
|
+
id: string,
|
|
55
|
+
options?: GuildOperationOptions,
|
|
56
|
+
): Effect.Effect<ExpressionSourceGuild, GuildOperationFailure>
|
|
57
|
+
/**
|
|
58
|
+
* Upload one community emoji and return its metadata.
|
|
59
|
+
* Inputs are copied when execution starts.
|
|
60
|
+
* No image URL is fetched automatically.
|
|
61
|
+
* Fluxer checks image format, dimensions, permissions and capacity.
|
|
62
|
+
* A write with an unknown outcome is not replayed
|
|
63
|
+
*/
|
|
64
|
+
create(
|
|
65
|
+
guildId: string,
|
|
66
|
+
input: EmojiCreate,
|
|
67
|
+
options?: ModerationOptions,
|
|
68
|
+
): Effect.Effect<GuildEmoji, GuildOperationFailure>
|
|
69
|
+
/**
|
|
70
|
+
* Upload 1–50 community emojis in one batch and return separate successes and failures.
|
|
71
|
+
* The input array is copied by index, then its entries are copied when execution starts.
|
|
72
|
+
* Some uploads can succeed while others fail.
|
|
73
|
+
* No rollback or automatic chunking is performed.
|
|
74
|
+
* Failures named by duplicate emoji names cannot be matched reliably to input positions.
|
|
75
|
+
* After an unknown outcome, fetch fresh remote data rather than blindly replaying the batch
|
|
76
|
+
*/
|
|
77
|
+
createMany(
|
|
78
|
+
guildId: string,
|
|
79
|
+
input: readonly EmojiCreate[],
|
|
80
|
+
options?: ModerationOptions,
|
|
81
|
+
): Effect.Effect<ExpressionBatch<GuildEmoji>, GuildOperationFailure>
|
|
82
|
+
/**
|
|
83
|
+
* Copy an emoji into a community by its source ID, using Fluxer's server-side copy.
|
|
84
|
+
* Source metadata is preserved.
|
|
85
|
+
* Fluxer enforces source copying restrictions
|
|
86
|
+
*/
|
|
87
|
+
clone(
|
|
88
|
+
guildId: string,
|
|
89
|
+
sourceId: string,
|
|
90
|
+
options?: ModerationOptions,
|
|
91
|
+
): Effect.Effect<GuildEmoji, GuildOperationFailure>
|
|
92
|
+
/**
|
|
93
|
+
* Rename a community emoji without changing its image or fetching its old metadata first
|
|
94
|
+
*/
|
|
95
|
+
edit(
|
|
96
|
+
target: ExpressionReference,
|
|
97
|
+
input: EmojiEdit,
|
|
98
|
+
options?: ModerationOptions,
|
|
99
|
+
): Effect.Effect<GuildEmoji, GuildOperationFailure>
|
|
100
|
+
/**
|
|
101
|
+
* Remove an emoji, succeeding with no value after HTTP 204.
|
|
102
|
+
* Retained metadata is invalidated.
|
|
103
|
+
* A missing target is an error, not proof of an earlier deletion.
|
|
104
|
+
* The purge option defaults to false.
|
|
105
|
+
* Setting it to true also queues irreversible media removal, subject to Fluxer's restrictions
|
|
106
|
+
*/
|
|
107
|
+
delete(target: ExpressionReference, options?: ExpressionDeleteOptions): Effect.Effect<void, GuildOperationFailure>
|
|
108
|
+
}
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import * as Deferred from "effect/Deferred"
|
|
2
|
+
import * as Effect from "effect/Effect"
|
|
3
|
+
import type { EventSource } from "#sdk/internal/events"
|
|
4
|
+
import { EventOverflowError } from "#sdk/message-errors"
|
|
5
|
+
import type { EventInvocation, HandlerOptions } from "#sdk/events"
|
|
6
|
+
import type { Message, MessageCore } from "#sdk/messages"
|
|
7
|
+
import { type FailureReport } from "./failures.js"
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* An event subscription registered in a Scope, independent of the client's connection.
|
|
11
|
+
* Use close to request a stop and waitForClose to wait for handler cleanup
|
|
12
|
+
*
|
|
13
|
+
* @category Events and collectors
|
|
14
|
+
*/
|
|
15
|
+
export interface Subscription {
|
|
16
|
+
/** Identifier of this subscription, such as messageCreate#3, used in failure reports and log records */
|
|
17
|
+
readonly id: string
|
|
18
|
+
/**
|
|
19
|
+
* Stop new deliveries, drop queued events and stop running handlers, without waiting for the handler that called close.
|
|
20
|
+
* When queued events are dropped, one events.discarded Debug record reports how many, and
|
|
21
|
+
* diagnostics().counters.eventsDropped.closed counts them
|
|
22
|
+
*
|
|
23
|
+
* @remarks
|
|
24
|
+
* Stops the subscription when the Effect executes and interrupts its handlers
|
|
25
|
+
*/
|
|
26
|
+
close(): Effect.Effect<void>
|
|
27
|
+
/**
|
|
28
|
+
* Wait until this subscription has closed and the SDK has released its queue and listeners.
|
|
29
|
+
* Normal closure succeeds with no value, and overflow fails with EventOverflowError, even for a later waiter.
|
|
30
|
+
* Cancelling this wait affects only the waiter, not the subscription or other waiters.
|
|
31
|
+
* Later waits see the same subscription outcome.
|
|
32
|
+
* Do not await this subscription's own closure from inside its handler
|
|
33
|
+
*
|
|
34
|
+
* @remarks
|
|
35
|
+
* Handlers or finalizers that disable interruption can delay completion.
|
|
36
|
+
* Unexpected faults remain in the Cause
|
|
37
|
+
*/
|
|
38
|
+
waitForClose(): Effect.Effect<void, EventOverflowError>
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
/** Set event-handler queue limits, concurrency, ordering, overflow policy and an optional failure hook.
|
|
42
|
+
* Reporting uses the services available when the handler is registered.
|
|
43
|
+
* The type parameter T is the event payload that a partition function receives
|
|
44
|
+
*
|
|
45
|
+
* @category Events and collectors
|
|
46
|
+
*/
|
|
47
|
+
export interface EventHandlerOptions<E = never, R = never, T = unknown> extends HandlerOptions<T> {
|
|
48
|
+
/** Receive this subscription's failures instead of the client-level onError, with the original error and its full Cause
|
|
49
|
+
*
|
|
50
|
+
* A failure only queues its report, so the hook never holds a handler slot. One worker with the services available at
|
|
51
|
+
* registration delivers reports one at a time in order, with up to 64 waiting while the hook is busy. Later ones
|
|
52
|
+
* are logged instead, with fields.reportOutcome "queueFull", and counted in diagnostics().counters.reportsDropped.
|
|
53
|
+
* A failed or defective hook is logged together with the original failure and is never retried.
|
|
54
|
+
* Reports already queued when the subscription closes are still delivered. Client shutdown interrupts a running
|
|
55
|
+
* hook and waits at most one second for its cleanup, then logs the interrupted and queued reports at Error
|
|
56
|
+
* with fields.reportOutcome "interrupted" or "subscriptionClosed". A hook that interrupts itself also logs its report
|
|
57
|
+
* with "interrupted", and later reports still reach the hook
|
|
58
|
+
*/
|
|
59
|
+
readonly onError?: (report: FailureReport) => Effect.Effect<unknown, E, R>
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
/**
|
|
63
|
+
* Event middleware for the Effect API, run around each client.on handler invocation that starts after registration.
|
|
64
|
+
* It receives the invocation and a next Effect that runs the rest of the chain and the handler.
|
|
65
|
+
* The next Effect completes when the rest of the chain has finished, whether or not it failed, and never fails.
|
|
66
|
+
* Failures after next are reported by the SDK where they occur, so middleware can time or trace a handler but cannot hide its failure.
|
|
67
|
+
* A failed or defective middleware Effect is reported like a handler failure, with its full Cause
|
|
68
|
+
*
|
|
69
|
+
* @category Events and collectors
|
|
70
|
+
*/
|
|
71
|
+
export type EventMiddleware<M extends MessageCore = Message, E = never, R = never> = (
|
|
72
|
+
invocation: EventInvocation<M>,
|
|
73
|
+
next: Effect.Effect<void>,
|
|
74
|
+
) => Effect.Effect<unknown, E, R>
|
|
75
|
+
|
|
76
|
+
/**
|
|
77
|
+
* Remove event middleware registered with client.use before its registration Scope closes
|
|
78
|
+
*
|
|
79
|
+
* @category Events and collectors
|
|
80
|
+
*/
|
|
81
|
+
export interface MiddlewareRegistration {
|
|
82
|
+
/** Stop applying the middleware to invocations that start later. Invocations already running keep their chain. Repeated calls do nothing */
|
|
83
|
+
close(): Effect.Effect<void>
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
export function nativeSubscription(source: Pick<EventSource, "stop" | "closed" | "id">): Subscription {
|
|
87
|
+
return Object.freeze({
|
|
88
|
+
id: source.id,
|
|
89
|
+
close: () => Effect.sync(() => source.stop()),
|
|
90
|
+
waitForClose: () => Deferred.await(source.closed),
|
|
91
|
+
})
|
|
92
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type * as Cause from "effect/Cause"
|
|
2
|
+
import type { FailureReport as SharedFailureReport } from "#sdk/failures"
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* A failure outside any returned result, delivered to a native onError hook or logged at Error with its full error.
|
|
6
|
+
* The error field is the handler's typed failure or defect value, and cause keeps the complete Effect Cause, including every reason.
|
|
7
|
+
* The report holds IDs only, never message content
|
|
8
|
+
*
|
|
9
|
+
* @category Logging and diagnostics
|
|
10
|
+
*/
|
|
11
|
+
export interface FailureReport extends SharedFailureReport {
|
|
12
|
+
/** The complete Effect Cause of the failure */
|
|
13
|
+
readonly cause: Cause.Cause<unknown>
|
|
14
|
+
}
|