Transferring Funds

Learn how you can transfer funds from one wallet to another

You can transfer funds between any two wallets you have created provided that:

  1. Both of the wallets are active
  2. The source wallet has sufficient funds for the transfer to succeed

The transfer can be done by using our Transfer funds endpoint by specifying:

  • the source and destination wallets, as well as
  • the amount to transfer

An example of how to do this is given below.

import os
import requests

API_URL = "https://api.dba.thepennyinc.com/v1"
ACCESS_TOKEN = os.getenv("PENNY_ACCESS_TOKEN")

headers = {
  "Authorization": f"Bearer {ACCESS_TOKEN}"
}

payload = {
  "from_wallet": "<source wallet ID>",
  "to_wallet": "<to wallet ID>",
  "amount": 100
}

response = requests.post(API_URL + "/wallets/transfer_funds", json=payload, headers=headers)