Python library for the TransferWise API
Project description
pywisetransfer
An unofficial, experimental Python client library for the TransferWise API.
:warning: The classes, functions and interfaces that this library provides are very much in-development and prone to change.
Installation
# Within your project directory
pip install pywisetransfer
Usage
API Requests
import pywisetransfer
client = pywisetransfer.Client(api_key="your-api-key-here")
for profile in client.profiles.list():
accounts = client.borderless_accounts.list(profile_id=profile.id)
for account in accounts:
currencies = [balance.currency for balance in account.balances]
print(f"AccountID={account.id}, Currencies={currencies}")
Webhook signature verification
from flask import abort, request
from pywisetransfer.webhooks import validate_request
@app.route("/payments/wise/webhooks")
def handle_wise_webhook():
try:
validate_request(request)
except Exception as e:
logger.error(f"Wise webhook request validation failed: {e}")
abort(400)
...
Run tests
# Within the pywisetransfer working directory
pip install .[dev]
pytest
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pywisetransfer-0.3.2.tar.gz
(18.2 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pywisetransfer-0.3.2.tar.gz.
File metadata
- Download URL: pywisetransfer-0.3.2.tar.gz
- Upload date:
- Size: 18.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.2 CPython/3.12.2 Linux/6.5.0-1016-azure
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f881cd149e02344021cdad938af44676821b3f5dc62bc4c81d51600556aca33d
|
|
| MD5 |
73d2335d1cd10dde3c30097262166b31
|
|
| BLAKE2b-256 |
51c3f8acfb8905b0f47ec24be1b3fb1871d16176ac0ac799367f87958b4fdd7f
|
File details
Details for the file pywisetransfer-0.3.2-py3-none-any.whl.
File metadata
- Download URL: pywisetransfer-0.3.2-py3-none-any.whl
- Upload date:
- Size: 22.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.2 CPython/3.12.2 Linux/6.5.0-1016-azure
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4abf1c24e85a0d3c38620f240101c0cfcaa8c5f70f7ea7a518b582e1153dc1a9
|
|
| MD5 |
819eaff479df72ef4c42cb037b65e11c
|
|
| BLAKE2b-256 |
77a2cb4ca9793af6c63c472fb4dc172576cb80fdc92a9af5e969961cc5ef8ed3
|