2017 © Pedro Peláez
 

library vkapi

Laravel helper for performing requests to VK API

image

bafoed/vkapi

Laravel helper for performing requests to VK API

  • Wednesday, July 13, 2016
  • by bafoed
  • Repository
  • 2 Watchers
  • 5 Stars
  • 245 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 3 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

Laravel VK API class

Install

Via Composer, (*1)

``` bash $ composer require bafoed/vkapi $ php artisan vendor:publish, (*2)


After updating composer, add the service provider to the `providers` array in `config/app.php` ``` php bafoed\VKAPI\VKAPIServiceProvider::class,

Also you can add alias to the aliases array in config/app.php, (*3)

``` php 'VKAPI' => bafoed\VKAPI\Facades\VKAPI::class,, (*4)


Do not forget to change `access_token` in `config/VKAPI.php` ## Usage Simple example (access_token is loaded from `config/VKAPI.php`) ``` php try { $result = VKAPI::call('users.get', ['user_ids' => '1,2,3']); foreach ($result as $user) { echo $user['first_name'] . ' ' . $user['last_name'] . PHP_EOL; } } catch(\bafoed\VKAPI\VKAPIException $e) { echo 'Something wrong: ' . $e->message; }

You can change access_token at runtime using setAccessToken method php VKAPI::setAccessToken('>>> INSERT TOKEN HERE <<<'), (*5)

Change log

Please see CHANGELOG for more information what has changed recently., (*6)

Contributing

Please see CONTRIBUTING and CONDUCT for details., (*7)

Security

If you discover any security related issues, please email bafoed@bafoed.ru instead of using the issue tracker., (*8)

Credits

License

The MIT License (MIT). Please see License File for more information., (*9)

The Versions

13/07 2016

dev-master

9999999-dev https://github.com/bafoed/laravel-vkapi

Laravel helper for performing requests to VK API

  Sources   Download

MIT

The Requires

 

The Development Requires

laravel vk vkapi bafoed