Documentation

GraphQL API: Playback

Skip to the previous track

Tracks in the playback queue can be skipped to the previous item. It returns the MutationStatus to indicate the success of the skip and it returns the previous item in the playback queue. Some subscription tiers have skip limits and if this is reached an error will be returned.

Podcast episodes, video ads and audio ads cannot be skipped. This feature is only available to Premium users, and thus can only be used on on-demand sources such as albums, and not stations.

The index field must be set to the current track’s index within the source and not the index you want to skip to. The result returned will be the previous track within the source. Take note that the index field will increase in the response even though the previous track will be the playback item.  

Request



mutation {
  playback {
    previous(deviceUuid: "deviceXYZ", sourceId: "AL:1811731", index: 1, elapsedTime: 200) {
      status
      current {
        ... on TrackItem {
          track {
            name
          }
        }
      }
    }
  }
}

* Add your OAuth bearer token to the Authorization header



curl 'https://ce.pandora.com/api/v1/graphql/graphql' \
  -H 'Authorization: Bearer ' \
  -H 'Content-Type: application/json' \
  -d '{"operationName":null,"variables":{},"query":"mutation {  playback { previous(deviceUuid: \"deviceXYZ\", sourceId: \"AL:1811731\", index: 1, elapsedTime: 200) { status current { ... on TrackItem { track { name } } } }  }}"}'

Response



{
  "data": {
    "playback": {
      "previous": {
        "status": "OK",
        "current": {
          "track": {
            "name": "Dreams"
          }
        }
      }
    }
  }
}