Skip to main content
Glama

batch_add_to_playlist

Add tracks from multiple Spotify sources (tracks, albums, artists, playlists) to a target playlist in one call. Deduplicates, batches writes, and supports dry-run previews.

Instructions

Add tracks from multiple source URIs (tracks, albums, artists, playlists) to a target playlist in one call. Dedupes within the batch and optionally against the existing playlist. Batches writes in groups of 100. Dry-run previews without writing. Elicitation for 100+ tracks. Target the playlist by ID/URI/URL or by lane name.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNoSource page size, 1–100. Default: 100
dedupeNoDeduplicate (within batch and against target). Default: true
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
max_resultsNoMax items to return (default: SPOTIFY_MCP_MAX_ITEMS env or 50)
source_urisYesSource URIs: spotify:track:, spotify:album:, spotify:artist:, spotify:playlist:
target_laneNoLane name from the lane registry; provide exactly one of target_playlist_id or target_lane
response_formatNo'concise' = human prose, 'detailed' = more fields in prose, 'json' = raw API objectconcise
target_playlist_idNoTarget playlist ID, spotify:playlist: URI, or URL; provide exactly one of target_playlist_id or target_lane

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changedv3.0.1
    • addedInput schema / properties / target_lane
      Added value: +{
      +  "description": "Lane name from the lane registry; provide exactly one of target_playlist_id or target_lane",
      +  "minLength": 1,
      +  "type": "string"
      +}
    • changedInput schema / properties / target_playlist_id / description
      Previous value: -"Target playlist ID, spotify:playlist: URI, or URL"New value: +"Target playlist ID, spotify:playlist: URI, or URL; provide exactly one of target_playlist_id or target_lane"
    • changedInput schema / required
      Previous value: -[
      -  "target_playlist_id",
      -  "source_uris"
      -]New value: +[
      +  "source_uris"
      +]
  2. Changed6 schema fields changedv1.31.0
    • removedInput schema / $schema
      Removed value: -"http://json-schema.org/draft-07/schema#"
    • addedInput schema / additionalProperties
      Added value: +false
    • addedInput schema / properties / limit
      Added value: +{
      +  "description": "Source page size, 1–100. Default: 100",
      +  "maximum": 100,
      +  "minimum": 1,
      +  "type": "integer"
      +}
    • 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"
      +}
    • changedInput schema / properties / target_playlist_id / description
      Previous value: -"Target playlist ID or spotify:playlist: URI"New value: +"Target playlist ID, spotify:playlist: URI, or URL"
    • addedInput schema / properties / target_playlist_id / minLength
      Added value: +1
  3. Addedv1.26.1

TDQS

A4.2/5.0
Behavior5/5

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

Annotations only supply destructiveHint=false, so the description carries most of the behavioral weight and delivers: in-batch and against-target dedupe, write batching in groups of 100, dry-run preview semantics, and an elicitation trigger at 100+ tracks. These are non-obvious operational traits an agent could not infer from the schema or annotations.

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?

Five compact sentences, each earning its place, with the core action front-loaded and operational caveats (dedupe, batching, dry-run, elicitation) following in descending priority. No filler.

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 9-parameter mutation with no output schema, the description covers the behaviors an agent most needs: dedupe semantics, batching, dry-run, and the confirmation threshold. It does not describe result shape or partial-failure behavior across batched writes, a minor gap since no output schema exists to cover it.

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 100%, so the schema already documents all nine parameters, setting the baseline at 3. The description echoes dedupe and target-selection semantics but adds no syntax or format detail beyond what the schema states, so it neither compensates for nor exceeds the structured data.

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?

States a specific verb and resource with scope: 'Add tracks from multiple source URIs (tracks, albums, artists, playlists) to a target playlist in one call.' The 'multiple source URIs ... in one call' framing distinguishes it cleanly from the single-item add_to_playlist sibling.

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

Usage Guidelines3/5

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

Gives targeting guidance ('by ID/URI/URL or by lane name') and mentions dry-run and elicitation thresholds, which is useful context. However, it never explicitly states when to prefer this over add_to_playlist or how it relates to bulk siblings like merge_playlists or grow_playlist; the batch intent is only implied.

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