Skip to main content
Glama
leonardosepulvedat

MCP Google Analytics Server

ga_send_purchase

Send ecommerce purchase events to Google Analytics with transaction details and item data, enabling accurate tracking of completed purchases.

Instructions

Send an ecommerce purchase event to Google Analytics.

Standard event for tracking completed purchases with transaction details and items.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
taxNoTax amount
itemsYesPurchased items
valueYesTotal purchase value
couponNoCoupon code used
user_idNo
currencyYesCurrency code (e.g., USD, EUR)
shippingNoShipping cost
client_idNo
affiliationNoStore or affiliation
transaction_idYesUnique transaction ID
user_propertiesNoUser properties (e.g., {subscription_tier: {value: "premium"}})

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. Changed17 schema fields changedv1.1.1
    • addedInput schema / $schema
      Added value: +"http://json-schema.org/draft-07/schema#"
    • addedInput schema / additionalProperties
      Added value: +false
    • addedInput schema / properties / items / items / additionalProperties
      Added value: +false
    • addedInput schema / properties / items / items / properties / affiliation
      Added value: +{
      +  "type": "string"
      +}
    • addedInput schema / properties / items / items / properties / coupon
      Added value: +{
      +  "type": "string"
      +}
    • addedInput schema / properties / items / items / properties / currency
      Added value: +{
      +  "type": "string"
      +}
    • addedInput schema / properties / items / items / properties / discount
      Added value: +{
      +  "type": "number"
      +}
    • addedInput schema / properties / items / items / properties / index
      Added value: +{
      +  "type": "number"
      +}
    • addedInput schema / properties / items / items / properties / item_category2
      Added value: +{
      +  "type": "string"
      +}
    • addedInput schema / properties / items / items / properties / item_category3
      Added value: +{
      +  "type": "string"
      +}
    • addedInput schema / properties / items / items / properties / item_category4
      Added value: +{
      +  "type": "string"
      +}
    • addedInput schema / properties / items / items / properties / item_category5
      Added value: +{
      +  "type": "string"
      +}
    • addedInput schema / properties / items / items / properties / item_list_id
      Added value: +{
      +  "type": "string"
      +}
    • addedInput schema / properties / items / items / properties / item_list_name
      Added value: +{
      +  "type": "string"
      +}
    • addedInput schema / properties / items / items / properties / location_id
      Added value: +{
      +  "type": "string"
      +}
    • changedInput schema / properties / user_properties / additionalProperties
      Previous value: -trueNew value: +{
      +  "additionalProperties": false,
      +  "properties": {
      +    "value": {
      +      "type": [
      +        "string",
      +        "number"
      +      ]
      +    }
      +  },
      +  "required": [
      +    "value"
      +  ],
      +  "type": "object"
      +}
    • addedInput schema / properties / user_properties / description
      Added value: +"User properties (e.g., {subscription_tier: {value: \"premium\"}})"
  2. First observedv1.0.1

TDQS

A3.9/5.0
Behavior3/5

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

Annotations already convey the safety profile: readOnlyHint=false, idempotentHint=false, destructiveHint=false. The description adds that this is the standard purchase event and carries transaction details, but it does not disclose operational behavior such as authentication needs, error conditions, or downstream effects of sending the event.

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?

Two sentences with no filler. The action is front-loaded, and the second sentence clarifies the event's standard purpose. Every word earns its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The description is adequate for identifying the tool's purpose, and the schema covers parameter details. However, it lacks explicit guidance on choosing this specialized event over ga_send_event, and with no output schema it does not clarify what an agent should expect in the response.

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 82%, and required parameters like transaction_id, value, currency, and items already have descriptions. The phrase 'transaction details and items' maps to those required parameters but adds no new semantic meaning beyond what the schema already provides.

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 description names a specific verb and resource: 'Send an ecommerce purchase event to Google Analytics.' It further distinguishes itself by calling out 'completed purchases with transaction details and items,' which separates it from sibling tools like ga_send_add_to_cart, ga_send_begin_checkout, and ga_send_event.

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?

The phrase 'Standard event for tracking completed purchases' gives clear context for when the tool should be used. However, it does not explicitly name alternatives or state when not to use it, such as pointing to ga_send_event for non-purchase events or ga_send_refund for returns.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/leonardosepulvedat/mcp-google-analytics'

If you have feedback or need assistance with the MCP directory API, please join our Discord server