opentok 4.1.0 → 4.5.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (67) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/ci.yml +30 -0
  3. data/.github/workflows/metrics.yml +17 -0
  4. data/CHANGES.md +171 -0
  5. data/README.md +62 -38
  6. data/lib/opentok/archive.rb +54 -4
  7. data/lib/opentok/archives.rb +115 -11
  8. data/lib/opentok/broadcast.rb +50 -3
  9. data/lib/opentok/broadcast_list.rb +14 -0
  10. data/lib/opentok/broadcasts.rb +178 -19
  11. data/lib/opentok/client.rb +251 -0
  12. data/lib/opentok/connections.rb +1 -1
  13. data/lib/opentok/constants.rb +1 -0
  14. data/lib/opentok/exceptions.rb +3 -1
  15. data/lib/opentok/opentok.rb +16 -10
  16. data/lib/opentok/render.rb +78 -0
  17. data/lib/opentok/render_list.rb +14 -0
  18. data/lib/opentok/renders.rb +101 -0
  19. data/lib/opentok/session.rb +4 -4
  20. data/lib/opentok/sip.rb +40 -2
  21. data/lib/opentok/streams.rb +49 -2
  22. data/lib/opentok/token_generator.rb +1 -0
  23. data/lib/opentok/version.rb +1 -1
  24. data/opentok.gemspec +2 -1
  25. data/sample/Broadcast/README.md +42 -0
  26. data/sample/Broadcast/broadcast_sample.rb +15 -0
  27. data/sample/Broadcast/views/all.erb +46 -0
  28. data/sample/Broadcast/views/index.erb +16 -1
  29. data/spec/cassettes/OpenTok_Archives/adds_a_stream_to_an_archive.yml +37 -0
  30. data/spec/cassettes/OpenTok_Archives/removes_a_stream_from_an_archive.yml +37 -0
  31. data/spec/cassettes/OpenTok_Archives/should_create_an_archive_with_matching_multi_archive_tag_when_multiArchiveTag_is_specified.yml +50 -0
  32. data/spec/cassettes/OpenTok_Archives/should_create_an_archive_with_multi_archive_tag_value_of_nil_when_multiArchiveTag_not_specified.yml +49 -0
  33. data/spec/cassettes/OpenTok_Archives/should_create_an_archives_with_a_specified_multiArchiveTag.yml +52 -0
  34. data/spec/cassettes/OpenTok_Archives/should_create_layout_archives_with_screenshare_layout_types.yml +50 -0
  35. data/spec/cassettes/OpenTok_Broadcasts/adds_a_stream_to_a_broadcast.yml +37 -0
  36. data/spec/cassettes/OpenTok_Broadcasts/for_many_broadcasts/should_return_all_broadcasts.yml +192 -0
  37. data/spec/cassettes/OpenTok_Broadcasts/for_many_broadcasts/should_return_broadcasts_with_an_offset.yml +117 -0
  38. data/spec/cassettes/OpenTok_Broadcasts/for_many_broadcasts/should_return_count_number_of_broadcasts.yml +92 -0
  39. data/spec/cassettes/OpenTok_Broadcasts/for_many_broadcasts/should_return_part_of_the_broadcasts_when_using_offset_and_count.yml +142 -0
  40. data/spec/cassettes/OpenTok_Broadcasts/for_many_broadcasts/should_return_session_broadcasts.yml +117 -0
  41. data/spec/cassettes/OpenTok_Broadcasts/removes_a_stream_from_a_broadcast.yml +37 -0
  42. data/spec/cassettes/OpenTok_Broadcasts/starts_a_broadcast_with_a_matching_multi_broadcast_tag_value_when_multiBroadcastTag_is_specified.yml +54 -0
  43. data/spec/cassettes/OpenTok_Broadcasts/starts_a_broadcast_with_a_multi_broadcast_tag_value_of_nil_when_multiBroadcastTag_not_specified.yml +53 -0
  44. data/spec/cassettes/OpenTok_Broadcasts/starts_a_broadcast_with_a_specified_multiBroadcastTag.yml +54 -0
  45. data/spec/cassettes/OpenTok_Renders/finds_an_Experience_Composer_render.yml +46 -0
  46. data/spec/cassettes/OpenTok_Renders/for_many_renders/should_return_all_renders.yml +108 -0
  47. data/spec/cassettes/OpenTok_Renders/for_many_renders/should_return_count_number_of_renders.yml +63 -0
  48. data/spec/cassettes/OpenTok_Renders/for_many_renders/should_return_part_of_the_renders_when_using_offset_and_count.yml +63 -0
  49. data/spec/cassettes/OpenTok_Renders/for_many_renders/should_return_renders_with_an_offset.yml +74 -0
  50. data/spec/cassettes/OpenTok_Renders/starts_an_Experience_Composer_render.yml +48 -0
  51. data/spec/cassettes/OpenTok_Renders/stops_an_Experience_Composer_render.yml +28 -0
  52. data/spec/cassettes/OpenTok_Sip/_play_dtmf_to_connection/returns_a_200_response_code_when_passed_a_valid_dtmf_digit_string.yml +39 -0
  53. data/spec/cassettes/OpenTok_Sip/_play_dtmf_to_session/returns_a_200_response_code_when_passed_a_valid_dtmf_digit_string.yml +39 -0
  54. data/spec/cassettes/OpenTok_Sip/receives_a_valid_response.yml +2 -2
  55. data/spec/cassettes/OpenTok_Streams/disables_the_mute_state_of_a_session.yml +37 -0
  56. data/spec/cassettes/OpenTok_Streams/forces_all_current_and_future_streams_in_a_session_to_be_muted.yml +39 -0
  57. data/spec/cassettes/OpenTok_Streams/forces_all_current_and_future_streams_in_a_session_to_be_muted_except_specified_excluded_streams.yml +39 -0
  58. data/spec/cassettes/OpenTok_Streams/forces_the_specified_stream_to_be_muted.yml +39 -0
  59. data/spec/opentok/archives_spec.rb +61 -0
  60. data/spec/opentok/broadcasts_spec.rb +157 -1
  61. data/spec/opentok/connection_spec.rb +1 -1
  62. data/spec/opentok/opentok_spec.rb +6 -0
  63. data/spec/opentok/renders_spec.rb +142 -0
  64. data/spec/opentok/sip_spec.rb +32 -1
  65. data/spec/opentok/streams_spec.rb +21 -1
  66. metadata +75 -7
  67. data/.travis.yml +0 -17
