# Playlists List

API call format

GET /broker/playlists					//Use token autorization
GET /broker/private/playlists			//Use Api Key

Description

This call gets all available playlists.

Precondition

  • Authorization token/Api key is needed.

Postcondition

  • On success response code should be 200
  • On success the whole JSON body of the available video playlists is returned with details.
  • On failure an error will be returned with the right error code and description.

Example:

[Request] GET https://<base_api_url>/broker/playlists
[Request] GET https://<base_api_url>/broker/private/playlists
[Request Headers] {"Content-Type":"application/json","Accept":"application/json","Authorization":"<IdToken>"} //Use token autorization
[Request Headers] {"Content-Type":"application/json","Accept":"application/json","X-Api-Key":"<api_key>"}     //Use Api Key

[Response] 200
[Response Headers] {"Content-Type":["application/json"],"Content-Length":["..."],"Connection":["keep-alive"],"Date":["..... GMT"],"x-amzn-RequestId":["....."],....]}
[Response] 
{
	"status": true,
	"data": 
	[
		{
			"guid": "<playlist_guid_01>",
			"name": "<playlist_name_01>",
			"sources": 
			[
				{
					"duration": 88074,
					"totalDuration": 88074,
					"guid": "<source_guid_01>",
					"type": "source",
					"meta": 
					{
						"description": "<source_description>",
						"type": "source",
						"title": "<source_title>",
						"imageUrl": "https://<server>/sources/<source_guid>/thumbnails/a195c2d0fb299646a9daa38f8031f74d_abr_tumb.0000015.jpg"
					}
				},

				{
					"duration": 132238,
					"totalDuration": 132238,
					"guid": "<source_guid_02>",
					"type": "source",
					"meta": 
					{
						"description": "<source_description>",
						"type": "source",
						"title": "<source_title>",
						"imageUrl": "https://<server>/sources/<source_guid>/thumbnails/a195c2d0fb299646a9daa38f8031f74d_abr_tumb.0000015.jpg"
					}
				},
				...
			],

			"duration": 660936,
			"title": "Test Title",
			"description": "Test Descr"
		},

		{
			"guid": "<playlist_guid_02>",
			"name": "<playlist_name_02>",
			"sources": 
			[
				{
					"duration": 88074,
					"totalDuration": 88074,
					"guid": "<source_guid_01>",
					"type": "source",
					"meta": 
					{
						"description": "<source_description>",
						"type": "source",
						"title": "<source_title>",
						"imageUrl": "https://<server>/sources/<source_guid>/thumbnails/a195c2d0fb299646a9daa38f8031f74d_abr_tumb.0000015.jpg"
					}
				},
			
				{
					"duration": 132238,
					"totalDuration": 132238,
					"guid": "<source_guid_02>",
					"type": "source",
					"meta": 
					{
						"description": "<source_description>",
						"type": "source",
						"title": "<source_title>",
						"imageUrl": "https://<server>/sources/<source_guid>/thumbnails/a195c2d0fb299646a9daa38f8031f74d_abr_tumb.0000015.jpg"
					}
				},
				...
			],

			"duration": 660936,
			"title": "Test Title",
			"color": "#E84B3C"
		}
		...
	]
}