Skip to main content
Glama

Upload knowledge document

ringkit_upload_knowledge_document
Idempotent

Step 2: Teach it the business. Upload a document the receptionist should answer from (menu, price list, policies, manual). contentBase64 is the file's bytes, base64-encoded; fileName's extension picks the type: .pdf, .docx, .txt, .md, .html (PDF/DOCX only where the server has them enabled). Text is extracted at upload and searched on every call; a website import never removes uploads. Limits by tier (see get_knowledge_usage): 10 MB per file; Starter 5 documents / 50k tokens, Pro 100 / 500k. Identical requests are deduplicated for 24 hours; use a new idempotencyKey only to deliberately repeat the action.

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": {
      "fileName": "<fileName>",
      "contentBase64": "<contentBase64>"
    },
    "name": "ringkit_upload_knowledge_document"
  }
}

Input Schema

NameRequiredDescriptionDefault
fileNameYes
businessIdNoDefaults to the business of the API key in the Authorization header.
contentTypeNo
contentBase64Yes
idempotencyKeyNoOptional. Retries of the same call should reuse it (the stored result comes back); a new value deliberately repeats an identical call. The MCP POST's Idempotency-Key header takes precedence.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.5/5.0
Behavior5/5

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

Goes well beyond the annotations: text is extracted at upload and indexed for every subsequent call, tier caps (10 MB, Starter 5 docs/50k tokens, Pro 100/500k), 24-hour deduplication of identical requests, and the idempotencyKey repeat-vs-retry distinction. This is exactly the operational context (cost, limits, side effects) an agent needs before writing data.

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?

Front-loads the setup-step framing, then moves through format, indexing behavior, limits, and dedup in a tight paragraph with no filler sentences. Dense but scannable; the parenthetical asides are load-bearing rather than decorative.

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

Completeness4/5

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

For a write tool with no output schema, it covers input formats, limits, indexing consequences, and idempotency. The main omission is what the call returns (document id/status) and how partial or failed extraction surfaces, which an agent would need to chain into get_knowledge_document.

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

Parameters4/5

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

With only 40% schema description coverage, the description compensates well for the required parameters: contentBase64 is the raw file bytes base64-encoded, and fileName's extension selects the parser (.pdf, .docx, .txt, .md, .html, with PDF/DOCX gated by server config), which also explains the effective 10 MB bound. contentType is left uninterpreted, a minor residual gap.

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 concrete verb and resource (upload a knowledge document the receptionist answers from) and gives concrete examples of document kinds (menu, price list, policies, manual). It also differentiates itself from the website-import path by noting that 'a website import never removes uploads', so an agent can tell the two ingestion routes apart.

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?

'Step 2: Teach it the business' places it in the onboarding sequence and the examples clarify the intended content. It also points to get_knowledge_usage for tier limits and contrasts with website import. It stops short of an explicit when-not-to-use rule or naming a specific alternative tool to use for URLs.

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