Skip to main content
Glama

calculate_trip_price

Read-onlyIdempotent

Live checkout quote for a configuration. Not a booking. Call before create_booking and before telling the student a final price.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
localeNoResponse language and site context. One of en, nl, da, sv.
trip_idNoOptional saved trip id; when set, the quote may be stored on that trip.
currencyNoISO 4217 currency for prices in this call. Usually EUR.EUR
school_idNoCraft CMS school entry id from search_language_schools hits (field school_id). Not the CRM UUID.
country_codeNoVisitor country ISO 3166-1 alpha-2 (e.g. NL). Affects fee display where applicable.
discountCodeNoOptional promotion or discount code.
configurationNoSame shape as the Extralingo school-page configurator: startDate (YYYY-MM-DD), students[] with courseId, weeks, optional accommodationGroupId, mealType, extras.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
dataNoFull pricing breakdown from the booking engine.
quoteNoHuman-oriented price summary.
successYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed14 schema fields changed
    • addedInput schema / properties / configuration / additionalProperties
      Added value: +true
    • changedInput schema / properties / configuration / description
      Previous value: -"Same shape as the V2 school-page configurator: startDate, students[].courseId, weeks, accommodationGroupId, mealType, extras."New value: +"Same shape as the Extralingo school-page configurator: startDate (YYYY-MM-DD), students[] with courseId, weeks, optional accommodationGroupId, mealType, extras."
    • addedInput schema / properties / configuration / properties
      Added value: +{
      +  "accommodationGroupId": {
      +    "description": "Accommodation group id from list_accommodations (optional).",
      +    "type": "string"
      +  },
      +  "mealType": {
      +    "description": "Meal plan key when accommodation is selected.",
      +    "type": "string"
      +  },
      +  "startDate": {
      +    "description": "Course start calendar date (YYYY-MM-DD). Typically a Monday from list_starting_dates.",
      +    "examples": [
      +      "2026-09-07"
      +    ],
      +    "type": "string"
      +  },
      +  "students": {
      +    "description": "One object per traveller. courseId comes from list_courses.",
      +    "items": {
      +      "additionalProperties": true,
      +      "properties": {
      +        "courseId": {
      +          "description": "Course product id from list_courses for this school.",
      +          "type": "string"
      +        },
      +        "weeks": {
      +          "description": "Course duration in weeks.",
      +          "minimum": 1,
      +          "type": "integer"
      +        }
      +      },
      +      "type": "object"
      +    },
      +    "type": "array"
      +  }
      +}
    • addedInput schema / properties / country_code / description
      Added value: +"Visitor country ISO 3166-1 alpha-2 (e.g. NL). Affects fee display where applicable."
    • addedInput schema / properties / country_code / examples
      Added value: +[
      +  "NL",
      +  "DE"
      +]
    • addedInput schema / properties / currency / description
      Added value: +"ISO 4217 currency for prices in this call. Usually EUR."
    • addedInput schema / properties / currency / examples
      Added value: +[
      +  "EUR"
      +]
    • addedInput schema / properties / discountCode / description
      Added value: +"Optional promotion or discount code."
    • addedInput schema / properties / locale / description
      Added value: +"Response language and site context. One of en, nl, da, sv."
    • addedInput schema / properties / locale / examples
      Added value: +[
      +  "en",
      +  "nl",
      +  "da",
      +  "sv"
      +]
    • addedInput schema / properties / school_id / description
      Added value: +"Craft CMS school entry id from search_language_schools hits (field school_id). Not the CRM UUID."
    • addedInput schema / properties / school_id / examples
      Added value: +[
      +  12345
      +]
    • addedInput schema / properties / trip_id / description
      Added value: +"Optional saved trip id; when set, the quote may be stored on that trip."
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "additionalProperties": true,
      +  "properties": {
      +    "data": {
      +      "additionalProperties": true,
      +      "description": "Full pricing breakdown from the booking engine.",
      +      "type": "object"
      +    },
      +    "quote": {
      +      "additionalProperties": true,
      +      "description": "Human-oriented price summary.",
      +      "type": "object"
      +    },
      +    "success": {
      +      "const": true
      +    }
      +  },
      +  "required": [
      +    "success"
      +  ],
      +  "type": "object"
      +}
  2. First observed

TDQS

A3.8/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, idempotentHint=true, and destructiveHint=false, so the safety profile is covered. The description usefully reinforces that this is not a booking, but adds no detail on rate limits, auth, or the fact that a quote may be persisted when trip_id is supplied (which sits in the schema, not the description).

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

Conciseness5/5

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

Three short, front-loaded sentences with zero filler; the disambiguation and the ordering constraint are stated immediately and nothing is redundant.

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 a rich nested input schema and an existing output schema, the description need not explain returns or fields. It supplies the workflow context an agent needs; only a note on quote persistence/rate behavior would improve it further.

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 including the nested configuration is already documented in the schema. The description adds no parameter-level meaning beyond the word 'configuration,' so the baseline 3 is appropriate.

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 states a specific operation (a live checkout quote for a configuration) and explicitly distinguishes itself from create_booking with 'Not a booking.' It clarifies scope and non-mutation, though the word 'quote' alone leaves slight ambiguity about whether it computes prices or retrieves a previously stored one.

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?

It gives concrete sequencing guidance: call before create_booking and before quoting a final price to the student. That is strong context, but it does not mention an alternative for non-live/exploratory pricing or reference siblings like request_quote.

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