Skip to main content
Glama

Multi-recipient hybrid KEM decapsulate

crypto_hybrid_kem_multi_decapsulate

Decapsulates multi-recipient post-quantum hybrid KEM keys using server-held X25519 and ML-KEM-768 handles, recovering a DEK and returning its symmetric-256 key handle.

Instructions

Decapsulate a multi-recipient post-quantum hybrid KEM key using server-held x25519 and ml-kem-768 key handles. Returns a symmetric-256 keyHandle for the recovered DEK.

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": {
      "x25519KeyHandle": "<x25519KeyHandle>",
      "mlKemKeyHandle": "<mlKemKeyHandle>"
    },
    "name": "crypto_hybrid_kem_multi_decapsulate"
  }
}

Input Schema

NameRequiredDescriptionDefault
recipientsNoOptional JSON-serialized array of encrypted recipient objects: [{ id?, ephemeralPublicKey, mlKemCiphertext, encryptedKey }].
wrappedKeyNoBase64-encoded wrapped DEK (RFC 3394 AES Key Wrap).
recipientIdNoOptional recipient ID to select from recipients array.
encryptedKeyNoAlias for wrappedKey.
mlKemKeyHandleYesHandle of recipient ML-KEM-768 key. Key handles look like 'kh_' followed by 32 hex characters.
recipientIndexNoOptional index to select from recipients array (default 0).
mlKemCiphertextNoHex-encoded ML-KEM-768 ciphertext (2176 hex characters).
x25519KeyHandleYesHandle of recipient X25519 key. Key handles look like 'kh_' followed by 32 hex characters.
ephemeralPublicKeyNoHex-encoded sender ephemeral X25519 public key (64 hex characters).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.0.41

TDQS

A3.6/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=false, destructiveHint=false, idempotentHint=false and a closed-world scope; the description adds that key material is server-held via handles and that a symmetric-256 keyHandle is produced. It does not explain why this is not read-only (presumably key-handle creation), nor whether repeated calls with the same inputs yield different handles, which is the main behavioral ambiguity for a non-idempotent tool.

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?

Two sentences, both earning their place: the first states the operation and its inputs, the second states the return value. Front-loaded and free of filler.

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?

With 9 parameters, no output schema, and no annotations covering return values, the description does the essential work of stating what comes back (a symmetric-256 keyHandle). It stops short of explaining the two input modes (recipients array vs. flat wrappedKey/ephemeralPublicKey/mlKemCiphertext) or how recipientId/recipientIndex selection interacts with the default index 0.

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%, so every parameter is already documented in the schema, including handle formats, ciphertext encoding, and the recipients array structure. The description adds no syntax, format, or selection semantics beyond mentioning key handles, so the baseline of 3 applies.

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

Purpose4/5

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

The description names a specific verb and resource ('Decapsulate a multi-recipient post-quantum hybrid KEM key') and specifies the key types involved (x25519, ml-kem-768). The 'multi-recipient' qualifier lets an agent distinguish it from the sibling crypto_hybrid_kem_decapsulate, though the single-recipient tool is never named explicitly.

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

Usage Guidelines3/5

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

Usage is only implied: the multi-recipient framing suggests it is the choice when several recipients are involved, and 'server-held ... key handles' hints at the storage model. There is no explicit when-to-use statement, no exclusion naming crypto_hybrid_kem_decapsulate, and no note on when to pass the recipients array versus direct wrappedKey/ciphertext parameters.

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