skipToNext
Advance to the next track in your current Spotify playback queue. Use this tool to control music progression during listening sessions.
Instructions
Skip to the next track in the current Spotify playback queue
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| deviceId | No | The Spotify device ID to skip on |
Implementation Reference
- src/play.ts:116-131 (handler)The handler function that performs the skip to next track action using the Spotify API.handler: async (args, _extra: SpotifyHandlerExtra) => { const { deviceId } = args; await handleSpotifyRequest(async (spotifyApi) => { await spotifyApi.player.skipToNext(deviceId || ''); }); return { content: [ { type: 'text', text: 'Skipped to next track', }, ], }; },
- src/play.ts:110-115 (schema)Input schema using Zod for the skipToNext tool, defining optional deviceId parameter.schema: { deviceId: z .string() .optional() .describe('The Spotify device ID to skip on'), },
- src/index.ts:12-14 (registration)Registration of all tools, including skipToNext via playTools, to the MCP server.[...readTools, ...playTools, ...albumTools].forEach((tool) => { server.tool(tool.name, tool.description, tool.schema, tool.handler); });
- src/play.ts:502-502 (registration)skipToNext tool included in the playTools export array for registration.skipToNext,