Skip to main content
Glama

diff_playlists

Read-onlyIdempotent

Compare two Spotify playlists to identify tracks only in A, only in B, and shared tracks at different positions. Set scan and result caps to manage large playlist diffs.

Instructions

Compare two playlists up to the configured source cap: tracks only in A, only in B (by track ID), and tracks present in both but at different positions. Rendered rows are capped by max_results; truncation metadata reports when source walks hit scan_cap.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNoSource page size, 1–100. Default: 100
dry_runNoPreview only: validate inputs and describe exactly what would change without performing it
scan_capNoMaximum source rows to scan; bounded by SPOTIFY_MCP_FETCH_ALL_CAP
playlist_aNoCanonical A playlist; provide with playlist_b
playlist_bNoCanonical B playlist; provide with playlist_a
max_resultsNoMax items to return (default: SPOTIFY_MCP_MAX_ITEMS env or 50)
response_formatNo'concise' = human prose, 'detailed' = more fields in prose, 'json' = raw API objectconcise

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changedv3.0.1
    • removedInput schema / properties / a
      Removed value: -{
      -  "description": "Deprecated one-release alias supported through v2.0; removed in v2.1. Provide a complete pair or canonical playlist_a/playlist_b.",
      -  "minLength": 1,
      -  "type": "string"
      -}
    • removedInput schema / properties / b
      Removed value: -{
      -  "description": "Deprecated one-release alias supported through v2.0; removed in v2.1. Provide a complete pair or canonical playlist_a/playlist_b.",
      -  "minLength": 1,
      -  "type": "string"
      -}
    • changedInput schema / properties / playlist_a / description
      Previous value: -"Canonical A playlist; provide with playlist_b or one complete documented legacy pair"New value: +"Canonical A playlist; provide with playlist_b"
    • changedInput schema / properties / playlist_b / description
      Previous value: -"Canonical B playlist; provide with playlist_a or one complete documented legacy pair"New value: +"Canonical B playlist; provide with playlist_a"
  2. Changed11 schema fields changedv1.31.0
    • removedInput schema / $schema
      Removed value: -"http://json-schema.org/draft-07/schema#"
    • addedInput schema / additionalProperties
      Added value: +false
    • changedInput schema / properties / a / description
      Previous value: -"First playlist, as ID or spotify:playlist: URI"New value: +"Deprecated one-release alias supported through v2.0; removed in v2.1. Provide a complete pair or canonical playlist_a/playlist_b."
    • addedInput schema / properties / a / minLength
      Added value: +1
    • changedInput schema / properties / b / description
      Previous value: -"Second playlist, as ID or spotify:playlist: URI"New value: +"Deprecated one-release alias supported through v2.0; removed in v2.1. Provide a complete pair or canonical playlist_a/playlist_b."
    • addedInput schema / properties / b / minLength
      Added value: +1
    • addedInput schema / properties / limit
      Added value: +{
      +  "description": "Source page size, 1–100. Default: 100",
      +  "maximum": 100,
      +  "minimum": 1,
      +  "type": "integer"
      +}
    • addedInput schema / properties / playlist_a
      Added value: +{
      +  "description": "Canonical A playlist; provide with playlist_b or one complete documented legacy pair",
      +  "minLength": 1,
      +  "type": "string"
      +}
    • addedInput schema / properties / playlist_b
      Added value: +{
      +  "description": "Canonical B playlist; provide with playlist_a or one complete documented legacy pair",
      +  "minLength": 1,
      +  "type": "string"
      +}
    • addedInput schema / properties / scan_cap
      Added value: +{
      +  "description": "Maximum source rows to scan; bounded by SPOTIFY_MCP_FETCH_ALL_CAP",
      +  "maximum": 10000,
      +  "minimum": 1,
      +  "type": "integer"
      +}
    • removedInput schema / required
      Removed value: -[
      -  "a",
      -  "b"
      -]
  3. Addedv1.26.1

TDQS

A3.7/5.0
Behavior4/5

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

Annotations already establish that this is a safe, repeatable read (readOnlyHint, idempotentHint), but the description adds real value beyond them: it discloses the source scan cap, that truncation metadata reports when source walks hit scan_cap, and that rendered rows are bounded by max_results. It stops short of describing output shape or how position comparison is computed.

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 tightly packed sentences, front-loaded with the operation and its result categories, followed by the capping/truncation semantics. No filler, restatement of the name, or redundant prose.

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?

For a comparison tool with no output schema and a fully documented parameter set, the description covers result categories, capping behavior, and truncation reporting, which is close to sufficient. It omits any note on empty/error cases or the fact that no parameters are required, but nothing critical to calling it correctly is missing.

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?

With 100% schema coverage the baseline is 3, but the description clarifies the non-obvious interplay between two similarly named caps: scan_cap bounds the source walk while max_results bounds rendered rows. That distinction is not obvious from the schema alone and materially helps correct invocation.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Compare two playlists') and enumerates the three result classes (only in A, only in B by track ID, in both but at different positions), which is genuinely informative. However, it never distinguishes itself from the many closely related siblings such as playlist_symmetric_difference, overlap_playlists, or playlist_union, so an agent must infer which comparison tool to pick.

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?

There is no when-to-use guidance, no prerequisites, and no named alternative despite a dense field of overlapping comparison/union/subtract/symmetric-difference siblings. Usage is only implied by the behavioral description.

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