> ## Documentation Index
> Fetch the complete documentation index at: https://docs.pinkfish.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# spotify-player

> Spotify Player - playback control, queue, devices, and listening history

**Server path:** `/spotify-player` | **Type:** Application | **PCID required:** Yes

## Tools

| Tool                                                                                                                                  | Description                 |
| ------------------------------------------------------------------------------------------------------------------------------------- | --------------------------- |
| [`spotify_player_add_to_queue`](#spotify_player_add_to_queue)                                                                         | Add Item to Playback Queue  |
| [`spotify_player_get_a_users_available_devices`](#spotify_player_get_a_users_available_devices)                                       | Get Available Devices       |
| [`spotify_player_get_information_about_the_users_current_playback`](#spotify_player_get_information_about_the_users_current_playback) | Get Playback State          |
| [`spotify_player_get_queue`](#spotify_player_get_queue)                                                                               | Get the User's Queue        |
| [`spotify_player_get_recently_played`](#spotify_player_get_recently_played)                                                           | Get Recently Played Tracks  |
| [`spotify_player_get_the_users_currently_playing_track`](#spotify_player_get_the_users_currently_playing_track)                       | Get Currently Playing Track |
| [`spotify_player_pause_a_users_playback`](#spotify_player_pause_a_users_playback)                                                     | Pause Playback              |
| [`spotify_player_seek_to_position_in_currently_playing_track`](#spotify_player_seek_to_position_in_currently_playing_track)           | Seek To Position            |
| [`spotify_player_set_repeat_mode_on_users_playback`](#spotify_player_set_repeat_mode_on_users_playback)                               | Set Repeat Mode             |
| [`spotify_player_set_volume_for_users_playback`](#spotify_player_set_volume_for_users_playback)                                       | Set Playback Volume         |
| [`spotify_player_skip_users_playback_to_next_track`](#spotify_player_skip_users_playback_to_next_track)                               | Skip To Next                |
| [`spotify_player_skip_users_playback_to_previous_track`](#spotify_player_skip_users_playback_to_previous_track)                       | Skip To Previous            |
| [`spotify_player_start_a_users_playback`](#spotify_player_start_a_users_playback)                                                     | Start/Resume Playback       |
| [`spotify_player_toggle_shuffle_for_users_playback`](#spotify_player_toggle_shuffle_for_users_playback)                               | Toggle Playback Shuffle     |
| [`spotify_player_transfer_a_users_playback`](#spotify_player_transfer_a_users_playback)                                               | Transfer Playback           |

***

## spotify\_player\_add\_to\_queue

Add Item to Playback Queue

**Parameters:**

| Parameter   | Type   | Required | Default | Description                                                                                                        |
| ----------- | ------ | -------- | ------- | ------------------------------------------------------------------------------------------------------------------ |
| `uri`       | string | Yes      | —       | The uri of the item to add to the queue. Must be a track or an episode uri.                                        |
| `device_id` | string | No       | —       | The id of the device this command is targeting. If not supplied, the user's currently active device is the target. |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "uri": {
        "type": "string",
        "description": "The uri of the item to add to the queue. Must be a track or an episode uri."
      },
      "device_id": {
        "type": "string",
        "description": "The id of the device this command is targeting. If not supplied, the user's currently active device is the target."
      }
    },
    "required": [
      "PCID",
      "uri"
    ]
  }
  ```
</Expandable>

***

## spotify\_player\_get\_a\_users\_available\_devices

Get Available Devices

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      }
    },
    "required": [
      "PCID"
    ]
  }
  ```
</Expandable>

***

## spotify\_player\_get\_information\_about\_the\_users\_current\_playback

Get Playback State

**Parameters:**

| Parameter          | Type   | Required | Default | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
| ------------------ | ------ | -------- | ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `market`           | string | No       | —       | An [ISO 3166-1 alpha-2 country code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2).   If a country code is specified, only content that is available in that market will be returned.\<br/>   If a valid user access token is specified in the request header, the country associated with   the user account will take priority over this parameter.\<br/>   ***Note**: If neither market or user country are provided, the content is considered unavailable for the client.*\<br/>   Users can view the country that is associated with their account in the [account settings](https://www.spotify.com/account/overview/). |
| `additional_types` | string | No       | —       | A comma-separated list of item types that your client supports besides the default `track` type. Valid types are: `track` and `episode`.\<br/> ***Note**: This parameter was introduced to allow existing clients to maintain their current behaviour and might be deprecated in the future.*\<br/> In addition to providing this parameter, make sure that your client properly handles cases of new types in the future by checking against the `type` field of each object.                                                                                                                                                     |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "market": {
        "type": "string",
        "description": "An [ISO 3166-1 alpha-2 country code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2).   If a country code is specified, only content that is available in that market will be returned.<br/>   If a valid user access token is specified in the request header, the country associated with   the user account will take priority over this parameter.<br/>   _**Note**: If neither market or user country are provided, the content is considered unavailable for the client._<br/>   Users can view the country that is associated with their account in the [account settings](https://www.spotify.com/account/overview/)."
      },
      "additional_types": {
        "type": "string",
        "description": "A comma-separated list of item types that your client supports besides the default `track` type. Valid types are: `track` and `episode`.<br/> _**Note**: This parameter was introduced to allow existing clients to maintain their current behaviour and might be deprecated in the future._<br/> In addition to providing this parameter, make sure that your client properly handles cases of new types in the future by checking against the `type` field of each object."
      }
    },
    "required": [
      "PCID"
    ]
  }
  ```
</Expandable>

***

## spotify\_player\_get\_queue

Get the User's Queue

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      }
    },
    "required": [
      "PCID"
    ]
  }
  ```
</Expandable>

***

## spotify\_player\_get\_recently\_played

Get Recently Played Tracks

**Parameters:**

| Parameter | Type    | Required | Default | Description                                                                                                                                                   |
| --------- | ------- | -------- | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `limit`   | integer | No       | —       | The maximum number of items to return. Default: 20. Minimum: 1. Maximum: 50.                                                                                  |
| `after`   | integer | No       | —       | A Unix timestamp in milliseconds. Returns all items after (but not including) this cursor position. If `after` is specified, `before` must not be specified.  |
| `before`  | integer | No       | —       | A Unix timestamp in milliseconds. Returns all items before (but not including) this cursor position. If `before` is specified, `after` must not be specified. |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "limit": {
        "type": "integer",
        "description": "The maximum number of items to return. Default: 20. Minimum: 1. Maximum: 50."
      },
      "after": {
        "type": "integer",
        "description": "A Unix timestamp in milliseconds. Returns all items after (but not including) this cursor position. If `after` is specified, `before` must not be specified."
      },
      "before": {
        "type": "integer",
        "description": "A Unix timestamp in milliseconds. Returns all items before (but not including) this cursor position. If `before` is specified, `after` must not be specified."
      }
    },
    "required": [
      "PCID"
    ]
  }
  ```
</Expandable>

***

## spotify\_player\_get\_the\_users\_currently\_playing\_track

Get Currently Playing Track

**Parameters:**

| Parameter          | Type   | Required | Default | Description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        |
| ------------------ | ------ | -------- | ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `market`           | string | No       | —       | An [ISO 3166-1 alpha-2 country code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2).   If a country code is specified, only content that is available in that market will be returned.\<br/>   If a valid user access token is specified in the request header, the country associated with   the user account will take priority over this parameter.\<br/>   ***Note**: If neither market or user country are provided, the content is considered unavailable for the client.*\<br/>   Users can view the country that is associated with their account in the [account settings](https://www.spotify.com/account/overview/). |
| `additional_types` | string | No       | —       | A comma-separated list of item types that your client supports besides the default `track` type. Valid types are: `track` and `episode`.\<br/> ***Note**: This parameter was introduced to allow existing clients to maintain their current behaviour and might be deprecated in the future.*\<br/> In addition to providing this parameter, make sure that your client properly handles cases of new types in the future by checking against the `type` field of each object.                                                                                                                                                     |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "market": {
        "type": "string",
        "description": "An [ISO 3166-1 alpha-2 country code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2).   If a country code is specified, only content that is available in that market will be returned.<br/>   If a valid user access token is specified in the request header, the country associated with   the user account will take priority over this parameter.<br/>   _**Note**: If neither market or user country are provided, the content is considered unavailable for the client._<br/>   Users can view the country that is associated with their account in the [account settings](https://www.spotify.com/account/overview/)."
      },
      "additional_types": {
        "type": "string",
        "description": "A comma-separated list of item types that your client supports besides the default `track` type. Valid types are: `track` and `episode`.<br/> _**Note**: This parameter was introduced to allow existing clients to maintain their current behaviour and might be deprecated in the future._<br/> In addition to providing this parameter, make sure that your client properly handles cases of new types in the future by checking against the `type` field of each object."
      }
    },
    "required": [
      "PCID"
    ]
  }
  ```
</Expandable>

***

## spotify\_player\_pause\_a\_users\_playback

Pause Playback

**Parameters:**

| Parameter   | Type   | Required | Default | Description                                                                                                        |
| ----------- | ------ | -------- | ------- | ------------------------------------------------------------------------------------------------------------------ |
| `device_id` | string | No       | —       | The id of the device this command is targeting. If not supplied, the user's currently active device is the target. |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "device_id": {
        "type": "string",
        "description": "The id of the device this command is targeting. If not supplied, the user's currently active device is the target."
      }
    },
    "required": [
      "PCID"
    ]
  }
  ```
</Expandable>

***

## spotify\_player\_seek\_to\_position\_in\_currently\_playing\_track

Seek To Position

**Parameters:**

| Parameter     | Type    | Required | Default | Description                                                                                                                                                                                  |
| ------------- | ------- | -------- | ------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `position_ms` | integer | Yes      | —       | The position in milliseconds to seek to. Must be a positive number. Passing in a position that is greater than the length of the track will cause the player to start playing the next song. |
| `device_id`   | string  | No       | —       | The id of the device this command is targeting. If not supplied, the user's currently active device is the target.                                                                           |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "position_ms": {
        "type": "integer",
        "description": "The position in milliseconds to seek to. Must be a positive number. Passing in a position that is greater than the length of the track will cause the player to start playing the next song."
      },
      "device_id": {
        "type": "string",
        "description": "The id of the device this command is targeting. If not supplied, the user's currently active device is the target."
      }
    },
    "required": [
      "PCID",
      "position_ms"
    ]
  }
  ```
</Expandable>

***

## spotify\_player\_set\_repeat\_mode\_on\_users\_playback

Set Repeat Mode

**Parameters:**

| Parameter   | Type   | Required | Default | Description                                                                                                                                                              |
| ----------- | ------ | -------- | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `state`     | string | Yes      | —       | **track**, **context** or **off**.\<br/> **track** will repeat the current track.\<br/> **context** will repeat the current context.\<br/> **off** will turn repeat off. |
| `device_id` | string | No       | —       | The id of the device this command is targeting. If not supplied, the user's currently active device is the target.                                                       |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "state": {
        "type": "string",
        "description": "**track**, **context** or **off**.<br/> **track** will repeat the current track.<br/> **context** will repeat the current context.<br/> **off** will turn repeat off."
      },
      "device_id": {
        "type": "string",
        "description": "The id of the device this command is targeting. If not supplied, the user's currently active device is the target."
      }
    },
    "required": [
      "PCID",
      "state"
    ]
  }
  ```
</Expandable>

***

## spotify\_player\_set\_volume\_for\_users\_playback

Set Playback Volume

**Parameters:**

| Parameter        | Type    | Required | Default | Description                                                                                                        |
| ---------------- | ------- | -------- | ------- | ------------------------------------------------------------------------------------------------------------------ |
| `volume_percent` | integer | Yes      | —       | The volume to set. Must be a value from 0 to 100 inclusive.                                                        |
| `device_id`      | string  | No       | —       | The id of the device this command is targeting. If not supplied, the user's currently active device is the target. |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "volume_percent": {
        "type": "integer",
        "description": "The volume to set. Must be a value from 0 to 100 inclusive."
      },
      "device_id": {
        "type": "string",
        "description": "The id of the device this command is targeting. If not supplied, the user's currently active device is the target."
      }
    },
    "required": [
      "PCID",
      "volume_percent"
    ]
  }
  ```
</Expandable>

***

## spotify\_player\_skip\_users\_playback\_to\_next\_track

Skip To Next

**Parameters:**

| Parameter   | Type   | Required | Default | Description                                                                                                        |
| ----------- | ------ | -------- | ------- | ------------------------------------------------------------------------------------------------------------------ |
| `device_id` | string | No       | —       | The id of the device this command is targeting. If not supplied, the user's currently active device is the target. |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "device_id": {
        "type": "string",
        "description": "The id of the device this command is targeting. If not supplied, the user's currently active device is the target."
      }
    },
    "required": [
      "PCID"
    ]
  }
  ```
</Expandable>

***

## spotify\_player\_skip\_users\_playback\_to\_previous\_track

Skip To Previous

**Parameters:**

| Parameter   | Type   | Required | Default | Description                                                                                                        |
| ----------- | ------ | -------- | ------- | ------------------------------------------------------------------------------------------------------------------ |
| `device_id` | string | No       | —       | The id of the device this command is targeting. If not supplied, the user's currently active device is the target. |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "device_id": {
        "type": "string",
        "description": "The id of the device this command is targeting. If not supplied, the user's currently active device is the target."
      }
    },
    "required": [
      "PCID"
    ]
  }
  ```
