Developer
Let an AI agent send documents for signature (MCP, API and CLI)
To let an AI agent send documents for signature, create a DocAISign API key and add the MCP server at https://docaisign.com/mcp to your agent. The agent can then send a document, check who has signed and fetch the signed PDF. Start with a test key, and keep a person in charge of real sends.
Connect an MCP client
Create a key on the Developer page of your account and tick Test key. The full key is shown once, so store it safely. Then add the server to your client. This is the command for Claude Code.
claude mcp add --transport http docaisign https://docaisign.com/mcp --header "Authorization: Bearer dsk_test_..."
Connect a local client
Claude Desktop, Cursor and other clients that run local servers can use the command-line tool as a bridge. It needs Node.js 18 or later. Keep the key in the client's configuration and out of any shared file.
{
"mcpServers": {
"docaisign": {
"command": "npx",
"args": ["-y", "https://docaisign.com/cli/docaisign-cli-1.3.0.tgz", "mcp"],
"env": { "DOCAISIGN_API_KEY": "dsk_test_..." }
}
}
} What the agent can do
The server offers 13 tools. Sends, reminders, corrections, voids and signed-file downloads are recorded on the envelope's audit trail.
By default, send_document turns any text tags in the file into fields. If the file has no tags and the agent gives no fields, it adds a signature page with a signature and date box for each signer. Recipient 1 is the first person in the list the agent sends.
- Look up: get_account, list_templates, get_template, list_envelopes, get_envelope
- Send: send_document (PDF, Word, JPEG or PNG by https URL or base64), send_template, bulk_send
- Follow up: remind, update_recipient, void_envelope
- Finish: get_signing_url for in-person or embedded signing, download_document for the signed PDF or certificate
Worked example: an agent sends an NDA
For example, you ask an agent to send a saved NDA template to a new supplier. A safe run has clear steps, and you approve the one that emails someone.
- The agent calls list_templates and get_template to find the roles and field labels
- It shows you the recipient's name, email and field values, and waits for your approval
- It calls send_template, with test_mode on while you are still trying the flow
- It calls get_envelope when you ask for status, and remind if the supplier has not signed
- Once completed, it calls download_document with kind set to signed
Keep a person in charge
The server tells agents to confirm names and email addresses with you before sending, but an instruction is not a control. Use the limits below as well. A test key can still read envelopes on your account, so protect it like any other key.
- Give the agent a test key until the flow does what you expect
- Ask the agent to set send to false, which saves a draft you can review and send yourself
- Create a separate key for each agent, so you can revoke one without stopping the others
- Set your client to ask before it runs send, void and update tools
- Treat a signing URL as private: it opens the signing page as that recipient
- Revoke the key on the Developer page when you are done, and later requests get a 401 error
Limits to plan for
Real envelopes use your plan's sends, and test envelopes are free. Daily sending limits apply to every account. A reminder can go out at most once every 10 minutes. Through MCP, a downloaded file can be up to 10 MB; use the REST API for a larger one. DocAISign delivers by email only and does not verify signers' identity, so an agent cannot add SMS delivery or ID checks.
Without MCP
The same actions are available in the REST API under /api/v1, described by OpenAPI 3.1 at /openapi.json, and in the docaisign command-line tool. The wait command returns exit code 0 when the envelope completes and 3 if it is declined, voided or expired, which suits scripts.
docaisign login
docaisign send lease.pdf --to "Ana Diaz <[email protected]>" --to "Ben Lee <[email protected]>" --order
docaisign wait <envelope-id> && docaisign download <envelope-id> Common questions
Which AI clients work with the server?
Any client that supports MCP over Streamable HTTP can connect with your key as a Bearer token. Local clients can use the stdio bridge instead.
Does DocAISign use an AI model on my documents?
The MCP server only carries out the tool calls your agent makes. What your agent does with a document depends on the agent and model you chose.
Is a test envelope legally binding?
No. Every page is marked TEST - NOT LEGALLY BINDING, and the certificate says so too.