adins-prd-mcp
v0.5.7Custom MCP server for AdIns — Confluence read, attachment download, and docx rendering
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
get_confluence_page
Fetch a Confluence page by its numeric ID. Args: page_id: Numeric Confluence page ID (e.g. "935559172"). format: "markdown" (default) returns clean markdown text. "html" returns raw Confluence storage HTML. Returns: dict — id, title, url, version, content
| Parameter | Type | Description |
|---|---|---|
page_id * | string | |
format | string |
search_confluence
Search Confluence using CQL (Confluence Query Language). Args: cql: CQL query string. Example: 'title ~ "Partial Prepayment" AND space = "GlobalAdIn"' Use 'parent = <folder_id>' to list direct children of a folder. limit: Max results per call (1-50, default 25). start: Zero-based offset for pagination (default 0). Call repeatedly with start=0, 50, 100, ... until the returned list has fewer items than `limit` to retrieve all pages from a large folder. Returns: List of dicts — id, title, type, url, excerpt, position Note:…
| Parameter | Type | Description |
|---|---|---|
cql * | string | |
limit | integer | |
start | integer |
list_confluence_attachments
List all file attachments on a Confluence page. Args: page_id: Numeric Confluence page ID. Returns: List of dicts — id, title, media_type, size, download_url
| Parameter | Type | Description |
|---|---|---|
page_id * | string |
download_confluence_attachment
Download a named attachment from a Confluence page to a local file. Convention for output_path: output/<Module>-<Version>/<page_id>/<original_filename> e.g. "C:/project/output/LMS-1.5/935559172/process-flow.png" Args: page_id: Numeric Confluence page ID. filename: Exact attachment filename. output_path: Absolute local path to save the file. Parent directories are created automatically. Returns: dict — saved_path, size_bytes, title
| Parameter | Type | Description |
|---|---|---|
filename * | string | |
output_path * | string | |
page_id * | string |
get_confluence_page_ancestors
Return the ancestor chain for a Confluence page, from root to immediate parent. Each ancestor includes a `type` field (`"page"` or `"folder"`). Use this to identify the release folder without guessing from title patterns. Args: page_id: Numeric Confluence page ID (e.g. "935559172"). Returns: List of dicts ordered root → immediate parent, each with: id, title, type, url
| Parameter | Type | Description |
|---|---|---|
page_id * | string |
get_confluence_page_to_file
Fetch a Confluence page and write its content directly to a local file. Use this instead of get_confluence_page when the page is large and you do not need to hold the content in context. The content is streamed to disk; only the file path, size, and page metadata are returned to the agent. Overwrites the file if it already exists. Parent directories are created automatically. Args: page_id: Numeric Confluence page ID (e.g. "935559172"). output_path: Absolute local path to write the content to. Convention: output/<Module>-<Version>/<page_id>/raw.md format: "markdown" (def…
| Parameter | Type | Description |
|---|---|---|
output_path * | string | |
page_id * | string | |
format | string |
get_confluence_page_siblings
Return all sibling pages of a given Confluence page (pages sharing the same parent). Results are sorted by extensions.position ASC, which matches the Confluence UI page tree order. Use the 0-based index in the returned list as the feature_order or service_order value. Args: page_id: Numeric Confluence page ID (e.g. "935559172"). Returns: List of dicts for each sibling (excludes the input page itself), sorted by position ASC: id, title, url, position
| Parameter | Type | Description |
|---|---|---|
page_id * | string |
init_document_db
Initialise a SQLite database for a document generation run. Creates the DB file and tables (idempotent — safe to call again on an existing DB). Stores module-level metadata used for cover page and headers. Call this once before any store_feature calls. To correct metadata, call it again with the corrected meta dict — INSERT OR REPLACE is used. Convention for db_path: output/<Module>-<Version>.db e.g. "C:/project/output/LMS-1.5.db" Args: db_path: Absolute path for the .db file. meta: dict with keys: module_name (str) — e.g. "Loan Management System…
| Parameter | Type | Description |
|---|---|---|
db_path * | string | |
meta * | object |
store_feature
Store one parsed feature (and its menus) into the SQLite database. Safe for parallel subagent calls — WAL mode + busy_timeout handle concurrent writes gracefully. Idempotent: calling with the same source_id replaces the existing feature row and all its menus atomically (INSERT OR REPLACE). To correct a stored feature, call this tool again with the same source_id and corrected data. Do not attempt to patch individual fields. Subagent usage: dispatch at most 5 parallel subagents, one per feature page. Each subagent reads its own Confluence page and calls this tool once. Do not dispatch sub…
| Parameter | Type | Description |
|---|---|---|
db_path * | string | |
feature_data * | object |
store_feature_from_file
Store one parsed feature (and its menus) into the SQLite database, reading the feature payload from a local JSON file instead of passing it inline. Use this instead of ``store_feature`` when the feature_data payload is too large to pass as an inline argument. Write the feature_data dict to a JSON file first, then call this tool with the path to that file. The JSON file must contain a single object whose schema is identical to the ``feature_data`` argument of ``store_feature`` — see that tool for the full field reference. Safe for parallel subagent calls — WAL mode + busy_timeout handle…
| Parameter | Type | Description |
|---|---|---|
db_path * | string | |
feature_data_path * | string |
raw_query_exec
Execute a raw SQL statement against the document SQLite database. Use this for ad-hoc inspection, targeted fixes, or schema migrations that store_feature does not cover. store_feature / store_feature_from_file are preferred for writing feature data — use write=True only for manual fixups. Hard limits: - SELECT results are capped at 200 rows. Rows beyond that are silently dropped; the returned dict includes a truncated=True flag when this happens. - DML / DDL (INSERT, UPDATE, DELETE, ALTER, CREATE, DROP) requires write=True. Passing a write statement with write=False raises an error. A…
| Parameter | Type | Description |
|---|---|---|
db_path * | string | |
sql * | string | |
params | ||
write | boolean |
render_srs_docx
Render the SRS Word document from data stored in the SQLite database. Reads all ready features from db_path, assembles the context internally (the agent never sees the assembled context dict), and renders the docx. Rendering always proceeds even if there are warnings — warnings mean the document may be incomplete. The agent MUST surface all returned warnings to the end user. Args: template_path: Absolute path to the SRS .docx template. output_path: Absolute path for the rendered output .docx. db_path: Path to the DB file populated by store_feature calls. Returns: dict —…
| Parameter | Type | Description |
|---|---|---|
db_path * | string | |
output_path * | string | |
template_path * | string |
render_urs_docx
Render the URS Word document from data stored in the SQLite database. Same behaviour as render_srs_docx but uses URS template and context shape. Rendering always proceeds even if there are warnings — warnings mean the document may be incomplete. The agent MUST surface all returned warnings to the end user. Args: template_path: Absolute path to the URS .docx template. output_path: Absolute path for the rendered output .docx. db_path: Path to the DB file populated by store_feature calls. Returns: dict — saved_path (str), size_bytes (int), warnings (list[str])
| Parameter | Type | Description |
|---|---|---|
db_path * | string | |
output_path * | string | |
template_path * | string |
inspect_docx
Inspect a .docx file and return its numbering and placeholder structure. Works on both template files and rendered outputs. Use this to debug heading numbering issues, verify that all headings share a single numId, or check which Jinja2 placeholders exist and what styles they carry. Returns three sections: numbering One entry per abstractNum that has at least one decimal/letter level. Each entry shows the abstractNumId, which numIds reference it, and the level definitions (ilvl, start, numFmt, lvlText). headings All paragraphs that use a Heading style or carry a non-zero n…
| Parameter | Type | Description |
|---|---|---|
path * | string |