Metadata-Version: 2.4
Name: django-payments-saferpay
Version: 0.0.3
Summary: SaferPay integration for django-payments
Author-email: EPFL CEDE <oleg.demakov@epfl.ch>
Project-URL: Documentation, https://github.com/epfl-cede/django-payments-saferpay#readme
Project-URL: Issues, https://github.com/epfl-cede/django-payments-saferpay/issues
Project-URL: Source, https://github.com/epfl-cede/django-payments-saferpay
Keywords: django,payments,saferpay
Classifier: Environment :: Web Environment
Classifier: Framework :: Django :: 4.2
Classifier: Framework :: Django :: 5.0
Classifier: Framework :: Django :: 5.1
Classifier: Framework :: Django
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Requires-Python: >=3.9
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: django-payments>=3.0.0
Provides-Extra: dev
Requires-Dist: django-stubs[compatible-mypy]; extra == "dev"
Requires-Dist: mock; extra == "dev"
Requires-Dist: pre-commit; extra == "dev"
Requires-Dist: pytest; extra == "dev"
Requires-Dist: pytest-django; extra == "dev"
Requires-Dist: pytest-mock; extra == "dev"
Requires-Dist: types-braintree; extra == "dev"
Dynamic: license-file

# django-payments-saferpay

[![PyPI - Version](https://img.shields.io/pypi/v/django-payments-saferpay.svg)](https://pypi.org/project/django-payments-saferpay)
[![PyPI - Python Version](https://img.shields.io/pypi/pyversions/django-payments-saferpay.svg)](https://pypi.org/project/django-payments-saferpay)

-----

Django Payments Saferpay is a python package that adds support for the [Saferpay payment provider](https://docs.saferpay.com/home) to [Django Payments](https://django-payments.readthedocs.io/).

**Table of Contents**

- [Installation](#installation)
- [Configuration](#configuration)
- [Sandbox](#sandbox)
- [License](#license)

## Installation

```console
pip install django-payments-saferpay
```

## Configuration

You should follow the configuration guide in the Django Payments documentation. To set up this package as a payment variant, use the following PAYMENT_VARIANTS in the Django settings file:

```python
PAYMENT_VARIANTS = {
    "saferpay": (
        "django_payments_saferpay.provider.SaferpayProvider",
        {
            "customer_id": "your-customer-id",
            "terminal_id": "your-terminal-id",
            "username": "your-username",
            "password": "your-password",
            "sandbox": True,  # Set to True for testing
        }
    )
}
```

### Available configuration options
- `customer_id`: Your Saferpay customer ID.
- `terminal_id`: Your terminal ID from Saferpay.
- `username`: The username for Saferpay API authentication.
- `password`: The password for Saferpay API authentication.
- `sandbox`: Boolean flag to enable or disable sandbox mode for testing.

## Sandbox

The project contains a sandbox that shows a very simple implementation of Django Payments with the SaferPay payment variant. You can use it to see how implementation could be done, or to actually run an application against your own SaferPay account.

## License

`django-payments-saferpay` is distributed under the terms of the [BSD](https://spdx.org/licenses/BSD-3-Clause.html) license.
