Use discord activities with your bot!
Project description
DiscordActivity
Discord activities in nextcord.
pip install DicsordActivity
Sync Example
import nextcord
from nextcord.ext import commands
from DiscordActivity import SyncActivity
bot = commands.Bot(command_prefix="!")
activity = SyncActivity(token='your-bot-token')
@bot.command()
async def fishing(ctx):
await ctx.send(f"Go fishing!\nhttps://discord.gg/{activity.get_activity(activity_name='fishing', author=ctx.author)}")
bot.run("your-bot-token")
Async example
import nextcord
from nextcord.ext import commands
from DiscordActivity import AsyncActivity
bot = commands.Bot(command_prefix="!")
activity = AsyncActivity(token='your-bot-token')
@bot.command()
async def fishing(ctx):
await ctx.send(f"Go fishing!\nhttps://discord.gg/{await activity.get_activity(activity_name='fishing', author=ctx.author)}")
bot.run("your-bot-token")
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
DiscordActivity-1.0.0.tar.gz
(2.9 kB
view hashes)