MCP server for authoring Elsa Workflows 3 definitions against a live Elsa engine.
Project description
elsa-mcp
An MCP (Model Context Protocol) server in Python that lets an AI client author Elsa Workflows 3
definitions against a live Elsa engine. The catalog of activities is fetched from the engine's
own /elsa/api/descriptors/activities endpoint — the same one Elsa Studio uses — so the MCP always
reflects whatever modules, custom activities, and dynamic providers are actually loaded on the
target server.
Architecture
[AI client] ──MCP──▶ [elsa-mcp (this project)] ──HTTPS──▶ [Elsa server]
(stateless adapter) (the engine, untouched)
elsa-mcp is a separate process from Elsa. It depends on Elsa's public REST API and adds:
- LLM-friendly tool surfaces (search → fetch → validate → publish)
- A curated authoring guide as an MCP resource
- Capability gating (
readonly/draft/fullmodes) - Short-TTL descriptor caching with stale-on-error fallback
- Structured, actionable validation errors
Install
# Recommended: uv
uv sync
# Or with pip
pip install -e ".[dev]"
Configure
Set environment variables (the server reads them at startup):
| Variable | Required | Default | Description |
|---|---|---|---|
ELSA_BASE_URL |
yes | https://localhost:5001 |
Base URL of the Elsa server |
ELSA_API_KEY |
yes* | — | API key for Authorization: ApiKey <KEY> |
ELSA_BEARER_TOKEN |
yes* | — | Alternative: JWT for Authorization: Bearer <JWT> |
ELSA_MODE |
no | readonly |
One of readonly, draft, full |
ELSA_VERIFY_TLS |
no | true |
Set false to accept self-signed dev certs |
ELSA_CACHE_TTL |
no | 60 |
Descriptor cache TTL in seconds |
* one of ELSA_API_KEY / ELSA_BEARER_TOKEN is required.
Capability modes
readonly— only search/get/list/validate tools registered. Safe default for production.draft— adds create/update tools, butpublishis forced tofalse. Good for staging.full— adds publish + dispatch. Use only on dev environments.
Tools are registered conditionally at startup — in readonly mode the LLM literally cannot
see the write tools.
Run locally (stdio, Claude Desktop)
Add to ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or
%APPDATA%\Claude\claude_desktop_config.json (Windows):
{
"mcpServers": {
"elsa-dev": {
"command": "/Users/you/.local/bin/uv",
"args": ["--directory", "/absolute/path/to/elsa-mcp", "run", "elsa-mcp"],
"env": {
"ELSA_BASE_URL": "https://localhost:5001",
"ELSA_API_KEY": "dev-key-here",
"ELSA_MODE": "full",
"ELSA_VERIFY_TLS": "false"
}
}
}
}
Use absolute paths for the command — Claude Desktop does not inherit your shell
PATH.
Run hosted (Streamable HTTP)
ELSA_BASE_URL=https://elsa.example.com \
ELSA_API_KEY=... \
ELSA_MODE=draft \
uv run elsa-mcp --http --host 0.0.0.0 --port 8000
Put TLS termination + bearer-token validation in a reverse proxy (Caddy / Traefik) in front.
Inspect with the MCP Inspector
npx @modelcontextprotocol/inspector \
uv --directory $(pwd) run elsa-mcp
Opens a browser UI on http://localhost:6274 where you can manually exercise tools and resources.
Spin up a test Elsa server
docker run --rm -p 13000:8080 \
-e ASPNETCORE_ENVIRONMENT=Development \
-e HTTP_PORTS=8080 \
elsaworkflows/elsa-server-and-studio-v3:latest
Then point ELSA_BASE_URL=http://localhost:13000 and run elsa-mcp. Default credentials are
admin / password.
Testing
uv run pytest
Unit tests use respx to mock the Elsa REST API.
License
MIT
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file elsa_mcp-0.1.dev9.tar.gz.
File metadata
- Download URL: elsa_mcp-0.1.dev9.tar.gz
- Upload date:
- Size: 134.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9a0f106cfb0733051b92b61005cd6e7d3ce1c74af71518dc67caa8dd903e5cb5
|
|
| MD5 |
a70ef3132ee6e62bad1fbcab3d6b7d4b
|
|
| BLAKE2b-256 |
fed57b3dd0dbb69d099c1a73bffc6de35d1d71f5ef10564ec12a4cb04c32f895
|
Provenance
The following attestation bundles were made for elsa_mcp-0.1.dev9.tar.gz:
Publisher:
publish.yml on neoblue-tech/elsa-mcp
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
elsa_mcp-0.1.dev9.tar.gz -
Subject digest:
9a0f106cfb0733051b92b61005cd6e7d3ce1c74af71518dc67caa8dd903e5cb5 - Sigstore transparency entry: 1566429214
- Sigstore integration time:
-
Permalink:
neoblue-tech/elsa-mcp@ebd3bf0615c43cb49336290214d64f55beda45b3 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/neoblue-tech
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@ebd3bf0615c43cb49336290214d64f55beda45b3 -
Trigger Event:
push
-
Statement type:
File details
Details for the file elsa_mcp-0.1.dev9-py3-none-any.whl.
File metadata
- Download URL: elsa_mcp-0.1.dev9-py3-none-any.whl
- Upload date:
- Size: 50.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
bc664034ff5aae1f1322476d51b021e117cfb3f77e97fb29f2508576bd0dba46
|
|
| MD5 |
eb7a27272e43f85d412e7cf56b47ddf3
|
|
| BLAKE2b-256 |
eb45e1bf3d24226317a7bb43537c24b2598a003f55431120c616eebe7b519bac
|
Provenance
The following attestation bundles were made for elsa_mcp-0.1.dev9-py3-none-any.whl:
Publisher:
publish.yml on neoblue-tech/elsa-mcp
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
elsa_mcp-0.1.dev9-py3-none-any.whl -
Subject digest:
bc664034ff5aae1f1322476d51b021e117cfb3f77e97fb29f2508576bd0dba46 - Sigstore transparency entry: 1566429220
- Sigstore integration time:
-
Permalink:
neoblue-tech/elsa-mcp@ebd3bf0615c43cb49336290214d64f55beda45b3 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/neoblue-tech
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@ebd3bf0615c43cb49336290214d64f55beda45b3 -
Trigger Event:
push
-
Statement type: