Skip to main content
Glama

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
POLESTAR_LOGNoSet to debug for verbose stderr diagnostics.normal
POLESTAR_CACHENoSet to off to disable the response cache.on
POLESTAR_UNITSNoUse mi or miles for humanized distances.km
POLESTAR_BUDGETNoDaily live-call ceiling; fails closed at the limit.10000
POLESTAR_SAMPLENoSet to 1 to run the background sampler; off by default, polling spends quora.off
POLESTAR_SCOPESNoSpace- or comma-separated scope override for the token request.all domain scopes
POLESTAR_BASE_URLNoOverriede the API base URL.production URL
POLESTAR_ENV_FILENoAlternative dotenv path (default ~/.config/polestar-mcp/.env.secrets).
POLESTAR_CLIENT_IDNoOAuth client ID from the Data Portal.
POLESTAR_HTTP_HOSTNoHTTP bind address.127.0.0.1
POLESTAR_HTTP_PORTNo1 to 65535 switches to Streamable HTTP.0 (stdio)
POLESTAR_ACCOUNT_IDNoThe Account ID, sent as x-client-id (distinct from the client ID).
POLESTAR_HTTP_TOKENNoBearer token for HTTP mode; required off loopback.
POLESTAR_REDACT_VINNoSet to 1 to mask VINs in rendered output and the structured envelope. raw:true is exempt.off
POLESTAR_STRICT_ENVNoSet to 1 to make an unrecognized variable fatal.off
POLESTAR_TIMEOUT_MSNoHard deadline per HTTP request.15000
POLESTAR_HISTORY_DIRNoEnable the JSONL history store (and history tools) here.
POLESTAR_FIXTURES_DIRNoServe captured responses instead of the live API.
POLESTAR_CLIENT_SECRETNoOAuth client secret.
POLESTAR_ENABLE_WRITESNoScaffold for future write endpoints; registers nothing today.off
POLESTAR_ALLOW_LOCATIONNoSet to 0 to refuse location reads and strip coordinates.on
POLESTAR_VEHICLE_LABELSNoVIN=Name pairs shown instead of VINs.
POLESTAR_BUDGET_PER_MINUTENoRolling per-minute ceiling the API also publishes; waited out rather than failed, when the wait fits the deadline.100
POLESTAR_M2M_TOKEN_ENDPOINTNoOverride just the token endpoint.{base}/token
POLESTAR_DELEGATED_ACCOUNT_IDNoDefault delegated account for third-party credentials.
POLESTAR_DELEGATED_ACCOUNT_IDSNoAllowlist that a call's delegated_account_id argument is checked against.
POLESTAR_HISTORY_SAMPLE_SECONDSNoSeconds between sampler rounds (clamped 60 to 3600).600

Instructions

Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.

This server publishes no instructions, or was last inspected before Glama recorded them.

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tools
{
  "listChanged": true
}
logging
{}
prompts
{
  "listChanged": true
}
resources
{
  "subscribe": true,
  "listChanged": true
}
completions
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
list_vehiclesA

List the VINs this Polestar Data Portal credential is authorized to access.

list_domainsA

Every domain this server reads, with its endpoint, OAuth scope and tool name. Answer from here rather than guessing a domain name: an unknown domain is a 404 VALIDATION_RESOURCE_NOT_FOUND from the API, which is a different thing from a vehicle reporting no data.

get_availabilityA

Vehicle availability: availabilityStatus and usageMode (whether the car is currently reachable/awake). (M2M endpoint: /v1/vehicles/{vin}/telemetry/availability, scope pdp-telemetry/availability).

get_batteryA

Battery state: charge level %, charging status (V1/V2/type), charger connection and power status, estimated distance to empty (km and miles), estimated time to full, and average consumption kWh/100km. The contract also defines charging current and voltage, charging power, since-charge and automatic-trip consumption averages, and an energy-consumption breakdown: those appear only when the car reports them, so a missing field means unreported, not zero. The reference vehicle answered with 14 fields and none of the optional ones. (M2M endpoint: /v1/vehicles/{vin}/telemetry/battery, scope pdp-telemetry/battery).

get_exteriorB

Exterior state: doors, windows, hood, tailgate, tank lid (open/closed), central lock, tailgate lock, alarm. (M2M endpoint: /v1/vehicles/{vin}/telemetry/exterior, scope pdp-telemetry/exterior).

get_healthA

Service health: days/distance/engine-hours to service, service warning, and fluid/light/12V warnings (brake fluid, coolant, oil, washer fluid, 19 exterior light positions). (M2M endpoint: /v1/vehicles/{vin}/telemetry/health, scope pdp-telemetry/health).

get_locationA

Last known position: latitude, longitude, altitude, heading, speed, with timestamp. (M2M endpoint: /v1/vehicles/{vin}/telemetry/location, scope pdp-telemetry/location).

get_odometerB

Odometer meters, trip meters (manual and automatic, km), average speeds (km/h). (M2M endpoint: /v1/vehicles/{vin}/telemetry/odometer, scope pdp-telemetry/odometer).

