1+ <?php
2+
3+ namespace UDX \Zoom \Endpoint ;
4+
5+ use UDX \Zoom \Http \Request ;
6+
7+ /**
8+ * Class Recordings
9+ * @package UDX\Zoom\Endpoint
10+ */
11+ class Recordings extends Request {
12+
13+ /**
14+ * Recordings constructor.
15+ * @param $apiKey
16+ * @param $apiSecret
17+ */
18+ public function __construct ($ apiKey , $ apiSecret ) {
19+ parent ::__construct ($ apiKey , $ apiSecret );
20+ }
21+
22+ /**
23+ * List
24+ *
25+ * @param $userId
26+ * @param array $query
27+ * @return array|mixed
28+ */
29+ public function listAll (string $ userId , array $ query = []) {
30+ return $ this ->get ("users/ {$ userId }/recordings " , $ query );
31+ }
32+
33+ /**
34+ * Meeting
35+ *
36+ * @param $meetingId
37+ * @return array|mixed
38+ */
39+ public function meeting (string $ meetingId ) {
40+ return $ this ->get ("meetings/ {$ meetingId }/recordings " );
41+ }
42+
43+ /**
44+ * Remove All
45+ *
46+ * @param $meetingId
47+ * @param array $query
48+ * @return array|mixed
49+ */
50+ public function removeAll (string $ meetingId , array $ query = [ 'action ' => 'trash ' ]) {
51+ return $ this ->delete ("meetings/ {$ meetingId }/recordings " , $ query );
52+ }
53+
54+ /**
55+ * Remove
56+ *
57+ * @param $meetingId
58+ * @param $recordingId
59+ * @param array $query
60+ * @return array|mixed
61+ */
62+ public function remove (string $ meetingId , string $ recordingId , array $ query = [ 'action ' => 'trash ' ]) {
63+ return $ this ->delete ("meetings/ {$ meetingId }/recordings/ {$ recordingId }" , $ query );
64+ }
65+
66+ /**
67+ * Recover All
68+ *
69+ * @param $meetingId
70+ * @param array $data
71+ * @return array|mixed
72+ */
73+ public function recoverAll (string $ meetingId , array $ data = [ 'action ' => 'recover ' ]) {
74+ return $ this ->put ("meetings/ {$ meetingId }/recordings/status " , $ data );
75+ }
76+
77+ /**
78+ * Recover
79+ *
80+ * @param $meetingId
81+ * @param $recordingId
82+ * @param array $data
83+ * @return array|mixed
84+ */
85+ public function recover (string $ meetingId , string $ recordingId , array $ data = [ 'action ' => 'recover ' ]) {
86+ return $ this ->put ("meetings/ {$ meetingId }/recordings/ {$ recordingId }/status " , $ data );
87+ }
88+
89+ }
0 commit comments