Created
November 8, 2012 02:11
-
-
Save jondanao/4036113 to your computer and use it in GitHub Desktop.
iWantv API 1.0
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Get episode details | |
GET /episodes/?token=xxxxxxxxxx&episode_id=1234 | |
{ | |
"episode_id": 1234, | |
"show_id": 1234, | |
"channel_id": 1234, | |
"title": "A Beautiful Affair", | |
"air_date": "2012-11-08", | |
"playable": false, | |
"synopsis": "Lorem ipsum dolor sit amet", | |
"cast": [ | |
{ | |
"name": "John Lloyd Cruz", | |
"character": "Napoleon Riego" | |
}, | |
... | |
], | |
"genre": [ | |
"Drama", | |
"Teleserye", | |
... | |
], | |
"media": { | |
"image_small": "/absolute/path/to/image.jpg", | |
"image_medium": "/absolute/path/to/image.jpg", | |
"image_large": "/absolute/path/to/image.jpg", | |
"video": "/absolute/path/to/video" | |
}, | |
"stats": { | |
"views": 12345, | |
"comments": 12345, | |
"in_playlist": 12345, | |
"in_favorites": 12345 | |
}, | |
"link": "link/to/iwantv/episode/page", | |
"metadata": { | |
"episode_id": 1234 | |
} | |
} | |
// Get show details | |
GET /shows/?token=xxxxxxxxxx&show_id=1234 | |
{ | |
"show_id": 1234, | |
"title": "A Beautiful Affair", | |
"description": "Lorem ipsum dolor sit amet", | |
"episodes": [ | |
{ | |
// Refer to episode object | |
}, | |
... | |
], | |
"media": { | |
"image_small": "/absolute/path/to/image.jpg", | |
"image_medium": "/absolute/path/to/image.jpg", | |
"image_large": "/absolute/path/to/image.jpg" | |
}, | |
"metadata": { | |
"show_id": 1234 | |
} | |
} | |
// List all shows in a channel | |
GET /channels/?token=xxxxxxxxxx&channel_id=1234 | |
{ | |
"channel_id": 1234, | |
"title": "ABS-CBN", | |
"features": [ | |
{ | |
"title": "Featured", // Recently Added, Most Watched, Most Viewed | |
"shows": [ | |
{ | |
// Refer to show object | |
}, | |
... // 4 items total | |
] | |
}, | |
... | |
], | |
"shows": [ | |
... // Refer to show object | |
], | |
"schedule": [ | |
{ | |
"day": "Sunday", | |
"timeslot": [ | |
{ | |
"time": "6:00 AM", | |
"show": "Healing Eucharist" | |
}, | |
{ | |
"time": "7:00 AM", | |
"show": "Kabuhayang Swak na Swak" | |
}, | |
... | |
] | |
}, | |
... | |
], | |
"media": { | |
"image_small": "/absolute/path/to/image.jpg", | |
"image_medium": "/absolute/path/to/image.jpg", | |
"image_large": "/absolute/path/to/image.jpg", | |
"video": "/absolute/path/to/live/video" | |
}, | |
"metadata": { | |
"channel_id": 1234 | |
} | |
} | |
// List all channels | |
GET /channels/?token=xxxxxxxxxx | |
{ | |
"features": [ | |
{ | |
"title": "Featured", // Recently Added, Most Watched, Most Viewed | |
"shows": [ | |
{ | |
// Refer to show objects | |
}, | |
... // 4 items total | |
] | |
}, | |
... | |
], | |
"channels": [ | |
... // Refer to channel objects | |
], | |
"metadata": { | |
} | |
} | |
// Commenting on certain episode | |
GET /comments/?token=xxxxxxxxxx&episode_id=1234&rpp=10&page=1 | |
{ | |
"comments": [ | |
{ | |
"firstname": "Vanessa", | |
"avatar": "path/to/avatar", | |
"post_date": "2012-11-08 10:00:00", | |
"text": "Lorem ipsum dolor" | |
}, | |
... | |
], | |
"metadata": { | |
"total": 1000, | |
"rpp": 10, | |
"page": 1, | |
"episode_id": 1234 | |
} | |
} | |
POST /comments/?token=xxxxxxxxxx&episode_id=1234&text=Lorem+ipsum+dolor | |
{ | |
"success": true, | |
"comments": [ | |
{ | |
"firstname": "Vanessa", | |
"avatar": "path/to/avatar", | |
"post_date": "2012-11-08 10:00:00", | |
"text": "Lorem ipsum dolor" | |
}, | |
... | |
], | |
"metadata": { | |
"total": 1000, | |
"rpp": 10, | |
"page": 1, | |
"episode_id": 1234, | |
"text": "lorem ipsum dolor" | |
} | |
} | |
// Favoriting an episode | |
POST /favorites/?token=xxxxxxxxxx&episode_id=1234 | |
{ | |
"success": true, | |
"metadata": { | |
"episode_id": 1234 | |
} | |
} | |
// Playlisting an episode | |
POST /playlists/?token=xxxxxxxxxx&episode_id=1234 | |
{ | |
"success": true, | |
"metadata": { | |
"episode_id": 1234 | |
} | |
} | |
// Search | |
GET /search/?token=xxxxxxxxxx&query=lorem+ipsum&rpp=10&page=1 | |
{ | |
"results": [ | |
{ | |
"id": 1234, | |
"title": "A Beautiful Affair", | |
"media": { | |
"image_small": "/absolute/path/to/image.jpg", | |
"image_medium": "/absolute/path/to/image.jpg", | |
"image_large": "/absolute/path/to/image.jpg" | |
}, | |
"type": "movie" | |
} | |
], | |
"metadata": { | |
"total": 1000, | |
"rpp": 10, | |
"page": 1, | |
"query": "lorem ipsum" | |
} | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment