@bossforce.ai/mcp-docusign
v0.1.0
Published
MCP server for the DocuSign **eSignature REST API**. List and inspect envelopes and send documents for electronic signature. Authenticated with OAuth2 using the Authorization Code grant's refresh-token flow; the server exchanges a refresh token for short-
Readme
@bossforce.ai/mcp-docusign
MCP server for the DocuSign eSignature REST API. List and inspect envelopes and send documents for electronic signature. Authenticated with OAuth2 using the Authorization Code grant's refresh-token flow; the server exchanges a refresh token for short-lived access tokens and discovers the account's base URI automatically.
Credentials
| Env | How to obtain |
| ------------------------ | -------------------------------------------------------------------------------------------------------------------- |
| DOCUSIGN_CLIENT_ID | Integration key of your DocuSign app (provided by the platform as the OAuth client_id). |
| DOCUSIGN_CLIENT_SECRET | Secret key of the integration (the OAuth client_secret). |
| DOCUSIGN_REFRESH_TOKEN | Obtained automatically when you authorize access. Exchanged for access tokens. |
| DOCUSIGN_ACCOUNT_ID | Optional account id (GUID). With DOCUSIGN_BASE_URI, skips the userinfo discovery call. Not secret. |
| DOCUSIGN_BASE_URI | Optional account base URI, e.g. https://na4.docusign.net. With DOCUSIGN_ACCOUNT_ID, skips discovery. Not secret. |
The credentials are read lazily, so the server boots and answers tools/list
without them; calls fail with an auth error until they are set. On the first
call the client POSTs the refresh token to
https://account.docusign.com/oauth/token (grant_type=refresh_token)
authenticating the app with an HTTP Basic header of
base64(integration_key:secret), caches the returned access_token, and
re-fetches once on a 401. Unless DOCUSIGN_ACCOUNT_ID and DOCUSIGN_BASE_URI
are both supplied, it discovers the account via
GET https://account.docusign.com/oauth/userinfo (the default account's
base_uri and account_id). The eSignature API base is
{base_uri}/restapi/v2.1/accounts/{accountId}.
Production gating
DocuSign integrations start in the demo environment
(account-d.docusign.com). To call production (account.docusign.com) your
integration must pass DocuSign's go-live review (API certification) and the
platform must be configured with production OAuth client credentials. Sending
envelopes consumes real envelope/transaction usage, which may require a paid
DocuSign plan.
Tools
| Tool | Arguments | Returns |
| --------------------- | ---------------------------------------------------------- | -------------------------------------------- |
| list_envelopes | from_date, status?, count? | envelopes array with status and timestamps |
| get_envelope | envelope_id | the envelope's core fields |
| get_envelope_status | envelope_id | the envelope with its recipients |
| send_envelope | email_subject, email_blurb?, documents, recipients | the created envelope id and status |
list_envelopes requires from_date (ISO 8601 with an explicit offset).
documents are DocuSign document objects (base64 content, name, fileExtension,
documentId) and recipients is a DocuSign recipients object (e.g. a signers
array). Responses are DocuSign's native JSON payloads, returned as
structuredContent.
Develop
pnpm --filter @bossforce.ai/mcp-docusign build
pnpm --filter @bossforce.ai/mcp-docusign testRegenerate the tools/list snapshot after an intentional signature change:
UPDATE_SNAPSHOTS=1 pnpm --filter @bossforce.ai/mcp-docusign test