Skip to main content
Glama

Attach a receipt to a payment

well_link_receipt_to_transaction
Idempotent

Attach a stored receipt to the payment the member picked from well_list_receipt_candidates. Well records the pick as a confirmed match, decided by a person, and puts the receipt on that payment. A later automatic match never replaces it.

Call it only after the member answered the numbered list with the number of a payment, with the document_id of that list and the picked payment's transaction_id. The member's answer is the consent: do not ask again. Never call it on your own guess, and never for the last choice (none of them).

Read outcome:

  • linked: confirm in one line with the payment's date, payee (transaction.label) and amount (for example « Reçu rattaché au paiement du 03/10 (Le Comptoir, 42,50 €). »). transaction.amount is signed: an outflow is negative. Say it without the minus sign. When the list named the payment's workspace (transaction.workspace, a workspace other than the one the receipt was filed in), the receipt is now filed there: say so in the same line.

  • already_linked: the receipt was already on this payment; say so.

  • ask_document_kind: Well read no receipt or invoice in this document; ask what it is (a receipt, a supplier invoice, or something else).

  • refused: nothing was written. reason says why: transaction_not_found (no such payment in a workspace the member reaches), transaction_has_other_document (that payment already holds another document, which Well never replaces), over_allocated (the receipt or the payment is already settled), invalid (Well cannot match this pair), settled_by_other_invoice (another invoice already settles that payment), wrong_direction (that payment moves the wrong way for this receipt), not_offered (that payment is not one the list offers for this receipt now: offer the list again), receipt_linked_elsewhere (the receipt already sits on another payment: say it is already attached to a payment, and do not offer the list again), document_not_read (Well is still reading the document: say you will try again in a moment). Tell the member in one line. Offer the list again for every reason except receipt_linked_elsewhere and document_not_read.

routine_offer, set only in Well's own chat on linked: this is the member's first matched receipt and they never decided on the Qonto receipt routine. After the link line, make the routine offer of the attach-invoice-in-qonto skill for routine_offer.workspace_connector_id, unless this turn already puts this receipt on its Qonto payment. When it is null or absent, offer nothing.

It writes only inside Well.

Input Schema

NameRequiredDescriptionDefault
document_idYesThe stored document of the receipt, as `well_list_receipt_candidates` read it.
workspace_idNoTarget workspace. Omit when the token authorizes one workspace. Required when it authorizes several — a write lands in exactly one workspace and this call would not say which.
transaction_idYesThe payment the member picked by its number.
conversation_idNoThe conversation id returned by the previous Well result, in its meta under well/conversation_id, in its structuredContent, or in its JSON text block. Pass it back on every call in the same conversation, including a call a card makes, so the chosen workspace and the earlier answers still apply. It decides the conversation on its own: nothing the host states about the session replaces it. Omit it only on the first call of a conversation.
idempotency_keyNoOptional client-supplied key. A retried write with the same key returns the original result instead of re-applying the operation.
workspace_scopeNoRestrict this call to the family: the token's primary workspace plus the company workspaces under it that you are a member of. Unrelated authorized workspaces drop out of the read; row reads merge across the family, while a per-workspace figure still reports exactly one workspace.

Output Schema

