# HotDocs MCP for AI Agents AI Agent Connect

> HotDocs lets you automate document assembly through HotDocs Advance. You can list templates, manage work items, conduct interviews, and generate final documents like contracts or HR forms directly from your AI agent. It removes the need to manually click through the web interface to get your paperwork done.

## Overview
- **Category:** productivity
- **Price:** Free
- **Endpoint:** https://edge.vinkius.com/vk_preview_3LH8aFkSFUYBfyKkjUilqSyl7MVRZdxklYtrmoJe/ai-agent-connect
- **Tags:** document-automation, template-management, assembly-workflows, compliance-automation, data-interview

## Description

Dealing with document assembly usually means jumping between tabs, copying data into forms, and waiting for files to generate. This Connector changes that by letting your AI agent do the heavy lifting for you. You can tell your agent to find a specific template, start a new project, and feed in the data needed to fill it out. Instead of manual data entry, you just provide the facts in a conversation. It handles the data injection and triggers the actual document creation in the background. You can then just ask your agent to grab the finished PDF or Word file. It's a way to turn your AI into a document specialist that knows your specific HotDocs tenancy. You'll find this works great because it's part of the Vinkius catalog, making it easy to plug into your existing workflow without extra friction.

## Tools

### list_template_packages
Browse all the templates available in your HotDocs account. This is your starting point for finding the right form.

### complete_assembly
Process collected answers to generate final documents. This makes the files ready for you to download.

### create_interview_session
Prepare the system to collect answers for template variables. Use this to set up the interactive data collection phase.

### create_work_item
Create a unique reference for a new document project. This ID is used for all following steps like interviews and assembly.

### get_auth_token
Grab a fresh API access token for your session. This helps fix any permission issues you might run into.

### get_document_content
Download the content of a finished PDF or Word file. It provides a direct link to the file you just created.

### get_template_package
View the structure of a specific template package. This helps you understand what data is needed before you start a project.

### get_unanswered_variables
Identify which data points are missing from a document. It helps you audit the work before you finalize everything.

### get_work_item
Inspect the details of an existing project. You can check the status or data of any work item by its ID.

### list_documents
See all the files that have been assembled for a specific project. Use this to find the IDs needed for downloading.

### list_template_versions
See the history of a template's different versions. This lets you pick the correct one for your current needs.

### list_work_items_by_date
Find projects created within a specific timeframe. This is great for auditing activity or generating reports.

### list_work_items
Find specific projects using filters like user ID or date. Use this to track progress across your team.

### update_answers
Feed in data using a specific XML format. This is the fastest way to do batch updates for multiple documents.

## Prompt Examples

**Prompt:** 
```
What templates do I have available for a new employment contract?
```

**Response:** 
```
I've checked your HotDocs tenancy and found the following templates available for employment contracts:

| Template Name | Package ID | Version |
| :--- | :--- | :--- |
| **Standard Employment Agreement** | `emp-agr-v2` | 2.4.1 |
| **Executive Offer Letter** | `exec-off-v1` | 1.0.2 |
| **Contractor Agreement** | `cont-agr-v3` | 3.1.0 |

Which one would you like to start with?
```

**Prompt:** 
```
Create a work item for a new NDA for 'TechCorp' and tell me what info I need to provide.
```

**Response:** 
```
I've created a new work item for you: **NDA-TechCorp-2024**. 

To complete this document, I'll need the following details:
* **Company Legal Name**
* **Jurisdiction State**
* **Effective Date**
* **Non-Compete Duration** (e.g., 12 months)

Once you provide those, I can start the assembly for you.
```

**Prompt:** 
```
List all the documents that were finished yesterday and give me the links.
```

**Response:** 
```
I found 3 documents assembled yesterday:

* **Employment_Agreement_Smith.pdf** (ID: `doc_9921`) - [Download Link]
* **NDA_TechCorp.docx** (ID: `doc_9925`) - [Download Link]
* **Offer_Letter_Jones.pdf** (ID: `doc_9930`) - [Download Link]

Would you like me to open any of these for you?
```

## Capabilities

### Find template packages
See every template and version available in your HotDocs tenancy.

### Create work items
Set up new projects with unique IDs for tracking and assembly.

### Start interview sessions
Initialize interactive data collection for specific templates.

### Generate documents
Inject data via XML and trigger the final document assembly.

### Download finished files
Retrieve completed PDFs and Word docs directly to your machine.

