Skip to main content
Glama

Upload Activity File

strava_create_upload

Upload an activity file (FIT, TCX, GPX) to create a new activity (one API request plus later status polls). Requires activity:write. Maximum decoded file size 25 MiB; canonical base64 only. Do not replay a lost response; reconcile first.

Instructions

Upload an activity file (FIT, TCX, GPX) to create a new activity (one API request plus later status polls). Requires activity:write. Maximum decoded file size 25 MiB; canonical base64 only. Do not replay a lost response; reconcile first. Returns an upload ID for strava_get_upload.

Input Schema

NameRequiredDescriptionDefault
nameNoActivity name
commuteNoWhether this is a commute
trainerNoWhether this is a trainer/indoor activity
data_typeYesFile format: fit, fit.gz, tcx, tcx.gz, gpx, gpx.gz
descriptionNoActivity description
external_idNoExternal identifier for deduplication
file_contentYesBase64-encoded file content (maximum decoded size 25 MiB)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed6 schema fields changedv4.4.1
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • removedInput schema / additionalProperties
      Removed value: -false
    • changedInput schema / properties / file_content / description
      Previous value: -"Base64-encoded file content"New value: +"Base64-encoded file content (maximum decoded size 25 MiB)"
    • addedInput schema / properties / file_content / maxLength
      Added value: +34952536
    • addedInput schema / properties / file_content / minLength
      Added value: +4
    • addedInput schema / properties / file_content / pattern
      Added value: +"^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$"
  2. First observedv1.0.0

TDQS

A4.7/5.0
Behavior5/5

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

Beyond the annotations, it discloses required scope, maximum decoded file size, base64 canonicalization, asynchronous polling behavior, and operational guidance for lost responses. These details materially inform safe invocation of a non-idempotent write operation.

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?

The description is compact and front-loaded, with the core purpose first followed by constraints, auth, retry guidance, and return value. Every sentence adds operational value.

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 non-idempotent upload tool with no output schema, the description covers authentication, file constraints, async status polling, reconciliation guidance, and the upload ID return value. An agent has enough context to invoke it correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is already 100%, so the baseline is 3. The description adds useful meaning beyond the schema by clarifying canonical base64, decoded size limits, and supported activity file semantics.

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 states a specific verb and resource: upload an activity file to create a new activity. It names supported formats and clarifies that this is distinct from a plain manual activity creation by emphasizing the file upload path.

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 explains the upload lifecycle (one API request plus later status polls), points to strava_get_upload for follow-up, and warns not to replay a lost response. It lacks an explicit comparison with strava_create_activity, but the intended context is clear.

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