Coder Social home page Coder Social logo

vkapi's Introduction

VK API

This is an ultimate library for vk.com API written in Python.

Installation

Just:

git clone https://github.com/ISosnovik/vkAPI
cd vkAPI
python setup.py install

General use

To begin with:

from vkapi.methods import *

You can use it exactly as it is described here. For example:

users.get(user_ids=1, fields='city')
#[{'city': 2, 'first_name': 'Pavel', 'last_name': 'Durov', 'uid': 1}]

Access Token

Some methods use access_token. It shouldn't be passed as a parameter to method. Nevertheless, it is defined as a class property token in vkapi.vkapi.Config class. Just set it at the beginnig:

from vkapi.methods import *
from vkapi import Config

Config.token = 'h3r3-1s-th3-4cc3ss-t0k3n'
account.getInfo(fields='country')

And that is it.

Documentation

All methods are provided with short description and reference to the official documentation. If you forget something, just call help or shift + tab + tab for Jupyter Notebook and you will get the description:

Help on function resolveScreenName in module vkapi.methods.utils:

resolveScreenName(screen_name=None)
    Detects a type of object (e.g., user, community, application)
    and its ID by screen name.
    https://vk.com/dev/utils.resolveScreenName

Examples

There are several examples of use of vkapi.

vkapi's People

Contributors

isosnovik avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

vkapi's Issues

Update API

Change the API, add some classes to make it Up-to-Date

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.