Advertisement
Guest User

Untitled

a guest
Feb 21st, 2020
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.67 KB | None | 0 0
  1. import requests
  2.  
  3. payload = {
  4.         "v": "5.102",
  5.         "access_token": "64d2ccfb6b9319de58606ac7cbc59cc763d35887b6342d59d42845d9e7ef7d97c9f685e19078baf9fe7f7",
  6.         "user_id": 209377620,
  7.         "message": 'VKPay test',
  8.         "keyboard": {
  9.             "one_time": False,
  10.             "buttons": [
  11.                 [{
  12.                     "action": {
  13.                         "type": "vkpay",
  14.                         "hash": {
  15.                             "action": 'pay-to-group',
  16.                             "group_id": 170835296,
  17.                             "aid": 10,
  18.                             "amount": 1,
  19.                             "data": {
  20.                                 "sender": 209377620
  21.                             },
  22.                             "description": 'test payment'
  23.                         }
  24.                     }
  25.                 }]
  26.             ]
  27.         }
  28.     }
  29.  
  30. r = requests.post("https://api.vk.com/method/messages.send", data=payload)
  31. print(r)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement