aiomailru
aiomailru is a python Mail.Ru API wrapper. The main features are:
authorization (Authorization Code, Implicit Flow, Password Grant, Refresh Token)
REST API methods
web scrapers
Usage
To use Mail.Ru API you need a registered app and Mail.Ru account. For more details, see aiomailru Documentation.
Client application
Use ClientSession when REST API is needed in:
a client component of the client-server application
a standalone mobile/desktop application
i.e. when you embed your app’s info (private key) in publicly available code.
from aiomailru import ClientSession, API
session = ClientSession(app_id, private_key, access_token, uid)
api = API(session)
events = await api.stream.get()
friends = await api.friends.getOnline()
Use access_token and uid
that were received after authorization. For more details, see
authorization instruction.
Server application
Use ServerSession when REST API is needed in:
a server component of the client-server application
requests from your servers
from aiomailru import ServerSession, API
session = ServerSession(app_id, secret_key, access_token)
api = API(session)
events = await api.stream.get()
friends = await api.friends.getOnline()
Use access_token that was received after authorization.
For more details, see
authorization instruction.
Installation
$ pip install aiomailru
or
$ python setup.py install
Supported Python Versions
Python 3.5, 3.6, 3.7 and 3.8 are supported.
Test
Run all tests.
$ python setup.py test
Run tests with PyTest.
$ python -m pytest [-k TEST_NAME]
License
aiomailru is released under the BSD 2-Clause License.
Release files for aiomailru 0.1.1.post1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| aiomailru-0.1.1.post1.tar.gz | 20.0 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| aiomailru-0.1.1.post1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 43.4 kB
Release files / aiomailru-0.1.1.post1.tar.gz
| Download URL | aiomailru-0.1.1.post1.tar.gz |
|---|---|
| Size | 20.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7e102948ba13871f6e5d78a99cde9d981b318e3ab2f87ac6a2a83ff4abbbed51
|
|
BLAKE2b-256 checksum How to use checksums |
88dfbd696a1427bed80f4f747404bf2b8cbc0f3245f48cd30146575614b85709
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.15.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.5.6
|
Release files / aiomailru-0.1.1.post1-py3-none-any.whl
| Download URL | aiomailru-0.1.1.post1-py3-none-any.whl |
|---|---|
| Size | 23.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
be4f9f340c002466afbb4a8f9dcdcee3729fb40ed1ee729621df5970512c16b7
|
|
BLAKE2b-256 checksum How to use checksums |
4f9825abf73bb304f7f9a99afd3836c2c1b368d577525270126f948edf5120d2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.15.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.5.6
|