Skip to content

Docker STF development

A Docker STF is a State Transition Function implemented as a container in any language. The contract is simple:

  • stdin: JSON input
  • stdout: {"output": ...}
  • stderr: error messages
  • Secrets: injected as environment variables at run time (write-only via API)

Because it is an ordinary container with no d6e SDK, you can unit-test with local docker run.

When designing, asking questions, or combining with Plugin / custom FE, prefer installing all skills. Docker-STF-focused minimum:

Terminal window
npx skills add d6e-ai/d6e-docker-stf-skills --skill '*' -y
# Also when packaging into a Plugin
npx skills add d6e-ai/d6e-plugin-skills --skill '*' -y

Repository: d6e-ai/d6e-docker-stf-skills

5-minute Quick Start: docs/QUICKSTART.md

  1. Generate code with the skill (Dockerfile / entrypoint / README)
  2. docker builddocker run locally and verify stdin/stdout
  3. Publish to a registry (ghcr.io / Docker Hub / …)
  4. Register as an STF in the d6e console or API (runtime: docker)
  5. Optionally bundle into a Plugin template.yaml
Choose Docker STF JS STF (QuickJS) is enough
Any language, heavy compute, native deps Simple SQL transforms / aggregations
Explicit external network / external DB Fully contained in workspace SQL
Reuse existing container assets A few lines of pure function

For registration, instant-run, and describe, see REST API and MCP.