From ebf1e1ec15f19b82f2f5e6fc850025b175ac1592 Mon Sep 17 00:00:00 2001 From: Leonov Kirill <25lvkl@gmail.com> Date: Sat, 20 Apr 2019 23:04:24 +0300 Subject: [PATCH 1/3] Implement groups.getTokenPermissions method --- src/VK/Actions/Groups.php | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/VK/Actions/Groups.php b/src/VK/Actions/Groups.php index fb1f8d4..841d49b 100644 --- a/src/VK/Actions/Groups.php +++ b/src/VK/Actions/Groups.php @@ -598,6 +598,18 @@ public function getSettings($access_token, array $params = []) { return $this->request->post('groups.getSettings', $access_token, $params); } + /** + * Returns community token permissions. + * + * @param string $access_token + * @throws VKApiException + * @throws VKClientException + * @return mixed + */ + public function getTokenPermissions($access_token) { + return $this->request->post('groups.getTokenPermissions', $access_token); + } + /** * Allows to invite friends to the community. * From a126e4134fb534a3ce97ef5b7a4968062544b876 Mon Sep 17 00:00:00 2001 From: Leonov Kirill <25lvkl@gmail.com> Date: Sat, 20 Apr 2019 23:05:09 +0300 Subject: [PATCH 2/3] Implement groups.addCallbackServer method --- src/VK/Actions/Groups.php | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/src/VK/Actions/Groups.php b/src/VK/Actions/Groups.php index 841d49b..496b24e 100644 --- a/src/VK/Actions/Groups.php +++ b/src/VK/Actions/Groups.php @@ -81,6 +81,23 @@ public function addAddress($access_token, array $params = []) { return $this->request->post('groups.addAddress', $access_token, $params); } + /** + * Add callback server to community. + * + * @param string $access_token + * @param array $params + * - @var integer group_id + * - @var string url + * - @var string title + * - @var string secret_key + * @throws VKApiException + * @throws VKClientException + * @return mixed + */ + public function addCallbackServer($access_token, array $params = []) { + return $this->request->post('groups.addCallbackServer', $access_token, $params); + } + /** * Allows to add a link to the community. * From af8ca36490926e38e06d419ba90ca472da6c37be Mon Sep 17 00:00:00 2001 From: Leonov Kirill <25lvkl@gmail.com> Date: Sat, 20 Apr 2019 23:07:50 +0300 Subject: [PATCH 3/3] Implement groups.getCallbackServers method --- src/VK/Actions/Groups.php | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/src/VK/Actions/Groups.php b/src/VK/Actions/Groups.php index 496b24e..2a32830 100644 --- a/src/VK/Actions/Groups.php +++ b/src/VK/Actions/Groups.php @@ -454,6 +454,21 @@ public function getCallbackConfirmationCode($access_token, array $params = []) { return $this->request->post('groups.getCallbackConfirmationCode', $access_token, $params); } + /** + * Returns callback servers information. + * + * @param string $access_token + * @param array $params + * - @var integer group_id + * - @var string server_ids + * @return mixed + * @throws VKApiException + * @throws VKClientException + */ + public function getCallbackServers($access_token, array $params = []) { + return $this->request->post('groups.getCallbackServers', $access_token, $params); + } + /** * Returns [vk.com/dev/callback_api|Callback API] notifications settings. *