Skip to main content

paymentsgate-easy

Python SDK for the PaymentsGate Easy API.

Install

pip install paymentsgate-easy

Import in Python:

import paymentsgate_easy

Features

  • Get wallet
  • Get banks list
  • Payin orders
  • Payout orders
  • Quotes (pre-payout quote calculate)

Usage

from paymentsgate_easy import (
    ApiClient,
    Currencies,
    DealLanguages,
    DealPayInRequest,
    DealSubtypes,
    FxCalculationRequest,
)

client = ApiClient(
    endpoint="https://api.example.com",
    credentials_path="./examples/credentials.json",
)

banks = client.get_banks(tag="fast")
wallet = client.get_wallet()

payin = client.create_payin(
    DealPayInRequest(
        amount=1500,
        currency=Currencies.KZT,
        invoice_id="INV-1000",
        client_id="CLIENT-1000",
        type=DealSubtypes.P2P,
        lang=DealLanguages.RU,
    )
)

quote = client.calculate_fx_post(
    FxCalculationRequest(
        currency_from=Currencies.USDT,
        currency_to=Currencies.KZT,
        amount=1500,
        subtype=DealSubtypes.P2P,
    )
)

Async Usage

import asyncio

from paymentsgate_easy import ApiAsyncClient, Currencies, DealSubtypes, FxCalculationRequest


async def main() -> None:
    client = ApiAsyncClient(
        endpoint="https://api.example.com",
        credentials_path="./examples/credentials.json",
    )

    quote = await client.calculate_fx_post(
        FxCalculationRequest(
            currency_from=Currencies.USDT,
            currency_to=Currencies.KZT,
            amount=1500,
            subtype=DealSubtypes.P2P,
        )
    )
    print(quote)


asyncio.run(main())

Methods

  • get_wallet()
  • get_banks(...)
  • get_deal(...)
  • create_payin(...)
  • create_payout(...)
  • calculate_fx_get(...)
  • calculate_fx_post(...)

Exceptions

All request failures extend ApiError.

Available specialized exceptions include:

  • MissingApiKeyError
  • CredentialsFileError
  • InvalidEndpointError
  • TransportError
  • RequestError
  • UnauthorizedError
  • ForbiddenError
  • DuplicateDealError
  • InvalidCurrencyFromError
  • InvalidCurrencyToError
  • ExchangeDirectionNotAvailableError

Enums and models

Exports include:

  • Currencies
  • DealSubtypes
  • DealStatuses
  • DealDirections
  • DealLanguages
  • RecipientTypes
  • BankTypes
  • BankPaymentSystems
  • TtlUnits
  • WidgetVersions
  • DealPayOutBaseCalculationTypes
  • DealPayOutFeesStrategies
  • Wallet, WalletAsset, Currency
  • Banks, Bank, BankLogo
  • Deal, DealStatus, DealMetadata
  • DealPayInRequest, DealPayInResponse
  • DealPayOutRecipient, DealPayOutRequest, DealPayOutResponse
  • FxCalculationRequest, FxCalculation, Quote

Examples

Ready-to-run examples are available in examples/config.py, examples/credentials.example.json, examples/create_payin.py, and examples/get_quote.py.

Metadata

Release files for paymentsgate-easy 0.1.0

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

Source distribution (sdist)

Source distribution for paymentsgate-easy 0.1.0
File Size Uploaded Provenance Actions
paymentsgate_easy-0.1.0.tar.gz 12.3 kB Without provenance Details for paymentsgate_easy-0.1.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for paymentsgate-easy 0.1.0
File Interpreter ABI Platform Actions
paymentsgate_easy-0.1.0-py3-none-any.whl Python 3 none any Details for paymentsgate_easy-0.1.0-py3-none-any.whl

Total release size: 25.5 kB

Release files / paymentsgate_easy-0.1.0.tar.gz

Download URL paymentsgate_easy-0.1.0.tar.gz
Size 12.3 kB
Tags Source
SHA-256 checksum
How to use checksums
fc441bc2274a1a403546f1a6a4ede41bfd4780c710168899ba51530a33af9717
BLAKE2b-256 checksum
How to use checksums
48723e9baff91b1c53984fd91e4993d13013af43ecfb9d3391968968166ad9d0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/2.3.3 CPython/3.14.5 Darwin/24.5.0

Release files / paymentsgate_easy-0.1.0-py3-none-any.whl

Download URL paymentsgate_easy-0.1.0-py3-none-any.whl
Size 13.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ee94a315107b19313070091cc3a11e66c57d30dee4f3877f6a29655fbb617f2b
BLAKE2b-256 checksum
How to use checksums
a1fd5e0f640999828cba6725d0ebd81ec40aeab400687484ac29bc7c989543a4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/2.3.3 CPython/3.14.5 Darwin/24.5.0

Security for paymentsgate-easy 0.1.0

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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files No provenance

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