@@ -0,0 +1,37 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: patch
5
+ uri: https://api.opentok.com/v2/project/123456/broadcast/13dbcc23-af92-4862-9184-74b21815a814/streams
6
+ body:
7
+ encoding: UTF-8
8
+ string: '{"removeStream":"12312312-3811-4726-b508-e41a0f96c68f"}'
9
+ headers:
10
+ User-Agent:
11
+ - OpenTok-Ruby-SDK/<%= version %>
12
+ X-Opentok-Auth:
13
+ - eyJpc3QiOiJwcm9qZWN0IiwiYWxnIjoiSFMyNTYifQ.eyJpc3MiOiIxMjM0NTYiLCJpYXQiOjE0OTI1MTA2NjAsImV4cCI6MTQ5MjUxMDk2MH0.BplMVhJWx4ld7KLKXqEmow6MjNPPFw9W8IHCMfeb120
14
+ Content-Type:
15
+ - application/json
16
+ Accept-Encoding:
17
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
18
+ Accept:
19
+ - "*/*"
20
+ response:
21
+ status:
22
+ code: 204
23
+ message: No Content
24
+ headers:
25
+ Server:
26
+ - nginx
27
+ Date:
28
+ - Tue, 23 Nov 2021 20:49:23 GMT
29
+ Connection:
30
+ - keep-alive
31
+ Set-Cookie:
32
+ - AWSALBTG=IVCBek0mkrwLClWNRdLjy1iFNSsOxBPlYS4DBo6ihXHl5qScay403/clceKAPEMdaMxF6eUaou388eSdkjuZ9olWCDF49IGVNCP4gmF8O9Ajvjqhh/cVuzMKL5kOrkjSgjVouTyOyAT3K4NaPfM+U6sBd7UQ0HhTHgND5lsgfSu9Y27EKj8=;
33
+ Expires=Tue, 30 Nov 2021 20:49:22 GMT; Path=/
34
+ - AWSALBTGCORS=IVCBek0mkrwLClWNRdLjy1iFNSsOxBPlYS4DBo6ihXHl5qScay403/clceKAPEMdaMxF6eUaou388eSdkjuZ9olWCDF49IGVNCP4gmF8O9Ajvjqhh/cVuzMKL5kOrkjSgjVouTyOyAT3K4NaPfM+U6sBd7UQ0HhTHgND5lsgfSu9Y27EKj8=;
35
+ Expires=Tue, 30 Nov 2021 20:49:22 GMT; Path=/; SameSite=None; Secure
36
+ recorded_at: Tue, 18 Apr 2017 10:17:40 GMT
37
+ recorded_with: VCR 6.0.0
@@ -0,0 +1,54 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: https://api.opentok.com/v2/project/123456/broadcast
6
+ body:
7
+ encoding: UTF-8
8
+ string: '{"sessionId":"SESSIONID","outputs":{"hls":{}},"multiBroadcastTag":"broadcast-1"}'
9
+ headers:
10
+ User-Agent:
11
+ - OpenTok-Ruby-SDK/<%= version %>
12
+ X-Opentok-Auth:
13
+ - eyJpc3QiOiJwcm9qZWN0IiwiYWxnIjoiSFMyNTYifQ.eyJpc3MiOiIxMjM0NTYiLCJpYXQiOjE0OTI1MTA2NjAsImV4cCI6MTQ5MjUxMDk2MH0.BplMVhJWx4ld7KLKXqEmow6MjNPPFw9W8IHCMfeb120
14
+ Content-Type:
15
+ - application/json
16
+ Accept-Encoding:
17
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
18
+ Accept:
19
+ - "*/*"
20
+ response:
21
+ status:
22
+ code: 200
23
+ message: OK
24
+ headers:
25
+ Server:
26
+ - nginx
27
+ Date:
28
+ - Mon, 03 Oct 2022 11:11:31 GMT
29
+ Content-Type:
30
+ - application/json; charset=utf-8
31
+ Connection:
32
+ - keep-alive
33
+ body:
34
+ encoding: UTF-8
35
+ string: |-
36
+ {
37
+ "id":"BROADCASTID",
38
+ "sessionId":"SESSIONID",
39
+ "projectId":123456,
40
+ "createdAt":1538086900154,
41
+ "broadcastUrls":
42
+ {
43
+ "hls":"https://cdn-broadcast001-pdx.tokbox.com/14787/14787_b930bf08-1c9f-4c55-ab04-7d192578c057.smil/playlist.m3u8"
44
+ },
45
+ "updatedAt":1538086900489,
46
+ "status":"started",
47
+ "maxDuration":7200,
48
+ "resolution":"640x480",
49
+ "partnerId":100,
50
+ "event":"broadcast",
51
+ "multiBroadcastTag":"broadcast-1"
52
+ }
53
+ recorded_at: Tue, 18 Apr 2017 10:17:40 GMT
54
+ recorded_with: VCR 6.0.0
@@ -0,0 +1,53 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: https://api.opentok.com/v2/project/123456/broadcast
6
+ body:
7
+ encoding: UTF-8
8
+ string: '{"sessionId":"SESSIONID","outputs":{"hls":{}}}'
9
+ headers:
10
+ User-Agent:
11
+ - OpenTok-Ruby-SDK/<%= version %>
12
+ X-Opentok-Auth:
13
+ - eyJpc3QiOiJwcm9qZWN0IiwiYWxnIjoiSFMyNTYifQ.eyJpc3MiOiIxMjM0NTYiLCJpYXQiOjE0OTI1MTA2NjAsImV4cCI6MTQ5MjUxMDk2MH0.BplMVhJWx4ld7KLKXqEmow6MjNPPFw9W8IHCMfeb120
14
+ Content-Type:
15
+ - application/json
16
+ Accept-Encoding:
17
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
18
+ Accept:
19
+ - "*/*"
20
+ response:
21
+ status:
22
+ code: 200
23
+ message: OK
24
+ headers:
25
+ Server:
26
+ - nginx
27
+ Date:
28
+ - Mon, 03 Oct 2022 11:11:31 GMT
29
+ Content-Type:
30
+ - application/json; charset=utf-8
31
+ Connection:
32
+ - keep-alive
33
+ body:
34
+ encoding: UTF-8
35
+ string: |-
36
+ {
37
+ "id":"BROADCASTID",
38
+ "sessionId":"SESSIONID",
39
+ "projectId":123456,
40
+ "createdAt":1538086900154,
41
+ "broadcastUrls":
42
+ {
43
+ "hls":"https://cdn-broadcast001-pdx.tokbox.com/14787/14787_b930bf08-1c9f-4c55-ab04-7d192578c057.smil/playlist.m3u8"
44
+ },
45
+ "updatedAt":1538086900489,
46
+ "status":"started",
47
+ "maxDuration":7200,
48
+ "resolution":"640x480",
49
+ "partnerId":100,
50
+ "event":"broadcast"
51
+ }
52
+ recorded_at: Tue, 18 Apr 2017 10:17:40 GMT
53
+ recorded_with: VCR 6.0.0
@@ -0,0 +1,54 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: https://api.opentok.com/v2/project/123456/broadcast
6
+ body:
7
+ encoding: UTF-8
8
+ string: '{"sessionId":"SESSIONID","outputs":{"hls":{}},"multiBroadcastTag":"broadcast-1"}'
9
+ headers:
10
+ User-Agent:
11
+ - OpenTok-Ruby-SDK/<%= version %>
12
+ X-Opentok-Auth:
13
+ - eyJpc3QiOiJwcm9qZWN0IiwiYWxnIjoiSFMyNTYifQ.eyJpc3MiOiIxMjM0NTYiLCJpYXQiOjE0OTI1MTA2NjAsImV4cCI6MTQ5MjUxMDk2MH0.BplMVhJWx4ld7KLKXqEmow6MjNPPFw9W8IHCMfeb120
14
+ Content-Type:
15
+ - application/json
16
+ Accept-Encoding:
17
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
18
+ Accept:
19
+ - "*/*"
20
+ response:
21
+ status:
22
+ code: 200
23
+ message: OK
24
+ headers:
25
+ Server:
26
+ - nginx
27
+ Date:
28
+ - Wed, 07 Sep 2022 13:52:17 GMT
29
+ Content-Type:
30
+ - application/json
31
+ Connection:
32
+ - keep-alive
33
+ body:
34
+ encoding: UTF-8
35
+ string: |-
36
+ {
37
+ "id":"BROADCASTID",
38
+ "sessionId":"SESSIONID",
39
+ "projectId":123456,
40
+ "createdAt":1538086900154,
41
+ "broadcastUrls":
42
+ {
43
+ "hls":"https://cdn-broadcast001-pdx.tokbox.com/14787/14787_b930bf08-1c9f-4c55-ab04-7d192578c057.smil/playlist.m3u8"
44
+ },
45
+ "updatedAt":1538086900489,
46
+ "status":"started",
47
+ "maxDuration":7200,
48
+ "resolution":"640x480",
49
+ "partnerId":100,
50
+ "event":"broadcast",
51
+ "multiBroadcastTag":"broadcast-1"
52
+ }
53
+ recorded_at: Tue, 18 Apr 2017 10:17:40 GMT
54
+ recorded_with: VCR 6.0.0
@@ -0,0 +1,46 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: https://api.opentok.com/v2/project/123456/render/80abaf0d-25a3-4efc-968f-6268d620668d
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers:
10
+ User-Agent:
11
+ - OpenTok-Ruby-SDK/<%= version %>
12
+ X-Opentok-Auth:
13
+ - eyJpc3QiOiJwcm9qZWN0IiwiYWxnIjoiSFMyNTYifQ.eyJpc3MiOiIxMjM0NTYiLCJpYXQiOjE0OTI1MTA2NjAsImV4cCI6MTQ5MjUxMDk2MH0.BplMVhJWx4ld7KLKXqEmow6MjNPPFw9W8IHCMfeb120
14
+ Accept-Encoding:
15
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
16
+ Accept:
17
+ - "*/*"
18
+ response:
19
+ status:
20
+ code: 200
21
+ message: OK
22
+ headers:
23
+ Server:
24
+ - nginx
25
+ Date:
26
+ - Thu, 15 Sep 2022 10:25:36 GMT
27
+ Content-Type:
28
+ - application/json
29
+ Connection:
30
+ - keep-alive
31
+ body:
32
+ encoding: UTF-8
33
+ string: |-
34
+ {
35
+ "id": "80abaf0d-25a3-4efc-968f-6268d620668d",
36
+ "sessionId": "SESSIONID",
37
+ "projectId": "e2343f23456g34709d2443a234",
38
+ "createdAt": 1437676551000,
39
+ "updatedAt": 1437676551000,
40
+ "url": "https://example.com/my-render",
41
+ "resolution": "1280x720",
42
+ "status": "started",
43
+ "streamId": "e32445b743678c98230f238"
44
+ }
45
+ recorded_at: Tue, 18 Apr 2017 10:17:40 GMT
46
+ recorded_with: VCR 6.0.0
@@ -0,0 +1,108 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: https://api.opentok.com/v2/project/123456/render
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers:
10
+ User-Agent:
11
+ - OpenTok-Ruby-SDK/<%= version %>
12
+ X-Opentok-Auth:
13
+ - eyJpc3QiOiJwcm9qZWN0IiwiYWxnIjoiSFMyNTYifQ.eyJpc3MiOiIxMjM0NTYiLCJpYXQiOjE0OTI1MTA2NjAsImV4cCI6MTQ5MjUxMDk2MH0.BplMVhJWx4ld7KLKXqEmow6MjNPPFw9W8IHCMfeb120
14
+ Accept-Encoding:
15
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
16
+ Accept:
17
+ - "*/*"
18
+ response:
19
+ status:
20
+ code: 200
21
+ message: OK
22
+ headers:
23
+ Server:
24
+ - nginx
25
+ Date:
26
+ - Thu, 15 Sep 2022 11:09:53 GMT
27
+ Content-Type:
28
+ - application/json
29
+ Connection:
30
+ - keep-alive
31
+ body:
32
+ encoding: UTF-8
33
+ string: |-
34
+ {
35
+ "count":6,
36
+ "items":[
37
+ {
38
+ "id":"80abaf0d-25a3-4efc-968f-6268d620668d",
39
+ "sessionId":"1_MX4yNzA4NjYxMn5-MTU0NzA4MDUyMTEzNn5sOXU5ZnlWYXplRnZGblV4RUo3dXJpZk1-fg",
40
+ "projectId":"27086612",
41
+ "createdAt":1547080532099,
42
+ "updatedAt":1547080532099,
43
+ "url": "https://example.com/my-render",
44
+ "resolution": "1280x720",
45
+ "status": "started",
46
+ "streamId": "d2334b35690a92f78945"
47
+ },
48
+ {
49
+ "id":"d95f6496-df6e-4f49-86d6-832e00303602",
50
+ "sessionId":"2_MX4yNzA4NjYxMn5-MTU0NzA4MDUwMDc2MH5STWRiSE1jZjVoV3lBQU9nN2JuNElUV3V-fg",
51
+ "projectId":"27086612",
52
+ "createdAt":1547080511760,
53
+ "updatedAt":1547080518965,
54
+ "url": "https://example.com/my-render",
55
+ "resolution": "1280x720",
56
+ "status":"stopped",
57
+ "streamId": "d2334b35690a92f78945",
58
+ "reason":"Max duration exceeded"
59
+ },
60
+ {
61
+ "id":"96abaf0d-25a3-4efc-968f-6268d620668d",
62
+ "sessionId":"3_MX4yNzA4NjYxMn5-MTU0NzA4MDUyMTEzNn5sOXU5ZnlWYXplRnZGblV4RUo3dXJpZk1-fg",
63
+ "projectId":"27086612",
64
+ "createdAt":1547080532099,
65
+ "updatedAt":1547080532099,
66
+ "url": "https://example.com/my-render",
67
+ "resolution": "1280x720",
68
+ "status": "started",
69
+ "streamId": "d2334b35690a92f78946"
70
+ },
71
+ {
72
+ "id":"c34f6496-df6e-4f49-86d6-832e00303602",
73
+ "sessionId":"4_MX4yNzA4NjYxMn5-MTU0NzA4MDUwMDc2MH5STWRiSE1jZjVoV3lBQU9nN2JuNElUV3V-fg",
74
+ "projectId":"27086612",
75
+ "createdAt":1547080511760,
76
+ "updatedAt":1547080518965,
77
+ "url": "https://example.com/my-render",
78
+ "resolution": "1280x720",
79
+ "status":"stopped",
80
+ "streamId": "d2334b35690a92f78912",
81
+ "reason":"Stop Requested"
82
+ },
83
+ {
84
+ "id":"52abaf0d-25a3-4efc-968f-6268d620668d",
85
+ "sessionId":"1_MX4yNzA4NjYxMn5-MTU0NzA4MDUyMTEzNn5sOXU5ZnlWYXplRnZGblV4RUo3dXJpZk1-fg",
86
+ "projectId":"27086612",
87
+ "createdAt":1547080532099,
88
+ "updatedAt":1547080532099,
89
+ "url": "https://example.com/my-render",
90
+ "resolution": "1280x720",
91
+ "status": "started",
92
+ "streamId": "d2334b35690a92f78948"
93
+ },
94
+ {
95
+ "id":"a87f6496-df6e-4f49-86d6-832e00303602",
96
+ "sessionId":"2_MX4yNzA4NjYxMn5-MTU0NzA4MDUwMDc2MH5STWRiSE1jZjVoV3lBQU9nN2JuNElUV3V-fg",
97
+ "projectId":"27086612",
98
+ "createdAt":1547080511760,
99
+ "updatedAt":1547080518965,
100
+ "url": "https://example.com/my-render",
101
+ "resolution": "1280x720",
102
+ "status":"starting",
103
+ "streamId": "d2334b35690a92f78947"
104
+ }
105
+ ]
106
+ }
107
+ recorded_at: Tue, 18 Apr 2017 10:17:40 GMT
108
+ recorded_with: VCR 6.0.0
@@ -0,0 +1,63 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: https://api.opentok.com/v2/project/123456/render?count=2
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers:
10
+ User-Agent:
11
+ - OpenTok-Ruby-SDK/<%= version %>
12
+ X-Opentok-Auth:
13
+ - eyJpc3QiOiJwcm9qZWN0IiwiYWxnIjoiSFMyNTYifQ.eyJpc3MiOiIxMjM0NTYiLCJpYXQiOjE0OTI1MTA2NjAsImV4cCI6MTQ5MjUxMDk2MH0.BplMVhJWx4ld7KLKXqEmow6MjNPPFw9W8IHCMfeb120
14
+ Accept-Encoding:
15
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
16
+ Accept:
17
+ - "*/*"
18
+ response:
19
+ status:
20
+ code: 200
21
+ message: OK
22
+ headers:
23
+ Server:
24
+ - nginx
25
+ Date:
26
+ - Thu, 15 Sep 2022 11:32:24 GMT
27
+ Content-Type:
28
+ - application/json
29
+ Connection:
30
+ - keep-alive
31
+ body:
32
+ encoding: UTF-8
33
+ string: |-
34
+ {
35
+ "count":2,
36
+ "items":[
37
+ {
38
+ "id":"80abaf0d-25a3-4efc-968f-6268d620668d",
39
+ "sessionId":"1_MX4yNzA4NjYxMn5-MTU0NzA4MDUyMTEzNn5sOXU5ZnlWYXplRnZGblV4RUo3dXJpZk1-fg",
40
+ "projectId":"27086612",
41
+ "createdAt":1547080532099,
42
+ "updatedAt":1547080532099,
43
+ "url": "https://example.com/my-render",
44
+ "resolution": "1280x720",
45
+ "status": "started",
46
+ "streamId": "d2334b35690a92f78945"
47
+ },
48
+ {
49
+ "id":"d95f6496-df6e-4f49-86d6-832e00303602",
50
+ "sessionId":"2_MX4yNzA4NjYxMn5-MTU0NzA4MDUwMDc2MH5STWRiSE1jZjVoV3lBQU9nN2JuNElUV3V-fg",
51
+ "projectId":"27086612",
52
+ "createdAt":1547080511760,
53
+ "updatedAt":1547080518965,
54
+ "url": "https://example.com/my-render",
55
+ "resolution": "1280x720",
56
+ "status":"stopped",
57
+ "streamId": "d2334b35690a92f78945",
58
+ "reason":"Max duration exceeded"
59
+ }
60
+ ]
61
+ }
62
+ recorded_at: Tue, 18 Apr 2017 10:17:40 GMT
63
+ recorded_with: VCR 6.0.0
@@ -0,0 +1,63 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: https://api.opentok.com/v2/project/123456/render?count=2&offset=2
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers:
10
+ User-Agent:
11
+ - OpenTok-Ruby-SDK/<%= version %>
12
+ X-Opentok-Auth:
13
+ - eyJpc3QiOiJwcm9qZWN0IiwiYWxnIjoiSFMyNTYifQ.eyJpc3MiOiIxMjM0NTYiLCJpYXQiOjE0OTI1MTA2NjAsImV4cCI6MTQ5MjUxMDk2MH0.BplMVhJWx4ld7KLKXqEmow6MjNPPFw9W8IHCMfeb120
14
+ Accept-Encoding:
15
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
16
+ Accept:
17
+ - "*/*"
18
+ response:
19
+ status:
20
+ code: 200
21
+ message: OK
22
+ headers:
23
+ Server:
24
+ - nginx
25
+ Date:
26
+ - Thu, 15 Sep 2022 11:34:05 GMT
27
+ Content-Type:
28
+ - application/json
29
+ Connection:
30
+ - keep-alive
31
+ body:
32
+ encoding: UTF-8
33
+ string: |-
34
+ {
35
+ "count":2,
36
+ "items":[
37
+ {
38
+ "id":"96abaf0d-25a3-4efc-968f-6268d620668d",
39
+ "sessionId":"3_MX4yNzA4NjYxMn5-MTU0NzA4MDUyMTEzNn5sOXU5ZnlWYXplRnZGblV4RUo3dXJpZk1-fg",
40
+ "projectId":"27086612",
41
+ "createdAt":1547080532099,
42
+ "updatedAt":1547080532099,
43
+ "url": "https://example.com/my-render",
44
+ "resolution": "1280x720",
45
+ "status": "started",
46
+ "streamId": "d2334b35690a92f78946"
47
+ },
48
+ {
49
+ "id":"c34f6496-df6e-4f49-86d6-832e00303602",
50
+ "sessionId":"4_MX4yNzA4NjYxMn5-MTU0NzA4MDUwMDc2MH5STWRiSE1jZjVoV3lBQU9nN2JuNElUV3V-fg",
51
+ "projectId":"27086612",
52
+ "createdAt":1547080511760,
53
+ "updatedAt":1547080518965,
54
+ "url": "https://example.com/my-render",
55
+ "resolution": "1280x720",
56
+ "status":"stopped",
57
+ "streamId": "d2334b35690a92f78912",
58
+ "reason":"Stop Requested"
59
+ }
60
+ ]
61
+ }
62
+ recorded_at: Tue, 18 Apr 2017 10:17:40 GMT
63
+ recorded_with: VCR 6.0.0
@@ -0,0 +1,74 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: https://api.opentok.com/v2/project/123456/render?offset=3
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers:
10
+ User-Agent:
11
+ - OpenTok-Ruby-SDK/<%= version %>
12
+ X-Opentok-Auth:
13
+ - eyJpc3QiOiJwcm9qZWN0IiwiYWxnIjoiSFMyNTYifQ.eyJpc3MiOiIxMjM0NTYiLCJpYXQiOjE0OTI1MTA2NjAsImV4cCI6MTQ5MjUxMDk2MH0.BplMVhJWx4ld7KLKXqEmow6MjNPPFw9W8IHCMfeb120
14
+ Accept-Encoding:
15
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
16
+ Accept:
17
+ - "*/*"
18
+ response:
19
+ status:
20
+ code: 200
21
+ message: OK
22
+ headers:
23
+ Server:
24
+ - nginx
25
+ Date:
26
+ - Thu, 15 Sep 2022 11:29:00 GMT
27
+ Content-Type:
28
+ - application/json
29
+ Connection:
30
+ - keep-alive
31
+ body:
32
+ encoding: UTF-8
33
+ string: |-
34
+ {
35
+ "count":3,
36
+ "items":[
37
+ {
38
+ "id":"c34f6496-df6e-4f49-86d6-832e00303602",
39
+ "sessionId":"4_MX4yNzA4NjYxMn5-MTU0NzA4MDUwMDc2MH5STWRiSE1jZjVoV3lBQU9nN2JuNElUV3V-fg",
40
+ "projectId":"27086612",
41
+ "createdAt":1547080511760,
42
+ "updatedAt":1547080518965,
43
+ "url": "https://example.com/my-render",
44
+ "resolution": "1280x720",
45
+ "status":"stopped",
46
+ "streamId": "d2334b35690a92f78912",
47
+ "reason":"Stop Requested"
48
+ },
49
+ {
50
+ "id":"52abaf0d-25a3-4efc-968f-6268d620668d",
51
+ "sessionId":"1_MX4yNzA4NjYxMn5-MTU0NzA4MDUyMTEzNn5sOXU5ZnlWYXplRnZGblV4RUo3dXJpZk1-fg",
52
+ "projectId":"27086612",
53
+ "createdAt":1547080532099,
54
+ "updatedAt":1547080532099,
55
+ "url": "https://example.com/my-render",
56
+ "resolution": "1280x720",
57
+ "status": "started",
58
+ "streamId": "d2334b35690a92f78948"
59
+ },
60
+ {
61
+ "id":"a87f6496-df6e-4f49-86d6-832e00303602",
62
+ "sessionId":"2_MX4yNzA4NjYxMn5-MTU0NzA4MDUwMDc2MH5STWRiSE1jZjVoV3lBQU9nN2JuNElUV3V-fg",
63
+ "projectId":"27086612",
64
+ "createdAt":1547080511760,
65
+ "updatedAt":1547080518965,
66
+ "url": "https://example.com/my-render",
67
+ "resolution": "1280x720",
68
+ "status":"starting",
69
+ "streamId": "d2334b35690a92f78947"
70
+ }
71
+ ]
72
+ }
73
+ recorded_at: Tue, 18 Apr 2017 10:17:40 GMT
74
+ recorded_with: VCR 6.0.0
@@ -0,0 +1,48 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: https://api.opentok.com/v2/project/123456/render
6
+ body:
7
+ encoding: UTF-8
8
+ string: '{"sessionId":"SESSIONID","token":"TOKEN","url":"https://example.com/my-render"}'
9
+ headers:
10
+ User-Agent:
11
+ - OpenTok-Ruby-SDK/<%= version %>
12
+ X-Opentok-Auth:
13
+ - eyJpc3QiOiJwcm9qZWN0IiwiYWxnIjoiSFMyNTYifQ.eyJpc3MiOiIxMjM0NTYiLCJpYXQiOjE0OTI1MTA2NjAsImV4cCI6MTQ5MjUxMDk2MH0.BplMVhJWx4ld7KLKXqEmow6MjNPPFw9W8IHCMfeb120
14
+ Content-Type:
15
+ - application/json
16
+ Accept-Encoding:
17
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
18
+ Accept:
19
+ - "*/*"
20
+ response:
21
+ status:
22
+ code: 202
23
+ message: Accepted
24
+ headers:
25
+ Server:
26
+ - nginx
27
+ Date:
28
+ - Thu, 15 Sep 2022 10:25:36 GMT
29
+ Content-Type:
30
+ - application/json
31
+ Connection:
32
+ - keep-alive
33
+ body:
34
+ encoding: UTF-8
35
+ string: |-
36
+ {
37
+ "id": "80abaf0d-25a3-4efc-968f-6268d620668d",
38
+ "sessionId": "SESSIONID",
39
+ "projectId": "e2343f23456g34709d2443a234",
40
+ "createdAt": 1437676551000,
41
+ "updatedAt": 1437676551000,
42
+ "url": "https://example.com/my-render",
43
+ "resolution": "1280x720",
44
+ "status": "starting",
45
+ "streamId": "e32445b743678c98230f238"
46
+ }
47
+ recorded_at: Tue, 18 Apr 2017 10:17:40 GMT
48
+ recorded_with: VCR 6.0.0
@@ -0,0 +1,28 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: delete
5
+ uri: https://api.opentok.com/v2/project/123456/render/80abaf0d-25a3-4efc-968f-6268d620668d
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers:
10
+ User-Agent:
11
+ - OpenTok-Ruby-SDK/<%= version %>
12
+ X-Opentok-Auth:
13
+ - eyJpc3QiOiJwcm9qZWN0IiwiYWxnIjoiSFMyNTYifQ.eyJpc3MiOiIxMjM0NTYiLCJpYXQiOjE0OTI1MTA2NjAsImV4cCI6MTQ5MjUxMDk2MH0.BplMVhJWx4ld7KLKXqEmow6MjNPPFw9W8IHCMfeb120
14
+ Accept-Encoding:
15
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
16
+ Accept:
17
+ - "*/*"
18
+ response:
19
+ status:
20
+ code: 204
21
+ message: No Content
22
+ headers:
23
+ Date:
24
+ - Thu, 15 Sep 2022 10:51:54 GMT
25
+ Connection:
26
+ - keep-alive
27
+ recorded_at: Tue, 18 Apr 2017 10:17:40 GMT
28
+ recorded_with: VCR 6.0.0
@@ -0,0 +1,39 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: https://api.opentok.com/v2/project/123456/session/SESSIONID/connection/CONNID/play-dtmf
6
+ body:
7
+ encoding: UTF-8
8
+ string: '{"digits":"0123456789*#p"}'
9
+ headers:
10
+ User-Agent:
11
+ - OpenTok-Ruby-SDK/<%= version %>
12
+ X-Opentok-Auth:
13
+ - eyJpc3QiOiJwcm9qZWN0IiwiYWxnIjoiSFMyNTYifQ.eyJpc3MiOiIxMjM0NTYiLCJpYXQiOjE0OTI1MTA2NjAsImV4cCI6MTQ5MjUxMDk2MH0.BplMVhJWx4ld7KLKXqEmow6MjNPPFw9W8IHCMfeb120
14
+ Content-Type:
15
+ - application/json
16
+ Accept-Encoding:
17
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
18
+ Accept:
19
+ - "*/*"
20
+ response:
21
+ status:
22
+ code: 200
23
+ message: OK
24
+ headers:
25
+ Server:
26
+ - nginx
27
+ Date:
28
+ - Mon, 01 Nov 2021 12:27:19 GMT
29
+ Content-Type:
30
+ - application/xml
31
+ Content-Length:
32
+ - '177'
33
+ Connection:
34
+ - keep-alive
35
+ body:
36
+ encoding: UTF-8
37
+ string: ""
38
+ recorded_at: Tue, 18 Apr 2017 10:17:40 GMT
39
+ recorded_with: VCR 6.0.0