Skip to main content
Glama
mingyangsun-sketch

DocuSign MCP Server (patched)

README.md
# mcp-server-docusign (patched)

A [Model Context Protocol](https://modelcontextprotocol.io) server exposing DocuSign
eSignature operations, authenticated via **JWT Grant** (headless / service-to-service —
no browser OAuth). Suitable for unattended AI-agent runtimes.

Fork of [luthersystems/mcp-server-docusign](https://github.com/luthersystems/mcp-server-docusign)
(MIT) with bug fixes found during live integration testing. Used as a self-hosted MCP
tool channel in an internal multi-agent AI platform.

## Why this fork

The upstream server's status/document tools had several bugs surfaced when integrating
against the DocuSign demo environment. This fork fixes them:

| Tool | Bug | Fix |
|------|-----|-----|
| `get_envelope_status` | Accessed non-existent `Envelope.signed_date_time` (a recipient-level field) → `AttributeError` | Removed the field |
| `list_envelope_documents` | Returned `doc.pages` (a list of non-serializable `Page` objects) → MCP "no structured output" error | Return page count instead |
| `list_envelopes` | DocuSign requires `from_date`; omitting it raised `INVALID_REQUEST_PARAMETER` | Default `from_date` to a far-past date so no-arg calls list all envelopes |

`download_envelope_document` works as-is — pass a valid `document_id` such as `combined`,
`certificate`, or an id returned by `list_envelope_documents`.

## Tools (8)

- **Templates**: `list_templates`, `get_template_definition`
- **Send**: `create_envelope_from_template`, `create_envelope_from_documents`
- **Track**: `get_envelope_status`, `list_envelopes`
- **Documents**: `list_envelope_documents`, `download_envelope_document`

## Configuration (JWT Grant)

Provide via environment variables:

| Env | Description |
|-----|-------------|
| `DS_AUTH_BASE` | `https://account-d.docusign.com` (demo) / `https://account.docusign.com` (prod) |
| `DS_INTEGRATION_KEY` | DocuSign app Integration Key (client ID) |
| `DS_USER_ID` | User GUID to impersonate |
| `DS_PRIVATE_KEY` | RSA private key, **base64-encoded** (single line); or `DS_PRIVATE_KEY_PATH` for a file |
| `DS_OAUTH_SCOPE` | `signature impersonation` |

One-time DocuSign setup: create an Integration Key, add an RSA keypair, grant consent for
`signature impersonation`. See [DocuSign JWT Grant](https://developers.docusign.com/platform/auth/jwt/).

## Run

stdio MCP server (Python ≥ 3.11):

```bash
uvx --from git+https://github.com/<you>/mcp-server-docusign@<commit> mcp-server-docusign
```

## License

MIT — inherited from upstream luthersystems/mcp-server-docusign. See [LICENSE](LICENSE).

TDQS

A4.1/5.0

Scored across 9 tools

Disambiguation5/5

Each tool has a clear, distinct purpose: envelope creation (two distinct modes), envelope querying, document listing/downloading, and template operations are all well-separated. The only near-overlap is create_envelope_from_template vs create_envelope_from_documents, but their input parameters and use cases are clearly different.

Naming Consistency5/5

All tool names follow a consistent verb_noun snake_case pattern (download_, get_, create_, list_). The two create_envelope variants are clearly named to indicate their source. No mixed conventions or vague verbs.

Tool Count5/5

With 9 tools, the server is well-scoped for DocuSign envelope and template management. Each tool covers a meaningful operation without excessive fragmentation or redundancy.

Completeness4/5

The core lifecycle for envelopes (create, list, status, documents) and templates (create, list, get definition) is covered. Minor gaps exist: no envelope void/update, no template update/delete, but these are not critical for basic signing workflows and can be worked around.

Maintenance

ActivityInactive
ResponsivenessNo issues