Skip to main content
Glama

Create itinerary item

segment_create

Create a new segment in a trip. FIRST call segment_get_schema to get the required fields for the segment type. Required in fields, besides trip_id: Flight airline (or a flightNumber starting with the airline code, e.g. UA 123), departureAirportCode, arrivalAirportCode, startDateTime; Lodging propertyName, startDateTime; Activity title, startDateTime; EventTicket eventName, startDateTime; CarRental rentalCompany, startDateTime; Train and Ferry operator, departureCity, arrivalCity, startDateTime; Transfer provider, pickupLocation, dropoffLocation, startDateTime; Parking facilityName, startDateTime; Note title; Poll title, options. Then provide the trip_id, segment_type, and fields matching the schema. Segment dates must fall within the parent trip dates. Dates up to 1 day outside the trip extend it, with a warning; further out, call trip_update first. For an Activity, Lodging, EventTicket or Parking at a real place, call places_search first and put the result's place ID in fields.placeId: Tineo links that place (map pin and coordinates) and fills a missing name, address, phone and website. Never invent a time: if the user has not given or chosen one, ask, or send the date only (YYYY-MM-DD) in startDateTime and Tineo stores it as time not set. Send a clock time only when the user stated it or a booking shows it. For commercial cruise reservations and sea/port days use cruise_* tools. Never substitute Activity, CruiseActivity or another segment type for a cruise day. Ordinary shore excursions remain valid Activity/CruiseActivity. If cruise tools are unavailable explain the limitation and ask for clarification. Cruise/CruiseDay generic writes require the dedicated cruise tools; their schemas and full reads remain available.

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": {
      "trip_id": "<trip_id>"
    },
    "name": "segment_create"
  }
}

Input Schema

NameRequiredDescriptionDefault
fieldsNoField values matching the schema for the segment type. Get schema first with segment_get_schema. Activity activityType is one of: tour, dining, show, spa, class, sports, sightseeing, other (other words are mapped or saved as other). title is optional for Flight, Lodging, Transfer, CarRental and Parking: Tineo derives one (e.g. "AA72 SYD → LAX", the property name, "Transfer to <dropoff>").
trip_idYesThe trip ID to add the segment to
segment_typeNoThe type of segment to create (Flight, Lodging, CarRental, Train, Transfer, Ferry, EventTicket, Parking, Activity, Note, Poll)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / fields / description
      Previous value: -"Field values matching the schema for the segment type. Get schema first with segment_get_schema."New value: +"Field values matching the schema for the segment type. Get schema first with segment_get_schema. Activity activityType is one of: tour, dining, show, spa, class, sports, sightseeing, other (other words are mapped or saved as other). title is optional for Flight, Lodging, Transfer, CarRental and Parking: Tineo derives one (e.g. \"AA72 SYD → LAX\", the property name, \"Transfer to <dropoff>\")."
  2. 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 readOnlyHint=false, destructiveHint=false and idempotentHint=false, so the basic mutation profile is covered. The description adds genuinely useful behavior beyond that: dates within one day of the trip extend it with a warning, placeId triggers place linking and auto-fills name/address/phone/website, and a date-only startDateTime is stored as 'time not set'. It does not say what the response looks like or what happens on partial field failures, which is a real gap for a creation tool.

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 most important instruction (call segment_get_schema first) is front-loaded and nothing is clearly filler, but the body is a dense wall of semicolon-separated clauses spanning several unrelated concerns (per-type fields, date bounds, place linking, time rules, cruise exclusions). A short bulleted structure would make it easier to scan without adding length.

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 a free-form nested 'fields' object, no output schema, and cross-tool dependencies, the description covers prerequisites, per-type requirements, validation constraints, and escalation paths. An agent has everything needed to call it correctly without guessing.

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 coverage is 100%, so the baseline would be 3, but the description goes far beyond the schema by listing the required fields per segment type (e.g. Flight needs departureAirportCode, arrivalAirportCode, startDateTime; Poll needs title and options). The schema only says 'fields: object', so this per-type detail is substantial added meaning that an agent cannot get from structured data.

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 and resource: 'Create a new segment in a trip.' It then enumerates the segment types (Flight, Lodging, CarRental, Train, Transfer, Ferry, EventTicket, Parking, Activity, Note, Poll) and distinguishes itself from the cruise_* tools and segment_get_schema, so an agent can identify it without opening the schema.

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 explicit ordering ('FIRST call segment_get_schema'), a conditional prerequisite for places_search when a real place is involved, and a fallback to trip_update when dates fall more than a day outside the trip. It also names the sibling tools to use instead for cruise reservations and states what to do if those tools are unavailable.

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