Skip to main content
Glama

export_library_json

Export your full Spotify library—saved tracks, albums, shows, episodes, audiobooks—to local JSON or CSV files. Respects per-type fetch caps and reports truncation when limits apply.

Instructions

Export your full library (saved tracks, albums, shows, episodes, audiobooks) to a local directory as JSON or CSV sidecar files. Respects SPOTIFY_MCP_FETCH_ALL_CAP per type; when capped, reports cap_reached + truncated and a prose footer ("first N of … — raise SPOTIFY_MCP_FETCH_ALL_CAP").

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
formatNoOutput format: json (single file) or csv (one file per type)json
output_dirNoLocal directory to write into, confined to the output root (default ~/.spotify-mcp/portability, set SPOTIFY_MCP_PORTABILITY_DIR to move it)
response_formatNo'concise' = human prose, 'detailed' = more fields in prose, 'json' = raw API objectconcise

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv2.1.2
    • changedInput schema / properties / output_dir / description
      Previous value: -"Local directory to write files into (default: ~/.spotify-mcp/portability)"New value: +"Local directory to write into, confined to the output root (default ~/.spotify-mcp/portability, set SPOTIFY_MCP_PORTABILITY_DIR to move it)"
  2. Changed2 schema fields changedv1.31.0
    • removedInput schema / $schema
      Removed value: -"http://json-schema.org/draft-07/schema#"
    • addedInput schema / additionalProperties
      Added value: +false
  3. Addedv1.26.1

TDQS

A3.8/5.0
Behavior4/5

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

Annotations only include destructiveHint=false, so the description carries the burden of behavioral disclosure. It explicitly discloses the SPOTIFY_MCP_FETCH_ALL_CAP behavior, reporting cap_reached, truncated, and a prose footer, which is valuable context beyond the annotation. However, it does not mention whether existing files are overwritten or how the output directory is created, but those are minor gaps given the export action is clear.

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 two concise sentences that front-load the core purpose and then add the cap behavior. Every word earns its place, with no redundancy or fluff. It efficiently conveys the tool's function and a key edge case without extra text.

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?

The description covers the main export scope and the cap/truncation behavior, and the schema covers format and output details. However, it does not describe the return value for a successful export (only the cap case), and it omits details like whether the output directory is created automatically. Given the tool's complexity and lack of output schema, these are minor but notable gaps.

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?

The schema already provides full descriptions for all three parameters (format, output_dir, response_format), including enums and defaults. The description adds no additional parameter-level meaning beyond what the schema covers. Since schema coverage is 100%, a baseline of 3 is appropriate; the description's cap explanation is not parameter-specific.

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 clearly states the tool exports the full library (saved tracks, albums, shows, episodes, audiobooks) to a local directory in JSON or CSV format, with a specific verb and resource. It also mentions the cap behavior, which distinguishes it from other export tools. The scope is explicit, making it easy to differentiate from siblings like export_playlist or export_followed_artists.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus the many other export tools in the sibling list (e.g., export_all_playlists, export_followed_artists, export_profile_state). It does not mention alternatives or exclusions, leaving the agent to infer usage context. No when-not-to-use conditions are given.

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

Deploy Server

Other Tools