Metadata-Version: 2.1
Name: aaio
Version: 1.0.5
Summary: Async AAIO api wrapper for python
Author-email: kewldan <kewldanil1@gmail.com>
License: MIT License
        
        Copyright (c) 2023 Daniil Tenishev
        
        Permission is hereby granted, free of charge, to any person obtaining a copy
        of this software and associated documentation files (the "Software"), to deal
        in the Software without restriction, including without limitation the rights
        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the Software is
        furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in all
        copies or substantial portions of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
        SOFTWARE.
        
Project-URL: Homepage, https://github.com/kewldan/AAIO
Keywords: payments,api
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Requires-Python: >=3.6
Description-Content-Type: text/markdown
License-File: LICENSE

# AAIO API for Python 3

<a href="https://aaio.io/" target="_blank">
	<img src="https://aaio.io/assets/svg/banners/big/dark-2.svg" title="Aaio - Сервис по приему онлайн платежей">
</a>

[AAIO Official documentation](https://wiki.aaio.io/)

## About

This library is a wrapper for the https://aaio.io API **from enthusiasts**. All methods are described and all types are
explicitly defined. The library does not handle any exceptions, so be careful. Methods that create requests to aaio.io
return an unprocessed server response in JSON format (Parsing JSON on the library side). A new session is used for each request. (Maybe will be
revised in future). Please write about all problems related to the library in issues. API is up-to-date as of *25 August
2023*.

* PyPl - https://pypi.org/project/aaio/
* Github - https://github.com/kewldan/AAIO
* Requirements: Python >= 3.6
* Added to AAIO SDKs

## Library Installation

* Install via pip: `pip install aaio`
* Download sources - `git clone https://github.com/kewldan/AAIO`

## Getting Started

### Get user balance

```python
import asyncio

import aaio


async def main():
    client = aaio.AAIO('MERCHANT ID', 'SECRET KEY', 'API KEY')
    balances = await client.get_balances()
    #  balances = {
    #      "type": "success",
    #      "balance": 50.43, // Текущий доступный баланс
    #      "referal": 0, // Текущий реферальный баланс
    #      "hold": 1.57 // Текущий замороженный баланс
    #  }
    balance = balances['balance']
    print(balance)  # 50.43


asyncio.run(main())
```

### Create payment URL for customer

```python
import aaio

client = aaio.AAIO('MERCHANT ID', 'SECRET KEY', 'API KEY')
payment_url = client.create_payment(100, 'my_order_id', 'My order description', 'qiwi', 'support@aaio.io',
                                    'referral code', currency='USD',
                                    language='en')  # Not send request, just build a URL from parameters!
print(payment_url)  # Prints payment url for customer
```

#### Contact
E-Mail - kewldanil1@gmail.com
Telegram - [@kewldan](https://t.me/kewldan)
