Shift72 Content API (1.0.0)

Download OpenAPI specification:Download

User Library

Get my user library

Gets the library content and plans for the current user

Authorizations:
AuthToken
query Parameters
location
string

override the users location, used for plan-as-library content

Responses

Response Schema: application/json
required
Array of objects (LibraryItem)
Array
ownership
required
string
Enum: "rent" "buy" "plan"

How you own the content. Plan content only appears here if the plan has been flagged as a library plan

type
required
string
Enum: "film" "film-bonus" "tv-season" "tv-episode" "tv-season-bonus"
slug
required
string
title
string
available_from
string

ISO8601 timestamp The start of the content's availability window. The content cannot be watched before this time

available_to
string

ISO8601 timestamp The end of the content's availability window. The content cannot be watched after this time.

expiry
string

ISO8601 timestamp. The rental expiry. If the watch window has been triggered, this will be the end of the watch window

is_expired
boolean

Has your rental expired?

watch_window_duration
number

Duration of the watch window for a rental, in minutes. Once you start playing the content, you will have this long to finish.

watch_window_start
string

If rental watch window has been triggered, this is when it started. ISO8601 UTC timestamp, or null

watch_window_end
string

If rental watch window has been triggered, this is when it will end. ISO8601 UTC timestamp or null. You must finish watching the content by this time.

plan_id
number

Plan content only. This is the plan ID that granted it

object

Where were you up to? This is based off playback telemetry and only accurate to about 30 seconds.

play_position
required
number

the position in seconds

last_played_at
string

when did you last watch?

length
required
number

how long is the content

completed
required
boolean

have you watched most of it? (>80%) this is used to determine if a player should just start over

required
Array of objects
Array
plan_id
required
number
expiry
required
string

Response samples

Content type
application/json
{
  • "items": [
    • {
      • "ownership": "rent",
      • "type": "film",
      • "slug": "string",
      • "title": "string",
      • "available_from": "string",
      • "available_to": "string",
      • "expiry": "string",
      • "is_expired": true,
      • "watch_window_duration": 0,
      • "watch_window_start": "string",
      • "watch_window_end": "string",
      • "plan_id": 0,
      • "playback_progress": {
        }
      }
    ],
  • "plans": [
    • {
      • "plan_id": 0,
      • "expiry": "string"
      }
    ]
}

Get a user library by User ID

A user can request to see their own library, or a privileged user can view others libraries.

Authorizations:
AuthTokenAdminAuthTokenApiKey
path Parameters
user_id
required
integer <int32>

User ID

query Parameters
location
string

override the users location for plan-as-library content

Responses

Response Schema: application/json
required
Array of objects (LibraryItem)
Array
ownership
required
string
Enum: "rent" "buy" "plan"

How you own the content. Plan content only appears here if the plan has been flagged as a library plan

type
required
string
Enum: "film" "film-bonus" "tv-season" "tv-episode" "tv-season-bonus"
slug
required
string
title
string
available_from
string

ISO8601 timestamp The start of the content's availability window. The content cannot be watched before this time

available_to
string

ISO8601 timestamp The end of the content's availability window. The content cannot be watched after this time.

expiry
string

ISO8601 timestamp. The rental expiry. If the watch window has been triggered, this will be the end of the watch window

is_expired
boolean

Has your rental expired?

watch_window_duration
number

Duration of the watch window for a rental, in minutes. Once you start playing the content, you will have this long to finish.

watch_window_start
string

If rental watch window has been triggered, this is when it started. ISO8601 UTC timestamp, or null

watch_window_end
string

If rental watch window has been triggered, this is when it will end. ISO8601 UTC timestamp or null. You must finish watching the content by this time.

plan_id
number

Plan content only. This is the plan ID that granted it

object

Where were you up to? This is based off playback telemetry and only accurate to about 30 seconds.

play_position
required
number

the position in seconds

last_played_at
string

when did you last watch?

length
required
number

how long is the content

completed
required
boolean

have you watched most of it? (>80%) this is used to determine if a player should just start over

required
Array of objects
Array
plan_id
required
number
expiry
required
string

Response samples

Content type
application/json
{
  • "items": [
    • {
      • "ownership": "rent",
      • "type": "film",
      • "slug": "string",
      • "title": "string",
      • "available_from": "string",
      • "available_to": "string",
      • "expiry": "string",
      • "is_expired": true,
      • "watch_window_duration": 0,
      • "watch_window_start": "string",
      • "watch_window_end": "string",
      • "plan_id": 0,
      • "playback_progress": {
        }
      }
    ],
  • "plans": [
    • {
      • "plan_id": 0,
      • "expiry": "string"
      }
    ]
}