Create invite
create_inviteCreate a Discord channel invite link with 24-hour expiry and unlimited uses by default; set roles, user limits, or no expiry, and confirm risky invites before they are made.
Instructions
Create an invite link for a channel. Defaults are deliberate: expires in 24 hours, unlimited uses. A never-expiring invite must be asked for explicitly with max_age_seconds 0. roles gives roles to whoever joins with it, and for_users limits it to particular people. An invite whose roles would give moderator or admin powers (such as banning, kicking, or timing out members, deleting other people's messages, or managing the server, roles, or channels), or open channels, needs confirming: the first call changes nothing and returns a preview and a confirm_token, and repeating the call with the token makes the change.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"channel": "<channel>"
},
"name": "create_invite"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| guild | No | Guild (server) name or ID. Omit to use the default guild. | |
| roles | No | Role names or IDs given to everyone who joins with this invite. Needs Manage Roles. | |
| channel | Yes | Channel name or ID. | |
| dry_run | No | ||
| max_uses | No | Use limit, 0 for unlimited. Default 0. | |
| for_users | No | User IDs of the only people who can use it (up to 1000). They need not be in the server yet. | |
| temporary | No | Members who join leave again when they disconnect. | |
| confirm_token | No | The token from this exact action's preview. Where the app can show a confirmation dialog, calling with it asks the user there, and it happens only if they agree. | |
| max_age_seconds | No | Lifetime in seconds, 0 for never. Default 86400 (24h). |