Discord icon

Discord

Interact with Discord API - Full Bot Features

Overview

This node operation creates an invite link for a specified Discord channel within a guild (server). It allows users to generate invite URLs with customizable parameters such as maximum age, maximum uses, and temporary membership. This is useful for automating the creation of invite links for events, communities, or private channels in Discord servers.

Use Case Examples

  1. Automatically generate a temporary invite link for a new event channel that expires after 24 hours.
  2. Create an invite link with unlimited uses for a public community channel.
  3. Generate an invite that grants temporary membership to users who join via the link.

Properties

Name Meaning
Guild ID The ID of the Discord server (guild) where the invite will be created.
Additional Fields Optional parameters to customize the invite such as max age, max uses, temporary membership, and reason for audit logs.

Output

JSON

  • code - The unique invite code generated by Discord.
  • url - The full URL of the invite link.
  • maxAge - The maximum age of the invite in seconds.
  • maxUses - The maximum number of uses for the invite.
  • temporary - Indicates if the invite grants temporary membership.

Dependencies

  • Discord API

Troubleshooting

  • Ensure the provided Guild ID and Channel ID are correct and that the bot has permission to create invites in the specified channel.
  • Invalid channel errors occur if the channel ID does not belong to a text or voice channel where invites can be created.
  • Permission errors may arise if the bot lacks the 'Create Invite' permission in the channel or guild.

Links

Discussion