sign the tx in http-client-server-api.html, server would reject otherwise

This commit is contained in:
Scott Sadler
2016-12-02 13:47:36 +01:00
parent b2f2ce3523
commit 4ce7f4e95d

View File

@@ -60,9 +60,11 @@ Content-Type: application/json
def main():
""" Main function """
pubkey = '9RaWxppkP9UyYWA7NJb5FcgkzfJNPfvPX3FCNw2T5Pwb'
privkey = 'CfdqtD7sS7FgkMoGPXw55MVGGFwQLAoHYTcBhZDtF99Z'
pubkey = '4K9sWUMFwTgaDGPfdynrbxWqWS6sWmKbZoTjxLtVUibD'
asset = Asset(None, 'e6969f87-4fc9-4467-b62a-f0dfa1c85002')
tx = Transaction.create([pubkey], [([pubkey], 1)], asset=asset)
tx = tx.sign([privkey])
tx_json = json.dumps(tx.to_dict(), indent=2, sort_keys=True)
base_path = os.path.join(os.path.dirname(__file__),