Skip to content
This repository has been archived by the owner on Dec 24, 2021. It is now read-only.

Commit

Permalink
Fixed Python3 compatibility issues
Browse files Browse the repository at this point in the history
  • Loading branch information
Pieter Poorthuis committed Aug 25, 2017
1 parent b2cfd59 commit 3f45611
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
8 changes: 4 additions & 4 deletions examples/test_merchant_facade.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from bitpay.bitpay_exceptions import *
import bitpay.bitpay_key_utils as bku
from bitpay.bitpay_client import *
from bitpay.exceptions import *
import bitpay.key_utils as bku
from bitpay.client import *
import pprint
import requests
import json
Expand Down Expand Up @@ -87,7 +87,7 @@ def post_to_bitpay_api(client, uri, resource, params):

#Now we assume that the pairing code that we generated along with the crypto keys is paired with your merchant account
#
print "We will create an invoice using the merchant facade"
print("We will create an invoice using the merchant facade")

invoice = client.create_invoice({"price": 50.00, "currency": "USD", "token": client.tokens['merchant']})

Expand Down
8 changes: 4 additions & 4 deletions examples/test_payouts.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from bitpay.bitpay_exceptions import *
import bitpay.bitpay_key_utils as bku
from bitpay.bitpay_client import *
from bitpay.exceptions import *
import bitpay.key_utils as bku
from bitpay.client import *
import pprint
import requests
import json
Expand Down Expand Up @@ -89,7 +89,7 @@ def post_to_bitpay_api(client, uri, resource, params):
print("Creating a payout batch now")
print("token = " + token)
# posting a payout batch
params = {"token":token, "notificationURL":"http://app-1494237706.000webhostapp.com/IPNlogger.php", "notificationEmail":"pieter@bitpay.com", "effectiveDate":"2017-08-23", "amount":"400","currency":"USD","instructions":[ {"label":"Test1","address":"mzDTjhkfJfatXHRUWKcE2BXxHt4Pfz2PK7","amount":"300"},{"label":"Test2","address":"mfadguj41aYgEwPATAFnkKcKQNqhpNTrdi","amount":"100"}]}
params = {"token":token, "notificationURL":"http://test.merchant.com/IPNlogger.php", "notificationEmail":"test@merchant.com", "effectiveDate":"2017-08-23", "amount":"400","currency":"USD","instructions":[ {"label":"Test1","address":"mzDTjhkfJfatXHRUWKcE2BXxHt4Pfz2PK7","amount":"300"},{"label":"Test2","address":"mfadguj41aYgEwPATAFnkKcKQNqhpNTrdi","amount":"100"}]}
payoutBatch = post_to_bitpay_api(client, "https://test.bitpay.com", "payouts", params)
pp.pprint(payoutBatch)

0 comments on commit 3f45611

Please sign in to comment.