Skip to main content
Glama

Avyttra anläggningstillgång

dispose_fixed_asset
Destructive

Sälj eller utrangera en anläggningstillgång: bokför bort anskaffningsvärdet och den ackumulerade avskrivning som faktiskt är bokförd för tillgången t.o.m. avyttringsdagen (ack.-kontot för tillgången blir 0), tar in köpeskillingen, bokför utgående moms och redovisar vinst/förlust mot bokfört värde. Tillgången slutar skrivas av. Ej bokförd avskrivning blir en del av vinsten/förlusten: bokför avskrivning t.o.m. avyttringsmånaden FÖRST om den ska redovisas som avskrivning (svaret visar calculation.unbooked_depreciation_ore). Kräver behörigheten 'book'. Argument: orgnr, asset_id, disposal_date (YYYY-MM-DD); valfritt proceeds_ore (köpeskilling INKLUSIVE moms, det som betalas in; 0 = utrangering), vat_rate (momssats i procent: 25, 12, 6 eller 0; standard 25 för inventarier och övrigt, 0 för byggnad och mark; ange 0 när försäljningen är momsfri, t.ex. en personbil som köptes utan avdrag för moms), proceeds_account (default 1930), gain_account (default 3973), loss_account (default 7973), note, book (default true, sätt false för att bara registrera avyttringen utan verifikat), confirm. Finns avskrivning t.o.m. avyttringsdagen som inte är bokförd nekas anropet med beloppet: bokför avskrivningen först (post_depreciation), eller anropa igen med confirm=true om användaren vill att den ingår i vinsten/förlusten.

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": {
      "orgnr": "<orgnr>",
      "asset_id": "<asset_id>",
      "disposal_date": "<disposal_date>"
    },
    "name": "dispose_fixed_asset"
  }
}

Input Schema

NameRequiredDescriptionDefault
bookNo
noteNo
orgnrYesBolagets organisationsnummer, 10 siffror med eller utan bindestreck, t.ex. 559900-1004. Hämta med list_companies.
confirmNo
asset_idYes
vat_rateNo
gain_accountNo
loss_accountNo
proceeds_oreNo
disposal_dateYes
proceeds_accountNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / confirm
      Added value: +{
      +  "default": false,
      +  "title": "Confirm",
      +  "type": "boolean"
      +}
  2. Changed1 schema field changed
    • addedInput schema / properties / vat_rate
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "integer"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Vat Rate"
      +}
  3. Changed1 schema field changed
    • addedInput schema / properties / orgnr / description
      Added value: +"Bolagets organisationsnummer, 10 siffror med eller utan bindestreck, t.ex. 559900-1004. Hämta med list_companies."
  4. First observed

TDQS

A4.5/5.0
Behavior3/5

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

Annotations already declare destructiveHint=true, readOnlyHint=false, idempotentHint=false, so the safety profile is covered. The description still adds real value beyond them: the 'book' permission requirement, the refusal-with-amount behaviour, the confirm override, and the fact that unbooked depreciation ends up in the gain/loss unless booked separately. It does not, however, describe reversibility of a completed disposal or what the response body contains beyond calculation.unbooked_depreciation_ore.

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?

Purpose and effects are front-loaded in the first sentence and the operational caveat about unbooked depreciation is placed at the end. The text is dense with semicolon-chained clauses and repeats the confirm=true path twice (once in the parameter list, once at the end), which costs some clarity but each part still carries 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 an 11-parameter destructive mutation with no output schema, the description covers permissions, ledger accounts touched, VAT handling branches, refusal semantics, the confirm escape hatch, and even one field of the response (calculation.unbooked_depreciation_ore). An agent has everything needed to invoke it correctly on the first attempt.

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 only 9%, so the description carries almost the whole burden and does so: proceeds_ore is defined as gross proceeds including VAT with 0 meaning scrapping, vat_rate is given its allowed values (25/12/6/0) plus default and the building/land and VAT-exempt-vehicle exceptions, and the account parameters are listed with their defaults. Only 'note' is left unexplained, which is negligible for a free-text field.

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 description opens with a specific verb and resource ('Sälj eller utrangera en anläggningstillgång') and immediately spells out the accounting effect: derecognise acquisition cost and accumulated depreciation, record proceeds, output VAT, and book gain/loss against carrying value. It also states the post-condition ('Tillgången slutar skrivas av'), which makes it unmistakable against siblings like delete_fixed_asset or update_fixed_asset.

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?

It gives an explicit branch condition and names the alternative: if unbooked depreciation exists up to the disposal date, the call is refused and the agent should either run post_depreciation first or re-call with confirm=true. It also defines the two modes (sale vs. scrapping via proceeds_ore=0) so the agent knows which invocation shape to choose.

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.