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 6af63bb..379463b 100644 --- a/README.md +++ b/README.md @@ -5,7 +5,7 @@ The official Xendit Python SDK provides a simple and convenient way to call Xendit's REST API in applications written in Python. -* Package version: 6.0.0 +* Package version: 6.1.0 ## Requirements diff --git a/docs/InvoiceApi.md b/docs/InvoiceApi.md index 44dce07..8eb7ddb 100644 --- a/docs/InvoiceApi.md +++ b/docs/InvoiceApi.md @@ -124,7 +124,7 @@ create_invoice_request = CreateInvoiceRequest( should_authenticate_credit_card=True, currency="currency_example", reminder_time=3.14, - local="local_example", + locale="locale_example", reminder_time_unit="reminder_time_unit_example", items=[ InvoiceItem( @@ -147,8 +147,20 @@ create_invoice_request = CreateInvoiceRequest( allowed_bins=[ "allowed_bins_example", ], + installment_configuration=ChannelPropertiesCardsInstallmentConfiguration( + allow_full_payment=True, + allowed_terms=[ + ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner( + issuer="issuer_example", + allowed_terms=[ + 3.14, + ], + ), + ], + ), ), ), + metadata={}, ) # CreateInvoiceRequest for_user_id = "62efe4c33e45694d63f585f0" # str | Business ID of the sub-account merchant (XP feature) diff --git a/docs/invoice/BankCode.md b/docs/invoice/BankCode.md index dad4a30..09e35ca 100644 --- a/docs/invoice/BankCode.md +++ b/docs/invoice/BankCode.md @@ -25,6 +25,20 @@ Representing the available bank channels used for invoice-related transactions. * `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 ae95273..e458c40 100644 --- a/docs/invoice/ChannelPropertiesCards.md +++ b/docs/invoice/ChannelPropertiesCards.md @@ -7,6 +7,7 @@ An object representing properties specific for credit card payment method. | Name | Type | Required | Description | Examples | |------------|:-------------:|:-------------:|-------------|:-------------:| | **allowed_bins** | **[str]** | | An array of allowed BINs (6 or 8 digits) for credit card payments. | | +| **installment_configuration** | [**ChannelPropertiesCardsInstallmentConfiguration**](ChannelPropertiesCardsInstallmentConfiguration.md) | | | | [[Back to README]](../../README.md) diff --git a/docs/invoice/ChannelPropertiesCardsInstallmentConfiguration.md b/docs/invoice/ChannelPropertiesCardsInstallmentConfiguration.md new file mode 100644 index 0000000..3cd049e --- /dev/null +++ b/docs/invoice/ChannelPropertiesCardsInstallmentConfiguration.md @@ -0,0 +1,15 @@ +# ChannelPropertiesCardsInstallmentConfiguration +> xendit.invoice.model.ChannelPropertiesCardsInstallmentConfiguration + +An object to pre-set cards installment for a specific invoice + +## Properties +| Name | Type | Required | Description | Examples | +|------------|:-------------:|:-------------:|-------------|:-------------:| +| **allow_full_payment** | **bool** | | Indicate whether full payment (without installment) is allowed | | +| **allowed_terms** | [**[ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner]**](ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner.md) | | An object to set what kind (from specific bank / specific tenor) of cards installments will be available on a specific invoice | | + + +[[Back to README]](../../README.md) + + diff --git a/docs/invoice/ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner.md b/docs/invoice/ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner.md new file mode 100644 index 0000000..5b628f3 --- /dev/null +++ b/docs/invoice/ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner.md @@ -0,0 +1,14 @@ +# ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner +> xendit.invoice.model.ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner + + +## Properties +| Name | Type | Required | Description | Examples | +|------------|:-------------:|:-------------:|-------------|:-------------:| +| **issuer** | **str** | | The bank code of the installment provider / issuer | | +| **allowed_terms** | **[float]** | | An array containing list of installment tenor available to choose | | + + +[[Back to README]](../../README.md) + + diff --git a/docs/invoice/CreateInvoiceRequest.md b/docs/invoice/CreateInvoiceRequest.md index 15b48a5..aa80e44 100644 --- a/docs/invoice/CreateInvoiceRequest.md +++ b/docs/invoice/CreateInvoiceRequest.md @@ -22,11 +22,12 @@ An object representing for an invoice creation request. | **should_authenticate_credit_card** | **bool** | | Indicates whether credit card authentication is required. | | | **currency** | **str** | | The currency of the invoice. | | | **reminder_time** | **float** | | The reminder time. | | -| **local** | **str** | | The local. | | +| **locale** | **str** | | The default language to display. | | | **reminder_time_unit** | **str** | | The unit of the reminder time. | | | **items** | [**[InvoiceItem]**](InvoiceItem.md) | | An array of items included in the invoice. | | | **fees** | [**[InvoiceFee]**](InvoiceFee.md) | | An array of fees associated with the invoice. | | | **channel_properties** | [**ChannelProperties**](ChannelProperties.md) | | | | +| **metadata** | **{str: (bool, date, datetime, dict, float, int, list, str, none_type)}** | | 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. | | [[Back to README]](../../README.md) diff --git a/docs/invoice/Invoice.md b/docs/invoice/Invoice.md index f140dd0..8bd23be 100644 --- a/docs/invoice/Invoice.md +++ b/docs/invoice/Invoice.md @@ -40,6 +40,7 @@ An object representing details for an invoice. | **customer_notification_preference** | [**NotificationPreference**](NotificationPreference.md) | | | | | **fees** | [**[InvoiceFee]**](InvoiceFee.md) | | An array of fees associated with the invoice. | | | **channel_properties** | [**ChannelProperties**](ChannelProperties.md) | | | | +| **metadata** | **{str: (bool, date, datetime, dict, float, int, list, str, none_type)}** | | 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. | | [[Back to README]](../../README.md) diff --git a/docs/invoice/InvoiceCurrency.md b/docs/invoice/InvoiceCurrency.md index 1830dd6..3ceb86a 100644 --- a/docs/invoice/InvoiceCurrency.md +++ b/docs/invoice/InvoiceCurrency.md @@ -17,6 +17,8 @@ Representing the currency used for an invoice. * `PHP` (value: `"PHP"`) + * `MYR` (value: `"MYR"`) + * `XenditEnumDefaultFallback` (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 e157777..8c8d880 100644 --- a/docs/invoice/QrCodeType.md +++ b/docs/invoice/QrCodeType.md @@ -11,6 +11,8 @@ Representing the available QR Code channels used for invoice-related transaction * `PROMPTPAY` (value: `"PROMPTPAY"`) + * `QRPH` (value: `"QRPH"`) + * `XenditEnumDefaultFallback` (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/pyproject.toml b/pyproject.toml index 0d211f2..d2a33a0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "xendit-python" -version = "6.0.0" +version = "6.1.0" description = "Xendit REST API Client for Python - Invoice, Payment Request, Payment Method, Refund, Balance, Transaction, Customer, and Payout Services https://xendit.github.io/apireference/" authors = ["DevX Team "] license = "MIT" diff --git a/setup.py b/setup.py index 81e0875..16eb026 100644 --- a/setup.py +++ b/setup.py @@ -6,7 +6,7 @@ from setuptools import setup, find_packages # noqa: H301 NAME = "xendit" -VERSION = "6.0.0" +VERSION = "6.1.0" # To install the library, run the following # # python setup.py install diff --git a/xendit/__init__.py b/xendit/__init__.py index e5efdb0..4ce5f0e 100644 --- a/xendit/__init__.py +++ b/xendit/__init__.py @@ -5,7 +5,7 @@ """ -__version__ = "6.0.0" +__version__ = "6.1.0" # import ApiClient from xendit.api_client import ApiClient diff --git a/xendit/api_client.py b/xendit/api_client.py index 05f5619..5ceaced 100644 --- a/xendit/api_client.py +++ b/xendit/api_client.py @@ -74,11 +74,11 @@ def __init__(self, configuration=None, header_name=None, header_value=None, # XENDIT headers self.default_headers['xendit-lib'] = 'python' - self.default_headers['xendit-lib-ver'] = '6.0.0' + self.default_headers['xendit-lib-ver'] = '6.1.0' self.cookie = cookie # Set default User-Agent. - self.user_agent = 'OpenAPI-Generator/6.0.0/python' + self.user_agent = 'OpenAPI-Generator/6.1.0/python' def __enter__(self): return self diff --git a/xendit/configuration.py b/xendit/configuration.py index 3b9ffad..e085a10 100644 --- a/xendit/configuration.py +++ b/xendit/configuration.py @@ -365,7 +365,7 @@ def to_debug_report(self): "OS: {env}\n"\ "Python Version: {pyversion}\n"\ "Version of the API: 1.70.0\n"\ - "SDK Package Version: 6.0.0".\ + "SDK Package Version: 6.1.0".\ format(env=sys.platform, pyversion=sys.version) def get_host_settings(self): diff --git a/xendit/invoice/invoice_api.py b/xendit/invoice/invoice_api.py index db2aedf..b00ec7c 100644 --- a/xendit/invoice/invoice_api.py +++ b/xendit/invoice/invoice_api.py @@ -3,7 +3,7 @@ xendit-invoice-service descriptions # noqa: E501 - The version of the OpenAPI document: 1.7.6 + The version of the OpenAPI document: 1.8.7 """ import re # noqa: F401 diff --git a/xendit/invoice/model/__init__.py b/xendit/invoice/model/__init__.py index 3813035..aeb01fb 100644 --- a/xendit/invoice/model/__init__.py +++ b/xendit/invoice/model/__init__.py @@ -16,6 +16,8 @@ from xendit.invoice.model.bank_code import BankCode from xendit.invoice.model.channel_properties import ChannelProperties from xendit.invoice.model.channel_properties_cards import ChannelPropertiesCards +from xendit.invoice.model.channel_properties_cards_installment_configuration import ChannelPropertiesCardsInstallmentConfiguration +from xendit.invoice.model.channel_properties_cards_installment_configuration_allowed_terms_inner import ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner from xendit.invoice.model.create_invoice_request import CreateInvoiceRequest from xendit.invoice.model.customer_object import CustomerObject from xendit.invoice.model.direct_debit import DirectDebit diff --git a/xendit/invoice/model/address_object.py b/xendit/invoice/model/address_object.py index f26f7e8..b530d03 100644 --- a/xendit/invoice/model/address_object.py +++ b/xendit/invoice/model/address_object.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/alternative_display_item.py b/xendit/invoice/model/alternative_display_item.py index 08e2e3e..e99c14e 100644 --- a/xendit/invoice/model/alternative_display_item.py +++ b/xendit/invoice/model/alternative_display_item.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/bad_request_error.py b/xendit/invoice/model/bad_request_error.py index 58029fb..6136127 100644 --- a/xendit/invoice/model/bad_request_error.py +++ b/xendit/invoice/model/bad_request_error.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/bank.py b/xendit/invoice/model/bank.py index b440cc3..864df8a 100644 --- a/xendit/invoice/model/bank.py +++ b/xendit/invoice/model/bank.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/bank_code.py b/xendit/invoice/model/bank_code.py index e0e7b51..f774703 100644 --- a/xendit/invoice/model/bank_code.py +++ b/xendit/invoice/model/bank_code.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ @@ -59,6 +59,13 @@ class BankCode(ModelSimple): 'BJB': "BJB", 'SAHABAT_SAMPOERNA': "SAHABAT_SAMPOERNA", 'CIMB': "CIMB", + 'VIETCAPITAL': "VIETCAPITAL", + 'WOORI': "WOORI", + 'PV': "PV", + 'MSB': "MSB", + 'VPB': "VPB", + 'BIDV': "BIDV", + 'CAKE': "CAKE", 'BNC': "BNC", 'HANA': "HANA", 'MUAMALAT': "MUAMALAT", @@ -114,10 +121,10 @@ def __init__(self, *args, **kwargs): Note that value can be passed either in args or in kwargs, but not in both. Args: - args[0] (str): Representing the available bank channels used for invoice-related transactions.., must be one of ["BCA", "BNI", "BRI", "MANDIRI", "PERMATA", "BSI", "BJB", "SAHABAT_SAMPOERNA", "CIMB", "BNC", "HANA", "MUAMALAT", ] # noqa: E501 + args[0] (str): Representing the available bank channels used for invoice-related transactions.., must be one of ["BCA", "BNI", "BRI", "MANDIRI", "PERMATA", "BSI", "BJB", "SAHABAT_SAMPOERNA", "CIMB", "VIETCAPITAL", "WOORI", "PV", "MSB", "VPB", "BIDV", "CAKE", "BNC", "HANA", "MUAMALAT", ] # noqa: E501 Keyword Args: - value (str): Representing the available bank channels used for invoice-related transactions.., must be one of ["BCA", "BNI", "BRI", "MANDIRI", "PERMATA", "BSI", "BJB", "SAHABAT_SAMPOERNA", "CIMB", "BNC", "HANA", "MUAMALAT", ] # noqa: E501 + value (str): Representing the available bank channels used for invoice-related transactions.., must be one of ["BCA", "BNI", "BRI", "MANDIRI", "PERMATA", "BSI", "BJB", "SAHABAT_SAMPOERNA", "CIMB", "VIETCAPITAL", "WOORI", "PV", "MSB", "VPB", "BIDV", "CAKE", "BNC", "HANA", "MUAMALAT", ] # noqa: E501 _check_type (bool): if True, values for parameters in openapi_types will be type checked and a TypeError will be raised if the wrong type is input. @@ -210,10 +217,10 @@ def _from_openapi_data(cls, *args, **kwargs): Note that value can be passed either in args or in kwargs, but not in both. Args: - args[0] (str): Representing the available bank channels used for invoice-related transactions.., must be one of ["BCA", "BNI", "BRI", "MANDIRI", "PERMATA", "BSI", "BJB", "SAHABAT_SAMPOERNA", "CIMB", "BNC", "HANA", "MUAMALAT", ] # noqa: E501 + args[0] (str): Representing the available bank channels used for invoice-related transactions.., must be one of ["BCA", "BNI", "BRI", "MANDIRI", "PERMATA", "BSI", "BJB", "SAHABAT_SAMPOERNA", "CIMB", "VIETCAPITAL", "WOORI", "PV", "MSB", "VPB", "BIDV", "CAKE", "BNC", "HANA", "MUAMALAT", ] # noqa: E501 Keyword Args: - value (str): Representing the available bank channels used for invoice-related transactions.., must be one of ["BCA", "BNI", "BRI", "MANDIRI", "PERMATA", "BSI", "BJB", "SAHABAT_SAMPOERNA", "CIMB", "BNC", "HANA", "MUAMALAT", ] # noqa: E501 + value (str): Representing the available bank channels used for invoice-related transactions.., must be one of ["BCA", "BNI", "BRI", "MANDIRI", "PERMATA", "BSI", "BJB", "SAHABAT_SAMPOERNA", "CIMB", "VIETCAPITAL", "WOORI", "PV", "MSB", "VPB", "BIDV", "CAKE", "BNC", "HANA", "MUAMALAT", ] # noqa: E501 _check_type (bool): if True, values for parameters in openapi_types will be type checked and a TypeError will be raised if the wrong type is input. diff --git a/xendit/invoice/model/channel_properties.py b/xendit/invoice/model/channel_properties.py index 3374595..33c73e6 100644 --- a/xendit/invoice/model/channel_properties.py +++ b/xendit/invoice/model/channel_properties.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/channel_properties_cards.py b/xendit/invoice/model/channel_properties_cards.py index 07c2aa6..2aa58de 100644 --- a/xendit/invoice/model/channel_properties_cards.py +++ b/xendit/invoice/model/channel_properties_cards.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ @@ -24,6 +24,8 @@ ) from xendit.exceptions import ApiAttributeError +from xendit.invoice.model.channel_properties_cards_installment_configuration import ChannelPropertiesCardsInstallmentConfiguration +globals()['ChannelPropertiesCardsInstallmentConfiguration'] = ChannelPropertiesCardsInstallmentConfiguration def lazy_import(): pass @@ -64,6 +66,7 @@ def additional_properties_type(): This must be a method because a model may have properties that are of type self, this must run after the class is loaded """ + lazy_import() return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 _nullable = False @@ -78,8 +81,10 @@ def openapi_types(): openapi_types (dict): The key is attribute name and the value is attribute type. """ + lazy_import() return { 'allowed_bins': ([str], none_type), # noqa: E501 + 'installment_configuration': (ChannelPropertiesCardsInstallmentConfiguration, none_type), # noqa: E501 } @cached_property @@ -89,6 +94,7 @@ def discriminator(): attribute_map = { 'allowed_bins': 'allowed_bins', # noqa: E501 + 'installment_configuration': 'installment_configuration', # noqa: E501 } read_only_vars = { @@ -133,6 +139,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 through its discriminator because we passed in _visited_composed_classes = (Animal,) allowed_bins ([str]): An array of allowed BINs (6 or 8 digits) for credit card payments.. [optional] # noqa: E501 + installment_configuration (ChannelPropertiesCardsInstallmentConfiguration): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) @@ -188,6 +195,7 @@ def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 @convert_js_args_to_python_args def __init__(self, allowed_bins: list | None = None, + installment_configuration: ChannelPropertiesCardsInstallmentConfiguration | None = None, *args, **kwargs ): # noqa: E501 """ChannelPropertiesCards - a model defined in OpenAPI @@ -225,6 +233,7 @@ def __init__(self, through its discriminator because we passed in _visited_composed_classes = (Animal,) allowed_bins ([str]): An array of allowed BINs (6 or 8 digits) for credit card payments.. [optional] # noqa: E501 + installment_configuration (ChannelPropertiesCardsInstallmentConfiguration): [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) @@ -258,6 +267,8 @@ def __init__(self, if allowed_bins is not None: self.allowed_bins = allowed_bins + if installment_configuration is not None: + self.installment_configuration = installment_configuration for var_name, var_value in kwargs.items(): if var_name not in self.attribute_map and \ self._configuration is not None and \ diff --git a/xendit/invoice/model/channel_properties_cards_installment_configuration.py b/xendit/invoice/model/channel_properties_cards_installment_configuration.py new file mode 100644 index 0000000..c2da5b1 --- /dev/null +++ b/xendit/invoice/model/channel_properties_cards_installment_configuration.py @@ -0,0 +1,282 @@ +""" + The version of the XENDIT API: 1.8.7 +""" + + +import re # noqa: F401 +import sys # noqa: F401 +from typing import List # noqa: F401 + +from xendit.model_utils import ( # noqa: F401 + ApiTypeError, + ModelComposed, + ModelNormal, + ModelSimple, + cached_property, + change_keys_js_to_python, + convert_js_args_to_python_args, + date, + datetime, + file_type, + none_type, + validate_get_composed_info, + OpenApiModel +) +from xendit.exceptions import ApiAttributeError + +from xendit.invoice.model.channel_properties_cards_installment_configuration_allowed_terms_inner import ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner +globals()['ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner'] = ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner + +def lazy_import(): + pass + +class ChannelPropertiesCardsInstallmentConfiguration(ModelNormal): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + + Attributes: + allowed_values (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + with a capitalized key describing the allowed value and an allowed + value. These dicts store the allowed enum values. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + discriminator_value_class_map (dict): A dict to go from the discriminator + variable value to the discriminator class name. + validations (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + that stores validations for max_length, min_length, max_items, + min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum, + inclusive_minimum, and regex. + additional_properties_type (tuple): A tuple of classes accepted + as additional properties values. + """ + + allowed_values = { + } + + validations = { + } + + @cached_property + def additional_properties_type(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + """ + lazy_import() + return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 + + _nullable = False + + @cached_property + def openapi_types(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + + Returns + openapi_types (dict): The key is attribute name + and the value is attribute type. + """ + lazy_import() + return { + 'allow_full_payment': (bool, none_type), # noqa: E501 + 'allowed_terms': ([ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner], none_type), # noqa: E501 + } + + @cached_property + def discriminator(): + return None + + + attribute_map = { + 'allow_full_payment': 'allow_full_payment', # noqa: E501 + 'allowed_terms': 'allowed_terms', # noqa: E501 + } + + read_only_vars = { + } + + _composed_schemas = {} + + @classmethod + @convert_js_args_to_python_args + def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 + """ChannelPropertiesCardsInstallmentConfiguration - a model defined in OpenAPI + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + allOf includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + allow_full_payment (bool): Indicate whether full payment (without installment) is allowed. [optional] # noqa: E501 + allowed_terms ([ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner]): An object to set what kind (from specific bank / specific tenor) of cards installments will be available on a specific invoice. [optional] # noqa: E501 + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', True) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + self = super(OpenApiModel, cls).__new__(cls) + + if args: + for arg in args: + if isinstance(arg, dict): + kwargs.update(arg) + elif isinstance(arg, str): + kwargs.update({"value": arg}) + else: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + return self + + required_properties = set([ + '_data_store', + '_check_type', + '_spec_property_naming', + '_path_to_item', + '_configuration', + '_visited_composed_classes', + ]) + + @convert_js_args_to_python_args + def __init__(self, + allow_full_payment: bool | None = None, + allowed_terms: list | None = None, + *args, **kwargs + ): # noqa: E501 + """ChannelPropertiesCardsInstallmentConfiguration - a model defined in OpenAPI + + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + allOf includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + allow_full_payment (bool): Indicate whether full payment (without installment) is allowed. [optional] # noqa: E501 + allowed_terms ([ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner]): An object to set what kind (from specific bank / specific tenor) of cards installments will be available on a specific invoice. [optional] # noqa: E501 + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + if args: + for arg in args: + if isinstance(arg, dict): + kwargs.update(arg) + elif isinstance(arg, str): + kwargs.update({"value": arg}) + else: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + if allow_full_payment is not None: + self.allow_full_payment = allow_full_payment + if allowed_terms is not None: + self.allowed_terms = allowed_terms + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + if var_name in self.read_only_vars: + raise ApiAttributeError(f"`{var_name}` is a read-only attribute. Use `from_openapi_data` to instantiate " + f"class with read only attributes.") diff --git a/xendit/invoice/model/channel_properties_cards_installment_configuration_allowed_terms_inner.py b/xendit/invoice/model/channel_properties_cards_installment_configuration_allowed_terms_inner.py new file mode 100644 index 0000000..92ab64c --- /dev/null +++ b/xendit/invoice/model/channel_properties_cards_installment_configuration_allowed_terms_inner.py @@ -0,0 +1,278 @@ +""" + The version of the XENDIT API: 1.8.7 +""" + + +import re # noqa: F401 +import sys # noqa: F401 +from typing import List # noqa: F401 + +from xendit.model_utils import ( # noqa: F401 + ApiTypeError, + ModelComposed, + ModelNormal, + ModelSimple, + cached_property, + change_keys_js_to_python, + convert_js_args_to_python_args, + date, + datetime, + file_type, + none_type, + validate_get_composed_info, + OpenApiModel +) +from xendit.exceptions import ApiAttributeError + + +def lazy_import(): + pass + +class ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner(ModelNormal): + """NOTE: This class is auto generated by OpenAPI Generator. + Ref: https://openapi-generator.tech + + Do not edit the class manually. + + Attributes: + allowed_values (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + with a capitalized key describing the allowed value and an allowed + value. These dicts store the allowed enum values. + attribute_map (dict): The key is attribute name + and the value is json key in definition. + discriminator_value_class_map (dict): A dict to go from the discriminator + variable value to the discriminator class name. + validations (dict): The key is the tuple path to the attribute + and the for var_name this is (var_name,). The value is a dict + that stores validations for max_length, min_length, max_items, + min_items, exclusive_maximum, inclusive_maximum, exclusive_minimum, + inclusive_minimum, and regex. + additional_properties_type (tuple): A tuple of classes accepted + as additional properties values. + """ + + allowed_values = { + } + + validations = { + } + + @cached_property + def additional_properties_type(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + """ + return (bool, date, datetime, dict, float, int, list, str, none_type,) # noqa: E501 + + _nullable = False + + @cached_property + def openapi_types(): + """ + This must be a method because a model may have properties that are + of type self, this must run after the class is loaded + + Returns + openapi_types (dict): The key is attribute name + and the value is attribute type. + """ + return { + 'issuer': (str, none_type), # noqa: E501 + 'allowed_terms': ([float], none_type), # noqa: E501 + } + + @cached_property + def discriminator(): + return None + + + attribute_map = { + 'issuer': 'issuer', # noqa: E501 + 'allowed_terms': 'allowed_terms', # noqa: E501 + } + + read_only_vars = { + } + + _composed_schemas = {} + + @classmethod + @convert_js_args_to_python_args + def _from_openapi_data(cls, *args, **kwargs): # noqa: E501 + """ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner - a model defined in OpenAPI + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + allOf includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + issuer (str): The bank code of the installment provider / issuer. [optional] # noqa: E501 + allowed_terms ([float]): An array containing list of installment tenor available to choose. [optional] # noqa: E501 + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', True) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + self = super(OpenApiModel, cls).__new__(cls) + + if args: + for arg in args: + if isinstance(arg, dict): + kwargs.update(arg) + elif isinstance(arg, str): + kwargs.update({"value": arg}) + else: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + return self + + required_properties = set([ + '_data_store', + '_check_type', + '_spec_property_naming', + '_path_to_item', + '_configuration', + '_visited_composed_classes', + ]) + + @convert_js_args_to_python_args + def __init__(self, + issuer: str | None = None, + allowed_terms: list | None = None, + *args, **kwargs + ): # noqa: E501 + """ChannelPropertiesCardsInstallmentConfigurationAllowedTermsInner - a model defined in OpenAPI + + + Keyword Args: + _check_type (bool): if True, values for parameters in openapi_types + will be type checked and a TypeError will be + raised if the wrong type is input. + Defaults to True + _path_to_item (tuple/list): This is a list of keys or values to + drill down to the model in received_data + when deserializing a response + _spec_property_naming (bool): True if the variable names in the input data + are serialized names, as specified in the OpenAPI document. + False if the variable names in the input data + are pythonic names, e.g. snake case (default) + _configuration (Configuration): the instance to use when + deserializing a file_type parameter. + If passed, type conversion is attempted + If omitted no type conversion is done. + _visited_composed_classes (tuple): This stores a tuple of + classes that we have traveled through so that + if we see that class again we will not use its + discriminator again. + When traveling through a discriminator, the + composed schema that is + is traveled through is added to this set. + For example if Animal has a discriminator + petType and we pass in "Dog", and the class Dog + allOf includes Animal, we move through Animal + once using the discriminator, and pick Dog. + Then in Dog, we will make an instance of the + Animal class but this time we won't travel + through its discriminator because we passed in + _visited_composed_classes = (Animal,) + issuer (str): The bank code of the installment provider / issuer. [optional] # noqa: E501 + allowed_terms ([float]): An array containing list of installment tenor available to choose. [optional] # noqa: E501 + """ + + _check_type = kwargs.pop('_check_type', True) + _spec_property_naming = kwargs.pop('_spec_property_naming', False) + _path_to_item = kwargs.pop('_path_to_item', ()) + _configuration = kwargs.pop('_configuration', None) + _visited_composed_classes = kwargs.pop('_visited_composed_classes', ()) + + if args: + for arg in args: + if isinstance(arg, dict): + kwargs.update(arg) + elif isinstance(arg, str): + kwargs.update({"value": arg}) + else: + raise ApiTypeError( + "Invalid positional arguments=%s passed to %s. Remove those invalid positional arguments." % ( + args, + self.__class__.__name__, + ), + path_to_item=_path_to_item, + valid_classes=(self.__class__,), + ) + + self._data_store = {} + self._check_type = _check_type + self._spec_property_naming = _spec_property_naming + self._path_to_item = _path_to_item + self._configuration = _configuration + self._visited_composed_classes = _visited_composed_classes + (self.__class__,) + + if issuer is not None: + self.issuer = issuer + if allowed_terms is not None: + self.allowed_terms = allowed_terms + for var_name, var_value in kwargs.items(): + if var_name not in self.attribute_map and \ + self._configuration is not None and \ + self._configuration.discard_unknown_keys and \ + self.additional_properties_type is None: + # discard variable. + continue + setattr(self, var_name, var_value) + if var_name in self.read_only_vars: + raise ApiAttributeError(f"`{var_name}` is a read-only attribute. Use `from_openapi_data` to instantiate " + f"class with read only attributes.") diff --git a/xendit/invoice/model/create_invoice_request.py b/xendit/invoice/model/create_invoice_request.py index 0932208..a8e688a 100644 --- a/xendit/invoice/model/create_invoice_request.py +++ b/xendit/invoice/model/create_invoice_request.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ @@ -66,6 +66,9 @@ class CreateInvoiceRequest(ModelNormal): } validations = { + ('metadata',): { + 'max_properties': 50, + }, } @cached_property @@ -107,11 +110,12 @@ def openapi_types(): 'should_authenticate_credit_card': (bool, none_type), # noqa: E501 'currency': (str, none_type), # noqa: E501 'reminder_time': (float, none_type), # noqa: E501 - 'local': (str, none_type), # noqa: E501 + 'locale': (str, none_type), # noqa: E501 'reminder_time_unit': (str, none_type), # noqa: E501 'items': ([InvoiceItem], none_type), # noqa: E501 'fees': ([InvoiceFee], none_type), # noqa: E501 'channel_properties': (ChannelProperties, none_type), # noqa: E501 + 'metadata': ({str: (bool, date, datetime, dict, float, int, list, str, none_type)}, none_type), # noqa: E501 } @cached_property @@ -136,11 +140,12 @@ def discriminator(): 'should_authenticate_credit_card': 'should_authenticate_credit_card', # noqa: E501 'currency': 'currency', # noqa: E501 'reminder_time': 'reminder_time', # noqa: E501 - 'local': 'local', # noqa: E501 + 'locale': 'locale', # noqa: E501 'reminder_time_unit': 'reminder_time_unit', # noqa: E501 'items': 'items', # noqa: E501 'fees': 'fees', # noqa: E501 'channel_properties': 'channel_properties', # noqa: E501 + 'metadata': 'metadata', # noqa: E501 } read_only_vars = { @@ -202,11 +207,12 @@ def _from_openapi_data(cls, external_id, amount, *args, **kwargs): # noqa: E501 should_authenticate_credit_card (bool): Indicates whether credit card authentication is required.. [optional] # noqa: E501 currency (str): The currency of the invoice.. [optional] # noqa: E501 reminder_time (float): The reminder time.. [optional] # noqa: E501 - local (str): The local.. [optional] # noqa: E501 + locale (str): The default language to display.. [optional] # noqa: E501 reminder_time_unit (str): The unit of the reminder time.. [optional] # noqa: E501 items ([InvoiceItem]): An array of items included in the invoice.. [optional] # noqa: E501 fees ([InvoiceFee]): An array of fees associated with the invoice.. [optional] # noqa: E501 channel_properties (ChannelProperties): [optional] # noqa: E501 + metadata ({str: (bool, date, datetime, dict, float, int, list, str, none_type)}): 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.. [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) @@ -279,11 +285,12 @@ def __init__(self, should_authenticate_credit_card: bool | None = None, currency: str | None = None, reminder_time: float | None = None, - local: str | None = None, + locale: str | None = None, reminder_time_unit: str | None = None, items: list | None = None, fees: list | None = None, channel_properties: ChannelProperties | None = None, + metadata: dict | None = None, *args, **kwargs ): # noqa: E501 """CreateInvoiceRequest - a model defined in OpenAPI @@ -338,11 +345,12 @@ def __init__(self, should_authenticate_credit_card (bool): Indicates whether credit card authentication is required.. [optional] # noqa: E501 currency (str): The currency of the invoice.. [optional] # noqa: E501 reminder_time (float): The reminder time.. [optional] # noqa: E501 - local (str): The local.. [optional] # noqa: E501 + locale (str): The default language to display.. [optional] # noqa: E501 reminder_time_unit (str): The unit of the reminder time.. [optional] # noqa: E501 items ([InvoiceItem]): An array of items included in the invoice.. [optional] # noqa: E501 fees ([InvoiceFee]): An array of fees associated with the invoice.. [optional] # noqa: E501 channel_properties (ChannelProperties): [optional] # noqa: E501 + metadata ({str: (bool, date, datetime, dict, float, int, list, str, none_type)}): 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.. [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) @@ -404,8 +412,8 @@ def __init__(self, self.currency = currency if reminder_time is not None: self.reminder_time = reminder_time - if local is not None: - self.local = local + if locale is not None: + self.locale = locale if reminder_time_unit is not None: self.reminder_time_unit = reminder_time_unit if items is not None: @@ -414,6 +422,8 @@ def __init__(self, self.fees = fees if channel_properties is not None: self.channel_properties = channel_properties + if metadata is not None: + self.metadata = metadata for var_name, var_value in kwargs.items(): if var_name not in self.attribute_map and \ self._configuration is not None and \ diff --git a/xendit/invoice/model/customer_object.py b/xendit/invoice/model/customer_object.py index 15c2218..855e0b4 100644 --- a/xendit/invoice/model/customer_object.py +++ b/xendit/invoice/model/customer_object.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/direct_debit.py b/xendit/invoice/model/direct_debit.py index 8331284..292f697 100644 --- a/xendit/invoice/model/direct_debit.py +++ b/xendit/invoice/model/direct_debit.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/direct_debit_type.py b/xendit/invoice/model/direct_debit_type.py index 110952d..3d2c9cf 100644 --- a/xendit/invoice/model/direct_debit_type.py +++ b/xendit/invoice/model/direct_debit_type.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/ewallet.py b/xendit/invoice/model/ewallet.py index 0b82a41..e292e94 100644 --- a/xendit/invoice/model/ewallet.py +++ b/xendit/invoice/model/ewallet.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/ewallet_type.py b/xendit/invoice/model/ewallet_type.py index 84f4dbb..e4401cd 100644 --- a/xendit/invoice/model/ewallet_type.py +++ b/xendit/invoice/model/ewallet_type.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/forbidden_error.py b/xendit/invoice/model/forbidden_error.py index 6c219e5..efddfdf 100644 --- a/xendit/invoice/model/forbidden_error.py +++ b/xendit/invoice/model/forbidden_error.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/invoice.py b/xendit/invoice/model/invoice.py index 37c3946..f57e318 100644 --- a/xendit/invoice/model/invoice.py +++ b/xendit/invoice/model/invoice.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ @@ -143,6 +143,7 @@ def openapi_types(): 'customer_notification_preference': (NotificationPreference, none_type), # noqa: E501 'fees': ([InvoiceFee], none_type), # noqa: E501 'channel_properties': (ChannelProperties, none_type), # noqa: E501 + 'metadata': ({str: (bool, date, datetime, dict, float, int, list, str, none_type)}, none_type), # noqa: E501 } @cached_property @@ -185,6 +186,7 @@ def discriminator(): 'customer_notification_preference': 'customer_notification_preference', # noqa: E501 'fees': 'fees', # noqa: E501 'channel_properties': 'channel_properties', # noqa: E501 + 'metadata': 'metadata', # noqa: E501 } read_only_vars = { @@ -264,6 +266,7 @@ def _from_openapi_data(cls, external_id, user_id, status, merchant_name, merchan customer_notification_preference (NotificationPreference): [optional] # noqa: E501 fees ([InvoiceFee]): An array of fees associated with the invoice.. [optional] # noqa: E501 channel_properties (ChannelProperties): [optional] # noqa: E501 + metadata ({str: (bool, date, datetime, dict, float, int, list, str, none_type)}): 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.. [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) @@ -369,6 +372,7 @@ def __init__(self, customer_notification_preference: NotificationPreference | None = None, fees: list | None = None, channel_properties: ChannelProperties | None = None, + metadata: dict | None = None, *args, **kwargs ): # noqa: E501 """Invoice - a model defined in OpenAPI @@ -441,6 +445,7 @@ def __init__(self, customer_notification_preference (NotificationPreference): [optional] # noqa: E501 fees ([InvoiceFee]): An array of fees associated with the invoice.. [optional] # noqa: E501 channel_properties (ChannelProperties): [optional] # noqa: E501 + metadata ({str: (bool, date, datetime, dict, float, int, list, str, none_type)}): 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.. [optional] # noqa: E501 """ _check_type = kwargs.pop('_check_type', True) @@ -523,6 +528,8 @@ def __init__(self, self.fees = fees if channel_properties is not None: self.channel_properties = channel_properties + if metadata is not None: + self.metadata = metadata for var_name, var_value in kwargs.items(): if var_name not in self.attribute_map and \ self._configuration is not None and \ diff --git a/xendit/invoice/model/invoice_callback.py b/xendit/invoice/model/invoice_callback.py index e7a532f..9e0af25 100644 --- a/xendit/invoice/model/invoice_callback.py +++ b/xendit/invoice/model/invoice_callback.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/invoice_callback_item.py b/xendit/invoice/model/invoice_callback_item.py index 19d04e0..841e691 100644 --- a/xendit/invoice/model/invoice_callback_item.py +++ b/xendit/invoice/model/invoice_callback_item.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/invoice_client_type.py b/xendit/invoice/model/invoice_client_type.py index 86b9ef1..8ff657d 100644 --- a/xendit/invoice/model/invoice_client_type.py +++ b/xendit/invoice/model/invoice_client_type.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/invoice_currency.py b/xendit/invoice/model/invoice_currency.py index 6370568..1477aa3 100644 --- a/xendit/invoice/model/invoice_currency.py +++ b/xendit/invoice/model/invoice_currency.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ @@ -55,6 +55,7 @@ class InvoiceCurrency(ModelSimple): 'THB': "THB", 'VND': "VND", 'PHP': "PHP", + 'MYR': "MYR", 'XENDIT_ENUM_DEFAULT_FALLBACK': 'UNKNOWN_ENUM_VALUE', }, } @@ -107,10 +108,10 @@ def __init__(self, *args, **kwargs): Note that value can be passed either in args or in kwargs, but not in both. Args: - args[0] (str): Representing the currency used for an invoice.., must be one of ["IDR", "USD", "THB", "VND", "PHP", ] # noqa: E501 + args[0] (str): Representing the currency used for an invoice.., must be one of ["IDR", "USD", "THB", "VND", "PHP", "MYR", ] # noqa: E501 Keyword Args: - value (str): Representing the currency used for an invoice.., must be one of ["IDR", "USD", "THB", "VND", "PHP", ] # noqa: E501 + value (str): Representing the currency used for an invoice.., must be one of ["IDR", "USD", "THB", "VND", "PHP", "MYR", ] # noqa: E501 _check_type (bool): if True, values for parameters in openapi_types will be type checked and a TypeError will be raised if the wrong type is input. @@ -203,10 +204,10 @@ def _from_openapi_data(cls, *args, **kwargs): Note that value can be passed either in args or in kwargs, but not in both. Args: - args[0] (str): Representing the currency used for an invoice.., must be one of ["IDR", "USD", "THB", "VND", "PHP", ] # noqa: E501 + args[0] (str): Representing the currency used for an invoice.., must be one of ["IDR", "USD", "THB", "VND", "PHP", "MYR", ] # noqa: E501 Keyword Args: - value (str): Representing the currency used for an invoice.., must be one of ["IDR", "USD", "THB", "VND", "PHP", ] # noqa: E501 + value (str): Representing the currency used for an invoice.., must be one of ["IDR", "USD", "THB", "VND", "PHP", "MYR", ] # noqa: E501 _check_type (bool): if True, values for parameters in openapi_types will be type checked and a TypeError will be raised if the wrong type is input. diff --git a/xendit/invoice/model/invoice_error404_response_definition.py b/xendit/invoice/model/invoice_error404_response_definition.py index 21003ae..268ffdc 100644 --- a/xendit/invoice/model/invoice_error404_response_definition.py +++ b/xendit/invoice/model/invoice_error404_response_definition.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/invoice_fee.py b/xendit/invoice/model/invoice_fee.py index c4384f4..b8b53b8 100644 --- a/xendit/invoice/model/invoice_fee.py +++ b/xendit/invoice/model/invoice_fee.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/invoice_item.py b/xendit/invoice/model/invoice_item.py index e4359cf..c3cf461 100644 --- a/xendit/invoice/model/invoice_item.py +++ b/xendit/invoice/model/invoice_item.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/invoice_not_found_error.py b/xendit/invoice/model/invoice_not_found_error.py index 60d7cac..adbeae1 100644 --- a/xendit/invoice/model/invoice_not_found_error.py +++ b/xendit/invoice/model/invoice_not_found_error.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/invoice_payment_method.py b/xendit/invoice/model/invoice_payment_method.py index 94376ca..ba98927 100644 --- a/xendit/invoice/model/invoice_payment_method.py +++ b/xendit/invoice/model/invoice_payment_method.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/invoice_status.py b/xendit/invoice/model/invoice_status.py index f67ce5a..e93ea09 100644 --- a/xendit/invoice/model/invoice_status.py +++ b/xendit/invoice/model/invoice_status.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/notification_channel.py b/xendit/invoice/model/notification_channel.py index 7342c40..b1bdd30 100644 --- a/xendit/invoice/model/notification_channel.py +++ b/xendit/invoice/model/notification_channel.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/notification_preference.py b/xendit/invoice/model/notification_preference.py index f4c6fa9..91c9cc3 100644 --- a/xendit/invoice/model/notification_preference.py +++ b/xendit/invoice/model/notification_preference.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/paylater.py b/xendit/invoice/model/paylater.py index 828522d..9dc80f0 100644 --- a/xendit/invoice/model/paylater.py +++ b/xendit/invoice/model/paylater.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/paylater_type.py b/xendit/invoice/model/paylater_type.py index 67c062b..a15970b 100644 --- a/xendit/invoice/model/paylater_type.py +++ b/xendit/invoice/model/paylater_type.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/payment_details.py b/xendit/invoice/model/payment_details.py index 6c02bab..4003865 100644 --- a/xendit/invoice/model/payment_details.py +++ b/xendit/invoice/model/payment_details.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/qr_code.py b/xendit/invoice/model/qr_code.py index 1d44f71..71f9f0b 100644 --- a/xendit/invoice/model/qr_code.py +++ b/xendit/invoice/model/qr_code.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/qr_code_type.py b/xendit/invoice/model/qr_code_type.py index bb75bbf..6b54d15 100644 --- a/xendit/invoice/model/qr_code_type.py +++ b/xendit/invoice/model/qr_code_type.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ @@ -52,6 +52,7 @@ class QrCodeType(ModelSimple): ('value',): { 'QRIS': "QRIS", 'PROMPTPAY': "PROMPTPAY", + 'QRPH': "QRPH", 'XENDIT_ENUM_DEFAULT_FALLBACK': 'UNKNOWN_ENUM_VALUE', }, } @@ -104,10 +105,10 @@ def __init__(self, *args, **kwargs): Note that value can be passed either in args or in kwargs, but not in both. Args: - args[0] (str): Representing the available QR Code channels used for invoice-related transactions.., must be one of ["QRIS", "PROMPTPAY", ] # noqa: E501 + args[0] (str): Representing the available QR Code channels used for invoice-related transactions.., must be one of ["QRIS", "PROMPTPAY", "QRPH", ] # noqa: E501 Keyword Args: - value (str): Representing the available QR Code channels used for invoice-related transactions.., must be one of ["QRIS", "PROMPTPAY", ] # noqa: E501 + value (str): Representing the available QR Code channels used for invoice-related transactions.., must be one of ["QRIS", "PROMPTPAY", "QRPH", ] # noqa: E501 _check_type (bool): if True, values for parameters in openapi_types will be type checked and a TypeError will be raised if the wrong type is input. @@ -200,10 +201,10 @@ def _from_openapi_data(cls, *args, **kwargs): Note that value can be passed either in args or in kwargs, but not in both. Args: - args[0] (str): Representing the available QR Code channels used for invoice-related transactions.., must be one of ["QRIS", "PROMPTPAY", ] # noqa: E501 + args[0] (str): Representing the available QR Code channels used for invoice-related transactions.., must be one of ["QRIS", "PROMPTPAY", "QRPH", ] # noqa: E501 Keyword Args: - value (str): Representing the available QR Code channels used for invoice-related transactions.., must be one of ["QRIS", "PROMPTPAY", ] # noqa: E501 + value (str): Representing the available QR Code channels used for invoice-related transactions.., must be one of ["QRIS", "PROMPTPAY", "QRPH", ] # noqa: E501 _check_type (bool): if True, values for parameters in openapi_types will be type checked and a TypeError will be raised if the wrong type is input. diff --git a/xendit/invoice/model/retail_outlet.py b/xendit/invoice/model/retail_outlet.py index 7b02f79..4b73e0a 100644 --- a/xendit/invoice/model/retail_outlet.py +++ b/xendit/invoice/model/retail_outlet.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/retail_outlet_name.py b/xendit/invoice/model/retail_outlet_name.py index 5eefaca..90d30da 100644 --- a/xendit/invoice/model/retail_outlet_name.py +++ b/xendit/invoice/model/retail_outlet_name.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/server_error.py b/xendit/invoice/model/server_error.py index 224def6..e53b04f 100644 --- a/xendit/invoice/model/server_error.py +++ b/xendit/invoice/model/server_error.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """ diff --git a/xendit/invoice/model/unauthorized_error.py b/xendit/invoice/model/unauthorized_error.py index 710dcc5..ae11313 100644 --- a/xendit/invoice/model/unauthorized_error.py +++ b/xendit/invoice/model/unauthorized_error.py @@ -1,5 +1,5 @@ """ - The version of the XENDIT API: 1.7.6 + The version of the XENDIT API: 1.8.7 """