get_parking_climatizationA

Parking climate (preheat/pre-cool): running status, runtime left, requested seat and steering-wheel heating intensities, ventilation. (M2M endpoint: /v1/vehicles/{vin}/telemetry/parking-climatization, scope pdp-telemetry/parkingClimatization).

get_pre_cleaningA

Cabin air pre-cleaning: running status, measured PM2.5 / air quality index, last cycle validity and completion time. (M2M endpoint: /v1/vehicles/{vin}/telemetry/pre-cleaning, scope pdp-telemetry/preCleaning).

get_amp_limitA

Configured maximum AC charging current (amps) with its source and last update, plus pendingAmpLimit when a change is recorded but the car has not confirmed it. Measured live. (M2M endpoint: /v1/vehicles/{vin}/charging/amp-limit, scope pdp-charging/ampLimit).

get_charge_locationsA

Configured charge locations. Over M2M this answers as a settings record — typically only an id and a utc0 flag, not a list of addresses — so finding no coordinates is normal rather than a failure. (M2M endpoint: /v1/vehicles/{vin}/charging/charge-locations, scope pdp-charging/chargeLocations).

get_charge_nowA

Charge-now override state. Over M2M it typically carries only the last sync timestamp of the override, not an active/inactive boolean. (M2M endpoint: /v1/vehicles/{vin}/charging/charge-now, scope pdp-charging/overrideChargeTimer).

get_global_charge_timerA

Recurring charge window: start/stop hour with timezone offset, activation flag and sync status. Pending changes appear only when an edit has not yet reached the car; an empty pending block means nothing is queued. (M2M endpoint: /v1/vehicles/{vin}/charging/global-charge-timer, scope pdp-charging/globalChargeTimer).

get_parking_climate_timerA

Scheduled parking-climate timers: ready-at hour, weekdays, repeat flag, activation. (M2M endpoint: /v1/vehicles/{vin}/charging/parking-climate-timer, scope pdp-charging/parkingClimateTimer).

get_target_socA

Target battery state of charge (%), setting type (CUSTOM/PRESET), last update. (M2M endpoint: /v1/vehicles/{vin}/charging/target-soc, scope pdp-charging/targetSoc).

get_is_at_charge_locationA

Whether the vehicle is currently at a saved charge location. Often unsupported on a vehicle (returns DATA_NOT_AVAILABLE). (M2M endpoint: /v1/vehicles/{vin}/charging/is-at-charge-location, scope pdp-charging/isAtChargeLocation).

get_car_statusA

One-call status of the car: charge level and state, range, lock/doors, availability, odometer, service countdown, and data age for each. Costs several domain reads (cached); use instead of calling five get_* tools.

is_car_secureA

True/false security check: are all doors, windows, hood and tailgate closed, central lock engaged, alarm OK? Names anything open.

get_needs_attentionA

Only the active warnings from the health domain (fluids, lights, 12V, service) plus the service countdown. Empty means nothing needs attention.

get_charging_estimateA

Estimates the energy and time needed to reach the target charge level from the current SoC, using the reported usable energy (dischargeInfo.energyAvailable) when available, the configured amp limit for power, and the car's own time-to-full when charging.

plan_cheapest_chargeA

Given hourly electricity prices, computes the cheapest hours inside the car's charge window (from global-charge-timer) that deliver enough energy to reach the target charge level.

polestar_statusA

Server self-report: daily API budget (used/limit/reset), per-minute ceiling, cache hit rate, token expiry, and mode. Call this if you suspect you are burning through the daily API budget.

Prompts

Interactive templates invoked by user choice

NameDescription
car-statusA one-glance briefing: charge, range, security, and anything needing attention.
charge-planPlan the cheapest charging hours for tonight given spot prices.
battery-health-reportDegradation and charging-session report from recorded history.

Resources

Contextual data attached and managed by the client

NameDescription

No resources

TDQS

A3.7/5.0

Scored across 23 tools

Disambiguation4/5

Most tools map cleanly to distinct M2M resources, so get_location, get_odometer, and get_exterior are unambiguous. The main overlap is get_health versus get_needs_attention, and get_car_status intentionally aggregates several get_* tools, which creates mild selection ambiguity.

Naming Consistency4/5

The dominant pattern is snake_case get_<resource>, which is predictable and consistent across the telemetry and charging tools. The pattern is not perfectly uniform because of list_vehicles, list_domains, is_car_secure, plan_cheapest_charge, and polestar_status.

Tool Count3/5

23 tools sits in the 16-25 range that feels heavy for an agent to navigate. Each tool is mostly endpoint-aligned, but the aggregate and derived helpers such as get_car_status, is_car_secure, get_needs_attention, and plan_cheapest_charge add useful value while also pushing the set toward redundancy.

Completeness4/5

The read-side surface is broad, covering the major telemetry domains, charging settings, and helpful derived queries, with list_domains preventing endpoint guessing. The main gaps are the lack of any write/control operations and some niche vehicle telemetry such as software version or tire pressure, which agents could work around.

Maintenance

ActivityMaintained
ResponsivenessNo issues