</Expandable>

***

## spotify\_player\_start\_a\_users\_playback

Start/Resume Playback

**Parameters:**

| Parameter     | Type      | Required | Default | Description                                                                                                                                                                                                                                                                                                                                                                                    |
| ------------- | --------- | -------- | ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `device_id`   | string    | No       | —       | The id of the device this command is targeting. If not supplied, the user's currently active device is the target.                                                                                                                                                                                                                                                                             |
| `context_uri` | string    | No       | —       | Optional. Spotify URI of the context to play. Valid contexts are albums, artists & playlists. `&#123;context_uri:"spotify:album:1Je1IMUlBXcx1Fz0WE7oPT"&#125;`                                                                                                                                                                                                                                 |
| `offset`      | object    | No       | —       | Optional. Indicates from where in the context playback should start. Only available when context\_uri corresponds to an album or playlist object "position" is zero based and can’t be negative. Example: `"offset": &#123;"position": 5&#125;` "uri" is a string representing the uri of the item to start at. Example: `"offset": &#123;"uri": "spotify:track:1301WleyT98MSxVHPZCA6M"&#125;` |
| `position_ms` | integer   | No       | —       | integer                                                                                                                                                                                                                                                                                                                                                                                        |
| `uris`        | string\[] | No       | —       | Optional. A JSON array of the Spotify track URIs to play. For example: `&#123;"uris": ["spotify:track:4iV5W9uYEdYUVa79Axb7Rh", "spotify:track:1301WleyT98MSxVHPZCA6M"]&#125;`                                                                                                                                                                                                                  |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "device_id": {
        "type": "string",
        "description": "The id of the device this command is targeting. If not supplied, the user's currently active device is the target."
      },
      "context_uri": {
        "type": "string",
        "description": "Optional. Spotify URI of the context to play. Valid contexts are albums, artists & playlists. `{context_uri:\"spotify:album:1Je1IMUlBXcx1Fz0WE7oPT\"}`"
      },
      "offset": {
        "type": "object",
        "description": "Optional. Indicates from where in the context playback should start. Only available when context_uri corresponds to an album or playlist object \"position\" is zero based and can’t be negative. Example: `\"offset\": {\"position\": 5}` \"uri\" is a string representing the uri of the item to start at. Example: `\"offset\": {\"uri\": \"spotify:track:1301WleyT98MSxVHPZCA6M\"}`"
      },
      "position_ms": {
        "type": "integer",
        "description": "integer"
      },
      "uris": {
        "type": "array",
        "items": {
          "type": "string"
        },
        "description": "Optional. A JSON array of the Spotify track URIs to play. For example: `{\"uris\": [\"spotify:track:4iV5W9uYEdYUVa79Axb7Rh\", \"spotify:track:1301WleyT98MSxVHPZCA6M\"]}`"
      }
    },
    "required": [
      "PCID"
    ]
  }
  ```
</Expandable>

***

## spotify\_player\_toggle\_shuffle\_for\_users\_playback

Toggle Playback Shuffle

**Parameters:**

| Parameter   | Type    | Required | Default | Description                                                                                                        |
| ----------- | ------- | -------- | ------- | ------------------------------------------------------------------------------------------------------------------ |
| `state`     | boolean | Yes      | —       | **true** : Shuffle user's playback.\<br/> **false** : Do not shuffle user's playback.                              |
| `device_id` | string  | No       | —       | The id of the device this command is targeting. If not supplied, the user's currently active device is the target. |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "state": {
        "type": "boolean",
        "description": "**true** : Shuffle user's playback.<br/> **false** : Do not shuffle user's playback."
      },
      "device_id": {
        "type": "string",
        "description": "The id of the device this command is targeting. If not supplied, the user's currently active device is the target."
      }
    },
    "required": [
      "PCID",
      "state"
    ]
  }
  ```
