MCP Server Tools
An assistant connected to DocSpring’s MCP server sees the tools that its access allows. You choose the access when you sign in: Read only, Read and write or Full access.
Tools that make PDFs or set up templates wait until DocSpring has finished, like the
synchronous API. When that takes longer than about 50 seconds, the tool
returns the record’s ID with the state processing, and the assistant checks it again with get_submission or
get_template.
Read only
Section titled “Read only”Every connection has these tools.
| Tool | What it does |
|---|---|
list_templates | Lists the account's templates, 50 at a time: each one's name, type, folder, latest published version and whether it's ready. |
get_template | Gets a template: its settings, a summary of each field (name, type, description, and on a PDF template its page and position), and for the draft, whether it has changes that aren't published yet. |
get_fields | Gets the settings of a template's fields, or of the fields chosen by ID or name. |
get_template_schema | Gets the JSON Schema of the data a template's submissions take: each field's name, type, and whether it's required. |
get_template_pages | Shows a PDF template's pages as images, to see where fields go. |
get_model_code | Generates types for a template's submission data, for code that creates submissions with DocSpring's API or SDKs: the types only, without code to convert JSON (the API's just_types option). |
preview_template | Shows a template's pages filled in with your data as PNG images (not a PDF), to check how an HTML or PDF template prints before you publish it or generate live PDFs. |
list_versions | Lists a template's published versions, newest first (up to 100), with who published each one and what changed. |
diff_versions | Shows what changed in a template's draft since its latest published version (or in a published version since the one before it): fields added, removed, changed and moved, settings, and whether the PDF was replaced. |
list_folders | Lists the account's template folders, with each one's path, 50 at a time. |
validate_data | Checks submission data against a template without making a PDF or saving anything: which fields are missing or have the wrong type. |
get_submission | Gets a submission (its state, data, signature requests and a link to download its PDF), a batch from generate_pdfs, or a combined PDF from combine_pdfs. |
list_submissions | Lists the account's submissions, newest first, 50 at a time: each one's state, template, test or live, metadata and times. |
Read and write
Section titled “Read and write”| Tool | What it does |
|---|---|
create_pdf_template | Creates a PDF template from a PDF, and waits until DocSpring has processed it. |
create_pdf_upload | Prepares an upload of a local PDF, for agents that can run commands: use it for any PDF file on disk, since base64 in a tool call only suits a small file. |
create_html_template | Creates an HTML template: DocSpring renders its HTML (a Liquid template) and SCSS as a PDF, with each submission's data. |
update_template | Changes a template's settings in its draft. |
replace_template_pdf | Replaces a PDF template's PDF in its draft, keeping its fields (or reimporting the new PDF's form fields), and waits until DocSpring has processed it. |
copy_template | Copies a template (its draft, or a published version) to a new template, and waits until the copy's PDF is ready. |
move_template | Moves a template, with all of its published versions, to a folder or to the root. |
add_fields | Adds fields to a template's draft: on a PDF template they're placed on its pages, and on an HTML template they define the data its HTML uses. |
update_fields | Changes fields of a template's draft: their settings, names, and on a PDF template their pages or positions. |
remove_fields | Removes fields from a template's draft. |
publish_version | Publishes a template's draft as a new version, which new submissions use straight away. |
restore_version | Replaces a template's draft with a published version. |
create_folder | Creates a template folder. |
rename_folder | Renames a template folder. |
move_folder | Moves a template folder, with everything in it, into another folder or to the root. |
generate_pdf | Fills in a template with data and makes a PDF (a submission), and waits for it. |
generate_pdfs | Makes up to 50 PDFs in one batch, from one template or several, and waits for them. |
combine_pdfs | Merges PDFs (submissions, templates, other combined PDFs or links) into one PDF, and waits for it. |
get_submission_pages | Shows a submission's PDF as page images, to check how the data looks on it. |
create_signature_request | Asks people to fill in and sign a template: creates a submission with a signature request for each signer, and returns a link for each one, for the user to send. |
create_signing_link | Makes a new link for a signer to open their signature request, such as when their link has expired. |
Full access
Section titled “Full access”Full access adds the tools that delete things and the webhook tools.
Delete
Section titled “Delete”These tools can’t be undone, so clients ask you to confirm each call.
| Tool | What it does |
|---|---|
delete_template | Deletes a template: its draft and every published version. |
delete_version | Deletes one published version of a template. |
delete_folder | Deletes an empty template folder. |
expire_submission | Expires a submission now: deletes its data (the field values), its metadata, its PDF, its error messages and the IP address and browser it was submitted from. |
Webhooks
Section titled “Webhooks”An assistant only sees and changes the webhooks it created. They’re deleted when you disconnect the assistant.
Webhooks you set up in DocSpring or with an API token aren’t listed, so list_webhooks can be empty when your account
has webhooks.
| Tool | What it does |
|---|---|
list_webhooks | Lists the webhooks that this connection (this assistant, as the user connected it) created, with their signing secrets. |
create_webhook | Creates a webhook: DocSpring sends a POST request to the URL for each event, signed with the webhook's secret. |
update_webhook | Changes a webhook this app created: its URL, events, filters, or whether it's enabled. |
delete_webhook | Deletes a webhook this app created. |