PHPackages                             vodka2/vk-audio-token - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Image &amp; Media](/categories/media)
4. /
5. vodka2/vk-audio-token

ActiveLibrary[Image &amp; Media](/categories/media)

vodka2/vk-audio-token
=====================

Library that obtains VK tokens that work for VK audio API. Библиотека для получения токена VK, подходящего для Audio API.

1.2(5y ago)1181.5k↑25%24[17 PRs](https://github.com/vodka2/vk-audio-token/pulls)MITPHP

Since Mar 15Pushed 3y ago13 watchersCompare

[ Source](https://github.com/vodka2/vk-audio-token)[ Packagist](https://packagist.org/packages/vodka2/vk-audio-token)[ RSS](/packages/vodka2-vk-audio-token/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (20)Used By (0)

Library that obtains VK tokens that work for VK audio API
=========================================================

[](#library-that-obtains-vk-tokens-that-work-for-vk-audio-api)

Read this in [russian](README.ru.md).

Python port of this library: [vodka2/vkaudiotoken-python](https://github.com/vodka2/vkaudiotoken-python)

This library obtains VK token, that works for VK audio API, so you can search artists, songs, albums, query audio URIs, add audios to "My audios" etc. The library supports Kate Mobile, Boom and VK Official clients. (Thanks to YTKABOBR for reversing the Boom client)

Actually there two versions of VK API, one for Kate Mobile and one for the official client. Boom client uses VK API somewhat similar to Kate one, but it has some limitations, not all methods are supported. Moreover it requires `messages` permission (do they scan our messages?) and sometimes returns 500 errors. On the other hand it supports another API in addition to VK API and may be used as a fallback.

Installation
------------

[](#installation)

```
composer require vodka2/vk-audio-token

```

... or simply copy the cloned repository somewhere and include `src/autoloader.php`. The library requires no dependencies.

Getting tokens
--------------

[](#getting-tokens)

The simplest example:

```
