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.4.tar.gz (71.2 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.4-py3-none-any.whl (109.5 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: sincpro_payments_sdk-5.0.4.tar.gz
  • Upload date:
  • Size: 71.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.4.1 CPython/3.12.3 Linux/6.17.0-1018-azure

File hashes

Hashes for sincpro_payments_sdk-5.0.4.tar.gz
Algorithm Hash digest
SHA256 3e5da58b6b477ba7ba88ddc17b9030eda731c2d168ebcb3f68d4b5c5be894887
MD5 b36bb4f9fe38de9ecec6a2c9c0a11285
BLAKE2b-256 985be2ca61d1541a05dbb97575d0118b76ac4dbd731d35c784cb6d218634c789

See more details on using hashes here.

File details

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

File metadata

  • Download URL: sincpro_payments_sdk-5.0.4-py3-none-any.whl
  • Upload date:
  • Size: 109.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.4.1 CPython/3.12.3 Linux/6.17.0-1018-azure

File hashes

Hashes for sincpro_payments_sdk-5.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 f6953f173e32a7c35eb4ca7b63e8510b319f2697ca7ce70c4e7822871cd8bc75
MD5 d2f6fa0b70f8cf3fd414ace9b7e4bb12
BLAKE2b-256 b5481178ef241cfb23b8952223639bf9ece6ff0445e13bd8ce080ae20644ca57

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