From 5747ea25dc17af8d72ab2c8e6f4f8cf8dd04be1c Mon Sep 17 00:00:00 2001 From: xendit-devx-bot Date: Thu, 30 Jan 2025 06:23:11 +0000 Subject: [PATCH] Generated Xendit php SDK --- LICENSE | 2 +- README.md | 4 +- composer.json | 2 +- docs/Invoice/BankCode.md | 14 + docs/Invoice/ChannelPropertiesCards.md | 1 + ...PropertiesCardsInstallmentConfiguration.md | 16 + ...stallmentConfigurationAllowedTermsInner.md | 16 + docs/Invoice/CreateInvoiceRequest.md | 3 +- docs/Invoice/Invoice.md | 1 + docs/Invoice/InvoiceCurrency.md | 2 + docs/Invoice/QrCodeType.md | 2 + lib/BalanceAndTransaction/BalanceApi.php | 2 +- lib/BalanceAndTransaction/TransactionApi.php | 4 +- lib/Configuration.php | 4 +- lib/Customer/CustomerApi.php | 8 +- lib/Invoice/AddressObject.php | 2 +- lib/Invoice/AlternativeDisplayItem.php | 2 +- lib/Invoice/BadRequestError.php | 2 +- lib/Invoice/Bank.php | 2 +- lib/Invoice/BankCode.php | 23 +- lib/Invoice/ChannelProperties.php | 2 +- lib/Invoice/ChannelPropertiesCards.php | 48 +- ...ropertiesCardsInstallmentConfiguration.php | 437 ++++++++++++++++++ ...tallmentConfigurationAllowedTermsInner.php | 436 +++++++++++++++++ lib/Invoice/CreateInvoiceRequest.php | 82 +++- lib/Invoice/CustomerObject.php | 2 +- lib/Invoice/DirectDebit.php | 2 +- lib/Invoice/DirectDebitType.php | 2 +- lib/Invoice/Ewallet.php | 2 +- lib/Invoice/EwalletType.php | 2 +- lib/Invoice/ForbiddenError.php | 2 +- lib/Invoice/Invoice.php | 48 +- lib/Invoice/InvoiceApi.php | 10 +- lib/Invoice/InvoiceCallback.php | 2 +- lib/Invoice/InvoiceCallbackItem.php | 2 +- lib/Invoice/InvoiceClientType.php | 2 +- lib/Invoice/InvoiceCurrency.php | 5 +- .../InvoiceError404ResponseDefinition.php | 2 +- lib/Invoice/InvoiceFee.php | 2 +- lib/Invoice/InvoiceItem.php | 2 +- lib/Invoice/InvoiceNotFoundError.php | 2 +- lib/Invoice/InvoicePaymentMethod.php | 2 +- lib/Invoice/InvoiceStatus.php | 2 +- lib/Invoice/NotificationChannel.php | 2 +- lib/Invoice/NotificationPreference.php | 2 +- lib/Invoice/Paylater.php | 2 +- lib/Invoice/PaylaterType.php | 2 +- lib/Invoice/PaymentDetails.php | 2 +- lib/Invoice/QrCode.php | 2 +- lib/Invoice/QrCodeType.php | 5 +- lib/Invoice/RetailOutlet.php | 2 +- lib/Invoice/RetailOutletName.php | 2 +- lib/Invoice/ServerError.php | 2 +- lib/Invoice/UnauthorizedError.php | 2 +- lib/PaymentMethod/PaymentMethodApi.php | 16 +- lib/PaymentRequest/PaymentRequestApi.php | 16 +- lib/Payout/PayoutApi.php | 10 +- lib/Refund/RefundApi.php | 8 +- 58 files changed, 1171 insertions(+), 114 deletions(-) create mode 100644 docs/Invoice/ChannelPropertiesCardsInstallmentConfiguration.md create mode 100644 docs/Invoice/ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner.md create mode 100644 lib/Invoice/ChannelPropertiesCardsInstallmentConfiguration.php create mode 100644 lib/Invoice/ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner.php diff --git a/LICENSE b/LICENSE index 74911bc..9d116f4 100644 --- a/LICENSE +++ b/LICENSE @@ -1,6 +1,6 @@ MIT License -Copyright (c) 2017-2024 Xendit +Copyright (c) 2017-2025 Xendit Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/README.md b/README.md index b956a0e..e719e69 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ The official Xendit PHP SDK provides a simple and convenient way to call Xendit's REST API in applications written in PHP. -* Package version: 6.0.0 +* Package version: 6.1.0 # Getting Started @@ -28,7 +28,7 @@ To install the bindings via [Composer](https://getcomposer.org/), add the follow } ], "require": { - "xendit/xendit-php": "6.0.0" + "xendit/xendit-php": "6.1.0" } } ``` diff --git a/composer.json b/composer.json index 84b1b2a..7fe3158 100644 --- a/composer.json +++ b/composer.json @@ -1,6 +1,6 @@ { "name": "xendit/xendit-php", - "version": "6.0.0", + "version": "6.1.0", "description": "Xendit PHP SDK", "keywords": [ "openapitools", diff --git a/docs/Invoice/BankCode.md b/docs/Invoice/BankCode.md index 6656f74..832d6d7 100644 --- a/docs/Invoice/BankCode.md +++ b/docs/Invoice/BankCode.md @@ -27,6 +27,20 @@ use Xendit\Invoice\BankCode; * `CIMB` (value: `'CIMB'`) + * `VIETCAPITAL` (value: `'VIETCAPITAL'`) + + * `WOORI` (value: `'WOORI'`) + + * `PV` (value: `'PV'`) + + * `MSB` (value: `'MSB'`) + + * `VPB` (value: `'VPB'`) + + * `BIDV` (value: `'BIDV'`) + + * `CAKE` (value: `'CAKE'`) + * `BNC` (value: `'BNC'`) * `HANA` (value: `'HANA'`) diff --git a/docs/Invoice/ChannelPropertiesCards.md b/docs/Invoice/ChannelPropertiesCards.md index a721e58..c97bb30 100644 --- a/docs/Invoice/ChannelPropertiesCards.md +++ b/docs/Invoice/ChannelPropertiesCards.md @@ -10,6 +10,7 @@ use Xendit\Invoice\ChannelPropertiesCards; | Name | Type | Required | Description | Examples | |------------|:-------------:|:-------------:|-------------|:-------------:| | **allowed_bins** | **string[]** | | An array of allowed BINs (6 or 8 digits) for credit card payments. | null | +| **installment_configuration** | [**ChannelPropertiesCardsInstallmentConfiguration**](ChannelPropertiesCardsInstallmentConfiguration.md) | | | null | [[Back to README]](../../README.md) diff --git a/docs/Invoice/ChannelPropertiesCardsInstallmentConfiguration.md b/docs/Invoice/ChannelPropertiesCardsInstallmentConfiguration.md new file mode 100644 index 0000000..c905421 --- /dev/null +++ b/docs/Invoice/ChannelPropertiesCardsInstallmentConfiguration.md @@ -0,0 +1,16 @@ +# # ChannelPropertiesCardsInstallmentConfiguration +An object to pre-set cards installment for a specific invoice + +```php +use Xendit\Invoice\ChannelPropertiesCardsInstallmentConfiguration; +``` + +## Properties + +| Name | Type | Required | Description | Examples | +|------------|:-------------:|:-------------:|-------------|:-------------:| +| **allow_full_payment** | **bool** | | Indicate whether full payment (without installment) is allowed | null | +| **allowed_terms** | [**array**](ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner.md) | | An object to set what kind (from specific bank / specific tenor) of cards installments will be available on a specific invoice | null | + + +[[Back to README]](../../README.md) diff --git a/docs/Invoice/ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner.md b/docs/Invoice/ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner.md new file mode 100644 index 0000000..f6a980a --- /dev/null +++ b/docs/Invoice/ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner.md @@ -0,0 +1,16 @@ +# # ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner + + +```php +use Xendit\Invoice\ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner; +``` + +## Properties + +| Name | Type | Required | Description | Examples | +|------------|:-------------:|:-------------:|-------------|:-------------:| +| **issuer** | **string** | | The bank code of the installment provider / issuer | null | +| **allowed_terms** | **float[]** | | An array containing list of installment tenor available to choose | null | + + +[[Back to README]](../../README.md) diff --git a/docs/Invoice/CreateInvoiceRequest.md b/docs/Invoice/CreateInvoiceRequest.md index 0061146..245544e 100644 --- a/docs/Invoice/CreateInvoiceRequest.md +++ b/docs/Invoice/CreateInvoiceRequest.md @@ -25,11 +25,12 @@ use Xendit\Invoice\CreateInvoiceRequest; | **should_authenticate_credit_card** | **bool** | | Indicates whether credit card authentication is required. | null | | **currency** | **string** | | The currency of the invoice. | null | | **reminder_time** | **float** | | The reminder time. | null | -| **local** | **string** | | The local. | null | +| **locale** | **string** | | The default language to display. | null | | **reminder_time_unit** | **string** | | The unit of the reminder time. | null | | **items** | [**array**](InvoiceItem.md) | | An array of items included in the invoice. | null | | **fees** | [**array**](InvoiceFee.md) | | An array of fees associated with the invoice. | null | | **channel_properties** | [**ChannelProperties**](ChannelProperties.md) | | | null | +| **metadata** | **object** | | A free-format JSON for additional information that you may use. Object can be up to 50 keys, with key names up to 40 characters long and values up to 500 characters long. | null | [[Back to README]](../../README.md) diff --git a/docs/Invoice/Invoice.md b/docs/Invoice/Invoice.md index ecb1f1b..9482e48 100644 --- a/docs/Invoice/Invoice.md +++ b/docs/Invoice/Invoice.md @@ -43,6 +43,7 @@ use Xendit\Invoice\Invoice; | **customer_notification_preference** | [**NotificationPreference**](NotificationPreference.md) | | | null | | **fees** | [**array**](InvoiceFee.md) | | An array of fees associated with the invoice. | null | | **channel_properties** | [**ChannelProperties**](ChannelProperties.md) | | | null | +| **metadata** | **object** | | A free-format JSON for additional information that you may use. Object can be up to 50 keys, with key names up to 40 characters long and values up to 500 characters long. | null | [[Back to README]](../../README.md) diff --git a/docs/Invoice/InvoiceCurrency.md b/docs/Invoice/InvoiceCurrency.md index 52da644..af2b413 100644 --- a/docs/Invoice/InvoiceCurrency.md +++ b/docs/Invoice/InvoiceCurrency.md @@ -19,6 +19,8 @@ use Xendit\Invoice\InvoiceCurrency; * `PHP` (value: `'PHP'`) + * `MYR` (value: `'MYR'`) + * `XENDIT_ENUM_DEFAULT_FALLBACK` (value: `UNKNOWN_ENUM_VALUE`) If you encounter `UNKNOWN_ENUM_VALUE`, it means that this ENUM is unavailable in your current SDK version. Please upgrade to get the newest ENUM. diff --git a/docs/Invoice/QrCodeType.md b/docs/Invoice/QrCodeType.md index 1316c48..bbf42bd 100644 --- a/docs/Invoice/QrCodeType.md +++ b/docs/Invoice/QrCodeType.md @@ -13,6 +13,8 @@ use Xendit\Invoice\QrCodeType; * `PROMPTPAY` (value: `'PROMPTPAY'`) + * `QRPH` (value: `'QRPH'`) + * `XENDIT_ENUM_DEFAULT_FALLBACK` (value: `UNKNOWN_ENUM_VALUE`) If you encounter `UNKNOWN_ENUM_VALUE`, it means that this ENUM is unavailable in your current SDK version. Please upgrade to get the newest ENUM. diff --git a/lib/BalanceAndTransaction/BalanceApi.php b/lib/BalanceAndTransaction/BalanceApi.php index 5fbae40..b46b2b7 100644 --- a/lib/BalanceAndTransaction/BalanceApi.php +++ b/lib/BalanceAndTransaction/BalanceApi.php @@ -382,7 +382,7 @@ public function getBalanceRequest($account_type = 'CASH', $currency = null, $at_ // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); diff --git a/lib/BalanceAndTransaction/TransactionApi.php b/lib/BalanceAndTransaction/TransactionApi.php index 590f52a..7cfe65f 100644 --- a/lib/BalanceAndTransaction/TransactionApi.php +++ b/lib/BalanceAndTransaction/TransactionApi.php @@ -363,7 +363,7 @@ public function getTransactionByIDRequest($id, $for_user_id = null, string $cont // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -806,7 +806,7 @@ public function getAllTransactionsRequest($for_user_id = null, $types = null, $s // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); diff --git a/lib/Configuration.php b/lib/Configuration.php index 36ffcb0..7789895 100644 --- a/lib/Configuration.php +++ b/lib/Configuration.php @@ -64,7 +64,7 @@ class Configuration * * @var string */ - protected $userAgent = 'OpenAPI-Generator/6.0.0/PHP'; + protected $userAgent = 'OpenAPI-Generator/6.1.0/PHP'; /** * Debug switch (default set to false) @@ -305,7 +305,7 @@ public static function toDebugReport() $report .= ' OS: ' . php_uname() . PHP_EOL; $report .= ' PHP Version: ' . PHP_VERSION . PHP_EOL; $report .= ' The version of the OpenAPI document: 1.70.0' . PHP_EOL; - $report .= ' SDK Package Version: 6.0.0' . PHP_EOL; + $report .= ' SDK Package Version: 6.1.0' . PHP_EOL; $report .= ' Temp Folder Path: ' . self::getDefaultConfiguration()->getTempFolderPath() . PHP_EOL; return $report; diff --git a/lib/Customer/CustomerApi.php b/lib/Customer/CustomerApi.php index 88606a3..0436844 100644 --- a/lib/Customer/CustomerApi.php +++ b/lib/Customer/CustomerApi.php @@ -369,7 +369,7 @@ public function createCustomerRequest($idempotency_key = null, $for_user_id = nu // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -628,7 +628,7 @@ public function getCustomerRequest($id, $for_user_id = null, string $contentType // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -891,7 +891,7 @@ public function getCustomerByReferenceIDRequest($reference_id, $for_user_id = nu // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -1163,7 +1163,7 @@ public function updateCustomerRequest($id, $for_user_id = null, $patch_customer // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); diff --git a/lib/Invoice/AddressObject.php b/lib/Invoice/AddressObject.php index 1140429..286a0ae 100644 --- a/lib/Invoice/AddressObject.php +++ b/lib/Invoice/AddressObject.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/AlternativeDisplayItem.php b/lib/Invoice/AlternativeDisplayItem.php index 8ab5f44..4c5f56f 100644 --- a/lib/Invoice/AlternativeDisplayItem.php +++ b/lib/Invoice/AlternativeDisplayItem.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/BadRequestError.php b/lib/Invoice/BadRequestError.php index 9386458..355dff7 100644 --- a/lib/Invoice/BadRequestError.php +++ b/lib/Invoice/BadRequestError.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/Bank.php b/lib/Invoice/Bank.php index 9512d1d..8b28557 100644 --- a/lib/Invoice/Bank.php +++ b/lib/Invoice/Bank.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/BankCode.php b/lib/Invoice/BankCode.php index d7ee958..b2c1a3f 100644 --- a/lib/Invoice/BankCode.php +++ b/lib/Invoice/BankCode.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** @@ -55,6 +55,20 @@ class BankCode public const CIMB = 'CIMB'; + public const VIETCAPITAL = 'VIETCAPITAL'; + + public const WOORI = 'WOORI'; + + public const PV = 'PV'; + + public const MSB = 'MSB'; + + public const VPB = 'VPB'; + + public const BIDV = 'BIDV'; + + public const CAKE = 'CAKE'; + public const BNC = 'BNC'; public const HANA = 'HANA'; @@ -100,6 +114,13 @@ public static function getAllowableEnumValues() self::BJB, self::SAHABAT_SAMPOERNA, self::CIMB, + self::VIETCAPITAL, + self::WOORI, + self::PV, + self::MSB, + self::VPB, + self::BIDV, + self::CAKE, self::BNC, self::HANA, self::MUAMALAT, diff --git a/lib/Invoice/ChannelProperties.php b/lib/Invoice/ChannelProperties.php index 1fb5715..dc77585 100644 --- a/lib/Invoice/ChannelProperties.php +++ b/lib/Invoice/ChannelProperties.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/ChannelPropertiesCards.php b/lib/Invoice/ChannelPropertiesCards.php index 704eeae..dc229b7 100644 --- a/lib/Invoice/ChannelPropertiesCards.php +++ b/lib/Invoice/ChannelPropertiesCards.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** @@ -51,7 +51,8 @@ class ChannelPropertiesCards implements ModelInterface, ArrayAccess, \JsonSerial * @var string[] */ protected static $openAPITypes = [ - 'allowed_bins' => 'string[]' + 'allowed_bins' => 'string[]', + 'installment_configuration' => '\Xendit\Invoice\ChannelPropertiesCardsInstallmentConfiguration' ]; /** @@ -62,7 +63,8 @@ class ChannelPropertiesCards implements ModelInterface, ArrayAccess, \JsonSerial * @psalm-var array */ protected static $openAPIFormats = [ - 'allowed_bins' => null + 'allowed_bins' => null, + 'installment_configuration' => null ]; /** @@ -71,7 +73,8 @@ class ChannelPropertiesCards implements ModelInterface, ArrayAccess, \JsonSerial * @var boolean[] */ protected static array $openAPINullables = [ - 'allowed_bins' => false + 'allowed_bins' => false, + 'installment_configuration' => false ]; /** @@ -160,7 +163,8 @@ public function isNullableSetToNull(string $property): bool * @var string[] */ protected static $attributeMap = [ - 'allowed_bins' => 'allowed_bins' + 'allowed_bins' => 'allowed_bins', + 'installment_configuration' => 'installment_configuration' ]; /** @@ -169,7 +173,8 @@ public function isNullableSetToNull(string $property): bool * @var string[] */ protected static $setters = [ - 'allowed_bins' => 'setAllowedBins' + 'allowed_bins' => 'setAllowedBins', + 'installment_configuration' => 'setInstallmentConfiguration' ]; /** @@ -178,7 +183,8 @@ public function isNullableSetToNull(string $property): bool * @var string[] */ protected static $getters = [ - 'allowed_bins' => 'getAllowedBins' + 'allowed_bins' => 'getAllowedBins', + 'installment_configuration' => 'getInstallmentConfiguration' ]; /** @@ -239,6 +245,7 @@ public function getModelName() public function __construct(array $data = null) { $this->setIfExists('allowed_bins', $data ?? [], null); + $this->setIfExists('installment_configuration', $data ?? [], null); } /** @@ -309,6 +316,33 @@ public function setAllowedBins($allowed_bins) return $this; } + + /** + * Gets installment_configuration + * + * @return \Invoice\ChannelPropertiesCardsInstallmentConfiguration|null + */ + public function getInstallmentConfiguration() + { + return $this->container['installment_configuration']; + } + + /** + * Sets installment_configuration + * + * @param \Invoice\ChannelPropertiesCardsInstallmentConfiguration|null $installment_configuration installment_configuration + * + * @return self + */ + public function setInstallmentConfiguration($installment_configuration) + { + if (is_null($installment_configuration)) { + throw new \InvalidArgumentException('non-nullable installment_configuration cannot be null'); + } + $this->container['installment_configuration'] = $installment_configuration; + + return $this; + } /** * Returns true if offset exists. False otherwise. * diff --git a/lib/Invoice/ChannelPropertiesCardsInstallmentConfiguration.php b/lib/Invoice/ChannelPropertiesCardsInstallmentConfiguration.php new file mode 100644 index 0000000..f9f2a94 --- /dev/null +++ b/lib/Invoice/ChannelPropertiesCardsInstallmentConfiguration.php @@ -0,0 +1,437 @@ + + */ +class ChannelPropertiesCardsInstallmentConfiguration implements ModelInterface, ArrayAccess, \JsonSerializable +{ + public const DISCRIMINATOR = null; + + /** + * The original name of the model. + * + * @var string + */ + protected static $openAPIModelName = 'ChannelPropertiesCards_installment_configuration'; + + /** + * Array of property to type mappings. Used for (de)serialization + * + * @var string[] + */ + protected static $openAPITypes = [ + 'allow_full_payment' => 'bool', + 'allowed_terms' => '\Xendit\Invoice\ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner[]' + ]; + + /** + * Array of property to format mappings. Used for (de)serialization + * + * @var string[] + * @phpstan-var array + * @psalm-var array + */ + protected static $openAPIFormats = [ + 'allow_full_payment' => null, + 'allowed_terms' => null + ]; + + /** + * Array of nullable properties. Used for (de)serialization + * + * @var boolean[] + */ + protected static array $openAPINullables = [ + 'allow_full_payment' => false, + 'allowed_terms' => false + ]; + + /** + * If a nullable field gets set to null, insert it here + * + * @var boolean[] + */ + protected array $openAPINullablesSetToNull = []; + + /** + * Array of property to type mappings. Used for (de)serialization + * + * @return array + */ + public static function openAPITypes() + { + return self::$openAPITypes; + } + + /** + * Array of property to format mappings. Used for (de)serialization + * + * @return array + */ + public static function openAPIFormats() + { + return self::$openAPIFormats; + } + + /** + * Array of nullable properties + * + * @return array + */ + protected static function openAPINullables(): array + { + return self::$openAPINullables; + } + + /** + * Array of nullable field names deliberately set to null + * + * @return boolean[] + */ + private function getOpenAPINullablesSetToNull(): array + { + return $this->openAPINullablesSetToNull; + } + + /** + * Setter - Array of nullable field names deliberately set to null + * + * @param boolean[] $openAPINullablesSetToNull + */ + private function setOpenAPINullablesSetToNull(array $openAPINullablesSetToNull): void + { + $this->openAPINullablesSetToNull = $openAPINullablesSetToNull; + } + + /** + * Checks if a property is nullable + * + * @param string $property + * @return bool + */ + public static function isNullable(string $property): bool + { + return self::openAPINullables()[$property] ?? false; + } + + /** + * Checks if a nullable property is set to null. + * + * @param string $property + * @return bool + */ + public function isNullableSetToNull(string $property): bool + { + return in_array($property, $this->getOpenAPINullablesSetToNull(), true); + } + + /** + * Array of attributes where the key is the local name, + * and the value is the original name + * + * @var string[] + */ + protected static $attributeMap = [ + 'allow_full_payment' => 'allow_full_payment', + 'allowed_terms' => 'allowed_terms' + ]; + + /** + * Array of attributes to setter functions (for deserialization of responses) + * + * @var string[] + */ + protected static $setters = [ + 'allow_full_payment' => 'setAllowFullPayment', + 'allowed_terms' => 'setAllowedTerms' + ]; + + /** + * Array of attributes to getter functions (for serialization of requests) + * + * @var string[] + */ + protected static $getters = [ + 'allow_full_payment' => 'getAllowFullPayment', + 'allowed_terms' => 'getAllowedTerms' + ]; + + /** + * Array of attributes where the key is the local name, + * and the value is the original name + * + * @return array + */ + public static function attributeMap() + { + return self::$attributeMap; + } + + /** + * Array of attributes to setter functions (for deserialization of responses) + * + * @return array + */ + public static function setters() + { + return self::$setters; + } + + /** + * Array of attributes to getter functions (for serialization of requests) + * + * @return array + */ + public static function getters() + { + return self::$getters; + } + + /** + * The original name of the model. + * + * @return string + */ + public function getModelName() + { + return self::$openAPIModelName; + } + + + /** + * Associative array for storing property values + * + * @var mixed[] + */ + protected $container = []; + + /** + * Constructor + * + * @param mixed[] $data Associated array of property values + * initializing the model + */ + public function __construct(array $data = null) + { + $this->setIfExists('allow_full_payment', $data ?? [], null); + $this->setIfExists('allowed_terms', $data ?? [], null); + } + + /** + * Sets $this->container[$variableName] to the given data or to the given default Value; if $variableName + * is nullable and its value is set to null in the $fields array, then mark it as "set to null" in the + * $this->openAPINullablesSetToNull array + * + * @param string $variableName + * @param array $fields + * @param mixed $defaultValue + */ + private function setIfExists(string $variableName, array $fields, $defaultValue): void + { + if (self::isNullable($variableName) && array_key_exists($variableName, $fields) && is_null($fields[$variableName])) { + $this->openAPINullablesSetToNull[] = $variableName; + } + + $this->container[$variableName] = $fields[$variableName] ?? $defaultValue; + } + + /** + * Show all the invalid properties with reasons. + * + * @return array invalid properties with reasons + */ + public function listInvalidProperties() + { + $invalidProperties = []; + + return $invalidProperties; + } + + /** + * Validate all the properties in the model + * return true if all passed + * + * @return bool True if all properties are valid + */ + public function valid() + { + return count($this->listInvalidProperties()) === 0; + } + + + /** + * Gets allow_full_payment + * + * @return bool|null + */ + public function getAllowFullPayment() + { + return $this->container['allow_full_payment']; + } + + /** + * Sets allow_full_payment + * + * @param bool|null $allow_full_payment Indicate whether full payment (without installment) is allowed + * + * @return self + */ + public function setAllowFullPayment($allow_full_payment) + { + if (is_null($allow_full_payment)) { + throw new \InvalidArgumentException('non-nullable allow_full_payment cannot be null'); + } + $this->container['allow_full_payment'] = $allow_full_payment; + + return $this; + } + + /** + * Gets allowed_terms + * + * @return \Invoice\ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner[]|null + */ + public function getAllowedTerms() + { + return $this->container['allowed_terms']; + } + + /** + * Sets allowed_terms + * + * @param \Invoice\ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner[]|null $allowed_terms An object to set what kind (from specific bank / specific tenor) of cards installments will be available on a specific invoice + * + * @return self + */ + public function setAllowedTerms($allowed_terms) + { + if (is_null($allowed_terms)) { + throw new \InvalidArgumentException('non-nullable allowed_terms cannot be null'); + } + $this->container['allowed_terms'] = $allowed_terms; + + return $this; + } + /** + * Returns true if offset exists. False otherwise. + * + * @param integer $offset Offset + * + * @return boolean + */ + public function offsetExists($offset): bool + { + return isset($this->container[$offset]); + } + + /** + * Gets offset. + * + * @param integer $offset Offset + * + * @return mixed|null + */ + #[\ReturnTypeWillChange] + public function offsetGet($offset) + { + return $this->container[$offset] ?? null; + } + + /** + * Sets value based on offset. + * + * @param int|null $offset Offset + * @param mixed $value Value to be set + * + * @return void + */ + public function offsetSet($offset, $value): void + { + if (is_null($offset)) { + $this->container[] = $value; + } else { + $this->container[$offset] = $value; + } + } + + /** + * Unsets offset. + * + * @param integer $offset Offset + * + * @return void + */ + public function offsetUnset($offset): void + { + unset($this->container[$offset]); + } + + /** + * Serializes the object to a value that can be serialized natively by json_encode(). + * @link https://www.php.net/manual/en/jsonserializable.jsonserialize.php + * + * @return mixed Returns data which can be serialized by json_encode(), which is a value + * of any type other than a resource. + */ + #[\ReturnTypeWillChange] + public function jsonSerialize() + { + return ObjectSerializer::sanitizeForSerialization($this); + } + + /** + * Gets the string presentation of the object + * + * @return string + */ + public function __toString() + { + return json_encode( + ObjectSerializer::sanitizeForSerialization($this), + JSON_PRETTY_PRINT + ); + } + + /** + * Gets a header-safe presentation of the object + * + * @return string + */ + public function toHeaderValue() + { + return json_encode(ObjectSerializer::sanitizeForSerialization($this)); + } +} + + diff --git a/lib/Invoice/ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner.php b/lib/Invoice/ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner.php new file mode 100644 index 0000000..cec6508 --- /dev/null +++ b/lib/Invoice/ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner.php @@ -0,0 +1,436 @@ + + */ +class ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner implements ModelInterface, ArrayAccess, \JsonSerializable +{ + public const DISCRIMINATOR = null; + + /** + * The original name of the model. + * + * @var string + */ + protected static $openAPIModelName = 'ChannelPropertiesCards_installment_configuration_allowed_terms_inner'; + + /** + * Array of property to type mappings. Used for (de)serialization + * + * @var string[] + */ + protected static $openAPITypes = [ + 'issuer' => 'string', + 'allowed_terms' => 'float[]' + ]; + + /** + * Array of property to format mappings. Used for (de)serialization + * + * @var string[] + * @phpstan-var array + * @psalm-var array + */ + protected static $openAPIFormats = [ + 'issuer' => null, + 'allowed_terms' => null + ]; + + /** + * Array of nullable properties. Used for (de)serialization + * + * @var boolean[] + */ + protected static array $openAPINullables = [ + 'issuer' => false, + 'allowed_terms' => false + ]; + + /** + * If a nullable field gets set to null, insert it here + * + * @var boolean[] + */ + protected array $openAPINullablesSetToNull = []; + + /** + * Array of property to type mappings. Used for (de)serialization + * + * @return array + */ + public static function openAPITypes() + { + return self::$openAPITypes; + } + + /** + * Array of property to format mappings. Used for (de)serialization + * + * @return array + */ + public static function openAPIFormats() + { + return self::$openAPIFormats; + } + + /** + * Array of nullable properties + * + * @return array + */ + protected static function openAPINullables(): array + { + return self::$openAPINullables; + } + + /** + * Array of nullable field names deliberately set to null + * + * @return boolean[] + */ + private function getOpenAPINullablesSetToNull(): array + { + return $this->openAPINullablesSetToNull; + } + + /** + * Setter - Array of nullable field names deliberately set to null + * + * @param boolean[] $openAPINullablesSetToNull + */ + private function setOpenAPINullablesSetToNull(array $openAPINullablesSetToNull): void + { + $this->openAPINullablesSetToNull = $openAPINullablesSetToNull; + } + + /** + * Checks if a property is nullable + * + * @param string $property + * @return bool + */ + public static function isNullable(string $property): bool + { + return self::openAPINullables()[$property] ?? false; + } + + /** + * Checks if a nullable property is set to null. + * + * @param string $property + * @return bool + */ + public function isNullableSetToNull(string $property): bool + { + return in_array($property, $this->getOpenAPINullablesSetToNull(), true); + } + + /** + * Array of attributes where the key is the local name, + * and the value is the original name + * + * @var string[] + */ + protected static $attributeMap = [ + 'issuer' => 'issuer', + 'allowed_terms' => 'allowed_terms' + ]; + + /** + * Array of attributes to setter functions (for deserialization of responses) + * + * @var string[] + */ + protected static $setters = [ + 'issuer' => 'setIssuer', + 'allowed_terms' => 'setAllowedTerms' + ]; + + /** + * Array of attributes to getter functions (for serialization of requests) + * + * @var string[] + */ + protected static $getters = [ + 'issuer' => 'getIssuer', + 'allowed_terms' => 'getAllowedTerms' + ]; + + /** + * Array of attributes where the key is the local name, + * and the value is the original name + * + * @return array + */ + public static function attributeMap() + { + return self::$attributeMap; + } + + /** + * Array of attributes to setter functions (for deserialization of responses) + * + * @return array + */ + public static function setters() + { + return self::$setters; + } + + /** + * Array of attributes to getter functions (for serialization of requests) + * + * @return array + */ + public static function getters() + { + return self::$getters; + } + + /** + * The original name of the model. + * + * @return string + */ + public function getModelName() + { + return self::$openAPIModelName; + } + + + /** + * Associative array for storing property values + * + * @var mixed[] + */ + protected $container = []; + + /** + * Constructor + * + * @param mixed[] $data Associated array of property values + * initializing the model + */ + public function __construct(array $data = null) + { + $this->setIfExists('issuer', $data ?? [], null); + $this->setIfExists('allowed_terms', $data ?? [], null); + } + + /** + * Sets $this->container[$variableName] to the given data or to the given default Value; if $variableName + * is nullable and its value is set to null in the $fields array, then mark it as "set to null" in the + * $this->openAPINullablesSetToNull array + * + * @param string $variableName + * @param array $fields + * @param mixed $defaultValue + */ + private function setIfExists(string $variableName, array $fields, $defaultValue): void + { + if (self::isNullable($variableName) && array_key_exists($variableName, $fields) && is_null($fields[$variableName])) { + $this->openAPINullablesSetToNull[] = $variableName; + } + + $this->container[$variableName] = $fields[$variableName] ?? $defaultValue; + } + + /** + * Show all the invalid properties with reasons. + * + * @return array invalid properties with reasons + */ + public function listInvalidProperties() + { + $invalidProperties = []; + + return $invalidProperties; + } + + /** + * Validate all the properties in the model + * return true if all passed + * + * @return bool True if all properties are valid + */ + public function valid() + { + return count($this->listInvalidProperties()) === 0; + } + + + /** + * Gets issuer + * + * @return string|null + */ + public function getIssuer() + { + return $this->container['issuer']; + } + + /** + * Sets issuer + * + * @param string|null $issuer The bank code of the installment provider / issuer + * + * @return self + */ + public function setIssuer($issuer) + { + if (is_null($issuer)) { + throw new \InvalidArgumentException('non-nullable issuer cannot be null'); + } + $this->container['issuer'] = $issuer; + + return $this; + } + + /** + * Gets allowed_terms + * + * @return float[]|null + */ + public function getAllowedTerms() + { + return $this->container['allowed_terms']; + } + + /** + * Sets allowed_terms + * + * @param float[]|null $allowed_terms An array containing list of installment tenor available to choose + * + * @return self + */ + public function setAllowedTerms($allowed_terms) + { + if (is_null($allowed_terms)) { + throw new \InvalidArgumentException('non-nullable allowed_terms cannot be null'); + } + $this->container['allowed_terms'] = $allowed_terms; + + return $this; + } + /** + * Returns true if offset exists. False otherwise. + * + * @param integer $offset Offset + * + * @return boolean + */ + public function offsetExists($offset): bool + { + return isset($this->container[$offset]); + } + + /** + * Gets offset. + * + * @param integer $offset Offset + * + * @return mixed|null + */ + #[\ReturnTypeWillChange] + public function offsetGet($offset) + { + return $this->container[$offset] ?? null; + } + + /** + * Sets value based on offset. + * + * @param int|null $offset Offset + * @param mixed $value Value to be set + * + * @return void + */ + public function offsetSet($offset, $value): void + { + if (is_null($offset)) { + $this->container[] = $value; + } else { + $this->container[$offset] = $value; + } + } + + /** + * Unsets offset. + * + * @param integer $offset Offset + * + * @return void + */ + public function offsetUnset($offset): void + { + unset($this->container[$offset]); + } + + /** + * Serializes the object to a value that can be serialized natively by json_encode(). + * @link https://www.php.net/manual/en/jsonserializable.jsonserialize.php + * + * @return mixed Returns data which can be serialized by json_encode(), which is a value + * of any type other than a resource. + */ + #[\ReturnTypeWillChange] + public function jsonSerialize() + { + return ObjectSerializer::sanitizeForSerialization($this); + } + + /** + * Gets the string presentation of the object + * + * @return string + */ + public function __toString() + { + return json_encode( + ObjectSerializer::sanitizeForSerialization($this), + JSON_PRETTY_PRINT + ); + } + + /** + * Gets a header-safe presentation of the object + * + * @return string + */ + public function toHeaderValue() + { + return json_encode(ObjectSerializer::sanitizeForSerialization($this)); + } +} + + diff --git a/lib/Invoice/CreateInvoiceRequest.php b/lib/Invoice/CreateInvoiceRequest.php index d62b0be..6616235 100644 --- a/lib/Invoice/CreateInvoiceRequest.php +++ b/lib/Invoice/CreateInvoiceRequest.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** @@ -67,11 +67,12 @@ class CreateInvoiceRequest implements ModelInterface, ArrayAccess, \JsonSerializ 'should_authenticate_credit_card' => 'bool', 'currency' => 'string', 'reminder_time' => 'float', - 'local' => 'string', + 'locale' => 'string', 'reminder_time_unit' => 'string', 'items' => '\Xendit\Invoice\InvoiceItem[]', 'fees' => '\Xendit\Invoice\InvoiceFee[]', - 'channel_properties' => '\Xendit\Invoice\ChannelProperties' + 'channel_properties' => '\Xendit\Invoice\ChannelProperties', + 'metadata' => 'object' ]; /** @@ -98,11 +99,12 @@ class CreateInvoiceRequest implements ModelInterface, ArrayAccess, \JsonSerializ 'should_authenticate_credit_card' => null, 'currency' => null, 'reminder_time' => null, - 'local' => null, + 'locale' => null, 'reminder_time_unit' => null, 'items' => null, 'fees' => null, - 'channel_properties' => null + 'channel_properties' => null, + 'metadata' => null ]; /** @@ -127,11 +129,12 @@ class CreateInvoiceRequest implements ModelInterface, ArrayAccess, \JsonSerializ 'should_authenticate_credit_card' => false, 'currency' => false, 'reminder_time' => false, - 'local' => false, + 'locale' => false, 'reminder_time_unit' => false, 'items' => false, 'fees' => false, - 'channel_properties' => false + 'channel_properties' => false, + 'metadata' => false ]; /** @@ -236,11 +239,12 @@ public function isNullableSetToNull(string $property): bool 'should_authenticate_credit_card' => 'should_authenticate_credit_card', 'currency' => 'currency', 'reminder_time' => 'reminder_time', - 'local' => 'local', + 'locale' => 'locale', 'reminder_time_unit' => 'reminder_time_unit', 'items' => 'items', 'fees' => 'fees', - 'channel_properties' => 'channel_properties' + 'channel_properties' => 'channel_properties', + 'metadata' => 'metadata' ]; /** @@ -265,11 +269,12 @@ public function isNullableSetToNull(string $property): bool 'should_authenticate_credit_card' => 'setShouldAuthenticateCreditCard', 'currency' => 'setCurrency', 'reminder_time' => 'setReminderTime', - 'local' => 'setLocal', + 'locale' => 'setLocale', 'reminder_time_unit' => 'setReminderTimeUnit', 'items' => 'setItems', 'fees' => 'setFees', - 'channel_properties' => 'setChannelProperties' + 'channel_properties' => 'setChannelProperties', + 'metadata' => 'setMetadata' ]; /** @@ -294,11 +299,12 @@ public function isNullableSetToNull(string $property): bool 'should_authenticate_credit_card' => 'getShouldAuthenticateCreditCard', 'currency' => 'getCurrency', 'reminder_time' => 'getReminderTime', - 'local' => 'getLocal', + 'locale' => 'getLocale', 'reminder_time_unit' => 'getReminderTimeUnit', 'items' => 'getItems', 'fees' => 'getFees', - 'channel_properties' => 'getChannelProperties' + 'channel_properties' => 'getChannelProperties', + 'metadata' => 'getMetadata' ]; /** @@ -374,11 +380,12 @@ public function __construct(array $data = null) $this->setIfExists('should_authenticate_credit_card', $data ?? [], null); $this->setIfExists('currency', $data ?? [], null); $this->setIfExists('reminder_time', $data ?? [], null); - $this->setIfExists('local', $data ?? [], null); + $this->setIfExists('locale', $data ?? [], null); $this->setIfExists('reminder_time_unit', $data ?? [], null); $this->setIfExists('items', $data ?? [], null); $this->setIfExists('fees', $data ?? [], null); $this->setIfExists('channel_properties', $data ?? [], null); + $this->setIfExists('metadata', $data ?? [], null); } /** @@ -862,28 +869,28 @@ public function setReminderTime($reminder_time) } /** - * Gets local + * Gets locale * * @return string|null */ - public function getLocal() + public function getLocale() { - return $this->container['local']; + return $this->container['locale']; } /** - * Sets local + * Sets locale * - * @param string|null $local The local. + * @param string|null $locale The default language to display. * * @return self */ - public function setLocal($local) + public function setLocale($locale) { - if (is_null($local)) { - throw new \InvalidArgumentException('non-nullable local cannot be null'); + if (is_null($locale)) { + throw new \InvalidArgumentException('non-nullable locale cannot be null'); } - $this->container['local'] = $local; + $this->container['locale'] = $locale; return $this; } @@ -995,6 +1002,35 @@ public function setChannelProperties($channel_properties) return $this; } + + /** + * Gets metadata + * + * @return object|null + */ + public function getMetadata() + { + return $this->container['metadata']; + } + + /** + * Sets metadata + * + * @param object|null $metadata A free-format JSON for additional information that you may use. Object can be up to 50 keys, with key names up to 40 characters long and values up to 500 characters long. + * + * @return self + */ + public function setMetadata($metadata) + { + if (is_null($metadata)) { + throw new \InvalidArgumentException('non-nullable metadata cannot be null'); + } + + + $this->container['metadata'] = $metadata; + + return $this; + } /** * Returns true if offset exists. False otherwise. * diff --git a/lib/Invoice/CustomerObject.php b/lib/Invoice/CustomerObject.php index 53e58d4..a732066 100644 --- a/lib/Invoice/CustomerObject.php +++ b/lib/Invoice/CustomerObject.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/DirectDebit.php b/lib/Invoice/DirectDebit.php index 045de87..1c93e03 100644 --- a/lib/Invoice/DirectDebit.php +++ b/lib/Invoice/DirectDebit.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/DirectDebitType.php b/lib/Invoice/DirectDebitType.php index d841c14..e513e7b 100644 --- a/lib/Invoice/DirectDebitType.php +++ b/lib/Invoice/DirectDebitType.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/Ewallet.php b/lib/Invoice/Ewallet.php index 8c3d7e3..cf4bc43 100644 --- a/lib/Invoice/Ewallet.php +++ b/lib/Invoice/Ewallet.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/EwalletType.php b/lib/Invoice/EwalletType.php index 3a4d8e6..650f6e1 100644 --- a/lib/Invoice/EwalletType.php +++ b/lib/Invoice/EwalletType.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/ForbiddenError.php b/lib/Invoice/ForbiddenError.php index f0dde3b..1b3473a 100644 --- a/lib/Invoice/ForbiddenError.php +++ b/lib/Invoice/ForbiddenError.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/Invoice.php b/lib/Invoice/Invoice.php index 2849ecc..3dee21b 100644 --- a/lib/Invoice/Invoice.php +++ b/lib/Invoice/Invoice.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** @@ -84,7 +84,8 @@ class Invoice implements ModelInterface, ArrayAccess, \JsonSerializable 'customer' => '\Xendit\Invoice\CustomerObject', 'customer_notification_preference' => '\Xendit\Invoice\NotificationPreference', 'fees' => '\Xendit\Invoice\InvoiceFee[]', - 'channel_properties' => '\Xendit\Invoice\ChannelProperties' + 'channel_properties' => '\Xendit\Invoice\ChannelProperties', + 'metadata' => 'object' ]; /** @@ -128,7 +129,8 @@ class Invoice implements ModelInterface, ArrayAccess, \JsonSerializable 'customer' => null, 'customer_notification_preference' => null, 'fees' => null, - 'channel_properties' => null + 'channel_properties' => null, + 'metadata' => null ]; /** @@ -170,7 +172,8 @@ class Invoice implements ModelInterface, ArrayAccess, \JsonSerializable 'customer' => false, 'customer_notification_preference' => false, 'fees' => false, - 'channel_properties' => false + 'channel_properties' => false, + 'metadata' => false ]; /** @@ -292,7 +295,8 @@ public function isNullableSetToNull(string $property): bool 'customer' => 'customer', 'customer_notification_preference' => 'customer_notification_preference', 'fees' => 'fees', - 'channel_properties' => 'channel_properties' + 'channel_properties' => 'channel_properties', + 'metadata' => 'metadata' ]; /** @@ -334,7 +338,8 @@ public function isNullableSetToNull(string $property): bool 'customer' => 'setCustomer', 'customer_notification_preference' => 'setCustomerNotificationPreference', 'fees' => 'setFees', - 'channel_properties' => 'setChannelProperties' + 'channel_properties' => 'setChannelProperties', + 'metadata' => 'setMetadata' ]; /** @@ -376,7 +381,8 @@ public function isNullableSetToNull(string $property): bool 'customer' => 'getCustomer', 'customer_notification_preference' => 'getCustomerNotificationPreference', 'fees' => 'getFees', - 'channel_properties' => 'getChannelProperties' + 'channel_properties' => 'getChannelProperties', + 'metadata' => 'getMetadata' ]; /** @@ -470,6 +476,7 @@ public function __construct(array $data = null) $this->setIfExists('customer_notification_preference', $data ?? [], null); $this->setIfExists('fees', $data ?? [], null); $this->setIfExists('channel_properties', $data ?? [], null); + $this->setIfExists('metadata', $data ?? [], null); } /** @@ -1482,6 +1489,33 @@ public function setChannelProperties($channel_properties) return $this; } + + /** + * Gets metadata + * + * @return object|null + */ + public function getMetadata() + { + return $this->container['metadata']; + } + + /** + * Sets metadata + * + * @param object|null $metadata A free-format JSON for additional information that you may use. Object can be up to 50 keys, with key names up to 40 characters long and values up to 500 characters long. + * + * @return self + */ + public function setMetadata($metadata) + { + if (is_null($metadata)) { + throw new \InvalidArgumentException('non-nullable metadata cannot be null'); + } + $this->container['metadata'] = $metadata; + + return $this; + } /** * Returns true if offset exists. False otherwise. * diff --git a/lib/Invoice/InvoiceApi.php b/lib/Invoice/InvoiceApi.php index d1a933c..1c64734 100644 --- a/lib/Invoice/InvoiceApi.php +++ b/lib/Invoice/InvoiceApi.php @@ -10,7 +10,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** @@ -365,7 +365,7 @@ public function createInvoiceRequest($create_invoice_request, $for_user_id = nul // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -624,7 +624,7 @@ public function getInvoiceByIdRequest($invoice_id, $for_user_id = null, string $ // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -1073,7 +1073,7 @@ public function getInvoicesRequest($for_user_id = null, $external_id = null, $st // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -1332,7 +1332,7 @@ public function expireInvoiceRequest($invoice_id, $for_user_id = null, string $c // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); diff --git a/lib/Invoice/InvoiceCallback.php b/lib/Invoice/InvoiceCallback.php index abed7ff..f73a209 100644 --- a/lib/Invoice/InvoiceCallback.php +++ b/lib/Invoice/InvoiceCallback.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/InvoiceCallbackItem.php b/lib/Invoice/InvoiceCallbackItem.php index c3e71b0..6c9d708 100644 --- a/lib/Invoice/InvoiceCallbackItem.php +++ b/lib/Invoice/InvoiceCallbackItem.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/InvoiceClientType.php b/lib/Invoice/InvoiceClientType.php index b184597..bc87975 100644 --- a/lib/Invoice/InvoiceClientType.php +++ b/lib/Invoice/InvoiceClientType.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/InvoiceCurrency.php b/lib/Invoice/InvoiceCurrency.php index c3ad9f0..e43e9ef 100644 --- a/lib/Invoice/InvoiceCurrency.php +++ b/lib/Invoice/InvoiceCurrency.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** @@ -47,6 +47,8 @@ class InvoiceCurrency public const PHP = 'PHP'; + public const MYR = 'MYR'; + public const XENDIT_ENUM_DEFAULT_FALLBACK = 'UNKNOWN_ENUM_VALUE'; private $value; @@ -82,6 +84,7 @@ public static function getAllowableEnumValues() self::THB, self::VND, self::PHP, + self::MYR, self::XENDIT_ENUM_DEFAULT_FALLBACK ]; } diff --git a/lib/Invoice/InvoiceError404ResponseDefinition.php b/lib/Invoice/InvoiceError404ResponseDefinition.php index 806be64..45e87f8 100644 --- a/lib/Invoice/InvoiceError404ResponseDefinition.php +++ b/lib/Invoice/InvoiceError404ResponseDefinition.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/InvoiceFee.php b/lib/Invoice/InvoiceFee.php index ab76647..f2a2b3e 100644 --- a/lib/Invoice/InvoiceFee.php +++ b/lib/Invoice/InvoiceFee.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/InvoiceItem.php b/lib/Invoice/InvoiceItem.php index 141b1f3..3133034 100644 --- a/lib/Invoice/InvoiceItem.php +++ b/lib/Invoice/InvoiceItem.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/InvoiceNotFoundError.php b/lib/Invoice/InvoiceNotFoundError.php index 5bf1769..522c7cb 100644 --- a/lib/Invoice/InvoiceNotFoundError.php +++ b/lib/Invoice/InvoiceNotFoundError.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/InvoicePaymentMethod.php b/lib/Invoice/InvoicePaymentMethod.php index 21b7099..a80a5ea 100644 --- a/lib/Invoice/InvoicePaymentMethod.php +++ b/lib/Invoice/InvoicePaymentMethod.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/InvoiceStatus.php b/lib/Invoice/InvoiceStatus.php index 24003fb..c5d5e23 100644 --- a/lib/Invoice/InvoiceStatus.php +++ b/lib/Invoice/InvoiceStatus.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/NotificationChannel.php b/lib/Invoice/NotificationChannel.php index f52f368..db468aa 100644 --- a/lib/Invoice/NotificationChannel.php +++ b/lib/Invoice/NotificationChannel.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/NotificationPreference.php b/lib/Invoice/NotificationPreference.php index cb27763..a92c08b 100644 --- a/lib/Invoice/NotificationPreference.php +++ b/lib/Invoice/NotificationPreference.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/Paylater.php b/lib/Invoice/Paylater.php index 3566f23..fba4933 100644 --- a/lib/Invoice/Paylater.php +++ b/lib/Invoice/Paylater.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/PaylaterType.php b/lib/Invoice/PaylaterType.php index 6780faa..3d76a34 100644 --- a/lib/Invoice/PaylaterType.php +++ b/lib/Invoice/PaylaterType.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/PaymentDetails.php b/lib/Invoice/PaymentDetails.php index 8b7686a..fd35ea3 100644 --- a/lib/Invoice/PaymentDetails.php +++ b/lib/Invoice/PaymentDetails.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/QrCode.php b/lib/Invoice/QrCode.php index a4bf452..9a7fb5b 100644 --- a/lib/Invoice/QrCode.php +++ b/lib/Invoice/QrCode.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/QrCodeType.php b/lib/Invoice/QrCodeType.php index e88b9f8..1783636 100644 --- a/lib/Invoice/QrCodeType.php +++ b/lib/Invoice/QrCodeType.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** @@ -41,6 +41,8 @@ class QrCodeType public const PROMPTPAY = 'PROMPTPAY'; + public const QRPH = 'QRPH'; + public const XENDIT_ENUM_DEFAULT_FALLBACK = 'UNKNOWN_ENUM_VALUE'; private $value; @@ -73,6 +75,7 @@ public static function getAllowableEnumValues() return [ self::QRIS, self::PROMPTPAY, + self::QRPH, self::XENDIT_ENUM_DEFAULT_FALLBACK ]; } diff --git a/lib/Invoice/RetailOutlet.php b/lib/Invoice/RetailOutlet.php index afa5009..01bc8c6 100644 --- a/lib/Invoice/RetailOutlet.php +++ b/lib/Invoice/RetailOutlet.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/RetailOutletName.php b/lib/Invoice/RetailOutletName.php index b318234..077c96c 100644 --- a/lib/Invoice/RetailOutletName.php +++ b/lib/Invoice/RetailOutletName.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/ServerError.php b/lib/Invoice/ServerError.php index bd6d7fb..ecc4aff 100644 --- a/lib/Invoice/ServerError.php +++ b/lib/Invoice/ServerError.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/Invoice/UnauthorizedError.php b/lib/Invoice/UnauthorizedError.php index 106e493..d51c77b 100644 --- a/lib/Invoice/UnauthorizedError.php +++ b/lib/Invoice/UnauthorizedError.php @@ -11,7 +11,7 @@ /** * xendit-invoice-service * - * The version of the OpenAPI document: 1.7.6 + * The version of the OpenAPI document: 1.8.7 */ /** diff --git a/lib/PaymentMethod/PaymentMethodApi.php b/lib/PaymentMethod/PaymentMethodApi.php index 8c81de2..99f75e8 100644 --- a/lib/PaymentMethod/PaymentMethodApi.php +++ b/lib/PaymentMethod/PaymentMethodApi.php @@ -371,7 +371,7 @@ public function createPaymentMethodRequest($for_user_id = null, $payment_method_ // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -630,7 +630,7 @@ public function getPaymentMethodByIDRequest($payment_method_id, $for_user_id = n // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -1069,7 +1069,7 @@ public function getPaymentsByPaymentMethodIdRequest($payment_method_id, $for_use // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -1341,7 +1341,7 @@ public function patchPaymentMethodRequest($payment_method_id, $for_user_id = nul // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -1718,7 +1718,7 @@ public function getAllPaymentMethodsRequest($for_user_id = null, $id = null, $ty // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -1990,7 +1990,7 @@ public function expirePaymentMethodRequest($payment_method_id, $for_user_id = nu // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -2262,7 +2262,7 @@ public function authPaymentMethodRequest($payment_method_id, $for_user_id = null // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -2497,7 +2497,7 @@ public function simulatePaymentRequest($payment_method_id, $simulate_payment_req // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); diff --git a/lib/PaymentRequest/PaymentRequestApi.php b/lib/PaymentRequest/PaymentRequestApi.php index cb81976..9e8f72d 100644 --- a/lib/PaymentRequest/PaymentRequestApi.php +++ b/lib/PaymentRequest/PaymentRequestApi.php @@ -391,7 +391,7 @@ public function createPaymentRequestRequest($idempotency_key = null, $for_user_i // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -650,7 +650,7 @@ public function getPaymentRequestByIDRequest($payment_request_id, $for_user_id = // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -924,7 +924,7 @@ public function getPaymentRequestCapturesRequest($payment_request_id, $for_user_ // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -1253,7 +1253,7 @@ public function getAllPaymentRequestsRequest($for_user_id = null, $reference_id // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -1525,7 +1525,7 @@ public function capturePaymentRequestRequest($payment_request_id, $for_user_id = // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -1797,7 +1797,7 @@ public function authorizePaymentRequestRequest($payment_request_id, $for_user_id // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -2056,7 +2056,7 @@ public function resendPaymentRequestAuthRequest($payment_request_id, $for_user_i // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -2305,7 +2305,7 @@ public function simulatePaymentRequestPaymentRequest($payment_request_id, string // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); diff --git a/lib/Payout/PayoutApi.php b/lib/Payout/PayoutApi.php index 2684817..dfe45ef 100644 --- a/lib/Payout/PayoutApi.php +++ b/lib/Payout/PayoutApi.php @@ -378,7 +378,7 @@ public function createPayoutRequest($idempotency_key, $for_user_id = null, $crea // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -637,7 +637,7 @@ public function getPayoutByIdRequest($id, $for_user_id = null, string $contentTy // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -921,7 +921,7 @@ public function getPayoutChannelsRequest($currency = null, $channel_category = n // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -1226,7 +1226,7 @@ public function getPayoutsRequest($reference_id, $limit = null, $after_id = null // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -1485,7 +1485,7 @@ public function cancelPayoutRequest($id, $for_user_id = null, string $contentTyp // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); diff --git a/lib/Refund/RefundApi.php b/lib/Refund/RefundApi.php index 5cce0f8..ca0be2e 100644 --- a/lib/Refund/RefundApi.php +++ b/lib/Refund/RefundApi.php @@ -361,7 +361,7 @@ public function createRefundRequest($idempotency_key = null, $for_user_id = null // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -622,7 +622,7 @@ public function getRefundRequest($refund_id, $idempotency_key = null, $for_user_ // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -958,7 +958,7 @@ public function getAllRefundsRequest($for_user_id = null, $payment_request_id = // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent(); @@ -1219,7 +1219,7 @@ public function cancelRefundRequest($refund_id, $idempotency_key = null, $for_us // Xendit's custom headers $defaultHeaders['xendit-lib'] = 'php'; - $defaultHeaders['xendit-lib-ver'] = '6.0.0'; + $defaultHeaders['xendit-lib-ver'] = '6.1.0'; if ($this->config->getUserAgent()) { $defaultHeaders['User-Agent'] = $this->config->getUserAgent();