### Audit missing data
Check which variables are still empty before you finish a document.

## Use Cases

### Legal Contract Batching
A lawyer needs 50 NDAs. They feed a CSV of names to the agent, which uses update_answers and complete_assembly to generate all 50 files in minutes.

### HR Onboarding
An HR lead asks the agent to create a new hire package. The agent uses create_work_item and create_interview_session to gather all the employee details.

### Loan Processing
A bank officer wants to check if a loan application is complete. The agent uses get_unanswered_variables to see what's missing and tells the officer exactly what to ask the client for.

### Compliance Auditing
An admin needs to see all documents created last week. The agent uses list_work_items_by_date to pull a list and summarize the activity for the weekly report.

## Benefits

- Skip the web interface: Use list_template_packages to find what you need without logging into the HotDocs portal.
- Faster data entry: Use update_answers to feed in XML data for batch processing instead of typing into forms one by one.
- Better auditing: Use get_unanswered_variables to catch missing info before you hit the final assembly button.
- Easy retrieval: Use list_documents and get_document_content to grab finished files without searching through folders.
- Precise versioning: Use list_template_versions to ensure you are always using the most current legal forms.
- Simplified tracking: Use list_work_items_by_date to pull reports on how many documents your team finished this month.

## How It Works

The bottom line is you get finished documents without ever opening the HotDocs web portal.

1. Subscribe to the HotDocs MCP and provide your tenancy, API client name, and service principal credentials.
2. Tell your agent which template you want to use and provide the necessary data for the document.
3. Get the finished document files delivered straight to your chat interface.

## Frequently Asked Questions

**Can I use the HotDocs MCP to generate contracts?**
Yes, it works by connecting to HotDocs Advance to pull templates and assemble documents like contracts using natural language.

**Does the HotDocs MCP support Word and PDF files?**
It handles both. You can use the agent to trigger assembly and then download the finished Word or PDF files directly.

**How does this help with HR documents?**
It automates the creation of offer letters and policy docs by feeding data into your HotDocs templates without manual entry.

**Can I check if a document is missing any info?**
Yes, the Connector can check for unanswered variables in a project so you know exactly what's missing before you finish it.

**Is it easy to set up the HotDocs MCP?**
It's straightforward. You just need your HotDocs Advance tenancy details and API credentials to get started with your AI agent.

**Can I batch process multiple documents at once?**
Yes, by using the XML update tool, you can feed in data for multiple documents in one go to speed up your workflow.

**What credentials do I need to connect HotDocs Advance to this Connector?**
You need four pieces of information: (1) your **Tenancy Moniker** (the subdomain in your HotDocs URL, e.g., 'mycompany' from mycompany.hotdocsadvance.com), (2) the **API Client Display Name** you created in Manage API Credentials, (3) the **Service Principal Name** you added to that client, and (4) the **Service Principal Password** (which is shown only once during creation). All of these are obtained from the HotDocs Advance Auth portal.

**Can I assemble documents automatically without going through the interview UI?**
Yes! Use the `create_work_item` tool to initialize a work item, then use `update_answers` to inject your data as HotDocs answer XML, and finally call `complete_assembly` to trigger document generation. This fully automated bypasses the interactive interview UI entirely, perfect for batch processing or integrating with external data sources.

**How do I find and download documents that have already been assembled?**
Use the `list_documents` tool with your workItemId to see all assembled documents and their IDs. Then use `get_document_content` with the workItemId and documentId to retrieve the actual file content. The response includes both the raw content and a direct download URL for easy access to your PDFs or Word documents.

**What is a work item and why is it important?**
A work item is a unique container in HotDocs Advance that holds interview answers, template associations, and assembled documents for a specific case. Think of it as a 'file folder' for each document automation request. It's identified by a unique ID you assign (like 'contract-john-doe-2024') and persists all data so you can revisit, update, and reassemble documents at any time.

**What credentials do I need to connect HotDocs Advance to this MCP server?**
You need four pieces of information: (1) your **Tenancy Moniker** (the subdomain in your HotDocs URL, e.g., 'mycompany' from mycompany.hotdocsadvance.com), (2) the **API Client Display Name** you created in Manage API Credentials, (3) the **Service Principal Name** you added to that client, and (4) the **Service Principal Password** (which is shown only once during creation). All of these are obtained from the HotDocs Advance Auth portal.