> **Building with AI coding agents?** If you're using an AI coding agent, install the official Scalekit plugin. It gives your agent full awareness of the Scalekit API — reducing hallucinations and enabling faster, more accurate code generation.
>
> - **Claude Code**: `/plugin marketplace add scalekit-inc/claude-code-authstack` then `/plugin install <auth-type>@scalekit-auth-stack`
> - **GitHub Copilot CLI**: `copilot plugin marketplace add scalekit-inc/github-copilot-authstack` then `copilot plugin install <auth-type>@scalekit-auth-stack`
> - **Codex**: run the bash installer, restart, then open Plugin Directory and enable `<auth-type>`
> - **Skills CLI** (Windsurf, Cline, 40+ agents): `npx skills add scalekit-inc/skills --list` then `--skill <skill-name>`
>
> `<auth-type>` / `<skill-name>`: `agent-auth`, `full-stack-auth`, `mcp-auth`, `modular-sso`, `modular-scim` — [Full setup guide](https://docs.scalekit.com/dev-kit/build-with-ai/)

---

# Discord

<div class="grid grid-cols-5 gap-4 items-center">
 <div class="col-span-4">
  Connect to Discord. Read user profiles, list guilds, retrieve member data, check entitlements, and verify OAuth2 authorization details.
 </div>
 <div class="flex justify-center">
  <img src="https://cdn.scalekit.com/sk-connect/assets/provider-icons/discord.svg" width="64" height="64" alt="Discord logo" />
 </div>
</div>

Supports authentication: OAuth 2.0

## Set up the agent connector

<SetupDiscordSection />

## Usage

<UsageDiscordSection />

## Tool list

## `get_guild_widget_png`

Retrieves a PNG image widget for a Discord guild. Returns a visual representation of the guild widget that can be embedded on external websites. The widget must be enabled in the guild's server settings under **Server Settings → Widget**.

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `guild_id` | string | Yes | The ID of the guild whose widget PNG to retrieve |

## `get_current_user_application_entitlements`

Retrieves entitlements for the current user for a given application. Use when you need to check what premium offerings or subscriptions the authenticated user has access to. Requires the `applications.entitlements` OAuth2 scope.

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `application_id` | string | Yes | The ID of the Discord application to check entitlements for |
| `sku_id` | string | No | Filter entitlements by a specific SKU ID |
| `before` | string | No | Retrieve entitlements before this entitlement ID (for pagination) |
| `after` | string | No | Retrieve entitlements after this entitlement ID (for pagination) |
| `limit` | integer | No | Maximum number of entitlements to return (1–100, default 100) |
| `guild_id` | string | No | Filter entitlements for a specific guild |
| `exclude_ended` | boolean | No | Set to `true` to exclude entitlements that have already ended |

## `get_guild_widget`

Retrieves the guild widget in JSON format. Returns public information about a Discord guild's widget including online member count and invite URL. The widget must be enabled in the guild's server settings.

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `guild_id` | string | Yes | The ID of the guild whose widget JSON to retrieve |

## `get_user`

Retrieve information about a Discord user. With an OAuth Bearer token, pass `@me` as `user_id` to return the authenticated user's information. With a Bot token, you can query any user by their ID. Returns username, avatar, discriminator, locale, premium status, and email (if the `email` scope is granted).

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `user_id` | string | Yes | The ID of the user to retrieve, or `@me` to get the authenticated user |

## `get_my_user`

Fetches comprehensive profile information for the currently authenticated Discord user, including username, avatar, discriminator, locale, and email if the `email` OAuth2 scope is granted. No additional parameters required — uses the OAuth token of the connected account.

_This tool takes no input parameters._

## `get_invite`
**Deprecated:** This tool is deprecated. Use `resolve_invite` instead for new integrations.

Retrieves information about a specific invite code including guild and channel details.

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `invite_code` | string | Yes | The Discord invite code to look up (the part after `discord.gg/`) |
| `with_counts` | boolean | No | Set to `true` to include approximate member and presence counts |
| `with_expiration` | boolean | No | Set to `true` to include expiration date information |

## `get_guild_template`

Retrieves information about a Discord guild template using its unique template code. Use when you need to get details about a guild template for creating new servers or auditing template configurations.

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `template_code` | string | Yes | The unique code of the guild template to retrieve |

## `get_public_keys`

Retrieves Discord OAuth2 public keys (JWKS). Use when you need to verify OAuth2 tokens or perform cryptographic signature verification against Discord-issued tokens.

_This tool takes no input parameters._

## `list_my_guilds`

Lists the current user's guilds, returning partial data (id, name, icon, owner, permissions, features) for each. Primarily used for displaying server lists or verifying guild memberships. Requires the `guilds` OAuth2 scope.

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `before` | string | No | Retrieve guilds with IDs before this guild ID (for pagination) |
| `after` | string | No | Retrieve guilds with IDs after this guild ID (for pagination) |
| `limit` | integer | No | Maximum number of guilds to return (1–200, default 200) |
| `with_counts` | boolean | No | Set to `true` to include approximate member and presence counts |

## `get_openid_connect_userinfo`

Retrieves OpenID Connect compliant user information for the authenticated user. Returns standardized OIDC claims (`sub`, `email`, `nickname`, `picture`, `locale`, etc.) following the OpenID Connect specification. Requires an OAuth2 access token with the `openid` scope; additional fields require the `identify` and `email` scopes.

_This tool takes no input parameters._

## `get_gateway`

Retrieves a valid WebSocket (`wss://`) URL for establishing a Gateway connection to Discord. Use when you need to connect to the Discord Gateway for real-time events. No authentication required.

_This tool takes no input parameters._

## `get_my_guild_member`

Retrieves the guild member object for the currently authenticated user within a specified guild, including roles, nickname, join date, and avatar. Requires the `guilds.members.read` OAuth2 scope.

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `guild_id` | string | Yes | The ID of the guild to retrieve the authenticated user's member data from |

## `list_sticker_packs`

Retrieves all available Discord Nitro sticker packs. Returns official Discord sticker packs including pack name, description, stickers, cover sticker, and banner asset. No authentication required.

_This tool takes no input parameters._

## `resolve_invite`

Resolves and retrieves information about a Discord invite code, including the associated guild, channel, scheduled event, and inviter. Prefer this over the deprecated `get_invite` tool for new integrations.

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| `invite_code` | string | Yes | The Discord invite code to resolve (the part after `discord.gg/`) |
| `with_counts` | boolean | No | Set to `true` to include approximate member and presence counts |
| `with_expiration` | boolean | No | Set to `true` to include expiration date information |
| `guild_scheduled_event_id` | string | No | Include details about a specific scheduled event associated with this invite |

## `get_my_oauth2_authorization`

Retrieves current OAuth2 authorization details for the application, including app info, granted scopes, token expiration date, and user data (contingent on scopes like `identify`). Useful for verifying what access the current token has before making downstream API calls.

_This tool takes no input parameters._

## `retrieve_user_connections`

Retrieves a list of the authenticated user's connected third-party accounts on Discord, such as Twitch, YouTube, GitHub, Steam, and others. Returns the service name, account ID, account name, and visibility for each connection. Requires the `connections` OAuth2 scope.

_This tool takes no input parameters._

---

## More Scalekit documentation

| Resource | What it contains | When to use it |
|----------|-----------------|----------------|
| [/llms.txt](/llms.txt) | Structured index with routing hints per product area | Start here — find which documentation set covers your topic before loading full content |
| [/llms-full.txt](/llms-full.txt) | Complete documentation for all Scalekit products in one file | Use when you need exhaustive context across multiple products or when the topic spans several areas |
| [sitemap-0.xml](https://docs.scalekit.com/sitemap-0.xml) | Full URL list of every documentation page | Use to discover specific page URLs you can fetch for targeted, page-level answers |
