> For the complete documentation index, see [llms.txt](https://docs.invitelogger.me/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.invitelogger.me/general-topics/invite-tracking/required-permissions.md).

# Required permissions

What are the required permissions for the bot to work correctly ?

To ensure that the bot functions correctly in your server, it needs specific permissions. Below is a list of required permissions, along with their purposes.

***

### 🔹 **Essential Permissions**

These permissions are **mandatory** for the bot to function properly.

| Permission Name                                             | Purpose                                                                                       |
| ----------------------------------------------------------- | --------------------------------------------------------------------------------------------- |
| `sendMessages`                                              | Allows the bot to send messages in text channels. For old message commands or invite logs     |
| `embedLinks`                                                | Enables the bot to send rich embeds                                                           |
| `viewAuditLog`                                              | Required to fetch audit logs for invite tracking                                              |
| <mark style="background-color:yellow;">`manageGuild`</mark> | <mark style="background-color:yellow;">Allows the bot to access the invite code list</mark>   |
| `createInstantInvite`                                       | Needed if the bot generates invite links for the createInvite command or the smartleaderboard |

***

### 🔹 **Channel Permissions**

The bot needs to verify its permissions **per channel** to ensure it can track invites and send messages in logging channels.

| Permission Name                                                | Purpose                                                                                                               |
| -------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------- |
| <mark style="background-color:yellow;">`manageChannels`</mark> | <mark style="background-color:yellow;">Required to check ans receive the newly created invites in that channel</mark> |

***

### 🔹 **Logging Channel Permissions**

If your bot logs events such as joins, leaves, or moderation actions, it requires specific permissions in those channels.

| Permission Name | Purpose                                                            |
| --------------- | ------------------------------------------------------------------ |
| `sendMessages`  | Needed for sending log messages in join/leave/action log channels. |
| `embedLinks`    | Required to format log messages properly in embeds.                |

The bot checks these permissions in **join logs**, **leave logs**, and **action log channels** (if configured).

***

### ✅ **How to Grant Permissions**

1. **Server-wide Permissions:**
   * Go to **Server Settings** → **Roles**.
   * Select the **Bot’s Role**.
   * Ensure the bot has all required permissions in the **"Permissions"** section.
2. **Per-Channel Permissions:**
   * Right-click the channel → **Edit Channel** → **Permissions**.
   * Find the bot’s role and ensure it has the required permissions.

***

### ❌ **What Happens if Permissions Are Missing?**

| Missing Permission | Consequence                                                             |
| ------------------ | ----------------------------------------------------------------------- |
| `sendMessages`     | Your invite logs aren't working                                         |
| `embedLinks`       | The bot's messages may not format correctly.                            |
| `viewAuditLog`     | The bot can't track invites correctly                                   |
| `manageGuild`      | The bot can't track invite at all                                       |
| `manageChannels`   | The bot cannot track accurately and will often fail to give the inviter |

If any of these permissions are missing, the bot may not function properly.

\
To check missing permissions, use the `/diagnose` command.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.invitelogger.me/general-topics/invite-tracking/required-permissions.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
