Skip to content

Commit

Permalink
Merge pull request #35 from gopaycommunity/hotfix/GPMAIN-7759-bnpl
Browse files Browse the repository at this point in the history
Hotfix/gpmain 7759 bnpl
  • Loading branch information
pmaryska authored Sep 6, 2024
2 parents 35ae41e + 15d59f7 commit 0bf3ef9
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 4 deletions.
6 changes: 6 additions & 0 deletions gopay/enums.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,8 @@ class PaymentInstrument(StrEnum):
ACCOUNT = "ACCOUNT"
APPLE_PAY = "APPLE_PAY"
CLICK_TO_PAY = "CLICK_TO_PAY"
TWISTO = "TWISTO"
SKIPPAY = "SKIPPAY"


class StatementGeneratingFormat(StrEnum):
Expand Down Expand Up @@ -269,3 +271,7 @@ class PaymentSubStatus(StrEnum):
class ContentType(StrEnum):
FORM = "application/x-www-form-urlencoded"
JSON = "application/json"

class BnplType(StrEnum):
DEFERRED_PAYMENT = "DEFERRED_PAYMENT"
PAY_IN_THREE = "PAY_IN_THREE"
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ name = "gopay"
packages = [{include = "gopay"}]
readme = "README.md"
repository = "https://github.com/gopaycommunity/gopay-python-api"
version = "2.1.0"
version = "2.2.0"

[tool.poetry.dependencies]
deprecated = "^1.2.14"
Expand Down
11 changes: 8 additions & 3 deletions tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import pytest

import gopay
from gopay.enums import BankSwiftCode, Currency, Language, PaymentInstrument
from gopay.enums import BankSwiftCode, Currency, Language, PaymentInstrument, BnplType
from gopay.http import Request, Response


Expand Down Expand Up @@ -61,13 +61,18 @@ def base_payment() -> dict:
"allowed_payment_instruments": [
PaymentInstrument.BANK_ACCOUNT,
PaymentInstrument.PAYMENT_CARD,
# PaymentInstrument.TWISTO,
# PaymentInstrument.SKIPPAY
],
# "default_payment_instrument": PaymentInstrument.TWISTO,
"allowed_swifts": [
BankSwiftCode.CESKA_SPORITELNA,
BankSwiftCode.RAIFFEISENBANK,
],
#'default_swift': BankSwiftCode.CESKA_SPORITELNA,
#'default_payment_instrument': PaymentInstrument.BANK_ACCOUNT,
# "allowed_bnpl_types": [BnplType.DEFERRED_PAYMENT, BnplType.PAY_IN_THREE],
# "default_bnpl_type": BnplType.DEFERRED_PAYMENT,
"default_swift": BankSwiftCode.CESKA_SPORITELNA,
"default_payment_instrument": PaymentInstrument.BANK_ACCOUNT,
"contact": {
"email": "[email protected]",
},
Expand Down

0 comments on commit 0bf3ef9

Please sign in to comment.