title: InvalidArgument: Webhook views require an associated state with the webhook
body: <p>I'm trying to get a webhook setup with python and nextcord. I would like the embedded messaged thats passed to the discord to include buttons that have callbacks when clicked. Not the most experienced with python. Been looking at documentation for days and no luck.</p>
  <pre class="lang-py prettyprint-override"><code>import aiohttp
  import asyncio
  import nextcord
  from nextcord.ext import commands
  from nextcord import File, ButtonStyle, Embed, Member
  from nextcord.ui import Button, View
  from nextcord import Webhook, TextChannel
  
  
  async def send_to_webhook(id, token):
      embed = Embed(color=0x000ff)
      embed.add_field(name=&quot;Test&quot;, value=&quot;Test&quot;, inline=False)
      embed.add_field(name=&quot;Upvotes&quot;, value=&quot;0&quot;, inline=True)
      embed.add_field(name=&quot;Downvotes&quot;, value=&quot;0&quot;, inline=True)
  
      count = 0
      count1 = 0
      button = Button(label=&quot;Upvote&quot;, style=ButtonStyle.green, emoji=&quot;&quot;)
      button1 = Button(label=&quot;Downvotes&quot;, style=ButtonStyle.red, emoji=&quot;&quot;)
      button2 = Button(label=&quot;Test&quot;, url='http://www.google.com', style=ButtonStyle.url)
  
  
      async def button_callback(interaction):
          nonlocal count
          count += 1
          await interaction.message.edit(embed=embed.set_field_at(index=1, name=&quot;Upvotes&quot;, value=count))
  
      button.callback = button_callback
  
      async def button_callback(interaction):
          nonlocal count1
          count1 += 1
          await interaction.message.edit(embed=embed.set_field_at(index=2, name=&quot;Downvotes&quot;, value=count1))
  
      button1.callback = button_callback
  
      view = View()
      view.add_item(button)
      view.add_item(button1)
      view.add_item(button2)
  
      # Create a new HTTP session and use it to create webhook object
      async with aiohttp.ClientSession() as session:
          webhook = Webhook.partial(id, token, session=session)
          await webhook.send(embed=embed, view=view)
  
  asyncio.run(send_to_webhook(&quot;ID&quot;, &quot;TOKEN&quot;))
  </code></pre>
  <p>I keep getting the following error</p>
  <pre><code>Traceback (most recent call last):
    File &quot;C:\Users\Michael\PycharmProjects\AlphaWave\button-test2.py&quot;, line 48, in &lt;module&gt;
      asyncio.run(send_to_webhook(&quot;952777439615004763&quot;, &quot;VJlnbm64i7oBljBJcSFkcDvKziC8UZplGkBjlLlmMhxvlz2f_J28lUoznp1kAZXQEjye&quot;))
    File &quot;C:\Users\Michael\AppData\Local\Programs\Python\Python310\lib\asyncio\runners.py&quot;, line 44, in run
      return loop.run_until_complete(main)
    File &quot;C:\Users\Michael\AppData\Local\Programs\Python\Python310\lib\asyncio\base_events.py&quot;, line 641, in run_until_complete
      return future.result()
    File &quot;C:\Users\Michael\PycharmProjects\AlphaWave\button-test2.py&quot;, line 46, in send_to_webhook
      await webhook.send(embed=embed, view=view)
    File &quot;C:\Users\Michael\PycharmProjects\AlphaWave\venv\lib\site-packages\nextcord\webhook\async_.py&quot;, line 1417, in send
      raise InvalidArgument('Webhook views require an associated state with the webhook')
  nextcord.errors.InvalidArgument: Webhook views require an associated state with the webhook
  </code></pre>