NameRequiredDescriptionDefault
errorNo
reasonNo
outcomeNo
receiptNo
successYes
document_idNo
transactionNo
routine_offerNo
transaction_idNo
conversation_idNoThe conversation this result belongs to. Pass it back as the conversation_id argument on every later Well call in the same conversation.
newly_connectedNoTools that connected to this workspace since the last result and that no session was told about yet, oldest first. Present only when at least one tool is new. The connected-line rule says when to tell an entry; when it does, one line per entry, in the person's language: "<name> is connected.". Never fold several entries into one sentence. Each entry comes back once, on one result only: never repeat its line later.
conversation_id_noteNoPresent only when the server opened a fresh lane, stating that no choice recorded earlier was read.
conversation_id_sourceNoWhere the conversation id came from: the host's own request meta, the caller's argument, or a fresh lane the server opened.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedOutput schema / properties / routine_offer
      Added value: +{
      +  "anyOf": [
      +    {
      +      "additionalProperties": false,
      +      "properties": {
      +        "routine_key": {
      +          "enum": [
      +            "qonto_receipt_export",
      +            "pennylane_receipt_export",
      +            "qonto_cash_flow_category_export"
      +          ],
      +          "type": "string"
      +        },
      +        "workspace_connector_id": {
      +          "type": "string"
      +        }
      +      },
      +      "required": [
      +        "routine_key",
      +        "workspace_connector_id"
      +      ],
      +      "type": "object"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ]
      +}
  2. Changed2 schema fields changed
    • changedOutput schema / properties / receipt / anyOf
      Previous value: -[
      -  {
      -    "additionalProperties": false,
      -    "properties": {
      -      "amount": {
      -        "anyOf": [
      -          {
      -            "type": "number"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ]
      -      },
      -      "currency": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ]
      -      },
      -      "date": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ]
      -      },
      -      "invoice_id": {
      -        "type": "string"
      -      },
      -      "supplier": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ]
      -      }
      -    },
      -    "required": [
      -      "invoice_id",
      -      "supplier",
      -      "amount",
      -      "currency",
      -      "date"
      -    ],
      -    "type": "object"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "additionalProperties": false,
      +    "properties": {
      +      "amount": {
      +        "type": [
      +          "number",
      +          "null"
      +        ]
      +      },
      +      "currency": {
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      },
      +      "date": {
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      },
      +      "invoice_id": {
      +        "type": "string"
      +      },
      +      "supplier": {
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      }
      +    },
      +    "required": [
      +      "invoice_id",
      +      "supplier",
      +      "amount",
      +      "currency",
      +      "date"
      +    ],
      +    "type": "object"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • changedOutput schema / properties / transaction / anyOf
      Previous value: -[
      -  {
      -    "additionalProperties": false,
      -    "properties": {
      -      "amount": {
      -        "anyOf": [
      -          {
      -            "type": "number"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ]
      -      },
      -      "currency": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ]
      -      },
      -      "date": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ]
      -      },
      -      "label": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ]
      -      },
      -      "paid_from": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ]
      -      },
      -      "time": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ]
      -      },
      -      "transaction_id": {
      -        "type": "string"
      -      },
      -      "workspace": {
      -        "additionalProperties": false,
      -        "properties": {
      -          "name": {
      -            "type": "string"
      -          },
      -          "workspace_id": {
      -            "type": "string"
      -          }
      -        },
      -        "required": [
      -          "workspace_id",
      -          "name"
      -        ],
      -        "type": "object"
      -      }
      -    },
      -    "required": [
      -      "transaction_id",
      -      "date",
      -      "amount",
      -      "currency",
      -      "label"
      -    ],
      -    "type": "object"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "additionalProperties": false,
      +    "properties": {
      +      "amount": {
      +        "type": [
      +          "number",
      +          "null"
      +        ]
      +      },
      +      "currency": {
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      },
      +      "date": {
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      },
      +      "label": {
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      },
      +      "paid_from": {
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      },
      +      "time": {
      +        "type": [
      +          "string",
      +          "null"
      +        ]
      +      },
      +      "transaction_id": {
      +        "type": "string"
      +      },
      +      "workspace": {
      +        "additionalProperties": false,
      +        "properties": {
      +          "name": {
      +            "type": "string"
      +          },
      +          "workspace_id": {
      +            "type": "string"
      +          }
      +        },
      +        "required": [
      +          "workspace_id",
      +          "name"
      +        ],
      +        "type": "object"
      +      }
      +    },
      +    "required": [
      +      "transaction_id",
      +      "date",
      +      "amount",
      +      "currency",
      +      "label"
      +    ],
      +    "type": "object"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
  3. Changed1 schema field changed
    • changedOutput schema / properties / transaction / anyOf
      Previous value: -[
      -  {
      -    "additionalProperties": false,
      -    "properties": {
      -      "amount": {
      -        "anyOf": [
      -          {
      -            "type": "number"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ]
      -      },
      -      "currency": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ]
      -      },
      -      "date": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ]
      -      },
      -      "label": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ]
      -      },
      -      "paid_from": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ]
      -      },
      -      "time": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ]
      -      },
      -      "transaction_id": {
      -        "type": "string"
      -      }
      -    },
      -    "required": [
      -      "transaction_id",
      -      "date",
      -      "amount",
      -      "currency",
      -      "label"
      -    ],
      -    "type": "object"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]New value: +[
      +  {
      +    "additionalProperties": false,
      +    "properties": {
      +      "amount": {
      +        "anyOf": [
      +          {
      +            "type": "number"
      +          },
      +          {
      +            "type": "null"
      +          }
      +        ]
      +      },
      +      "currency": {
      +        "anyOf": [
      +          {
      +            "type": "string"
      +          },
      +          {
      +            "type": "null"
      +          }
      +        ]
      +      },
      +      "date": {
      +        "anyOf": [
      +          {
      +            "type": "string"
      +          },
      +          {
      +            "type": "null"
      +          }
      +        ]
      +      },
      +      "label": {
      +        "anyOf": [
      +          {
      +            "type": "string"
      +          },
      +          {
      +            "type": "null"
      +          }
      +        ]
      +      },
      +      "paid_from": {
      +        "anyOf": [
      +          {
      +            "type": "string"
      +          },
      +          {
      +            "type": "null"
      +          }
      +        ]
      +      },
      +      "time": {
      +        "anyOf": [
      +          {
      +            "type": "string"
      +          },
      +          {
      +            "type": "null"
      +          }
      +        ]
      +      },
      +      "transaction_id": {
      +        "type": "string"
      +      },
      +      "workspace": {
      +        "additionalProperties": false,
      +        "properties": {
      +          "name": {
      +            "type": "string"
      +          },
      +          "workspace_id": {
      +            "type": "string"
      +          }
      +        },
      +        "required": [
      +          "workspace_id",
      +          "name"
      +        ],
      +        "type": "object"
      +      }
      +    },
      +    "required": [
      +      "transaction_id",
      +      "date",
      +      "amount",
      +      "currency",
      +      "label"
      +    ],
      +    "type": "object"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
  4. Changed1 schema field changed
    • changedOutput schema / properties / newly_connected / description
      Previous value: -"Tools that connected to this workspace since the last result and that no session was told about yet, oldest first. Present only when at least one tool is new. Start the reply with one line per entry, in the person's language: \"<name> is connected.\". Never fold several entries into one sentence. Each entry comes back once, on one result only: never repeat its line later."New value: +"Tools that connected to this workspace since the last result and that no session was told about yet, oldest first. Present only when at least one tool is new. The connected-line rule says when to tell an entry; when it does, one line per entry, in the person's language: \"<name> is connected.\". Never fold several entries into one sentence. Each entry comes back once, on one result only: never repeat its line later."
  5. Changed1 schema field changed
    • addedInput schema / properties / workspace_scope
      Added value: +{
      +  "description": "Restrict this call to the family: the token's primary workspace plus the company workspaces under it that you are a member of. Unrelated authorized workspaces drop out of the read; row reads merge across the family, while a per-workspace figure still reports exactly one workspace.",
      +  "enum": [
      +    "family"
      +  ],
      +  "type": "string"
      +}
  6. Changed1 schema field changed
    • addedOutput schema / properties / newly_connected
      Added value: +{
      +  "description": "Tools that connected to this workspace since the last result and that no session was told about yet, oldest first. Present only when at least one tool is new. Start the reply with one line per entry, in the person's language: \"<name> is connected.\". Never fold several entries into one sentence. Each entry comes back once, on one result only: never repeat its line later.",
      +  "items": {
      +    "additionalProperties": false,
      +    "properties": {
      +      "name": {
      +        "type": "string"
      +      },
      +      "service_id": {
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "name",
      +      "service_id"
      +    ],
      +    "type": "object"
      +  },
      +  "type": "array"
      +}
  7. Added

TDQS

A4.8/5.0
Behavior5/5

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

Far exceeds the annotations (readOnly=false, idempotent=true, destructive=false) by disclosing durable precedence ('A later automatic match never replaces it'), the full outcome set, every refusal reason with recovery behavior, and the write scope ('It writes only inside Well'). This is the behavioral context an agent cannot recover from structured fields.

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 purpose and consent rules, then organizes outcomes and refusal reasons as scannable bullets, so every section maps to a decision the agent must make. It is long, but the length is justified by the many distinct outcome branches; only the routine_offer paragraph is dense enough to risk skimming.

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?

Despite an output schema existing, the description still spells out how to interpret `outcome`, each refusal `reason`, retry behavior, and the `routine_offer` follow-up, plus the workspace note. An agent has everything needed to call, interpret, and follow up correctly.

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 baseline is 3, but the description adds provenance meaning beyond the schema: `document_id` comes from the candidate list and `transaction_id` is 'the payment the member picked by its number', reinforcing the two required IDs. It does not elaborate on the optional `workspace_id`/`workspace_scope` beyond what the schema already documents.

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 ('Attach a stored receipt to the payment the member picked from `well_list_receipt_candidates`') and explicitly ties the input to a named sibling tool. An agent can immediately tell this is the write that follows a candidate listing, distinct from the listing itself.

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 preconditions ('only after the member answered the numbered list...'), clarifies consent semantics ('The member's answer is the consent: do not ask again'), and states clear exclusions ('Never call it on your own guess, and never for the last choice'). When-to-call, when-not-to-call, and the upstream alternative are all named.

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