> For the complete documentation index, see [llms.txt](https://devkiki7000.gitbook.io/discord-components/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://devkiki7000.gitbook.io/discord-components/api-reference/discordcomponents.md).

# DiscordComponents

## DiscordComponents

Represents discord\_components client.

{% tabs %}
{% tab title="Parameters" %}

| bot                                                                                 |                                           |
| ----------------------------------------------------------------------------------- | ----------------------------------------- |
| <p>The bot to wrap.</p><p></p><p><strong>Type:</strong> <code>discord.Client</code> | <code>discord.ext.commands.Bot</code></p> |
| {% endtab %}                                                                        |                                           |

{% tab title="Attributes" %}

| bot                                                                                 |                                           |
| ----------------------------------------------------------------------------------- | ----------------------------------------- |
| <p>Your discord bot</p><p></p><p><strong>Type:</strong> <code>discord.Client</code> | <code>discord.ext.commands.Bot</code></p> |

| http                                                                                                                                                                                |
| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| <p>The HTTPClient for this library</p><p></p><p><strong>Type:</strong> <a href="/discord-components/api-reference/httpclient.md"><code>discord-components.HTTPClient</code></a></p> |
| {% endtab %}                                                                                                                                                                        |

{% tab title="Methods" %}

| wait\_for                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| <p>Wait for interaction with structured filters.</p><p></p><p><strong>Parameters:</strong></p><ul><li><strong>component</strong> (<a href="/discord-components/api-reference/component.md"><code>discord-components.Component</code></a>) - The component</li><li><strong>message</strong> ( <code>discord.Message</code>) - The message with component</li><li><strong>guild</strong> (<code>discord.Guild</code>) - The guild of message with component</li><li><strong>channel</strong> (<code>discord.abc.Messageable</code>) - The channel of message with component</li><li><strong>user</strong> (<code>discord.User</code>) - The user to interact</li><li><strong>timeout</strong> (<code>float</code>) - The time to wait</li></ul><p><strong>Returns:</strong> <a href="/discord-components/api-reference/interaction.md"><code>discord-components.Interaction</code></a></p> |

| add\_callback                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| <p>Add a callback function to a component<br></p><p><strong>Parameters:</strong></p><ul><li><strong>component</strong> (<a href="/discord-components/api-reference/component.md"><code>discord-components.Component</code></a>) - The component to add callback</li><li><strong>callback</strong> - The callback function</li><li><strong>uses</strong> (<code>int</code>) - How many times to make the component usable</li><li><strong>filter</strong> - The filter function</li></ul><p><strong>Returns:</strong> <a href="/discord-components/api-reference/componentmessage.md"><code>discord-components.ComponentMessage</code></a></p> |
| {% endtab %}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| {% endtabs %}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
