Skip to main content
Glama

Upload a file

create_document

Use this to add a file the person gave you to a fax: a PDF, or a photo saved as JPG, PNG, WEBP or HEIC, up to 20 MB. Call it once per file, before create_fax, in the order the files should be faxed. It returns document_id, upload_url and upload_headers: PUT the file's exact bytes to upload_url with those headers within 5 minutes, then pass document_id to create_fax within an hour. Nothing is faxed or charged. If you can't read the file's bytes, don't use this: call create_fax without document_ids, and the person adds the file on the status page.

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": {
      "fax_number": "<fax_number>",
      "filename": "<filename>",
      "byte_size": "<byte_size>",
      "checksum": "<checksum>",
      "content_type": "<content_type>"
    },
    "name": "create_document"
  }
}

Input Schema

NameRequiredDescriptionDefault
regionNoFor a fax to the US or Canada from a person who isn't signed in and who the conversation shows is in Europe: pass "eu" to send it through Faxette's European service. It's ignored for other numbers and when the person is signed in. Pass the same value to create_document and create_fax.
checksumYesThe file's MD5 digest, base64-encoded, as printed by: openssl md5 -binary <file> | base64
filenameYesThe file's name with its extension, like referral.pdf.
byte_sizeYesThe file's exact size in bytes.
fax_numberYesThe fax number the file will be faxed to, in international format, like +14155552671. Numbers in the US, Canada, Mexico, Puerto Rico, Costa Rica, the EU, the UK, Switzerland, Norway, Iceland, Liechtenstein, Monaco, Montenegro, Ukraine and the Isle of Man only. Use the same number in create_fax.
content_typeYesThe file's media type. It must match the file's contents.

Output Schema

NameRequiredDescriptionDefault
upload_urlYesPUT the file's exact bytes here within 5 minutes.
document_idYesPass this to create_fax in document_ids.
upload_headersYesSend these headers, unchanged, with the PUT.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • changedInput schema / properties / fax_number / description
      Previous value: -"The fax number the file will be faxed to, in international format, like +14155552671. Numbers in the US, Canada, Mexico, Puerto Rico and Costa Rica only. Use the same number in create_fax."New value: +"The fax number the file will be faxed to, in international format, like +14155552671. Numbers in the US, Canada, Mexico, Puerto Rico, Costa Rica, the EU, the UK, Switzerland, Norway, Iceland, Liechtenstein, Monaco, Montenegro, Ukraine and the Isle of Man only. Use the same number in create_fax."
    • addedInput schema / properties / region
      Added value: +{
      +  "description": "For a fax to the US or Canada from a person who isn't signed in and who the conversation shows is in Europe: pass \"eu\" to send it through Faxette's European service. It's ignored for other numbers and when the person is signed in. Pass the same value to create_document and create_fax.",
      +  "enum": [
      +    "eu"
      +  ],
      +  "type": "string"
      +}
  2. Changed1 schema field changed
    • changedInput schema / properties / fax_number / description
      Previous value: -"The fax number the file will be faxed to, in international format, like +14155552671. Numbers in the US and Canada only. Use the same number in create_fax."New value: +"The fax number the file will be faxed to, in international format, like +14155552671. Numbers in the US, Canada, Mexico, Puerto Rico and Costa Rica only. Use the same number in create_fax."
  3. First observed

TDQS

A4.7/5.0
Behavior4/5

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

Goes well beyond the annotations by disclosing the two-step upload contract (PUT exact bytes to upload_url with upload_headers within 5 minutes, pass document_id to create_fax within an hour) and the reassurance that nothing is faxed or charged, which is consistent with destructiveHint=false. It does not discuss failure modes of the upload itself (expired URL, checksum mismatch, retry semantics), so it stops short of a 5.

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

Conciseness5/5

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

One tight paragraph, front-loaded with what the tool does and the sequencing constraint, then the return/upload contract, then the fallback. Every sentence carries distinct operational information; nothing is restated from the schema.

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?

Covers the unusual two-step upload flow, time limits, ordering, cost implications, and the fallback path, which is exactly what an agent needs for a non-idempotent upload-initiation tool. Return values are additionally summarized even though an output schema exists.

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?

Schema coverage is 100%, so the baseline would be 3, but the description adds meaning the schema lacks: a 20 MB size ceiling for byte_size, the accepted extension set matching content_type, and the per-file ordering semantics that govern repeated calls. It does not touch the region parameter, which the schema already explains in detail.

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 ("add a file ... to a fax") plus accepted formats and the 20 MB cap, and explicitly positions it as a prerequisite step to create_fax rather than the send action itself. An agent can distinguish it from create_fax, send_fax, and prepare_fax_upload without opening any schema.

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

Usage Guidelines5/5

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

Gives explicit when-to-use (once per file, before create_fax, in fax order) and an explicit when-not with an alternative: if the file bytes can't be read, skip this tool, call create_fax without document_ids, and the person uploads on the status page. That is the full when/when-not/alternative triad.

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.