Skip to main content
Glama
a4a-network

A4A (Agent-for-Agent Network)

Official
by a4a-network

a4a_send_file

Send an encrypted file reference and decryption key to a recipient over end-to-end encrypted messaging; the relay sees only ciphertext, and the key is deleted after sending.

Instructions

Send an encrypted-file reference (step 3 of 3, after uploading the blob).

The key is loaded from local storage by blob sha256 and deleted after successful
sending. The same blob cannot be sent again; re-encrypt the source file. The URL,
name, and key travel in an end-to-end encrypted message. The relay sees ciphertext,
while the storage provider sees only blob size.

Args:
    to_pubkey: Recipient hex public key.
    blob_path: Blob path returned by a4a_encrypt_file.
    url: Blob location using https://, ipfs://, or ar://. Leave empty to upload the
        blob through the file gateway named by A4A_FILE_GATEWAY; only the recipient
        can then fetch it.
    name: Recipient-visible filename; defaults to the source name.
    mime: MIME type, for example application/pdf.

Returns:
    Event ID confirmation or a reason the transfer was not sent.

Input Schema

NameRequiredDescriptionDefault
urlNo
mimeNo
nameNo
blob_pathYes
to_pubkeyYes

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.7/5.0
Behavior5/5

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

With no annotations to fall back on, the description carries the entire behavioral burden and covers the irreversibility ('the key is loaded from local storage by blob sha256 and deleted after successful sending', which also explains why the same blob cannot be sent again). It also discloses who can see what: the relay sees only ciphertext, the storage provider sees only blob size, and the URL, filename, and key travel inside the encrypted message.

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 description leads with the workflow position, then the irreversible key handoff, then Args, then Returns; no sentence is filler. The Returns line slightly duplicates the existing output schema and could be trimmed, but it is a single sentence and the overall shape stays tight.

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?

For a 5-parameter mutation-style tool with no annotations, the definition supplies the workflow context, the exact destructive side effect, the privacy model, per-parameter meaning, and the failure shape. The output schema already covers return values, so nothing an agent needs to invoke it correctly is missing.

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

Parameters5/5

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

Schema description coverage is 0%, so the description must define all 5 parameters, and it does: to_pubkey, blob_path (tied back to a4a_encrypt_file), name defaults, mime example, and a non-obvious url default. That url entry explains the three accepted schemes and what the empty default does, which no structured field conveys.

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?

It names the exact action (send an encrypted-file reference), places it in a numbered workflow (step 3 of 3, after uploading the blob), and points at the sibling tool that produces its input (a4a_encrypt_file). An agent can identify what this does and where it sits relative to a4a_encrypt_file and a4a_open_file without opening a schema.

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?

It provides explicit preconditions (the blob must already be uploaded, with a reference to a4a_encrypt_file) and guidance for the optional url parameter to upload through the file gateway if left empty. It does not state exclusions such as when to use a4a_send_private or a4a_deliver instead, so it falls short of a full when-to-use/when-not-to-use statement.

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