Skip to main content

fkwallet-sdk

Async Python SDK for the FKWallet API.

Features

  • ✅ Fully async (httpx + async/await)
  • ✅ Pydantic v2 models with full type hints
  • ✅ SHA-256 request signing (GET & POST)
  • ✅ Webhook signature verification
  • ✅ Custom exceptions
  • ✅ Typed status enums with helper properties

Installation

pip install fkwallet-sdk

Or with Poetry:

poetry add fkwallet-sdk

Quick Start

import asyncio
from fkwallet import FKWalletClient

async def main():
    async with FKWalletClient(
        public_key="YOUR_PUBLIC_KEY",
        private_key="YOUR_PRIVATE_KEY",
    ) as client:
        balance = await client.get_balance()
        print(f"Balance: {balance.value} {balance.currency_code}")

asyncio.run(main())

API Reference

FKWalletClient

All methods are async and must be used inside an async with block.

Method Description
get_balance() Current wallet balance
get_history(date_from, date_to, page, limit) Transaction history
get_currencies() List supported currencies
get_payment_systems() List payment systems
get_sbp_list() List SBP banks
get_mobile_carrier_list() List mobile carriers
create_withdrawal(request) Create withdrawal order
get_withdrawal_status(order_id, type) Get withdrawal status
create_transfer(request) Transfer to another wallet
get_transfer(id) Get transfer status
get_op_categories() Online product categories
get_op_products(category_id) Products in a category
create_op_order(request) Purchase online product
get_op_status(order_id) Online product order status

Webhook Verification

from fkwallet.webhook import verify_webhook

# In your web framework:
form_data = dict(await request.form())
verify_webhook(form_data, private_key="YOUR_PRIVATE_KEY")
# Raises FKWalletWebhookError on invalid signature

Status Enums

from fkwallet import WithdrawalStatus

status = WithdrawalStatus(2)
status.is_processing  # True
status.is_terminal    # False
status.is_error       # False

Error Handling

from fkwallet import FKWalletAPIError

try:
    result = await client.create_withdrawal(...)
except FKWalletAPIError as e:
    print(e.message, e.status_code, e.raw)

Development

poetry install
poetry run pytest tests/ -v

License

MIT

Metadata

Release files for fkwallet-sdk 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for fkwallet-sdk 0.1.1
File Size Uploaded
fkwallet_sdk-0.1.1.tar.gz 8.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for fkwallet-sdk 0.1.1
File Interpreter ABI Platform
fkwallet_sdk-0.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 17.8 kB

Release files / fkwallet_sdk-0.1.1.tar.gz

Download URL fkwallet_sdk-0.1.1.tar.gz
Size 8.0 kB
Tags Source
SHA-256 checksum
How to use checksums
fae1b464787dd64d35d301ea2742cea4a4c7bbf7e960e7f28eef495b0769943f
BLAKE2b-256 checksum
How to use checksums
85a8a955973aea747e85ce35042ec7ef17a49b8cea6af23f90da37f38e749980
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.8

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Mar 20, 2026.

Transparency log

Release files / fkwallet_sdk-0.1.1-py3-none-any.whl

Download URL fkwallet_sdk-0.1.1-py3-none-any.whl
Size 9.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
1ba0988b564da551f2aefda50504db571549af04ebe717e830ac0781b46f6f01
BLAKE2b-256 checksum
How to use checksums
ea389d1dfdd2531b2c8d413a41d2577fea41bc6e39a2281b6f76d80d6b4563ab
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.8

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Mar 20, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page