</Expandable>

***

## spotify\_player\_transfer\_a\_users\_playback

Transfer Playback

**Parameters:**

| Parameter    | Type      | Required | Default | Description                                                                                                                                                                                                                                                                                                               |
| ------------ | --------- | -------- | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `device_ids` | string\[] | Yes      | —       | A JSON array containing the ID of the device on which playback should be started/transferred.\<br/>For example:`&#123;device_ids:["74ASZWbe4lXaubB36ztrGX"]&#125;`\<br/>***Note**: Although an array is accepted, only a single device\_id is currently supported. Supplying more than one will return `400 Bad Request`* |
| `play`       | boolean   | No       | —       | **true**: ensure playback happens on new device.\<br/>**false** or not provided: keep the current playback state.                                                                                                                                                                                                         |

<Expandable title="inputSchema">
  ```json theme={null}
  {
    "type": "object",
    "properties": {
      "PCID": {
        "type": "string",
        "description": "Pink Connect ID for the authenticated connection"
      },
      "device_ids": {
        "type": "array",
        "items": {
          "type": "string"
        },
        "description": "A JSON array containing the ID of the device on which playback should be started/transferred.<br/>For example:`{device_ids:[\"74ASZWbe4lXaubB36ztrGX\"]}`<br/>_**Note**: Although an array is accepted, only a single device_id is currently supported. Supplying more than one will return `400 Bad Request`_"
      },
      "play": {
        "type": "boolean",
        "description": "**true**: ensure playback happens on new device.<br/>**false** or not provided: keep the current playback state."
      }
    },
    "required": [
      "PCID",
      "device_ids"
    ]
  }
  ```
</Expandable>
