Skip to main content

Agnostic SDK for payments like cybersource, Paypal and local payments

Project description

Sincpro Payments SDK

SDK para integración con pasarelas de pago y servicios bancarios, construido sobre el Sincpro Framework con arquitectura hexagonal.


Bounded Contexts

cybersource — Pagos con tarjeta (Cybersource)

Proveedor: Cybersource / Linkser

Use case Command
Tokenizar tarjeta CommandCreatePaymentMethod
Tokenizar tarjeta + cliente CommandCreateCustomerPaymentMethod
Pago tarjeta nueva (enrollment) CommandPayNewCardEnrollment
Pago tarjeta nueva (validación) CommandPayNewCardValidation
Pago tarjeta guardada (enrollment) CommandPaySavedCardEnrollment
Pago tarjeta guardada (validación) CommandPaySavedCardValidation
Pago recurrente CommandRecurringPayment
Cancelar / reembolso CommandCancelOrRefund
Pre-pago: setup auth CommandSetupAuth
Pre-pago: iniciar monitor CommandStartMonitorAuth
Pre-pago: verificar 3DS CommandCheckRequireAuth
Pre-pago: validar auth CommandValidateAuth
from sincpro_payments_sdk.apps.cybersource import cybersource, tokenization

result = cybersource(
    tokenization.CommandCreatePaymentMethod(...),
    tokenization.ResponseCreatePaymentMethod,
)

qr — Pagos QR

Tres proveedores bajo el mismo bounded context:

BNB

Use case Command
Autenticar CommandAuthenticateBNB
Crear QR CommandCreateQR
Verificar estado CommandCheckQRStatus
Listar QRs CommandListQRs
Cancelar QR CommandCancelQR

Banco Económico

Use case Command
Autenticar CommandAuthenticateEconomico
Crear QR CommandCreateQR
Verificar estado CommandCheckQRStatus
QRs cobrados CommandGetPaidQRs
Cancelar QR CommandCancelQR

Linkser

Use case Command
Crear QR CommandCreateQR
Verificar estado CommandCheckQRStatus
from sincpro_payments_sdk.apps.qr import qr, economico, bnb, linkser

auth = qr(
    economico.CommandAuthenticateEconomico(user_name="...", password="...", aes_key="..."),
    economico.ResponseAuthenticateEconomico,
)
qr_image = qr(economico.CommandCreateQR(...), economico.ResponseCreateQR)

bank_account — Extractos bancarios (Banco Económico)

Use case Command
Autenticar CommandAuthenticateEconomico
Consultar movimientos CommandGetMovements
from sincpro_payments_sdk.apps.bank_account import bank_account, economico

auth = bank_account(
    economico.CommandAuthenticateEconomico(user_name="...", password="...", aes_key="..."),
    economico.ResponseAuthenticateEconomico,
)
movements = bank_account(
    economico.CommandGetMovements(account_code="...", start_date=..., end_date=...),
    economico.ResponseGetMovements,
)

Documentación

Documentación detallada de DTOs, Features y Application Services disponible en generated_docs/site/index.html.

Para regenerar:

make docs

Desarrollo

make install          # instalar dependencias
make format           # formatear código (obligatorio antes de commit)
make test             # ejecutar tests
make test_one t=<archivo>  # test específico

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

sincpro_payments_sdk-5.0.2.tar.gz (70.9 kB view details)

Uploaded Source

Built Distribution

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

sincpro_payments_sdk-5.0.2-py3-none-any.whl (108.6 kB view details)

Uploaded Python 3

File details

Details for the file sincpro_payments_sdk-5.0.2.tar.gz.

File metadata

  • Download URL: sincpro_payments_sdk-5.0.2.tar.gz
  • Upload date:
  • Size: 70.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.3.2 CPython/3.12.3 Linux/6.14.0-1017-azure

File hashes

Hashes for sincpro_payments_sdk-5.0.2.tar.gz
Algorithm Hash digest
SHA256 77fee58053d5f6eefaf471ee3a7816d1565524b685cd36ca883e1b0e33730ba4
MD5 bd95d6b6c61c62e868a2dbf65e9bc8fc
BLAKE2b-256 f2d91d52d4d78acac446b2e52e211ff85dfe4ff3c6f232d5353e6d06f4ab7680

See more details on using hashes here.

File details

Details for the file sincpro_payments_sdk-5.0.2-py3-none-any.whl.

File metadata

  • Download URL: sincpro_payments_sdk-5.0.2-py3-none-any.whl
  • Upload date:
  • Size: 108.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.3.2 CPython/3.12.3 Linux/6.14.0-1017-azure

File hashes

Hashes for sincpro_payments_sdk-5.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 42af0eb6148dcbda74a58c97f946e6b42a0b7c3b5a817474a152e73c738152ca
MD5 0086b121ef2a6344aaf492ebcbc0e8e9
BLAKE2b-256 ab856bf1e6aeabbaf846cd387b2864762108e4e7bfa0c747f2e0c2218e93b7a1

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