GET All Playback Positions
Overview
Returns all saved playback positions for a specific user across all videos, sorted by most recently updated first. This can be used to build a "Continue Watching" section by displaying the user's in-progress videos with their watched duration.
| GET All Playback Positions | |
|---|---|
| Method | GET |
| URL or Endpoint | /position/userId |
| Headers | Not Applicable |
| Parameters | userId |
| Body | Not Applicable |
The description of the URL parameters is as follows:
| URL Parameter Name | Mandatory | Type | Description |
|---|---|---|---|
userId | Yes | string | Unique ID of the user. |
Request Body
The request does not contain a request body.
Response
[
{
"assetId": "{videoId}",
"position": "{position}",
"expiration": 0
}
]
Information about the fields that appear when you receive the response are displayed in the table below.
| Field Name | Type | Description |
|---|---|---|
assetId | string | Unique ID of the video. |
position | string | The playback position in seconds where the user last stopped watching the video. |
expiration | integer | Time-to-live in seconds until the position record expires. Positions are stored for one year from the last update. |
The results are sorted by expiration in descending order, meaning the most recently updated positions appear first.
If the action is successful, the service sends back an HTTP 200 response.
Errors
For information about the errors that are common to all actions, see Common Errors:
HTTP Status Code 400: Bad Request
HTTP Status Code 500: Internal Server Error
The base URL for this endpoint is not publicly listed. Contact VP Support to obtain the host URL for your project. The userId parameter corresponds to the value set via the player's setUserId() method. For setup details, see the Continue Watching guide.