Skip to main content

flexdeck

flexdeck (Python)

Write FlexDeck plugins in Python.
Standard library only. A packed plugin carries the SDK with it, so it runs on any Python 3.10+ with nothing else installed.

Python 3.10+ No dependencies Plugin guide


Start in a minute

pip install flexdeck
flexdeck-plugin new lights "Desk lights"
cd lights
python -m unittest                 # its tests, without FlexDeck
flexdeck-plugin verify             # ask FlexDeck itself whether it will work
flexdeck-plugin pack               # lights-0.1.0.fdpkg, ready to install

A whole plugin

from flexdeck_plugin import Plugin, arg

plugin = Plugin(id="lights", name="Desk lights", version="0.1.0", permissions=["network"])
plugin.variable("lights.on", "bool", "Whether the lights are on")

@plugin.action("toggle", "Turn the lights on or off", {"room": arg("text", "desk", "Which room")})
def toggle(args, ctx):
    ctx.vars.set({"lights.on": not ctx.vars.get("lights.on")})

if __name__ == "__main__":
    plugin.serve()

Verify before you publish

verify packs the plugin and runs it through the FlexDeck on this computer (flexdeck verify-plugin), exactly as an install would. It checks:

  • its catalogue and gallery keys
  • every action's example arguments
  • its values, feeds and settings
  • that it keeps to its own namespace and its declared events
  • that it writes nothing but the protocol to stdout
  • that it stops cleanly

If FlexDeck is installed somewhere unusual, set FLEXDECK_BIN to its path.

See also


MIT licensed, so your plugins can use any license.

Metadata

Release files for flexdeck 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for flexdeck 0.1.1
File Size Uploaded
flexdeck-0.1.1.tar.gz 19.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for flexdeck 0.1.1
File Interpreter ABI Platform
flexdeck-0.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 39.0 kB

Release files / flexdeck-0.1.1.tar.gz

Download URL flexdeck-0.1.1.tar.gz
Size 19.2 kB
Tags Source
SHA-256 checksum
How to use checksums
049c08bae5a4d5cf0666bb1f1d36bcea532f9040af2688179114202e0f38bc3e
BLAKE2b-256 checksum
How to use checksums
98434f1101f08cd66113a03a10b7d8a4252773443b5e6ab3d2eaf8a76d467629
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / flexdeck-0.1.1-py3-none-any.whl

Download URL flexdeck-0.1.1-py3-none-any.whl
Size 19.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
df0e252b282696224cdd4fd6aabf269aff3d171a3cba415856f233f3a9efbfa1
BLAKE2b-256 checksum
How to use checksums
057e57e7fad3881802196fe8b67cd004bc441dee83a03f6efa45d74830701467
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page