Skip to main content

Async Python SDK for the Velvpay payment gateway

Project description

Pyvelv

Async Python SDK for the Velvpay payment gateway.

Installation

pip install pyvelv
# or
poetry add pyvelv

Quick Start

import asyncio
from pyvelv import Velvpay
from pyvelv.models import CreatePaymentLinkRequest

async def main():
    async with Velvpay(secret_key="your-secret-key") as client:
        # Create a payment link
        response = await client.payment_links.create(
            CreatePaymentLinkRequest(
                amount=1500.00,
                currency="NGN",
                description="Order #12345",
            )
        )
        print(response.data.url)

        # Verify a transaction
        txn = await client.transactions.verify(reference="ref_abc123")
        print(txn.data.status)

asyncio.run(main())

Authentication

Pyvelv handles authentication automatically. The SDK generates the required api-key header using a legacy OpenSSL EVP_BytesToKey routine (AES-256-CBC) with a random 8-byte salt on every request.

Simply pass your Velvpay secret key when initializing the client:

client = Velvpay(secret_key="sk_live_...")

Resources

Resource Methods
payment_links create(), get(), list()
transactions get(), list(), verify()

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyvelv-0.1.0.tar.gz (7.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pyvelv-0.1.0-py3-none-any.whl (10.1 kB view details)

Uploaded Python 3

File details

Details for the file pyvelv-0.1.0.tar.gz.

File metadata

  • Download URL: pyvelv-0.1.0.tar.gz
  • Upload date:
  • Size: 7.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.4.1 CPython/3.14.3 Windows/11

File hashes

Hashes for pyvelv-0.1.0.tar.gz
Algorithm Hash digest
SHA256 eea45ea7cc9f364c5297441bfd987cfe3eab47c8277eb7e38b9acefc9837eff1
MD5 06a38221d293f1ead0c1850c0a746d93
BLAKE2b-256 37f3e5d8a24e4fcc105979263ccc012c6fc6b12ec0b8c1ad9e5a402784975f87

See more details on using hashes here.

File details

Details for the file pyvelv-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: pyvelv-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 10.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.4.1 CPython/3.14.3 Windows/11

File hashes

Hashes for pyvelv-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 a8bdba2d246a04fb3349e26288146bcb6491191fc47e965e55f864aaa98b7971
MD5 793ed7e9b8eb26bbe368383eafc0e998
BLAKE2b-256 036a377ec6506382b44a61d6739e1aa83081fe6d6a3f47935a35a2919b76c81f

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page