Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,30 @@
# Changelog

## 0.4.0

Every change applies to `EpointClient` and `AsyncEpointClient`.

- `get_status` returns a payment that ended in status `error` instead of raising. On
`get_status`, a 2xx response with `status: "error"` and a `transaction` field is a payment
state. Any other error body and any 4xx or 5xx answer still raise `GatewayError`, and other
methods behave as before.
- `Response.ok` is also true for the B2B `SUCCESS` and the heartbeat's `ok`, listed in the new
`OK_STATUSES`.
- `create_token_split_payment` posts to `/api/1/token/split-payment`, the split payment for
Apple Pay and Google Pay, with the same arguments as `create_split_payment`.
- `checkout_form` builds the signed fields and action URL for the browser form post to
`/api/1/checkout`, returned as a `CheckoutForm`, without making a request.
- New optional parameters: `is_installment` on `create_payment`, `checkout_form` and
`create_payment_request`; `bulk_description` on `create_bank_transfer`; `description` and
`other_attr` on `get_installment_plans`; `other_attr` on `pay_by_installment`; `tin`,
`contract_number` and `merchant_order_id` on `update_invoice`.
- `Response` has typed attributes for `trace_id`, `code`, `bank_transaction`, `bank_response`,
`operation_code`, `rrn`, `card_name`, `card_mask`, `amount`, `card_id`, `order_id` and
`widget_url`. `amount` is a float read from a number or a numeric string.
- `Callback` carries the optional `bank_response`, `trace_id` and `card_id`.
- `parse_b2b_webhook` turns a B2B webhook body into a typed `B2BWebhook`. The docs define no
signature for it, so confirm the result with `get_bank_transfer` before acting on it.

## 0.3.0

- `register_card` takes `success_redirect_url` and `error_redirect_url`, so a card saved without
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "epoint"
version = "0.3.0"
version = "0.4.0"
description = "Python client for the epoint.az payment gateway"
readme = "README.md"
requires-python = ">=3.10"
Expand Down
2 changes: 1 addition & 1 deletion src/epoint/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
from .errors import EpointError, GatewayError, SignatureError, TransportError
from .models import B2BWebhook, Callback, CheckoutForm, Response

__version__ = "0.3.0"
__version__ = "0.4.0"

__all__ = [
"AZN_ONLY",
Expand Down
2 changes: 1 addition & 1 deletion uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading