Skip to main content
Glama

Taokeh MCP server

Replaced by its MCP Registry listing

This endpoint is listed in the official MCP Registry as mcp. If you published it, claim ownership there.

Get original document link

get_attachment
Read-only

Returns a short-lived link to the original document filed against something in the books: the receipt behind a posted expense, a photo waiting in the shoebox, or the receipt, sales note, supplier bill, bank-in slip or name card riding a pending draft. Takes owner plus the id of what owns it: for a posted expense, the expenseId from search_expenses (plus its attachmentId when it carries more than one file); for a draft, the draftId; for a shoebox photo, its id from shoebox_items. search_expenses rows and every create_*_draft / revise_draft result say whether an original is on file. Returns a signed URL (about 15 minutes, usable by anyone holding it), the filename, the media type and the size in bytes. The file's bytes are not inlined, and Taokeh does not read or OCR the file. An approved draft reports no original, because on approval the file moves onto the posted document. Read-only; it emails nobody, and no link reaches another company.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "owner": "<owner>",
      "id": "<id>"
    },
    "name": "get_attachment"
  }
}

Input Schema

NameRequiredDescriptionDefault
idYesThe owner's id — the expenseId from search_expenses for 'expense', otherwise the draftId a create_*_draft or revise_draft call returned.
ownerYesWhat the original hangs off: 'expense' = a posted paid expense (id = expenseId from search_expenses); 'expense_draft' / 'invoice_draft' / 'bill_draft' / 'quote_draft' / 'receipt_draft' / 'payment_draft' / 'contact_draft' = a pending draft (id = its draftId); 'shoebox' = an unread phone photo (id from shoebox_items).
attachmentIdNoWhich file, when a posted expense carries more than one — the `attachmentId` from that expense's `attachments` list in search_expenses. Omit for a draft (a draft carries at most one original), and omit for an expense with exactly one file.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  2. Changed1 schema field changed
    • changedInput schema / properties / owner / description
      Previous value: -"What the original hangs off: 'expense' = a POSTED paid expense (use the expenseId from search_expenses); 'expense_draft' / 'invoice_draft' / 'bill_draft' / 'quote_draft' / 'receipt_draft' / 'payment_draft' / 'contact_draft' = a PENDING draft (use its draftId); 'shoebox' = a photo someone in the business sent in from their phone and nobody has read yet (use the id from shoebox_items)."New value: +"What the original hangs off: 'expense' = a posted paid expense (id = expenseId from search_expenses); 'expense_draft' / 'invoice_draft' / 'bill_draft' / 'quote_draft' / 'receipt_draft' / 'payment_draft' / 'contact_draft' = a pending draft (id = its draftId); 'shoebox' = an unread phone photo (id from shoebox_items)."
  3. Changed2 schema fields changed
    • changedInput schema / properties / owner / description
      Previous value: -"What the original hangs off: 'expense' = a POSTED paid expense (use the expenseId from search_expenses); 'expense_draft' / 'invoice_draft' / 'bill_draft' / 'quote_draft' / 'receipt_draft' / 'contact_draft' = a PENDING draft (use its draftId); 'shoebox' = a photo someone in the business sent in from their phone and nobody has read yet (use the id from shoebox_items)."New value: +"What the original hangs off: 'expense' = a POSTED paid expense (use the expenseId from search_expenses); 'expense_draft' / 'invoice_draft' / 'bill_draft' / 'quote_draft' / 'receipt_draft' / 'payment_draft' / 'contact_draft' = a PENDING draft (use its draftId); 'shoebox' = a photo someone in the business sent in from their phone and nobody has read yet (use the id from shoebox_items)."
    • changedInput schema / properties / owner / enum
      Previous value: -[
      -  "expense",
      -  "invoice",
      -  "credit_note",
      -  "bill",
      -  "quote",
      -  "expense_draft",
      -  "invoice_draft",
      -  "bill_draft",
      -  "quote_draft",
      -  "receipt_draft",
      -  "contact_draft",
      -  "journal_draft",
      -  "shoebox"
      -]New value: +[
      +  "expense",
      +  "invoice",
      +  "credit_note",
      +  "bill",
      +  "quote",
      +  "expense_draft",
      +  "invoice_draft",
      +  "bill_draft",
      +  "quote_draft",
      +  "receipt_draft",
      +  "payment_draft",
      +  "contact_draft",
      +  "journal_draft",
      +  "shoebox"
      +]
  4. Changed2 schema fields changed
    • changedInput schema / properties / owner / description
      Previous value: -"What the original hangs off: 'expense' = a POSTED paid expense (use the expenseId from search_expenses); 'expense_draft' / 'invoice_draft' / 'bill_draft' / 'quote_draft' / 'receipt_draft' / 'contact_draft' = a PENDING draft (use its draftId)."New value: +"What the original hangs off: 'expense' = a POSTED paid expense (use the expenseId from search_expenses); 'expense_draft' / 'invoice_draft' / 'bill_draft' / 'quote_draft' / 'receipt_draft' / 'contact_draft' = a PENDING draft (use its draftId); 'shoebox' = a photo someone in the business sent in from their phone and nobody has read yet (use the id from shoebox_items)."
    • changedInput schema / properties / owner / enum
      Previous value: -[
      -  "expense",
      -  "invoice",
      -  "credit_note",
      -  "bill",
      -  "quote",
      -  "expense_draft",
      -  "invoice_draft",
      -  "bill_draft",
      -  "quote_draft",
      -  "receipt_draft",
      -  "contact_draft",
      -  "journal_draft"
      -]New value: +[
      +  "expense",
      +  "invoice",
      +  "credit_note",
      +  "bill",
      +  "quote",
      +  "expense_draft",
      +  "invoice_draft",
      +  "bill_draft",
      +  "quote_draft",
      +  "receipt_draft",
      +  "contact_draft",
      +  "journal_draft",
      +  "shoebox"
      +]
  5. Changed1 schema field changed
    • changedInput schema / properties / owner / enum
      Previous value: -[
      -  "expense",
      -  "invoice",
      -  "credit_note",
      -  "bill",
      -  "quote",
      -  "expense_draft",
      -  "invoice_draft",
      -  "bill_draft",
      -  "quote_draft",
      -  "receipt_draft",
      -  "contact_draft"
      -]New value: +[
      +  "expense",
      +  "invoice",
      +  "credit_note",
      +  "bill",
      +  "quote",
      +  "expense_draft",
      +  "invoice_draft",
      +  "bill_draft",
      +  "quote_draft",
      +  "receipt_draft",
      +  "contact_draft",
      +  "journal_draft"
      +]
  6. First observed

