-
Notifications
You must be signed in to change notification settings - Fork 1
/
apiary.apib
130 lines (89 loc) · 3.13 KB
/
apiary.apib
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
FORMAT: 1A
# raiapi
RaiPlay API to retrieve tv program information and files for the past seven days
## Canali Collection [/api/canali]
### List All Canali [GET]
Lists all the available channels
+ Response 200 (application/json; charset=utf-8)
[
{
"id": 0,
"name": "RaiUno"
}
]
## Programmi Collection [/api/canali/{canaleId}/programmi]
### List All Programmi [GET]
Lists available programs given a channel
+ Parameters
+ canaleId: `0` (int) - Canale ID
+ Response 200 (application/json; charset=utf-8)
[
{
"id": 0,
"name": "TG1 NOTTE"
}
]
## Qualità Collection [/api/canali/{canaleId}/programmi/{programmaId}/qualita]
### List All Qualità [GET]
Lists available quality for a given program
+ Parameters
+ canaleId: `0` (int) - Canale ID
+ programmaId: `0` (int) - Programma ID
+ Response 200 (application/json; charset=utf-8)
[
{
"id": 0,
"name": "h264 800"
},
{
"id": 1,
"name": "h264 1200"
},
{
"id": 2,
"name": "h264 1800"
}
]
## File URL [/api/canali/{canaleId}/programmi/{programmaId}/qualita/{qualitaId}/url]
### Get URL [GET]
Gets video file URL
+ Parameters
+ canaleId: `0` (int) - Canale ID
+ programmaId: `0` (int) - Programma ID
+ qualitaId: `0` (int) - Qualita ID
+ Response 200 (application/json; charset=utf-8)
{
"url": "http://distribution.bbb3d.renderfarming.net/video/mp4/bbb_sunflower_1080p_30fps_normal.mp4"
}
## File [/api/canali/{canaleId}/programmi/{programmaId}/qualita/{qualitaId}/file]
### Get File [GET]
Redirects to te file URL
+ Parameters
+ canaleId: `0` (int) - Canale ID
+ programmaId: `0` (int) - Programma ID
+ qualitaId: `0` (int) - Qualita ID
+ Response 302
+ Headers
Location: http://distribution.bbb3d.renderfarming.net/video/mp4/bbb_sunflower_1080p_30fps_normal.mp4
+ Body
Found Redirecting to http://distribution.bbb3d.renderfarming.net/video/mp4/bbb_sunflower_1080p_30fps_normal.mp4
## RSS [/rss/canali/{canaleId}.xml]
### Get RSS [GET]
Gets video files RSS feed
+ Parameters
+ canaleId: `0` (int) - Canale ID
+ Response 200 (text/xml; charset=utf-8)
+ Headers
Cache-Control: public, max-age=86400
+ Body
<rss version="2.0" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:atom="http://www.w3.org/2005/Atom">
<channel>
<title>Rai API - RaiUno</title>
<description>Rai API RSS feed for RaiUno</description>
<generator>raiapi.js</generator>
<link>https://localhost</link>
<language>it-IT</language>
<copyright>(c) 2016 localhost</copyright>
<atom:link href="https://localhost/canali/0/rss.xml" rel="self" type="application/rss+xml" />
</channel>
</rss>