{"library":"braintree","type":"library","category":null,"description":"PayPal's Braintree payment gateway Python SDK. Current version: 4.42.0 (Mar 2026). Stable API — no major breaking changes from v3 to v4 for Python. SSL certificate update required: Braintree updated root SSL cert April 2024 — SDKs older than ~4.33 will fail after March 2026. Three-step flow: generate client token server-side → collect payment method nonce client-side → create transaction server-side. Amount as string. submit_for_settlement must be True to actually capture funds.","language":"python","status":"active","version":"4.42.0","tags":["braintree","payments","paypal","python","payment-gateway"],"last_verified":"Tue Jun 09","install":[{"cmd":"pip install braintree","imports":["import braintree\n\ngateway = braintree.BraintreeGateway(\n    braintree.Configuration(\n        environment=braintree.Environment.Sandbox,\n        merchant_id='your_merchant_id',\n        public_key='your_public_key',\n        private_key='your_private_key'\n    )\n)\n\n# Generate client token — send to frontend\nclient_token = gateway.client_token.generate()\n\n# Create transaction with nonce from frontend\nresult = gateway.transaction.sale({\n    'amount': '100.00',   # string, not float\n    'payment_method_nonce': nonce_from_client,\n    'options': {\n        'submit_for_settlement': True  # capture immediately\n    }\n})\n\nif result.is_success:\n    print(result.transaction.id)\nelse:\n    for error in result.errors.deep_errors:\n        print(error.message)"]}],"homepage":"https://developer.paypal.com/braintree/docs/reference/overview","github":null,"docs":null,"changelog":null,"pypi":"https://pypi.org/project/braintree/","npm":null,"openapi_spec":null,"status_page":null,"smithery":null,"compatibility":{"summary":{"python_range":"3.10–3.9","success_rate":100,"avg_install_s":2.2,"avg_import_s":0.8,"wheel_type":"wheel"},"url":"https://checklist.day/v1/registry/braintree/compatibility"}}