Skip to main content

SDK for building YourBot Marketplace plugins

Project description

YourBot SDK

SDK for building plugins for the YourBot Discord bot platform.

YourBot runs marketplace plugins in sandboxed Docker containers. This SDK is the official Python interface plugins use to receive Discord events, call the Discord API, store data, render dashboards, and emit metrics — all routed through the platform so plugins never need direct network access or credentials.

Install

pip install yourbot-sdk

Python 3.10 or newer.

Hello, plugin

from yourbot_sdk import Plugin, Context

plugin = Plugin()

@plugin.on_event("message_create")
def on_message(ctx: Context, event: dict):
    if "!ping" in event.get("content", ""):
        ctx.discord.send_message(
            channel_id=event["channel_id"],
            content="Pong!",
        )

plugin.run()  # must be the last line

Drop this in a folder named my_plugin/ as __main__.py, zip it, and upload it via the Developer Portal.

CLI

The package installs a yourbot command for scaffolding and a local dev loop:

yourbot new my_plugin     # scaffold a new plugin from the template
yourbot dev               # run your plugin locally against a mock host

Documentation

Full plugin contract, capability reference, and publishing guide:

License

MIT — see LICENSE.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

yourbot_sdk-0.7.0.tar.gz (68.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

yourbot_sdk-0.7.0-py3-none-any.whl (73.7 kB view details)

Uploaded Python 3

File details

Details for the file yourbot_sdk-0.7.0.tar.gz.

File metadata

  • Download URL: yourbot_sdk-0.7.0.tar.gz
  • Upload date:
  • Size: 68.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for yourbot_sdk-0.7.0.tar.gz
Algorithm Hash digest
SHA256 539b06c18fdb60aa410fb679b5d2e19c396b665adcbfb9cbbdf2d7d5183e6eff
MD5 8b988eeb7a946c81754091169fbeb31a
BLAKE2b-256 3a06c8b8e197c281f22e695d9a1a94fe25cc1a9ab3dd5a0f10bd0eb19f1f0b95

See more details on using hashes here.

Provenance

The following attestation bundles were made for yourbot_sdk-0.7.0.tar.gz:

Publisher: publish.yml on NotUSeee/yourbot-sdk

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file yourbot_sdk-0.7.0-py3-none-any.whl.

File metadata

  • Download URL: yourbot_sdk-0.7.0-py3-none-any.whl
  • Upload date:
  • Size: 73.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for yourbot_sdk-0.7.0-py3-none-any.whl
Algorithm Hash digest
SHA256 6c8f9417ebb10a9e3ee4bc6b0e34d5c41c7755b3401f990e67ba3b57045a9e7e
MD5 6995ad887f0eabeab231f327acf64c35
BLAKE2b-256 691e4d179271042c9963a9c6cf9b5e59fb9196dbdc9e1973c26f34e765494a6d

See more details on using hashes here.

Provenance

The following attestation bundles were made for yourbot_sdk-0.7.0-py3-none-any.whl:

Publisher: publish.yml on NotUSeee/yourbot-sdk

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page