TDQS

A4.4/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Adds substantial behavior beyond the annotations: the URL is signed, lives about 15 minutes, and is usable by anyone holding it; bytes are not inlined and the file is not read or OCR'd; approved drafts have no original because the file moves to the posted document; no emails are sent and no link crosses to another company. These are exactly the auth, lifetime and side-effect facts an agent needs before handing a link to a user.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The return value and lifetime are front-loaded in the first and third sentences, with case-by-case id routing in between. It is dense and every clause carries information, though phrases like 'riding a pending draft' and the closing reassurance list add a little color that could be trimmed without loss.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

There is no output schema, so the description must explain the return shape, and it does: a signed URL with roughly a 15-minute lifetime, plus filename, media type and size in bytes. Combined with the coverage of the approved-draft edge case and the multi-file case, an agent has everything needed to call this correctly and set user expectations.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, and the description largely restates the owner→id mapping already documented in the `owner` and `id` schema descriptions. The one useful addition is the conditional rule that `attachmentId` is only needed when a posted expense carries more than one file, which is also present in the schema. Baseline 3 applies since the schema does the heavy lifting.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Returns a short-lived link to the original document') and immediately enumerates the concrete cases it covers: the receipt behind a posted expense, a shoebox photo, or a file on a pending draft. It also implicitly separates itself from byte-serving siblings by stating the file's bytes are not inlined and no OCR happens.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Gives explicit routing: which `id` to pull from search_expenses vs shoebox_items vs a create_*_draft result, and notes that search_expenses rows and draft results report whether an original exists. It also warns that an approved draft reports no original, which prevents a pointless call. It stops short of naming an alternative tool for retrieving file bytes, so a 4 rather than a 5.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources