Skip to main content
Glama

CAM / operating expense reconciliation

calc_cam_reconciliation
Read-onlyIdempotent

Reconcile a tenant's annual CAM charge: exclusions, occupancy gross-up of variable expenses, pro rata share, controllable-expense caps (compounding_from_base, simple_from_base, year_over_year), an admin fee (before or after the cap, inside or outside it, with per-line exclusions), base year or expense stop, partial-year occupancy (move-in/move-out prorates share, cap, and base by days), and estimates paid. Returns balance due and a full trace with order-of-operations warnings. Deterministic: the same inputs always give the same result, with formula ID calc.cam_reconciliation@2, every step, and any warnings.

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": {
      "year": "<year>",
      "pro_rata_share": "<pro_rata_share>",
      "expenses": "<expenses>"
    },
    "name": "calc_cam_reconciliation"
  }
}

Input Schema

NameRequiredDescriptionDefault
capNoCap on the tenant's share of controllable expenses. Omit if the lease has no cap.
yearYesCalendar or lease year being reconciled.
expensesYesBuilding operating expense lines for the year.
gross_upNoGross up variable expenses to the target occupancy when actual occupancy is lower. Omit if the lease has no gross-up.
admin_feeNoAdministrative fee the lease adds to the tenant's share. Omit if the lease has none.
occupancyNoPartial-year occupancy: the tenant's share, cap limit, and base-year or stop deduction are prorated by occupied days ÷ period days (both inclusive), so a full-year cap and base are not applied to a part year. Omit for a full year.
structureNoExpense structure from the lease. Default: net.
estimates_paidNoEstimated CAM payments the tenant made during the year, USD (total for the year, not monthly).
pro_rata_shareYesTenant's pro rata share, 0 < share ≤ 1 (e.g. 12,000 / 150,000 = 0.08). Must be greater than 0.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed20 schema fields changed
    • changedInput schema / properties / admin_fee / properties / rate / description
      Previous value: -"Administrative or management fee as a decimal of the fee base, e.g. 0.15 for 15%. The base is the tenant's share of recoverable lines with admin_fee_applies (after gross-up)."New value: +"Administrative or management fee as a decimal of the fee base, e.g. 0.15 for 15%. The base is the tenant's share of recoverable lines with admin_fee_applies (after gross-up). Must be greater than -1. Must be less than 10."
    • removedInput schema / properties / admin_fee / properties / rate / exclusiveMaximum
      Removed value: -10
    • removedInput schema / properties / admin_fee / properties / rate / exclusiveMinimum
      Removed value: --1
    • addedInput schema / properties / admin_fee / properties / rate / maximum
      Added value: +10
    • addedInput schema / properties / admin_fee / properties / rate / minimum
      Added value: +-1
    • changedInput schema / properties / cap / properties / rate / description
      Previous value: -"Annual cap as a decimal, e.g. 0.05."New value: +"Annual cap as a decimal, e.g. 0.05. Must be greater than -1. Must be less than 10."
    • removedInput schema / properties / cap / properties / rate / exclusiveMaximum
      Removed value: -10
    • removedInput schema / properties / cap / properties / rate / exclusiveMinimum
      Removed value: --1
    • addedInput schema / properties / cap / properties / rate / maximum
      Added value: +10
    • addedInput schema / properties / cap / properties / rate / minimum
      Added value: +-1
    • removedInput schema / properties / cap / properties / years_elapsed / maximum
      Removed value: -9007199254740991
    • changedInput schema / properties / gross_up / properties / actual_occupancy / description
      Previous value: -"Average occupancy for the year, e.g. 0.82."New value: +"Average occupancy for the year, e.g. 0.82. Must be greater than 0."
    • removedInput schema / properties / gross_up / properties / actual_occupancy / exclusiveMinimum
      Removed value: -0
    • addedInput schema / properties / gross_up / properties / actual_occupancy / minimum
      Added value: +0
    • changedInput schema / properties / gross_up / properties / target_occupancy / description
      Previous value: -"Gross-up occupancy stated in the lease (commonly 0.95 or 1.0)."New value: +"Gross-up occupancy stated in the lease (commonly 0.95 or 1.0). Must be greater than 0."
    • removedInput schema / properties / gross_up / properties / target_occupancy / exclusiveMinimum
      Removed value: -0
    • addedInput schema / properties / gross_up / properties / target_occupancy / minimum
      Added value: +0
    • changedInput schema / properties / pro_rata_share / description
      Previous value: -"Tenant's pro rata share, 0 < share ≤ 1 (e.g. 12,000 / 150,000 = 0.08)."New value: +"Tenant's pro rata share, 0 < share ≤ 1 (e.g. 12,000 / 150,000 = 0.08). Must be greater than 0."
    • removedInput schema / properties / pro_rata_share / exclusiveMinimum
      Removed value: -0
    • addedInput schema / properties / pro_rata_share / minimum
      Added value: +0
  2. Changed2 schema fields changed
    • changedInput schema / properties / expenses / items / properties / controllable / description
      Previous value: -"Subject to the cap. Taxes, insurance, and utilities are typically uncontrollable."New value: +"Subject to the cap. Taxes, insurance, and utilities are typically uncontrollable. Default true; under a cap, lines left unset are named in warnings."
    • changedInput schema / properties / expenses / items / properties / variable / description
      Previous value: -"Varies with occupancy, so eligible for gross-up (janitorial, utilities, management fee)."New value: +"Varies with occupancy, so eligible for gross-up (janitorial, utilities, management fee). Default false; with a gross-up, lines left unset are named in warnings."
  3. Changed3 schema fields changed
    • addedInput schema / properties / admin_fee
      Added value: +{
      +  "description": "Administrative fee the lease adds to the tenant's share. Omit if the lease has none.",
      +  "properties": {
      +    "applied": {
      +      "default": "after_cap",
      +      "description": "Fee on controllable lines computed on the tenant's share before the cap (before_cap) or on the capped amount (after_cap). Fees on uncontrollable lines are never capped. Irrelevant without a cap.",
      +      "enum": [
      +        "before_cap",
      +        "after_cap"
      +      ],
      +      "type": "string"
      +    },
      +    "capped": {
      +      "default": false,
      +      "description": "True when the fee on controllable lines counts toward the controllable cap (controllable share plus fee may not exceed the cap limit); false adds it outside the cap.",
      +      "type": "boolean"
      +    },
      +    "rate": {
      +      "description": "Administrative or management fee as a decimal of the fee base, e.g. 0.15 for 15%. The base is the tenant's share of recoverable lines with admin_fee_applies (after gross-up).",
      +      "exclusiveMaximum": 10,
      +      "exclusiveMinimum": -1,
      +      "type": "number"
      +    }
      +  },
      +  "required": [
      +    "rate"
      +  ],
      +  "type": "object"
      +}
    • addedInput schema / properties / expenses / items / properties / admin_fee_applies
      Added value: +{
      +  "default": true,
      +  "description": "Included in the admin_fee base. Set false for lines the lease excludes from the fee (often taxes, insurance, utilities, or a management fee already charged).",
      +  "type": "boolean"
      +}
    • addedInput schema / properties / occupancy
      Added value: +{
      +  "description": "Partial-year occupancy: the tenant's share, cap limit, and base-year or stop deduction are prorated by occupied days ÷ period days (both inclusive), so a full-year cap and base are not applied to a part year. Omit for a full year.",
      +  "properties": {
      +    "move_in_date": {
      +      "description": "Date the tenant's share starts within the reconciliation period, YYYY-MM-DD (inclusive). Defaults to period_start_date.",
      +      "format": "date",
      +      "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
      +      "type": "string"
      +    },
      +    "move_out_date": {
      +      "description": "Last day of the tenant's share within the period, YYYY-MM-DD (inclusive). Defaults to period_end_date.",
      +      "format": "date",
      +      "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
      +      "type": "string"
      +    },
      +    "period_end_date": {
      +      "description": "Last day of the reconciliation period, YYYY-MM-DD (at most 366 days after the start). Defaults to December 31 of year.",
      +      "format": "date",
      +      "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
      +      "type": "string"
      +    },
      +    "period_start_date": {
      +      "description": "First day of the reconciliation period, YYYY-MM-DD. Defaults to January 1 of year; set it for a lease year.",
      +      "format": "date",
      +      "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
      +      "type": "string"
      +    }
      +  },
      +  "type": "object"
      +}
  4. First observed

TDQS

A3.7/5.0
Behavior4/5

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

Annotations already cover the safety profile (readOnly, idempotent, non-destructive, closed-world), and the description adds real value beyond them: determinism guarantee, the formula ID calc.cam_reconciliation@2, that it returns balance due plus a full step trace, and that it emits order-of-operations warnings. It does not mention permission/auth requirements or any size limits on expense lines.

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-loaded with the action and resource, then a dense but purposeful feature list, then return behavior and the determinism guarantee. The long middle clause is information-bearing for capability matching rather than filler, though it partially duplicates schema content.

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?

For a 9-parameter, deeply nested calculation tool with no output schema, the description still tells the agent what comes back (balance due, trace, warnings) and that the computation is deterministic and repeatable via a formula ID. Remaining gaps — currency/units conventions, error behavior on invalid cap method combinations — are minor and largely covered by the schema.

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 the baseline is 3. The description restates the cap methods and admin-fee placement options that are already fully documented in the schema enums and field descriptions, adding no syntax, unit, or edge-case detail beyond it.

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?

Opens with a specific verb+resource ("Reconcile a tenant's annual CAM charge") and enumerates the computations covered, so an agent knows exactly what domain this tool handles. It stops short of naming why it exists alongside the near-identical siblings calc_reconcile_cam and calc_cam_reconciliation_batch, leaving the single-vs-batch split to inference.

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 by the domain (a CAM reconciliation). There is no explicit when-to-use, no prerequisites (e.g. lease must be NNN or gross-with-stop), and no named alternative for batch runs or for when the lease omits a cap/gross-up — though the schema itself says "omit" for optional blocks.

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.