Skip to main content

Swarmauri Logo

PyPI - Downloads Hits PyPI - Python Version PyPI - License PyPI - swarmauri_billing_braintree


Swarmauri Billing Braintree

Swarmauri Billing Braintree offers a Braintree-flavoured provider that implements the Swarmauri billing interfaces. Use the package to exercise subscription renewals, vaulting, drop-in checkouts, and settlement reporting without wiring up the live Braintree SDK on day one.

Features

  • ✅ Models Braintree primitives such as customer vault, payment methods, subscriptions, and disbursements.
  • ✅ Returns predictable payloads so downstream Swarmauri workflows can be validated in isolation.
  • ✅ Highlights Braintree's fraud tools and reporting by exposing capability flags.
  • ✅ Stays self-contained: swap the stubbed responses for real API calls when ready.

Installation

Install from PyPI using either pip or uv:

pip install swarmauri_billing_braintree
uv add swarmauri_billing_braintree

Usage

from swarmauri_billing_braintree import BraintreeBillingProvider
from swarmauri_base.billing import PaymentIntentRequest

provider = BraintreeBillingProvider(api_key="sandbox-key")

payment_intent = provider.create_payment_intent(
    PaymentIntentRequest(payload={"amount_minor": 1500, "currency": "USD", "confirm": True}),
)
result = provider.capture_payment(payment_intent.id)

print(payment_intent.status, result.status)

Capability Mapping

The provider advertises Swarmauri Capability values which map to tigrbl_billing through capabilities_to_tigrbl. You can assert on those capabilities to feature-gate behaviour before hitting the Braintree API for real.

Contributing

Contributions that wire the stubbed operations to official Braintree REST or GraphQL calls are welcome. Please update the README usage section and add tests when expanding the integration.

Metadata

Release files for swarmauri_billing_braintree 0.1.2

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

Source distribution (sdist)

Source distribution for swarmauri_billing_braintree 0.1.2
File Size Uploaded
swarmauri_billing_braintree-0.1.2.tar.gz 8.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for swarmauri_billing_braintree 0.1.2
File Interpreter ABI Platform
swarmauri_billing_braintree-0.1.2-py3-none-any.whl Python 3 none any Details

Total release size: 18.4 kB

Release files / swarmauri_billing_braintree-0.1.2.tar.gz

Download URL swarmauri_billing_braintree-0.1.2.tar.gz
Size 8.7 kB
Tags Source
SHA-256 checksum
How to use checksums
56304392a59eb348887783616c3846aed549f5d9496e1ead5103e307d26dec24
BLAKE2b-256 checksum
How to use checksums
569fe35d4566b8df0ac9cf61fd09ac3e46d164886c3a27b3eaf2cfb5868029b4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.0 {"installer":{"name":"uv","version":"0.11.0","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / swarmauri_billing_braintree-0.1.2-py3-none-any.whl

Download URL swarmauri_billing_braintree-0.1.2-py3-none-any.whl
Size 9.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
1f9eafcb49a80830ab48714a5d6c33cd10d0e6041f0e8fcab2aa849c815603be
BLAKE2b-256 checksum
How to use checksums
2122560110f9bd52389752c0bf2187de46dc93fae5e20833e6aaf282bd47f22a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.0 {"installer":{"name":"uv","version":"0.11.0","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
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