Last active
July 30, 2016 00:51
-
-
Save fredzannarbor/08ee12e03d0155605e870743c1f8d8f5 to your computer and use it in GitHub Desktop.
baby client
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
from two1.wallet import Wallet | |
from two1.bitrequests import BitTransferRequests | |
# set up bitrequest client for BitTransfer requests | |
wallet = Wallet() | |
requests = BitTransferRequests(wallet) | |
# server address | |
server_url = 'http://localhost:5000/' | |
def buy_fortune(): | |
url = server_url+'buy?payout_address={0}' | |
response = requests.get(url=url.format(wallet.get_payout_address())) | |
print(response.text) | |
if __name__ == '__main__': | |
buy_fortune() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment