Skip to main content
Glama

Prepare the micro-entrepreneur turnover declaration

well_prepare_micro_declaration

Prepare a French micro-entrepreneur's URSSAF turnover declaration for one period, as a draft PDF stored in the workspace: the turnover of each activity box from the bank receipts matched to issued invoices, and an estimate of what URSSAF will ask. Well fills the turnover on autoentrepreneur.urssaf.fr in the person's own Chrome; the person clicks Send and files it. This call declares, sends and pays nothing.

Call it when the person asks to prepare or file their URSSAF turnover declaration, after the period's turnover was read with well_get_micro_turnover and every payment with no invoice was answered. Pass no window for the next declaration due whose period has ended (when none is due yet, the latest period that has ended, whose due date has passed: say it is late), or from and to (YYYY-MM-01, to exclusive) for one declaration period. Before every fill, call it again: it reads the URSSAF rates again first.

Refusals, with no PDF:

  • profile_incomplete: the profile lacks the keys in missing (the URSSAF filing frequency, the legal form). Propose a value only from what a read returned, save it with well_upsert_accounting_settings on the person's yes, and call again.

  • not_owed: the profile is not a micro-entrepreneur's. not_a_period: the window is not one declaration period. period_not_ended: the period is still running.

  • already_filed: a draft of this period is already filed (document_id, filed_at). Never offer the fill: a second one would declare the period twice.

  • unsupported_jurisdiction (not France), unsupported_currency (books not in EUR), too_many_receipts (the period holds more receipts than one read takes), failed.

On ok, a period with no turnover is still a declaration: nil is true and each box reads « néant ». document_id names the PDF, the input of the browser fill. lines lists each declared box in whole euros; the fill types only these. estimate is what URSSAF will likely ask: URSSAF computes the amount itself, so say it is an estimate, give estimate.total_euros, and say each estimate.gaps item in one clause (ACRE not asked, undated or ending inside the period, CIPAV not applied, CFP at the commercial rate, chamber fees left out, flat income tax option unknown, a rate with no value, receipts in another currency left out). Four gaps change the turnover itself; say each and ask the person to confirm the boxes before the fill: vat_share_assumed (some receipts have no known VAT share, so they count net of VAT at the standard 20 % rate), vat_regime_assumed_franchise (the profile states no VAT regime, so receipts with no invoice count in full, as in the VAT franchise: ask the VAT regime and save it with well_upsert_accounting_settings on the person's yes), bank_copy_not_fresh and no_bank_source (the receipts can be incomplete, and the fill waits). stale_sources lists each bank source that is not fresh enough: for an installation with syncable: true, call well_request_sync with its workspace_connector_id, then prepare again; with syncable: false it belongs to another workspace, so never request its sync and say the bank copy dates from synced_at; for a statement, say the statements stop at covered_to and ask for the statement that covers the rest of the period; for an uncovered_account, name the account and ask the person to connect its bank or send its statements. unsourced_receipts above zero means receipts came from a bank that is no longer connected or from no bank: say so. sources_truncated true means the period has more bank sources than one read lists. Either one holds the fill like a stale source. When estimate.total_euros is null, a rate is missing: say the amount is to be completed, never zero. rate_read: rule_changed means a URSSAF rate changed since the last draft of this period: say the new amount and ask again before the fill. read_failed means the rates could not be read: the fill waits until a later call reads them. Null means no box needed a rate. receipts_waiting above zero means payments still wait for the person's answer: ask about them before the fill. other_currency_receipts above zero means receipts in another currency than the euro are not in any box, because Well does not convert them: say so, and the fill waits. Never say the declaration is filed.

When the token authorizes one workspace, call this directly — no workspace call is needed first. When it authorizes several, this read will not guess which one you mean: pass workspace_id on the call.

Input Schema

NameRequiredDescriptionDefault
toNoEXCLUSIVE end: the first day of the month after the period, YYYY-MM-01.
fromNoFirst day of the period, YYYY-MM-01. Give it with `to`, or omit both for the next declaration due.
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.
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
nilNoTrue when every declared box is zero: the period is declared « néant ».
fileNo
errorNo
linesNo
periodNo
statusYes
missingNo
successYes
currencyNo
estimateNo
filed_atNoWhen the period's draft was filed, on an `already_filed` refusal.
filenameNo
rate_readNo
document_idNo
stale_sourcesNoThe bank sources not fresh enough for the period: the receipts can be incomplete, and the fill waits.
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.
receipts_waitingNo
sources_truncatedNoTrue when the period has more bank sources than one read lists: the fill waits.
unsigned_receiptsNo
browser_skill_slugNo
resolved_workspaceNoThe workspace that answered, when the caller named none and the token authorizes several.
unsourced_receiptsNoReceipts of the period that no listed bank source stands for: the fill waits while above zero.
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.
other_currency_receiptsNoReceipts in another currency than the euro, which no box counts: the fill waits while above zero.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedOutput schema / properties / missing / items / enum
      Previous value: -[
      -  "legal_form",
      -  "vat_regime",
      -  "vat_filing_frequency",
      -  "corporate_tax_regime",
      -  "fiscal_year_end",
      -  "urssaf_filing_frequency"
      -]New value: +[
      +  "legal_form",
      +  "vat_regime",
      +  "vat_filing_frequency",
      +  "corporate_tax_regime",
      +  "fiscal_year_end",
      +  "urssaf_filing_frequency",
      +  "payroll_contribution_payment_frequency"
      +]
  2. Changed16 schema fields changed
    • removedOutput schema / properties / browser_skill_slug / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / browser_skill_slug / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedOutput schema / properties / estimate / properties / lines / items / properties / rate / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / estimate / properties / lines / items / properties / rate / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedOutput schema / properties / resolved_workspace / properties / name / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / resolved_workspace / properties / name / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedOutput schema / properties / stale_sources / items / properties / account_id / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / stale_sources / items / properties / account_id / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedOutput schema / properties / stale_sources / items / properties / covered_to / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / stale_sources / items / properties / covered_to / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedOutput schema / properties / stale_sources / items / properties / name / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / stale_sources / items / properties / name / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedOutput schema / properties / stale_sources / items / properties / synced_at / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / stale_sources / items / properties / synced_at / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedOutput schema / properties / stale_sources / items / properties / workspace_connector_id / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / stale_sources / items / properties / workspace_connector_id / type
      Added value: +[
      +  "string",
      +  "null"
      +]
  3. Changed1 schema field changed
    • addedOutput schema / properties / browser_skill_slug
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ]
      +}
  4. Added

