Skip to content
This repository has been archived by the owner on Apr 11, 2020. It is now read-only.

rnovatorov/async-vk-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

57 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build Status codecov

async-vk-api

Async VK API built with asks and trio.

Inspired by vk.

Installation

Stable from PyPi

pip install async-vk-api

Latest from Github

pip install git+https://github.com/Suenweek/async-vk-api#egg=async-vk-api

Usage

import os

import trio
import async_vk_api


async def main():
    # Make API
    access_token = os.getenv('VK_API_ACCESS_TOKEN')
    api = async_vk_api.make_api(access_token, version='5.89')

    # Use methods
    user, = await api.users.get(user_ids=1)
    assert user['id'] == 1
    assert user['first_name'] == 'Pavel'
    assert user['last_name'] == 'Durov'


if __name__ == '__main__':
    trio.run(main)

For the list of available methods see https://vk.com/dev/methods.

About

Async VK API built with asks and trio.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages