Skip to content

bultakov/aiopay

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 

Repository files navigation

alt text

Payme API uchun Asinxron kutubxona!!!


Boshlash

  • O'rnatish:
$ pip install -U aiopay
  • Example:
from asyncio import get_event_loop

from payme_uz.cards import PaymeSubscribeCard


async def main():
    card_api = PaymeSubscribeCard(
        paycom_id='paycom_id',
        debug=True
    )  # debug: True - sinov rejimi, False - ishlab chiqarish rejimi
    data = await card_api.create(number='860006******6311', expire='0399', save=True)
    print(data)
    await card_api.close()


if __name__ == '__main__':
    get_event_loop().run_until_complete(main())
  • Result:
{
  "jsonrpc": "2.0",
  "result": {
    "card": {
      "number": "860006******6311",
      "expire": "03/99",
      "token": "6308******5xUj",
      "recurrent": true,
      "verify": false,
      "type": "22618"
    }
  }
}