diff --git a/samples/init_kaspi_apm_payment.php b/samples/init_kaspi_apm_payment.php new file mode 100644 index 0000000..989c7c1 --- /dev/null +++ b/samples/init_kaspi_apm_payment.php @@ -0,0 +1,35 @@ + ApmType::KASPI, + 'price' => 1, + 'paidPrice' => 1, + 'currency' => Currency::KZT, + 'paymentGroup' => PaymentGroup::LISTING_OR_SUBSCRIPTION, + 'conversationId' => '456d1297-908e-4bd6-a13b-4be31a6e47d5', + 'externalId' => 'optional-externalId', + 'callbackUrl' => 'https://www.your-website.com/craftgate-apm-callback', + 'items' => array( + array( + 'externalId' => Guid::generate(), + 'name' => 'Item 1', + 'price' => 0.40 + ), + array( + 'externalId' => Guid::generate(), + 'name' => 'Item 2', + 'price' => 0.60 + ) + ) +); + +$response = SampleConfig::craftgate()->payment()->initApmPayment($request); + +print_r($response); diff --git a/src/Model/ApmType.php b/src/Model/ApmType.php index 1cb14af..1bdce86 100644 --- a/src/Model/ApmType.php +++ b/src/Model/ApmType.php @@ -12,6 +12,8 @@ class ApmType const PAYPAL = 'PAYPAL'; const KLARNA = 'KLARNA'; const AFTERPAY = 'AFTERPAY'; + const STRIPE = 'STRIPE'; + const KASPI = 'KASPI'; const FUND_TRANSFER = 'FUND_TRANSFER'; const CASH_ON_DELIVERY = 'CASH_ON_DELIVERY'; } diff --git a/src/Model/Currency.php b/src/Model/Currency.php index b42b283..2383e85 100644 --- a/src/Model/Currency.php +++ b/src/Model/Currency.php @@ -14,4 +14,5 @@ class Currency const AED = 'AED'; const IQD = 'IQD'; const AZN = 'AZN'; + const KZT = 'KZT'; } diff --git a/src/Model/PaymentMethod.php b/src/Model/PaymentMethod.php index 19719df..f1089ae 100644 --- a/src/Model/PaymentMethod.php +++ b/src/Model/PaymentMethod.php @@ -11,6 +11,8 @@ class PaymentMethod const SODEXO = 'SODEXO'; const EDENRED = 'EDENRED'; const EDENRED_GIFT = 'EDENRED_GIFT'; + const STRIPE = 'STRIPE'; + const KASPI = 'KASPI'; const ALIPAY = 'ALIPAY'; const PAYPAL = 'PAYPAL'; const KLARNA = 'KLARNA'; diff --git a/src/Model/PaymentProvider.php b/src/Model/PaymentProvider.php index 7a7e83e..779866b 100644 --- a/src/Model/PaymentProvider.php +++ b/src/Model/PaymentProvider.php @@ -12,6 +12,8 @@ class PaymentProvider const PAYONEER = "PAYONEER"; const SODEXO = "SODEXO"; const EDENRED = "EDENRED"; + const STRIPE = "STRIPE"; + const KASPI = "KASPI"; const YKB_WORLD_PAY = "YKB_WORLD_PAY"; const APPLEPAY = "APPLEPAY"; const GOOGLEPAY = "GOOGLEPAY";