-
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: added new enties and updated composer
- Loading branch information
1 parent
a379319
commit 11fb027
Showing
33 changed files
with
3,838 additions
and
1,311 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
<?php | ||
|
||
namespace Offlineagency\LaravelWebex\Api\Meetings; | ||
|
||
use Offlineagency\LaravelWebex\Api\AbstractApi; | ||
use Offlineagency\LaravelWebex\Entities\Error; | ||
use Offlineagency\LaravelWebex\Entities\Meetings\MeetingChats as MeetingChatsEntity; | ||
|
||
class MeetingChats extends AbstractApi | ||
{ | ||
public function listChats( | ||
string $meetingId, | ||
?array $additional_data = [] | ||
) { | ||
$additional_data = $this->data($additional_data, [ | ||
'max', 'offset' | ||
]); | ||
|
||
$response = $this->get('meetings/postMeetingChats', array_merge([ | ||
'meeting_Id' => $meetingId | ||
], $additional_data)); | ||
|
||
if (! $response->success) { | ||
return new Error($response->data); | ||
} | ||
|
||
$meetings = $response->data; | ||
|
||
return array_map(function ($meeting) { | ||
return new MeetingChatsEntity($meeting); | ||
}, $meetings->items); | ||
} | ||
|
||
public function destroyChats( | ||
string $meeting_id | ||
) { | ||
|
||
$response = $this->delete('meetings/postMeetingChats'.$meeting_id, [ | ||
'meeting_Id' => $meeting_id | ||
]); | ||
|
||
if (! $response->success) { | ||
return new Error($response->data); | ||
} | ||
|
||
return 'Meeting chats deleted'; | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
<?php | ||
|
||
namespace Offlineagency\LaravelWebex\Api\Meetings; | ||
|
||
use Offlineagency\LaravelWebex\Api\AbstractApi; | ||
use Offlineagency\LaravelWebex\Entities\Error; | ||
use Offlineagency\LaravelWebex\Entities\Meetings\MeetingClosedCaptions as MeetingClosedCaptionsEntity; | ||
|
||
class MeetingClosedCaptions extends AbstractApi | ||
{ | ||
public function listClosedCaptions( | ||
string $meetingId | ||
) { | ||
$response = $this->get('meetingClosedCaptions', [ | ||
'meetingId' => $meetingId, | ||
]); | ||
|
||
if (! $response->success) { | ||
return new Error($response->data); | ||
} | ||
|
||
$meeting_invitees = $response->data; | ||
|
||
return array_map(function ($meeting_invitee) { | ||
return new MeetingClosedCaptionsEntity($meeting_invitee); | ||
}, $meeting_invitees->items); | ||
} | ||
|
||
public function listClosedCaptionSnippets( | ||
string $closedCaptionId, | ||
string $meetingId | ||
) { | ||
$response = $this->get('meetingClosedCaptions/'.$closedCaptionId.'/snippets', [ | ||
'meetingId' => $meetingId, | ||
]); | ||
|
||
if (! $response->success) { | ||
return new Error($response->data); | ||
} | ||
|
||
$meeting_invitees = $response->data; | ||
|
||
return array_map(function ($meeting_invitee) { | ||
return new MeetingClosedCaptionsEntity($meeting_invitee); | ||
}, $meeting_invitees->items); | ||
} | ||
|
||
public function downloadClosedCaptionSnippets( | ||
string $closedCaptionId, | ||
string $meetingId, | ||
?array $additional_data = [] | ||
) { | ||
$additional_data = $this->data($additional_data, [ | ||
'format' | ||
]); | ||
|
||
$response = $this->get('meetingClosedCaptions/'.$closedCaptionId.'/download', array_merge([ | ||
'meetingId' => $meetingId, | ||
], $additional_data)); | ||
|
||
if (! $response->success) { | ||
return new Error($response->data); | ||
} | ||
|
||
return new MeetingClosedCaptionsEntity($response->data); | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
<?php | ||
|
||
namespace Offlineagency\LaravelWebex\Api\Meetings; | ||
|
||
use Offlineagency\LaravelWebex\Api\AbstractApi; | ||
use Offlineagency\LaravelWebex\Entities\Error; | ||
|
||
class MeetingMessages extends AbstractApi | ||
{ | ||
|
||
public function destroyMessage( | ||
string $meetingMessageId | ||
) { | ||
$response = $this->delete('meeting/messages/'.$meetingMessageId, []); | ||
|
||
if (! $response->success) { | ||
return new Error($response->data); | ||
} | ||
|
||
return 'Meeting Message deleted'; | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
<?php | ||
|
||
namespace Offlineagency\LaravelWebex\Api\Meetings; | ||
|
||
use Offlineagency\LaravelWebex\Api\AbstractApi; | ||
use Offlineagency\LaravelWebex\Entities\Error; | ||
use Offlineagency\LaravelWebex\Entities\Meetings\MeetingPolls as MeetingPollsEntity; | ||
|
||
class MeetingPolls extends AbstractApi | ||
{ | ||
public function listPolls( | ||
string $meetingId | ||
) { | ||
$response = $this->get('meetings/polls', [ | ||
'meeting_Id' => $meetingId, | ||
]); | ||
|
||
if (! $response->success) { | ||
return new Error($response->data); | ||
} | ||
|
||
$meetingPolls = $response->data; | ||
|
||
return array_map(function ($meetingPolls) { | ||
return new MeetingPollsEntity($meetingPolls); | ||
}, $meetingPolls->items); | ||
} | ||
|
||
public function detailPollResults( | ||
string $meetingId, | ||
?array $additional_data = [] | ||
) { | ||
$additional_data = $this->data($additional_data, [ | ||
'max' | ||
]); | ||
|
||
$response = $this->get('meetings/pollResults', array_merge([ | ||
'meetingId' => $meetingId, | ||
], $additional_data)); | ||
|
||
if (! $response->success) { | ||
return new Error($response->data); | ||
} | ||
|
||
return new MeetingPollsEntity($response->data); | ||
} | ||
|
||
public function listRespondentsQuestion( | ||
string $pollId, | ||
string $questionId, | ||
string $meetingId, | ||
?array $additional_data = [] | ||
) { | ||
$additional_data = $this->data($additional_data, [ | ||
'max' | ||
]); | ||
|
||
$response = $this->get('meetings/polls/'.$pollId.'/questions/'.$questionId.'/respondents', array_merge([ | ||
'meetingId' => $meetingId, | ||
], $additional_data)); | ||
|
||
if (! $response->success) { | ||
return new Error($response->data); | ||
} | ||
|
||
$listRespondentsQuestion = $response->data; | ||
|
||
return array_map(function ($listRespondentsQuestion) { | ||
return new MeetingPollsEntity($listRespondentsQuestion); | ||
}, $listRespondentsQuestion->items); | ||
} | ||
} |
Oops, something went wrong.