Skip to main content
Glama

More AI - ChatGPT & Claude MCP (Fortnox)

Resultaträkning

get_profit_and_loss
Read-onlyIdempotent

Profit and loss statement: income and expenses per account class for the financial year, a month, a quarter or another period of whole months, compared with the same period the year before. Use when the person asks for the income statement or how a period went. period takes YYYY-MM, YYYY-Qn or YYYY. Example question: "Visa resultaträkningen för mars. Hur gick kvartal 3 jämfört med i fjol?" Read-only; computed on the server from live Fortnox data over all pages (Fortnox API, https://api.fortnox.se/apidocs).

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "get_profit_and_loss"
  }
}

Input Schema

NameRequiredDescriptionDefault
dateNoÅÅÅÅ-MM-DD för att välja år Date as YYYY-MM-DD unless the text allows more.
periodNoen månad "2026-03", ett kvartal "2026-Q3" eller ett kalenderår "2026"; utelämnad = hela räkenskapsåret YYYY-MM, YYYY-Qn or YYYY.
todateNoÅÅÅÅ-MM eller ÅÅÅÅ-MM-DD: periodens slut Date as YYYY-MM-DD unless the text allows more.
fromdateNoÅÅÅÅ-MM eller ÅÅÅÅ-MM-DD: periodens början (räknas i hela månader) Date as YYYY-MM-DD unless the text allows more.
financialyearNoräkenskapsårets id; standard det som innehåller i dag Number.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed6 schema fields changed
    • changedInput schema / properties / date / description
      Previous value: -"ÅÅÅÅ-MM-DD för att välja år"New value: +"ÅÅÅÅ-MM-DD för att välja år Date as YYYY-MM-DD unless the text allows more."
    • changedInput schema / properties / financialyear / description
      Previous value: -"räkenskapsårets id; standard det som innehåller i dag"New value: +"räkenskapsårets id; standard det som innehåller i dag Number."
    • changedInput schema / properties / financialyear / type
      Previous value: -[
      -  "string",
      -  "number"
      -]New value: +[
      +  "number",
      +  "string"
      +]
    • changedInput schema / properties / fromdate / description
      Previous value: -"ÅÅÅÅ-MM eller ÅÅÅÅ-MM-DD: periodens början (räknas i hela månader)"New value: +"ÅÅÅÅ-MM eller ÅÅÅÅ-MM-DD: periodens början (räknas i hela månader) Date as YYYY-MM-DD unless the text allows more."
    • changedInput schema / properties / period / description
      Previous value: -"en månad \"2026-03\", ett kvartal \"2026-Q3\" eller ett kalenderår \"2026\"; utelämnad = hela räkenskapsåret"New value: +"en månad \"2026-03\", ett kvartal \"2026-Q3\" eller ett kalenderår \"2026\"; utelämnad = hela räkenskapsåret YYYY-MM, YYYY-Qn or YYYY."
    • changedInput schema / properties / todate / description
      Previous value: -"ÅÅÅÅ-MM eller ÅÅÅÅ-MM-DD: periodens slut"New value: +"ÅÅÅÅ-MM eller ÅÅÅÅ-MM-DD: periodens slut Date as YYYY-MM-DD unless the text allows more."
  2. Added

TDQS

A3.9/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint, destructiveHint=false and openWorldHint=false, so safety is covered. The description adds genuinely new behavioral context: the figures are computed server-side from live Fortnox data and aggregated across all pages, and results are compared against the same period the prior year. It does not mention latency or whether the prior-year comparison can be suppressed.

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 core definition and the usage cue are front-loaded in the first two sentences, and the example questions earn their space by showing natural-language triggers and the year-over-year intent. The period-format clause and the API/URL citation are somewhat redundant with the schema and annotations, adding mild bloat.

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 an output schema present, the description needn't explain return shape, and it does cover source, freshness and comparison semantics, which is the right allocation of effort. What remains thin is the interaction between period, fromdate/todate and financialyear — the description notes whole-month granularity but not which parameter wins when several are supplied.

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 (date, period, fromdate, todate, financialyear) is already documented, including the YYYY-MM / YYYY-Qn / YYYY formats. The description repeats those formats rather than adding meaning, and it does not clarify how fromdate/todate interact with period or with the default financial year. Baseline 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 gives a specific verb/resource pair (profit and loss statement: income and expenses per account class) plus the supported period granularities and a year-over-year comparison. That is far more precise than the Swedish title 'Resultaträkning' alone. It stops short of explicitly distinguishing itself from close siblings such as get_balance_sheet or get_monthly_result, so an agent must infer the boundary.

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?

'Use when the person asks for the income statement or how a period went' gives a clear triggering intent, reinforced by two concrete example questions in Swedish covering both a single month and a quarter-vs-last-year comparison. There are no when-not-to-use exclusions or named alternatives, which keeps it from a 5.

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