TDQS

A4.7/5.0
Behavior5/5

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

Far beyond the annotations it explains that only a draft PDF is produced, that a human clicks Send in their own Chrome, and that nothing is declared or paid. It enumerates refusal codes (`already_filed`, `not_a_period`, `period_not_ended`, `too_many_receipts`) and their consequences, plus staleness/truncation handling — consistent with destructiveHint=false and idempotentHint=false.

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

Conciseness3/5

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

The purpose and prerequisites are front-loaded, but the body is a dense multi-hundred-word wall that spends much of its length explaining output fields (`lines`, `estimate`, `rate_read`, `stale_sources`) despite an output schema existing. The refusal and gap enumerations are useful, yet several clauses could be compressed without losing decision-relevant information.

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 tool with six parameters, an output schema, and a complex multi-step conversation flow, the description covers invocation timing, re-invocation, every failure branch, what to tell the user, and which sibling to call next. Nothing an agent needs to call it safely appears to be missing.

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 parameters are already documented, but the description adds real semantics: the omitted-window default (next declaration due whose period has ended, else the latest ended period flagged late) and the `from`/`to` YYYY-MM-01 exclusive convention. It also explains the workspace_id rule tied to token scope, which the schema only partly covers.

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?

The first sentence states a specific verb, resource and scope: preparing a French micro-entrepreneur's URSSAF turnover declaration for one period as a draft PDF in the workspace. It explicitly distinguishes itself from filing/sending/paying ("This call declares, sends and pays nothing") and from the sibling read that precedes it (`well_get_micro_turnover`).

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 triggers ("when the person asks to prepare or file their URSSAF turnover declaration"), prerequisites (after `well_get_micro_turnover` and after unanswered payments are answered), and a re-invocation rule ("Before every fill, call it again"). It also names the pivot to `well_upsert_accounting_settings` and `well_request_sync` for specific branches, leaving little to inference.

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