Commit 9643747b by Murlidhar Fichadia

Initial commit

parents
# ref: https://github.com/github/gitignore/blob/master/Composer.gitignore
composer.phar
/vendor/
# Commit your application's lock file https://getcomposer.org/doc/01-basic-usage.md#commit-your-composer-lock-file-to-version-control
# You may choose to ignore a library lock file http://getcomposer.org/doc/02-libraries.md#lock-file
# composer.lock
# php-cs-fixer cache
.php_cs.cache
.php-cs-fixer.cache
# PHPUnit cache
.phpunit.result.cache
# OpenAPI Generator Ignore
# Generated by openapi-generator https://github.com/openapitools/openapi-generator
# Use this file to prevent files from being overwritten by the generator.
# The patterns follow closely to .gitignore or .dockerignore.
# As an example, the C# client generator defines ApiClient.cs.
# You can make changes and tell OpenAPI Generator to ignore just this file by uncommenting the following line:
#ApiClient.cs
# You can match any string of characters against a directory, file or extension with a single asterisk (*):
#foo/*/qux
# The above matches foo/bar/qux and foo/baz/qux, but not foo/bar/baz/qux
# You can recursively match patterns against a directory, file or extension with a double asterisk (**):
#foo/**/qux
# This matches foo/bar/qux, foo/baz/qux, and foo/bar/baz/qux
# You can also negate patterns with an exclamation (!).
# For example, you can ignore all files in a docs folder with the file extension .md:
#docs/*.md
# Then explicitly reverse the ignore rule for a single file:
#!docs/README.md
.gitignore
.openapi-generator-ignore
.php-cs-fixer.dist.php
.travis.yml
README.md
composer.json
docs/Api/DefaultApi.md
docs/Model/Address.md
docs/Model/AssetUrls.md
docs/Model/Attachment.md
docs/Model/AuthorizedPaymentMethod.md
docs/Model/CreateOrderRequest.md
docs/Model/Customer.md
docs/Model/CustomerRead.md
docs/Model/CustomerReadCreateToken.md
docs/Model/CustomerTokenCreationRequest.md
docs/Model/CustomerTokenCreationResponse.md
docs/Model/ErrorV2.md
docs/Model/MerchantSession.md
docs/Model/MerchantUrls.md
docs/Model/Options.md
docs/Model/Order.md
docs/Model/OrderLine.md
docs/Model/PaymentMethodCategory.md
docs/Model/ProductIdentifiers.md
docs/Model/Session.md
docs/Model/SessionCreate.md
docs/Model/SessionRead.md
docs/Model/Subscription.md
git_push.sh
lib/Api/DefaultApi.php
lib/ApiException.php
lib/Configuration.php
lib/HeaderSelector.php
lib/Model/Address.php
lib/Model/AssetUrls.php
lib/Model/Attachment.php
lib/Model/AuthorizedPaymentMethod.php
lib/Model/CreateOrderRequest.php
lib/Model/Customer.php
lib/Model/CustomerRead.php
lib/Model/CustomerReadCreateToken.php
lib/Model/CustomerTokenCreationRequest.php
lib/Model/CustomerTokenCreationResponse.php
lib/Model/ErrorV2.php
lib/Model/MerchantSession.php
lib/Model/MerchantUrls.php
lib/Model/ModelInterface.php
lib/Model/Options.php
lib/Model/Order.php
lib/Model/OrderLine.php
lib/Model/PaymentMethodCategory.php
lib/Model/ProductIdentifiers.php
lib/Model/Session.php
lib/Model/SessionCreate.php
lib/Model/SessionRead.php
lib/Model/Subscription.php
lib/ObjectSerializer.php
phpunit.xml.dist
test/Api/DefaultApiTest.php
test/Model/AddressTest.php
test/Model/AssetUrlsTest.php
test/Model/AttachmentTest.php
test/Model/AuthorizedPaymentMethodTest.php
test/Model/CreateOrderRequestTest.php
test/Model/CustomerReadCreateTokenTest.php
test/Model/CustomerReadTest.php
test/Model/CustomerTest.php
test/Model/CustomerTokenCreationRequestTest.php
test/Model/CustomerTokenCreationResponseTest.php
test/Model/ErrorV2Test.php
test/Model/MerchantSessionTest.php
test/Model/MerchantUrlsTest.php
test/Model/OptionsTest.php
test/Model/OrderLineTest.php
test/Model/OrderTest.php
test/Model/PaymentMethodCategoryTest.php
test/Model/ProductIdentifiersTest.php
test/Model/SessionCreateTest.php
test/Model/SessionReadTest.php
test/Model/SessionTest.php
test/Model/SubscriptionTest.php
<?php
/**
* @generated
* @link https://github.com/FriendsOfPHP/PHP-CS-Fixer/blob/HEAD/doc/config.rst
*/
$finder = PhpCsFixer\Finder::create()
->in(__DIR__)
->exclude('vendor')
->exclude('test')
->exclude('tests')
;
$config = new PhpCsFixer\Config();
return $config->setRules([
'@PSR12' => true,
'phpdoc_order' => true,
'array_syntax' => [ 'syntax' => 'short' ],
'strict_comparison' => true,
'strict_param' => true,
'no_trailing_whitespace' => false,
'no_trailing_whitespace_in_comment' => false,
'braces' => false,
'single_blank_line_at_eof' => false,
'blank_line_after_namespace' => false,
'no_leading_import_slash' => false,
])
->setFinder($finder)
;
language: php
# Bionic environment has preinstalled PHP from 7.1 to 7.4
# https://docs.travis-ci.com/user/reference/bionic/#php-support
dist: bionic
php:
- 7.4
before_install: "composer install"
script: "vendor/bin/phpunit"
# OpenAPIClient-php
The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement).
**Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details.
Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
## Installation & Usage
### Requirements
PHP 7.4 and later.
Should also work with PHP 8.0.
### Composer
To install the bindings via [Composer](https://getcomposer.org/), add the following to `composer.json`:
```json
{
"repositories": [
{
"type": "vcs",
"url": "https://github.com/GIT_USER_ID/GIT_REPO_ID.git"
}
],
"require": {
"GIT_USER_ID/GIT_REPO_ID": "*@dev"
}
}
```
Then run `composer install`
### Manual Installation
Download the files and include `autoload.php`:
```php
<?php
require_once('/path/to/OpenAPIClient-php/vendor/autoload.php');
```
## Getting Started
Please follow the [installation procedure](#installation--usage) and then run the following:
```php
<?php
require_once(__DIR__ . '/vendor/autoload.php');
$apiInstance = new KlarnaPayments\Client\Api\DefaultApi(
// If you want use custom http client, pass your client which implements `GuzzleHttp\ClientInterface`.
// This is optional, `GuzzleHttp\Client` will be used as default.
new GuzzleHttp\Client()
);
$authorization_token = 'authorization_token_example'; // string
try {
$apiInstance->cancelAuthorization($authorization_token);
} catch (Exception $e) {
echo 'Exception when calling DefaultApi->cancelAuthorization: ', $e->getMessage(), PHP_EOL;
}
```
## API Endpoints
All URIs are relative to *https://api.klarna.com*
Class | Method | HTTP request | Description
------------ | ------------- | ------------- | -------------
*DefaultApi* | [**cancelAuthorization**](docs/Api/DefaultApi.md#cancelauthorization) | **DELETE** /payments/v1/authorizations/{authorizationToken} | Cancel an authorization
*DefaultApi* | [**createCreditSession**](docs/Api/DefaultApi.md#createcreditsession) | **POST** /payments/v1/sessions | Create a session
*DefaultApi* | [**createOrder**](docs/Api/DefaultApi.md#createorder) | **POST** /payments/v1/authorizations/{authorizationToken}/order | Create an order
*DefaultApi* | [**purchaseToken**](docs/Api/DefaultApi.md#purchasetoken) | **POST** /payments/v1/authorizations/{authorizationToken}/customer-token | Generate a customer token
*DefaultApi* | [**readCreditSession**](docs/Api/DefaultApi.md#readcreditsession) | **GET** /payments/v1/sessions/{session_id} | Get details about a session
*DefaultApi* | [**updateCreditSession**](docs/Api/DefaultApi.md#updatecreditsession) | **POST** /payments/v1/sessions/{session_id} | Update a session
## Models
- [Address](docs/Model/Address.md)
- [AssetUrls](docs/Model/AssetUrls.md)
- [Attachment](docs/Model/Attachment.md)
- [AuthorizedPaymentMethod](docs/Model/AuthorizedPaymentMethod.md)
- [CreateOrderRequest](docs/Model/CreateOrderRequest.md)
- [Customer](docs/Model/Customer.md)
- [CustomerRead](docs/Model/CustomerRead.md)
- [CustomerReadCreateToken](docs/Model/CustomerReadCreateToken.md)
- [CustomerTokenCreationRequest](docs/Model/CustomerTokenCreationRequest.md)
- [CustomerTokenCreationResponse](docs/Model/CustomerTokenCreationResponse.md)
- [ErrorV2](docs/Model/ErrorV2.md)
- [MerchantSession](docs/Model/MerchantSession.md)
- [MerchantUrls](docs/Model/MerchantUrls.md)
- [Options](docs/Model/Options.md)
- [Order](docs/Model/Order.md)
- [OrderLine](docs/Model/OrderLine.md)
- [PaymentMethodCategory](docs/Model/PaymentMethodCategory.md)
- [ProductIdentifiers](docs/Model/ProductIdentifiers.md)
- [Session](docs/Model/Session.md)
- [SessionCreate](docs/Model/SessionCreate.md)
- [SessionRead](docs/Model/SessionRead.md)
- [Subscription](docs/Model/Subscription.md)
## Authorization
Endpoints do not require authorization.
## Tests
To run the tests, use:
```bash
composer install
vendor/bin/phpunit
```
## Author
## About this package
This PHP package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
- API version: `1.0.0`
- Generator version: `7.12.0`
- Build package: `org.openapitools.codegen.languages.PhpClientCodegen`
{
"description": "The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).",
"keywords": [
"openapitools",
"openapi-generator",
"openapi",
"php",
"sdk",
"rest",
"api"
],
"homepage": "https://openapi-generator.tech",
"license": "unlicense",
"authors": [
{
"name": "OpenAPI",
"homepage": "https://openapi-generator.tech"
}
],
"require": {
"php": "^7.4 || ^8.0",
"ext-curl": "*",
"ext-json": "*",
"ext-mbstring": "*",
"guzzlehttp/guzzle": "^7.3",
"guzzlehttp/psr7": "^1.7 || ^2.0"
},
"require-dev": {
"phpunit/phpunit": "^8.0 || ^9.0",
"friendsofphp/php-cs-fixer": "^3.5"
},
"autoload": {
"psr-4": { "KlarnaPayments\\Client\\" : "lib/" }
},
"autoload-dev": {
"psr-4": { "KlarnaPayments\\Client\\Test\\" : "test/" }
}
}
# # Address
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**attention** | **string** | ‘Attn.’ (if applicable). Only applicable for B2B customers. | [optional]
**city** | **string** | Customer’s city. | [optional]
**country** | **string** | Customer’s country. This value overrides the purchase country if they are different. Should follow the standard of ISO 3166 alpha-2. E.g. GB, US, DE, SE. | [optional]
**email** | **string** | Customer’s email address. | [optional]
**family_name** | **string** | Customers family name in UTF-8 encoding. Cannot be only numbers, must be more than 1 character. Allowed special characters: -&#39;’. More information can be found [in this link](https://docs.klarna.com/klarna-payments/in-depth-knowledge/customer-data-requirements/#details-needed-per-market) | [optional]
**given_name** | **string** | Customers given name in UTF-8 encoding. Cannot be only numbers, must be more than 1 character. Allowed special characters: -&#39;’. More information can be found [in this link](https://docs.klarna.com/klarna-payments/in-depth-knowledge/customer-data-requirements/#details-needed-per-market) | [optional]
**organization_name** | **string** | Organization name (if applicable). Only applicable for B2B customers. | [optional]
**phone** | **string** | Phone number. Preferably a mobile phone number. | [optional]
**postal_code** | **string** | Customer’s postal code. Validation according to [Universal Postal Union addressing system](https://www.upu.int/en/activities/addressing/postal-addressing-systems-in-member-countries.html). E.g. 12345, W1G OPW. | [optional]
**region** | **string** | Customer’s region or state - Mandatory for US and AU market. Validations according to ISO 3166-2 format, e.g. US-OH, AU-ACT, etc. | [optional]
**street_address** | **string** | Customer’s street address. Validation according to [Universal Postal Union addressing system](https://www.upu.int/en/activities/addressing/postal-addressing-systems-in-member-countries.html). Regional formatting is required, as follows: UK/US/FR: 33 Cavendish Square Rest of EU: De Ruijterkade 7 | [optional]
**street_address2** | **string** | Customer’s street address. Second Line. | [optional]
**title** | **string** | Customer’s Title. Allowed values per country: UK - \&quot;Mr\&quot;, \&quot;Ms\&quot; DE - \&quot;Herr\&quot;, \&quot;Frau\&quot; AT: \&quot;Herr, \&quot;Frau\&quot; CH: de-CH: \&quot;Herr, \&quot;Frau\&quot; it-CH: \&quot;Sig.\&quot;, \&quot;Sig.ra\&quot; fr-CH: \&quot;M\&quot;, \&quot;Mme\&quot; BE: \&quot;Dhr.\&quot;, \&quot;Mevr.\&quot; NL: \&quot;Dhr.\&quot;, \&quot;Mevr.\&quot; | [optional]
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # AssetUrls
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**descriptive** | **string** | URL of the descriptive asset. Using this dynamic asset will make sure that any copy update of Klarna will automatically be propagated. | [optional]
**standard** | **string** | URL of the standard asset. Using this dynamic asset will make sure that any copy update of Klarna will automatically be propagated. | [optional]
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # Attachment
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**body** | **string** | The content of the extra merchant data should be presented as a string inside this property. The body should be an object containing any of the keys and sub-objects described below serialized to JSON. More information on that object can be found [here](https://docs.klarna.com/api/extra-merchant-data). |
**content_type** | **string** | The content type of the body. It is usually represented as \&quot;application/vnd.klarna.internal.emd-v2+json\&quot; |
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # AuthorizedPaymentMethod
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**number_of_days** | **int** | | [optional]
**number_of_installments** | **int** | | [optional]
**type** | **string** | |
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # CreateOrderRequest
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**authorization_token** | **string** | Authorization token. | [optional] [readonly]
**auto_capture** | **bool** | Allow merchant to trigger auto capturing. | [optional] [default to false]
**billing_address** | [**\KlarnaPayments\Client\Model\Address**](Address.md) | | [optional]
**custom_payment_method_ids** | **string[]** | Promo codes - The array could be used to define which of the configured payment options within a payment category (pay_later, pay_over_time, etc.) should be shown for this purchase. Discuss with the delivery manager to know about the promo codes that will be configured for your account. The feature could also be used to provide promotional offers to specific customers (eg: 0% financing). Please be informed that the usage of this feature can have commercial implications. | [optional]
**customer** | [**\KlarnaPayments\Client\Model\Customer**](Customer.md) | | [optional]
**locale** | **string** | Used to define the language and region of the customer. The locale follows the format of [RFC 1766](https://datatracker.ietf.org/doc/rfc1766/), meaning its value consists of language-country. Read more on **[Supported Locals and Currencies](https://docs.klarna.com/klarna-payments/in-depth-knowledge/puchase-countries-currencies-locales/)**. | [optional]
**merchant_data** | **string** | Pass through field to send any information about the order to be used later for reference while retrieving the order details (max 6000 characters) | [optional]
**merchant_reference1** | **string** | Used for storing merchant&#39;s internal order number or other reference. | [optional]
**merchant_reference2** | **string** | Used for storing merchant&#39;s internal order number or other reference. The value is available in the settlement files. (max 255 characters). | [optional]
**merchant_urls** | [**\KlarnaPayments\Client\Model\MerchantUrls**](MerchantUrls.md) | | [optional]
**order_amount** | **int** | Total amount of the order including tax and any available discounts. The value should be in non-negative minor units. Eg: 25 Euros should be 2500. |
**order_lines** | [**\KlarnaPayments\Client\Model\OrderLine[]**](OrderLine.md) | The array containing list of line items that are part of this order. Maximum of 1000 line items could be processed in a single order. |
**order_tax_amount** | **int** | Total tax amount of the order. The value should be in non-negative minor units. Eg: 25 Euros should be 2500. | [optional]
**payment_method_categories** | [**\KlarnaPayments\Client\Model\PaymentMethodCategory[]**](PaymentMethodCategory.md) | Available payment method categories | [optional] [readonly]
**purchase_country** | **string** | The purchase country of the customer. The billing country always overrides purchase country if the values are different. Formatted according to ISO 3166 alpha-2 standard, e.g. GB, SE, DE, US, etc. |
**purchase_currency** | **string** | The purchase currency of the order. Formatted according to ISO 4217 standard, e.g. USD, EUR, SEK, GBP, etc. |
**shipping_address** | [**\KlarnaPayments\Client\Model\Address**](Address.md) | | [optional]
**status** | **string** | The current status of the session. Possible values: &#39;complete&#39;, &#39;incomplete&#39; where &#39;complete&#39; is set when the order has been placed. | [optional] [readonly]
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # Customer
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**date_of_birth** | **string** | Customer’s date of birth. The format is ‘yyyy-mm-dd’ | [optional]
**gender** | **string** | Customer’s gender - ‘male’ or ‘female’ | [optional]
**last_four_ssn** | **string** | Last four digits of the customer&#39;s social security number. This value is available for US customers. | [optional]
**national_identification_number** | **string** | The customer&#39;s national identification number. This value is available for EU customers utilizing national identification numbers. | [optional]
**organization_entity_type** | **string** | Organization entity type. Only applicable for B2B customers. | [optional]
**organization_registration_id** | **string** | Organization registration id. Only applicable for B2B customers. | [optional]
**title** | **string** | Customer’s Title. Allowed values per country: UK - \&quot;Mr\&quot;, \&quot;Ms\&quot; DE - \&quot;Herr\&quot;, \&quot;Frau\&quot; AT: \&quot;Herr, \&quot;Frau\&quot; CH: de-CH: \&quot;Herr, \&quot;Frau\&quot; it-CH: \&quot;Sig.\&quot;, \&quot;Sig.ra\&quot; fr-CH: \&quot;M\&quot;, \&quot;Mme\&quot; BE: \&quot;Dhr.\&quot;, \&quot;Mevr.\&quot; NL: \&quot;Dhr.\&quot;, \&quot;Mevr.\&quot; | [optional]
**type** | **string** | Type of customer in the session. If nothing is added, a B2C session will be the default. If it is a b2b-session, you should enter organization to trigger a B2B session. | [optional]
**vat_id** | **string** | VAT ID. Only applicable for B2B customers. | [optional]
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # CustomerRead
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**date_of_birth** | **string** | Customer’s date of birth. The format is ‘yyyy-mm-dd’ | [optional]
**gender** | **string** | Customer’s gender - ‘male’ or ‘female’ | [optional]
**organization_entity_type** | **string** | Organization entity type. Only applicable for B2B customers. | [optional]
**organization_registration_id** | **string** | Organization registration id. Only applicable for B2B customers. | [optional]
**title** | **string** | Customer’s Title. Allowed values per country: UK - \&quot;Mr\&quot;, \&quot;Ms\&quot; DE - \&quot;Herr\&quot;, \&quot;Frau\&quot; AT: \&quot;Herr, \&quot;Frau\&quot; CH: de-CH: \&quot;Herr, \&quot;Frau\&quot; it-CH: \&quot;Sig.\&quot;, \&quot;Sig.ra\&quot; fr-CH: \&quot;M\&quot;, \&quot;Mme\&quot; BE: \&quot;Dhr.\&quot;, \&quot;Mevr.\&quot; NL: \&quot;Dhr.\&quot;, \&quot;Mevr.\&quot; | [optional]
**type** | **string** | Type of customer in the session. If nothing is added, a B2C session will be the default. If it is a b2b-session, you should enter organization to trigger a B2B session. | [optional]
**vat_id** | **string** | VAT ID. Only applicable for B2B customers. | [optional]
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # CustomerReadCreateToken
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**date_of_birth** | **string** | Customer’s date of birth. The format is ‘yyyy-mm-dd’ | [optional]
**gender** | **string** | Customer’s gender - ‘male’ or ‘female’ | [optional]
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # CustomerTokenCreationRequest
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**billing_address** | [**\KlarnaPayments\Client\Model\Address**](Address.md) | | [optional]
**customer** | [**\KlarnaPayments\Client\Model\Customer**](Customer.md) | | [optional]
**description** | **string** | Description of the purpose of the token. |
**intended_use** | **string** | Intended use for the token. |
**locale** | **string** | RFC 1766 customer&#39;s locale. |
**purchase_country** | **string** | ISO 3166 alpha-2 purchase country. |
**purchase_currency** | **string** | ISO 4217 purchase currency. |
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # CustomerTokenCreationResponse
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**billing_address** | [**\KlarnaPayments\Client\Model\Address**](Address.md) | | [optional]
**customer** | [**\KlarnaPayments\Client\Model\CustomerReadCreateToken**](CustomerReadCreateToken.md) | | [optional]
**payment_method_reference** | **string** | Used to connect customers with payment method when it is present. | [optional]
**redirect_url** | **string** | URL to redirect the customer to after placing the order. This is a Klarna URL where Klarna will place a cookie in the customer’s browser (if redirected) and redirect the customer back to the confirmation URL provided by the merchant. This is not a mandatory step but a recommended one to improve the returning customer’s experience. | [optional]
**token_id** | **string** | Generated customer token. This token will be used to create a new order for the subscription using the Create a New order using token API. |
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # ErrorV2
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**correlation_id** | **string** | | [optional]
**error_code** | **string** | | [optional]
**error_messages** | **string[]** | | [optional]
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # MerchantSession
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**client_token** | **string** | Client token to be passed to the JS client while initializing the JS SDK in the next step. |
**payment_method_categories** | [**\KlarnaPayments\Client\Model\PaymentMethodCategory[]**](PaymentMethodCategory.md) | Available payment method categories for this particular session | [optional]
**session_id** | **string** | ID of the created session. Please use this ID to share with Klarna for identifying any issues during integration. |
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # MerchantUrls
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**confirmation** | **string** | URL of the merchant confirmation page. The consumer will be redirected back to the confirmation page if the consumer is sent to the redirect URL after placing the order. Insert {session.id} and/or {order.id} as placeholder to connect either of those IDs to the URL(max 2000 characters). | [optional]
**notification** | **string** | URL for notifications on pending orders. Insert {session.id} and/or {order.id} as placeholder to connect either of those IDs to the URL (max 2000 characters). | [optional]
**push** | **string** | URL that will be requested when an order is completed. Should be different than checkout and confirmation URLs. Insert {session.id} and/or {order.id} as placeholder to connect either of those IDs to the URL (max 2000 characters). | [optional]
**authorization** | **string** | URL for receiving the authorization token when payment is completed. Used for Authorization Callback. | [optional]
**app_return_url** | **string** | Mobile application return URL (app scheme with no action deeplink). The customer will be redirected to this URL after third party redirects or redirects to the Klarna Application. It is expected to open the integrating mobile application in it&#39;s last state (no state changes or deeplink navigations). | [optional]
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # Options
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**color_border** | **string** | Color for the border of elements within the iFrame. Value should be a CSS hex color, e.g. \&quot;#FF9900\&quot; | [optional]
**color_border_selected** | **string** | Color for the border of elements within the iFrame when selected by the customer. Value should be a CSS hex color, e.g. \&quot;#FF9900\&quot; | [optional]
**color_details** | **string** | Color for the bullet points within the iFrame. Value should be a CSS hex color, e.g. \&quot;#FF9900\&quot; | [optional]
**color_text** | **string** | Color for the texts within the iFrame. Value should be a CSS hex color, e.g. \&quot;#FF9900\&quot; | [optional]
**radius_border** | **string** | Radius for the border of elements within the iFrame. | [optional]
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # Order
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**authorized_payment_method** | [**\KlarnaPayments\Client\Model\AuthorizedPaymentMethod**](AuthorizedPaymentMethod.md) | | [optional]
**fraud_status** | **string** | Fraud status for the order. Either ACCEPTED or PENDING. If ACCEPTED, the order could be captured. If PENDING, please wait till you receive the notification from Klarna in the notification URL that the order has been approved. You can find additional information [here](https://docs.klarna.com/payments/after-payments/order-management/more-actions/pending-orders/). | [optional]
**order_id** | **string** | Unique order ID of the transaction. This ID will be used for all order management processes. |
**redirect_url** | **string** | URL to redirect the customer to after placing the order. This is a Klarna URL to which the merchant should redirect the customer to. Klarna will place a cookie in the customer’s browser (if redirected) and redirect the customer back to the confirmation URL provided by the merchant. This is not a mandatory step but a recommended one to improve the returning customer’s experience. It is a spontaneous step and does not harm the customer’s experience. | [optional]
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # OrderLine
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**image_url** | **string** | URL to an image that can be later embedded in communications between Klarna and the customer. (max 1024 characters). A minimum of 250x250 px resolution is recommended for the image to look good in the Klarna app, and below 50x50 px won&#39;t even show. We recommend using a good sized image (650x650 px or more), however the file size must not exceed 12MB. | [optional]
**merchant_data** | **string** | Used for storing merchant&#39;s internal order number or other reference. Pass through field. (max 1024 characters) | [optional]
**name** | **string** | Descriptive name of the order line item. |
**product_identifiers** | [**\KlarnaPayments\Client\Model\ProductIdentifiers**](ProductIdentifiers.md) | | [optional]
**product_url** | **string** | URL to the product in the merchant’s webshop that can be later used in communications between Klarna and the customer. (max 1024 characters) | [optional]
**quantity** | **int** | Quantity of the order line item. Must be a non-negative number. |
**quantity_unit** | **string** | Unit used to describe the quantity, e.g. kg, pcs, etc. If defined the value has to be 1-8 characters. | [optional]
**reference** | **string** | Client facing article number, SKU or similar. Max length is 256 characters. | [optional]
**tax_rate** | **int** | Tax rate of the order line. Non-negative value. The percentage value is represented with two implicit decimals. I.e 2000 &#x3D; 20%. | [optional]
**total_amount** | **int** | Total amount of the order line. Must be defined as minor units. Includes tax and discount. Eg: 2000&#x3D;20 euros Value &#x3D; (quantity x unit_price) - total_discount_amount. (max value: 200000000) |
**total_discount_amount** | **int** | Non-negative minor units. Includes tax. Eg: 500&#x3D;5 euros | [optional]
**total_tax_amount** | **int** | Total tax amount of the order line. Must be within ±1 of total_amount - total_amount 10000 / (10000 + tax_rate). Negative when type is discount. | [optional]
**type** | **string** | Type of the order line item. | [optional]
**unit_price** | **int** | Price for a single unit of the order line. Must be defined as minor units and exclude any discount. Typically including taxes, however some countries may include specific requirements, see [Tax handling guidelines](https://docs.klarna.com/payments/web-payments/additional-resources/error-handling-and-validations/tax-handling/) for further details. (max value: 200000000) |
**subscription** | [**\KlarnaPayments\Client\Model\Subscription**](Subscription.md) | | [optional]
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # PaymentMethodCategory
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**asset_urls** | [**\KlarnaPayments\Client\Model\AssetUrls**](AssetUrls.md) | | [optional]
**identifier** | **string** | ID of the payment method category to be used while loading the widget later. The possible values are:&lt;ul&gt;&lt;li&gt;klarna&lt;/li&gt;&lt;li&gt;pay_later&lt;/li&gt;&lt;li&gt;pay_now&lt;/li&gt;&lt;li&gt;pay_over_time&lt;/li&gt;&lt;li&gt;direct_bank_transfer&lt;/li&gt;&lt;li&gt;direct_debit&lt;/li&gt;&lt;/ul&gt; | [optional]
**name** | **string** | Name of the payment method category. These names are dynamic depending on what payment method is in the category. Using this dynamic asset will make sure that any copy update of Klarna will automatically be propagated, or any updates of included payment methods by you. | [optional]
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # ProductIdentifiers
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**brand** | **string** | The product&#39;s brand name as generally recognized by consumers. If no brand is available for a product, do not supply any value. | [optional]
**category_path** | **string** | The product&#39;s category path as used in the merchant&#39;s webshop. Include the full and most detailed category and separate the segments with &#39; &gt; &#39; | [optional]
**global_trade_item_number** | **string** | The product&#39;s Global Trade Item Number (GTIN). Common types of GTIN are EAN, ISBN or UPC. Exclude dashes and spaces, where possible | [optional]
**manufacturer_part_number** | **string** | The product&#39;s Manufacturer Part Number (MPN), which - together with the brand - uniquely identifies a product. Only submit MPNs assigned by a manufacturer and use the most specific MPN possible | [optional]
**color** | **string** | Color to be shown to the end customer (max 64 characters). | [optional]
**size** | **string** | Size to be shown to the end customer (max 64 characters). | [optional]
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # Session
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**acquiring_channel** | **string** | The acquiring channel in which the session takes place. Ecommerce is default unless specified. Any other values should be defined in the agreement. | [optional]
**attachment** | [**\KlarnaPayments\Client\Model\Attachment**](Attachment.md) | | [optional]
**authorization_token** | **string** | Authorization token. | [optional] [readonly]
**billing_address** | [**\KlarnaPayments\Client\Model\Address**](Address.md) | | [optional]
**client_token** | **string** | Token to be passed to the JS client | [optional] [readonly]
**custom_payment_method_ids** | **string[]** | Promo codes - The array could be used to define which of the configured payment options within a payment category (pay_later, pay_over_time, etc.) should be shown for this purchase. Discuss with the delivery manager to know about the promo codes that will be configured for your account. The feature could also be used to provide promotional offers to specific customers (eg: 0% financing). Please be informed that the usage of this feature can have commercial implications. | [optional]
**customer** | [**\KlarnaPayments\Client\Model\Customer**](Customer.md) | | [optional]
**design** | **string** | Design package to use in the session. This can only by used if a custom design has been implemented for Klarna Payments and agreed upon in the agreement. It might have a financial impact. Delivery manager will provide the value for the parameter. | [optional]
**expires_at** | **\DateTime** | Session expiration date | [optional] [readonly]
**locale** | **string** | Used to define the language and region of the customer. The locale follows the format of [RFC 1766](https://datatracker.ietf.org/doc/rfc1766/), meaning its value consists of language-country. Read more on **[Supported Locals and Currencies](https://docs.klarna.com/klarna-payments/in-depth-knowledge/puchase-countries-currencies-locales/)**. | [optional]
**merchant_data** | **string** | Pass through field to send any information about the order to be used later for reference while retrieving the order details (max 6000 characters) | [optional]
**merchant_reference1** | **string** | Used for storing merchant&#39;s internal order number or other reference. | [optional]
**merchant_reference2** | **string** | Used for storing merchant&#39;s internal order number or other reference. The value is available in the settlement files. (max 255 characters). | [optional]
**merchant_urls** | [**\KlarnaPayments\Client\Model\MerchantUrls**](MerchantUrls.md) | | [optional]
**options** | [**\KlarnaPayments\Client\Model\Options**](Options.md) | | [optional]
**order_amount** | **int** | Total amount of the order including tax and any available discounts. The value should be in non-negative minor units. Eg: 25 Euros should be 2500. | [optional]
**order_lines** | [**\KlarnaPayments\Client\Model\OrderLine[]**](OrderLine.md) | The array containing list of line items that are part of this order. Maximum of 1000 line items could be processed in a single order. | [optional]
**order_tax_amount** | **int** | Total tax amount of the order. The value should be in non-negative minor units. Eg: 25 Euros should be 2500. | [optional]
**payment_method_categories** | [**\KlarnaPayments\Client\Model\PaymentMethodCategory[]**](PaymentMethodCategory.md) | Available payment method categories | [optional] [readonly]
**purchase_country** | **string** | The purchase country of the customer. The billing country always overrides purchase country if the values are different. Formatted according to ISO 3166 alpha-2 standard, e.g. GB, SE, DE, US, etc. | [optional]
**purchase_currency** | **string** | The purchase currency of the order. Formatted according to ISO 4217 standard, e.g. USD, EUR, SEK, GBP, etc. | [optional]
**shipping_address** | [**\KlarnaPayments\Client\Model\Address**](Address.md) | | [optional]
**status** | **string** | The current status of the session. Possible values: &#39;complete&#39;, &#39;incomplete&#39; where &#39;complete&#39; is set when the order has been placed. | [optional] [readonly]
**intent** | **string** | Intent for the session. The field is designed to let partners inform Klarna of the purpose of the customer’s session. | [optional]
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # SessionCreate
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**acquiring_channel** | **string** | The acquiring channel in which the session takes place. Ecommerce is default unless specified. Any other values should be defined in the agreement. | [optional]
**attachment** | [**\KlarnaPayments\Client\Model\Attachment**](Attachment.md) | | [optional]
**authorization_token** | **string** | Authorization token. | [optional] [readonly]
**billing_address** | [**\KlarnaPayments\Client\Model\Address**](Address.md) | | [optional]
**client_token** | **string** | Token to be passed to the JS client | [optional] [readonly]
**custom_payment_method_ids** | **string[]** | Promo codes - The array could be used to define which of the configured payment options within a payment category (pay_later, pay_over_time, etc.) should be shown for this purchase. Discuss with the delivery manager to know about the promo codes that will be configured for your account. The feature could also be used to provide promotional offers to specific customers (eg: 0% financing). Please be informed that the usage of this feature can have commercial implications. | [optional]
**customer** | [**\KlarnaPayments\Client\Model\Customer**](Customer.md) | | [optional]
**design** | **string** | Design package to use in the session. This can only by used if a custom design has been implemented for Klarna Payments and agreed upon in the agreement. It might have a financial impact. Delivery manager will provide the value for the parameter. | [optional]
**expires_at** | **\DateTime** | Session expiration date | [optional] [readonly]
**locale** | **string** | Used to define the language and region of the customer. The locale follows the format of [RFC 1766](https://datatracker.ietf.org/doc/rfc1766/), meaning its value consists of language-country. Default value is \&quot;en-US\&quot;. Read more on **[Supported Locals and Currencies](https://docs.klarna.com/klarna-payments/in-depth-knowledge/puchase-countries-currencies-locales/)**. | [optional]
**merchant_data** | **string** | Pass through field to send any information about the order to be used later for reference while retrieving the order details (max 6000 characters) | [optional]
**merchant_reference1** | **string** | Used for storing merchant&#39;s internal order number or other reference. | [optional]
**merchant_reference2** | **string** | Used for storing merchant&#39;s internal order number or other reference. The value is available in the settlement files. (max 255 characters). | [optional]
**merchant_urls** | [**\KlarnaPayments\Client\Model\MerchantUrls**](MerchantUrls.md) | | [optional]
**options** | [**\KlarnaPayments\Client\Model\Options**](Options.md) | | [optional]
**order_amount** | **int** | Total amount of the order including tax and any available discounts. The value should be in non-negative minor units. Eg: 25 Euros should be 2500. |
**order_lines** | [**\KlarnaPayments\Client\Model\OrderLine[]**](OrderLine.md) | The array containing list of line items that are part of this order. Maximum of 1000 line items could be processed in a single order. |
**order_tax_amount** | **int** | Total tax amount of the order. The value should be in non-negative minor units. Eg: 25 Euros should be 2500. | [optional]
**payment_method_categories** | [**\KlarnaPayments\Client\Model\PaymentMethodCategory[]**](PaymentMethodCategory.md) | Available payment method categories | [optional] [readonly]
**purchase_country** | **string** | The purchase country of the customer. The billing country always overrides purchase country if the values are different. Formatted according to ISO 3166 alpha-2 standard, e.g. GB, SE, DE, US, etc. |
**purchase_currency** | **string** | The purchase currency of the order. Formatted according to ISO 4217 standard, e.g. USD, EUR, SEK, GBP, etc. |
**shipping_address** | [**\KlarnaPayments\Client\Model\Address**](Address.md) | | [optional]
**status** | **string** | The current status of the session. Possible values: &#39;complete&#39;, &#39;incomplete&#39; where &#39;complete&#39; is set when the order has been placed. | [optional] [readonly]
**intent** | **string** | Intent for the session. The field is designed to let partners inform Klarna of the purpose of the customer’s session. | [optional]
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # SessionRead
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**acquiring_channel** | **string** | The acquiring channel in which the session takes place. Ecommerce is default unless specified. Any other values should be defined in the agreement. | [optional]
**attachment** | [**\KlarnaPayments\Client\Model\Attachment**](Attachment.md) | | [optional]
**authorization_token** | **string** | Authorization token. | [optional] [readonly]
**billing_address** | [**\KlarnaPayments\Client\Model\Address**](Address.md) | | [optional]
**client_token** | **string** | Token to be passed to the JS client | [optional] [readonly]
**custom_payment_method_ids** | **string[]** | Promo codes - The array could be used to define which of the configured payment options within a payment category (pay_later, pay_over_time, etc.) should be shown for this purchase. Discuss with the delivery manager to know about the promo codes that will be configured for your account. The feature could also be used to provide promotional offers to specific customers (eg: 0% financing). Please be informed that the usage of this feature can have commercial implications. | [optional]
**customer** | [**\KlarnaPayments\Client\Model\CustomerRead**](CustomerRead.md) | | [optional]
**design** | **string** | Design package to use in the session. This can only by used if a custom design has been implemented for Klarna Payments and agreed upon in the agreement. It might have a financial impact. Delivery manager will provide the value for the parameter. | [optional]
**expires_at** | **\DateTime** | Session expiration date | [optional] [readonly]
**locale** | **string** | Used to define the language and region of the customer. The locale follows the format of [RFC 1766](https://datatracker.ietf.org/doc/rfc1766/), meaning its value consists of language-country. Read more on **[Supported Locals and Currencies](https://docs.klarna.com/klarna-payments/in-depth-knowledge/puchase-countries-currencies-locales/)**. | [optional]
**merchant_data** | **string** | Pass through field to send any information about the order to be used later for reference while retrieving the order details (max 6000 characters) | [optional]
**merchant_reference1** | **string** | Used for storing merchant&#39;s internal order number or other reference. | [optional]
**merchant_reference2** | **string** | Used for storing merchant&#39;s internal order number or other reference. The value is available in the settlement files. (max 255 characters). | [optional]
**merchant_urls** | [**\KlarnaPayments\Client\Model\MerchantUrls**](MerchantUrls.md) | | [optional]
**options** | [**\KlarnaPayments\Client\Model\Options**](Options.md) | | [optional]
**order_amount** | **int** | Total amount of the order including tax and any available discounts. The value should be in non-negative minor units. Eg: 25 Euros should be 2500. | [optional]
**order_lines** | [**\KlarnaPayments\Client\Model\OrderLine[]**](OrderLine.md) | The array containing list of line items that are part of this order. Maximum of 1000 line items could be processed in a single order. | [optional]
**order_tax_amount** | **int** | Total tax amount of the order. The value should be in non-negative minor units. Eg: 25 Euros should be 2500. | [optional]
**payment_method_categories** | [**\KlarnaPayments\Client\Model\PaymentMethodCategory[]**](PaymentMethodCategory.md) | Available payment method categories | [optional] [readonly]
**purchase_country** | **string** | The purchase country of the customer. The billing country always overrides purchase country if the values are different. Formatted according to ISO 3166 alpha-2 standard, e.g. GB, SE, DE, US, etc. | [optional]
**purchase_currency** | **string** | The purchase currency of the order. Formatted according to ISO 4217 standard, e.g. USD, EUR, SEK, GBP, etc. | [optional]
**shipping_address** | [**\KlarnaPayments\Client\Model\Address**](Address.md) | | [optional]
**status** | **string** | The current status of the session. Possible values: &#39;complete&#39;, &#39;incomplete&#39; where &#39;complete&#39; is set when the order has been placed. | [optional] [readonly]
**intent** | **string** | Intent for the session. The field is designed to let partners inform Klarna of the purpose of the customer’s session. | [optional]
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
# # Subscription
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**name** | **string** | The name of the subscription product |
**interval** | **string** | The cadence unit for this. |
**interval_count** | **int** | The number of intervals |
[[Back to Model list]](../../README.md#models) [[Back to API list]](../../README.md#endpoints) [[Back to README]](../../README.md)
#!/bin/sh
# ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/
#
# Usage example: /bin/sh ./git_push.sh wing328 openapi-petstore-perl "minor update" "gitlab.com"
git_user_id=$1
git_repo_id=$2
release_note=$3
git_host=$4
if [ "$git_host" = "" ]; then
git_host="github.com"
echo "[INFO] No command line input provided. Set \$git_host to $git_host"
fi
if [ "$git_user_id" = "" ]; then
git_user_id="GIT_USER_ID"
echo "[INFO] No command line input provided. Set \$git_user_id to $git_user_id"
fi
if [ "$git_repo_id" = "" ]; then
git_repo_id="GIT_REPO_ID"
echo "[INFO] No command line input provided. Set \$git_repo_id to $git_repo_id"
fi
if [ "$release_note" = "" ]; then
release_note="Minor update"
echo "[INFO] No command line input provided. Set \$release_note to $release_note"
fi
# Initialize the local directory as a Git repository
git init
# Adds the files in the local repository and stages them for commit.
git add .
# Commits the tracked changes and prepares them to be pushed to a remote repository.
git commit -m "$release_note"
# Sets the new remote
git_remote=$(git remote)
if [ "$git_remote" = "" ]; then # git remote not defined
if [ "$GIT_TOKEN" = "" ]; then
echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git credential in your environment."
git remote add origin https://${git_host}/${git_user_id}/${git_repo_id}.git
else
git remote add origin https://${git_user_id}:"${GIT_TOKEN}"@${git_host}/${git_user_id}/${git_repo_id}.git
fi
fi
git pull origin master
# Pushes (Forces) the changes in the local repository up to the remote repository
echo "Git pushing to https://${git_host}/${git_user_id}/${git_repo_id}.git"
git push origin master 2>&1 | grep -v 'To https'
<?php
/**
* ApiException
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
namespace KlarnaPayments\Client;
use \Exception;
/**
* ApiException Class Doc Comment
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class ApiException extends Exception
{
/**
* The HTTP body of the server response either as Json or string.
*
* @var \stdClass|string|null
*/
protected $responseBody;
/**
* The HTTP header of the server response.
*
* @var string[][]|null
*/
protected $responseHeaders;
/**
* The deserialized response object
*
* @var \stdClass|string|null
*/
protected $responseObject;
/**
* Constructor
*
* @param string $message Error message
* @param int $code HTTP status code
* @param string[][]|null $responseHeaders HTTP response header
* @param \stdClass|string|null $responseBody HTTP decoded body of the server response either as \stdClass or string
*/
public function __construct($message = "", $code = 0, $responseHeaders = [], $responseBody = null)
{
parent::__construct($message, $code);
$this->responseHeaders = $responseHeaders;
$this->responseBody = $responseBody;
}
/**
* Gets the HTTP response header
*
* @return string[][]|null HTTP response header
*/
public function getResponseHeaders()
{
return $this->responseHeaders;
}
/**
* Gets the HTTP body of the server response either as Json or string
*
* @return \stdClass|string|null HTTP body of the server response either as \stdClass or string
*/
public function getResponseBody()
{
return $this->responseBody;
}
/**
* Sets the deserialized response object (during deserialization)
*
* @param mixed $obj Deserialized response object
*
* @return void
*/
public function setResponseObject($obj)
{
$this->responseObject = $obj;
}
/**
* Gets the deserialized response object (during deserialization)
*
* @return mixed the deserialized response object
*/
public function getResponseObject()
{
return $this->responseObject;
}
}
<?php
/**
* HeaderSelector
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
namespace KlarnaPayments\Client;
/**
* HeaderSelector Class Doc Comment
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class HeaderSelector
{
/**
* @param string[] $accept
* @param string $contentType
* @param bool $isMultipart
* @return string[]
*/
public function selectHeaders(array $accept, string $contentType, bool $isMultipart): array
{
$headers = [];
$accept = $this->selectAcceptHeader($accept);
if ($accept !== null) {
$headers['Accept'] = $accept;
}
if (!$isMultipart) {
if($contentType === '') {
$contentType = 'application/json';
}
$headers['Content-Type'] = $contentType;
}
return $headers;
}
/**
* Return the header 'Accept' based on an array of Accept provided.
*
* @param string[] $accept Array of header
*
* @return null|string Accept (e.g. application/json)
*/
private function selectAcceptHeader(array $accept): ?string
{
# filter out empty entries
$accept = array_filter($accept);
if (count($accept) === 0) {
return null;
}
# If there's only one Accept header, just use it
if (count($accept) === 1) {
return reset($accept);
}
# If none of the available Accept headers is of type "json", then just use all them
$headersWithJson = $this->selectJsonMimeList($accept);
if (count($headersWithJson) === 0) {
return implode(',', $accept);
}
# If we got here, then we need add quality values (weight), as described in IETF RFC 9110, Items 12.4.2/12.5.1,
# to give the highest priority to json-like headers - recalculating the existing ones, if needed
return $this->getAcceptHeaderWithAdjustedWeight($accept, $headersWithJson);
}
/**
* Detects whether a string contains a valid JSON mime type
*
* @param string $searchString
* @return bool
*/
public function isJsonMime(string $searchString): bool
{
return preg_match('~^application/(json|[\w!#$&.+-^_]+\+json)\s*(;|$)~', $searchString) === 1;
}
/**
* Select all items from a list containing a JSON mime type
*
* @param array $mimeList
* @return array
*/
private function selectJsonMimeList(array $mimeList): array {
$jsonMimeList = [];
foreach ($mimeList as $mime) {
if($this->isJsonMime($mime)) {
$jsonMimeList[] = $mime;
}
}
return $jsonMimeList;
}
/**
* Create an Accept header string from the given "Accept" headers array, recalculating all weights
*
* @param string[] $accept Array of Accept Headers
* @param string[] $headersWithJson Array of Accept Headers of type "json"
*
* @return string "Accept" Header (e.g. "application/json, text/html; q=0.9")
*/
private function getAcceptHeaderWithAdjustedWeight(array $accept, array $headersWithJson): string
{
$processedHeaders = [
'withApplicationJson' => [],
'withJson' => [],
'withoutJson' => [],
];
foreach ($accept as $header) {
$headerData = $this->getHeaderAndWeight($header);
if (stripos($headerData['header'], 'application/json') === 0) {
$processedHeaders['withApplicationJson'][] = $headerData;
} elseif (in_array($header, $headersWithJson, true)) {
$processedHeaders['withJson'][] = $headerData;
} else {
$processedHeaders['withoutJson'][] = $headerData;
}
}
$acceptHeaders = [];
$currentWeight = 1000;
$hasMoreThan28Headers = count($accept) > 28;
foreach($processedHeaders as $headers) {
if (count($headers) > 0) {
$acceptHeaders[] = $this->adjustWeight($headers, $currentWeight, $hasMoreThan28Headers);
}
}
$acceptHeaders = array_merge(...$acceptHeaders);
return implode(',', $acceptHeaders);
}
/**
* Given an Accept header, returns an associative array splitting the header and its weight
*
* @param string $header "Accept" Header
*
* @return array with the header and its weight
*/
private function getHeaderAndWeight(string $header): array
{
# matches headers with weight, splitting the header and the weight in $outputArray
if (preg_match('/(.*);\s*q=(1(?:\.0+)?|0\.\d+)$/', $header, $outputArray) === 1) {
$headerData = [
'header' => $outputArray[1],
'weight' => (int)($outputArray[2] * 1000),
];
} else {
$headerData = [
'header' => trim($header),
'weight' => 1000,
];
}
return $headerData;
}
/**
* @param array[] $headers
* @param float $currentWeight
* @param bool $hasMoreThan28Headers
* @return string[] array of adjusted "Accept" headers
*/
private function adjustWeight(array $headers, float &$currentWeight, bool $hasMoreThan28Headers): array
{
usort($headers, function (array $a, array $b) {
return $b['weight'] - $a['weight'];
});
$acceptHeaders = [];
foreach ($headers as $index => $header) {
if($index > 0 && $headers[$index - 1]['weight'] > $header['weight'])
{
$currentWeight = $this->getNextWeight($currentWeight, $hasMoreThan28Headers);
}
$weight = $currentWeight;
$acceptHeaders[] = $this->buildAcceptHeader($header['header'], $weight);
}
$currentWeight = $this->getNextWeight($currentWeight, $hasMoreThan28Headers);
return $acceptHeaders;
}
/**
* @param string $header
* @param int $weight
* @return string
*/
private function buildAcceptHeader(string $header, int $weight): string
{
if($weight === 1000) {
return $header;
}
return trim($header, '; ') . ';q=' . rtrim(sprintf('%0.3f', $weight / 1000), '0');
}
/**
* Calculate the next weight, based on the current one.
*
* If there are less than 28 "Accept" headers, the weights will be decreased by 1 on its highest significant digit, using the
* following formula:
*
* next weight = current weight - 10 ^ (floor(log(current weight - 1)))
*
* ( current weight minus ( 10 raised to the power of ( floor of (log to the base 10 of ( current weight minus 1 ) ) ) ) )
*
* Starting from 1000, this generates the following series:
*
* 1000, 900, 800, 700, 600, 500, 400, 300, 200, 100, 90, 80, 70, 60, 50, 40, 30, 20, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1
*
* The resulting quality codes are closer to the average "normal" usage of them (like "q=0.9", "q=0.8" and so on), but it only works
* if there is a maximum of 28 "Accept" headers. If we have more than that (which is extremely unlikely), then we fall back to a 1-by-1
* decrement rule, which will result in quality codes like "q=0.999", "q=0.998" etc.
*
* @param int $currentWeight varying from 1 to 1000 (will be divided by 1000 to build the quality value)
* @param bool $hasMoreThan28Headers
* @return int
*/
public function getNextWeight(int $currentWeight, bool $hasMoreThan28Headers): int
{
if ($currentWeight <= 1) {
return 1;
}
if ($hasMoreThan28Headers) {
return $currentWeight - 1;
}
return $currentWeight - 10 ** floor( log10($currentWeight - 1) );
}
}
<?php
/**
* ModelInterface
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client\Model
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
namespace KlarnaPayments\Client\Model;
/**
* Interface abstracting model access.
*
* @package KlarnaPayments\Client\Model
* @author OpenAPI Generator team
*/
interface ModelInterface
{
/**
* The original name of the model.
*
* @return string
*/
public function getModelName();
/**
* Array of property to type mappings. Used for (de)serialization
*
* @return array
*/
public static function openAPITypes();
/**
* Array of property to format mappings. Used for (de)serialization
*
* @return array
*/
public static function openAPIFormats();
/**
* Array of attributes where the key is the local name, and the value is the original name
*
* @return array
*/
public static function attributeMap();
/**
* Array of attributes to setter functions (for deserialization of responses)
*
* @return array
*/
public static function setters();
/**
* Array of attributes to getter functions (for serialization of requests)
*
* @return array
*/
public static function getters();
/**
* Show all the invalid properties with reasons.
*
* @return array
*/
public function listInvalidProperties();
/**
* Validate all the properties in the model
* return true if all passed
*
* @return bool
*/
public function valid();
/**
* Checks if a property is nullable
*
* @param string $property
* @return bool
*/
public static function isNullable(string $property): bool;
/**
* Checks if a nullable property is set to null.
*
* @param string $property
* @return bool
*/
public function isNullableSetToNull(string $property): bool;
}
<?xml version="1.0" encoding="UTF-8"?>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" bootstrap="./vendor/autoload.php" colors="true" convertErrorsToExceptions="true" convertNoticesToExceptions="true" convertWarningsToExceptions="true" stopOnFailure="false" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.3/phpunit.xsd">
<coverage processUncoveredFiles="true">
<include>
<directory suffix=".php">./lib/Api</directory>
<directory suffix=".php">./lib/Model</directory>
</include>
</coverage>
<testsuites>
<testsuite name="tests">
<directory>./test/Api</directory>
<directory>./test/Model</directory>
</testsuite>
</testsuites>
<php>
<ini name="error_reporting" value="E_ALL"/>
</php>
</phpunit>
<?php
/**
* DefaultApiTest
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the endpoint.
*/
namespace KlarnaPayments\Client\Test\Api;
use \KlarnaPayments\Client\Configuration;
use \KlarnaPayments\Client\ApiException;
use \KlarnaPayments\Client\ObjectSerializer;
use PHPUnit\Framework\TestCase;
/**
* DefaultApiTest Class Doc Comment
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class DefaultApiTest extends TestCase
{
/**
* Setup before running any test cases
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test case for cancelAuthorization
*
* Cancel an authorization.
*
*/
public function testCancelAuthorization()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test case for createCreditSession
*
* Create a session.
*
*/
public function testCreateCreditSession()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test case for createOrder
*
* Create an order.
*
*/
public function testCreateOrder()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test case for purchaseToken
*
* Generate a customer token.
*
*/
public function testPurchaseToken()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test case for readCreditSession
*
* Get details about a session.
*
*/
public function testReadCreditSession()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test case for updateCreditSession
*
* Update a session.
*
*/
public function testUpdateCreditSession()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* AddressTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* AddressTest Class Doc Comment
*
* @category Class
* @description Address
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class AddressTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "Address"
*/
public function testAddress()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "attention"
*/
public function testPropertyAttention()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "city"
*/
public function testPropertyCity()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "country"
*/
public function testPropertyCountry()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "email"
*/
public function testPropertyEmail()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "family_name"
*/
public function testPropertyFamilyName()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "given_name"
*/
public function testPropertyGivenName()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "organization_name"
*/
public function testPropertyOrganizationName()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "phone"
*/
public function testPropertyPhone()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "postal_code"
*/
public function testPropertyPostalCode()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "region"
*/
public function testPropertyRegion()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "street_address"
*/
public function testPropertyStreetAddress()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "street_address2"
*/
public function testPropertyStreetAddress2()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "title"
*/
public function testPropertyTitle()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* AssetUrlsTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* AssetUrlsTest Class Doc Comment
*
* @category Class
* @description AssetUrls
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class AssetUrlsTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "AssetUrls"
*/
public function testAssetUrls()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "descriptive"
*/
public function testPropertyDescriptive()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "standard"
*/
public function testPropertyStandard()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* AttachmentTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* AttachmentTest Class Doc Comment
*
* @category Class
* @description Attachment
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class AttachmentTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "Attachment"
*/
public function testAttachment()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "body"
*/
public function testPropertyBody()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "content_type"
*/
public function testPropertyContentType()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* AuthorizedPaymentMethodTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* AuthorizedPaymentMethodTest Class Doc Comment
*
* @category Class
* @description AuthorizedPaymentMethod
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class AuthorizedPaymentMethodTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "AuthorizedPaymentMethod"
*/
public function testAuthorizedPaymentMethod()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "number_of_days"
*/
public function testPropertyNumberOfDays()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "number_of_installments"
*/
public function testPropertyNumberOfInstallments()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "type"
*/
public function testPropertyType()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* CreateOrderRequestTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* CreateOrderRequestTest Class Doc Comment
*
* @category Class
* @description CreateOrderRequest
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class CreateOrderRequestTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "CreateOrderRequest"
*/
public function testCreateOrderRequest()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "authorization_token"
*/
public function testPropertyAuthorizationToken()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "auto_capture"
*/
public function testPropertyAutoCapture()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "billing_address"
*/
public function testPropertyBillingAddress()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "custom_payment_method_ids"
*/
public function testPropertyCustomPaymentMethodIds()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "customer"
*/
public function testPropertyCustomer()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "locale"
*/
public function testPropertyLocale()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "merchant_data"
*/
public function testPropertyMerchantData()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "merchant_reference1"
*/
public function testPropertyMerchantReference1()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "merchant_reference2"
*/
public function testPropertyMerchantReference2()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "merchant_urls"
*/
public function testPropertyMerchantUrls()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "order_amount"
*/
public function testPropertyOrderAmount()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "order_lines"
*/
public function testPropertyOrderLines()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "order_tax_amount"
*/
public function testPropertyOrderTaxAmount()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "payment_method_categories"
*/
public function testPropertyPaymentMethodCategories()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "purchase_country"
*/
public function testPropertyPurchaseCountry()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "purchase_currency"
*/
public function testPropertyPurchaseCurrency()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "shipping_address"
*/
public function testPropertyShippingAddress()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "status"
*/
public function testPropertyStatus()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* CustomerReadCreateTokenTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* CustomerReadCreateTokenTest Class Doc Comment
*
* @category Class
* @description CustomerReadCreateToken
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class CustomerReadCreateTokenTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "CustomerReadCreateToken"
*/
public function testCustomerReadCreateToken()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "date_of_birth"
*/
public function testPropertyDateOfBirth()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "gender"
*/
public function testPropertyGender()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* CustomerReadTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* CustomerReadTest Class Doc Comment
*
* @category Class
* @description CustomerRead
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class CustomerReadTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "CustomerRead"
*/
public function testCustomerRead()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "date_of_birth"
*/
public function testPropertyDateOfBirth()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "gender"
*/
public function testPropertyGender()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "organization_entity_type"
*/
public function testPropertyOrganizationEntityType()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "organization_registration_id"
*/
public function testPropertyOrganizationRegistrationId()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "title"
*/
public function testPropertyTitle()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "type"
*/
public function testPropertyType()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "vat_id"
*/
public function testPropertyVatId()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* CustomerTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* CustomerTest Class Doc Comment
*
* @category Class
* @description Customer
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class CustomerTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "Customer"
*/
public function testCustomer()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "date_of_birth"
*/
public function testPropertyDateOfBirth()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "gender"
*/
public function testPropertyGender()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "last_four_ssn"
*/
public function testPropertyLastFourSsn()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "national_identification_number"
*/
public function testPropertyNationalIdentificationNumber()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "organization_entity_type"
*/
public function testPropertyOrganizationEntityType()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "organization_registration_id"
*/
public function testPropertyOrganizationRegistrationId()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "title"
*/
public function testPropertyTitle()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "type"
*/
public function testPropertyType()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "vat_id"
*/
public function testPropertyVatId()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* CustomerTokenCreationRequestTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* CustomerTokenCreationRequestTest Class Doc Comment
*
* @category Class
* @description CustomerTokenCreationRequest
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class CustomerTokenCreationRequestTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "CustomerTokenCreationRequest"
*/
public function testCustomerTokenCreationRequest()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "billing_address"
*/
public function testPropertyBillingAddress()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "customer"
*/
public function testPropertyCustomer()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "description"
*/
public function testPropertyDescription()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "intended_use"
*/
public function testPropertyIntendedUse()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "locale"
*/
public function testPropertyLocale()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "purchase_country"
*/
public function testPropertyPurchaseCountry()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "purchase_currency"
*/
public function testPropertyPurchaseCurrency()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* CustomerTokenCreationResponseTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* CustomerTokenCreationResponseTest Class Doc Comment
*
* @category Class
* @description CustomerTokenCreationResponse
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class CustomerTokenCreationResponseTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "CustomerTokenCreationResponse"
*/
public function testCustomerTokenCreationResponse()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "billing_address"
*/
public function testPropertyBillingAddress()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "customer"
*/
public function testPropertyCustomer()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "payment_method_reference"
*/
public function testPropertyPaymentMethodReference()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "redirect_url"
*/
public function testPropertyRedirectUrl()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "token_id"
*/
public function testPropertyTokenId()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* ErrorV2Test
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* ErrorV2Test Class Doc Comment
*
* @category Class
* @description ErrorV2
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class ErrorV2Test extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "ErrorV2"
*/
public function testErrorV2()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "correlation_id"
*/
public function testPropertyCorrelationId()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "error_code"
*/
public function testPropertyErrorCode()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "error_messages"
*/
public function testPropertyErrorMessages()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* MerchantSessionTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* MerchantSessionTest Class Doc Comment
*
* @category Class
* @description MerchantSession
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class MerchantSessionTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "MerchantSession"
*/
public function testMerchantSession()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "client_token"
*/
public function testPropertyClientToken()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "payment_method_categories"
*/
public function testPropertyPaymentMethodCategories()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "session_id"
*/
public function testPropertySessionId()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* MerchantUrlsTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* MerchantUrlsTest Class Doc Comment
*
* @category Class
* @description MerchantUrls
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class MerchantUrlsTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "MerchantUrls"
*/
public function testMerchantUrls()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "confirmation"
*/
public function testPropertyConfirmation()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "notification"
*/
public function testPropertyNotification()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "push"
*/
public function testPropertyPush()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "authorization"
*/
public function testPropertyAuthorization()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "app_return_url"
*/
public function testPropertyAppReturnUrl()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* OptionsTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* OptionsTest Class Doc Comment
*
* @category Class
* @description Options
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class OptionsTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "Options"
*/
public function testOptions()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "color_border"
*/
public function testPropertyColorBorder()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "color_border_selected"
*/
public function testPropertyColorBorderSelected()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "color_details"
*/
public function testPropertyColorDetails()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "color_text"
*/
public function testPropertyColorText()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "radius_border"
*/
public function testPropertyRadiusBorder()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* OrderLineTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* OrderLineTest Class Doc Comment
*
* @category Class
* @description OrderLine
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class OrderLineTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "OrderLine"
*/
public function testOrderLine()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "image_url"
*/
public function testPropertyImageUrl()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "merchant_data"
*/
public function testPropertyMerchantData()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "name"
*/
public function testPropertyName()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "product_identifiers"
*/
public function testPropertyProductIdentifiers()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "product_url"
*/
public function testPropertyProductUrl()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "quantity"
*/
public function testPropertyQuantity()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "quantity_unit"
*/
public function testPropertyQuantityUnit()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "reference"
*/
public function testPropertyReference()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "tax_rate"
*/
public function testPropertyTaxRate()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "total_amount"
*/
public function testPropertyTotalAmount()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "total_discount_amount"
*/
public function testPropertyTotalDiscountAmount()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "total_tax_amount"
*/
public function testPropertyTotalTaxAmount()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "type"
*/
public function testPropertyType()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "unit_price"
*/
public function testPropertyUnitPrice()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "subscription"
*/
public function testPropertySubscription()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* OrderTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* OrderTest Class Doc Comment
*
* @category Class
* @description Order
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class OrderTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "Order"
*/
public function testOrder()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "authorized_payment_method"
*/
public function testPropertyAuthorizedPaymentMethod()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "fraud_status"
*/
public function testPropertyFraudStatus()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "order_id"
*/
public function testPropertyOrderId()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "redirect_url"
*/
public function testPropertyRedirectUrl()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* PaymentMethodCategoryTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* PaymentMethodCategoryTest Class Doc Comment
*
* @category Class
* @description PaymentMethodCategory
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class PaymentMethodCategoryTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "PaymentMethodCategory"
*/
public function testPaymentMethodCategory()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "asset_urls"
*/
public function testPropertyAssetUrls()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "identifier"
*/
public function testPropertyIdentifier()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "name"
*/
public function testPropertyName()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* ProductIdentifiersTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* ProductIdentifiersTest Class Doc Comment
*
* @category Class
* @description ProductIdentifiers
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class ProductIdentifiersTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "ProductIdentifiers"
*/
public function testProductIdentifiers()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "brand"
*/
public function testPropertyBrand()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "category_path"
*/
public function testPropertyCategoryPath()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "global_trade_item_number"
*/
public function testPropertyGlobalTradeItemNumber()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "manufacturer_part_number"
*/
public function testPropertyManufacturerPartNumber()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "color"
*/
public function testPropertyColor()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "size"
*/
public function testPropertySize()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* SessionCreateTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* SessionCreateTest Class Doc Comment
*
* @category Class
* @description SessionCreate
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class SessionCreateTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "SessionCreate"
*/
public function testSessionCreate()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "acquiring_channel"
*/
public function testPropertyAcquiringChannel()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "attachment"
*/
public function testPropertyAttachment()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "authorization_token"
*/
public function testPropertyAuthorizationToken()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "billing_address"
*/
public function testPropertyBillingAddress()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "client_token"
*/
public function testPropertyClientToken()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "custom_payment_method_ids"
*/
public function testPropertyCustomPaymentMethodIds()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "customer"
*/
public function testPropertyCustomer()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "design"
*/
public function testPropertyDesign()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "expires_at"
*/
public function testPropertyExpiresAt()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "locale"
*/
public function testPropertyLocale()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "merchant_data"
*/
public function testPropertyMerchantData()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "merchant_reference1"
*/
public function testPropertyMerchantReference1()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "merchant_reference2"
*/
public function testPropertyMerchantReference2()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "merchant_urls"
*/
public function testPropertyMerchantUrls()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "options"
*/
public function testPropertyOptions()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "order_amount"
*/
public function testPropertyOrderAmount()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "order_lines"
*/
public function testPropertyOrderLines()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "order_tax_amount"
*/
public function testPropertyOrderTaxAmount()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "payment_method_categories"
*/
public function testPropertyPaymentMethodCategories()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "purchase_country"
*/
public function testPropertyPurchaseCountry()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "purchase_currency"
*/
public function testPropertyPurchaseCurrency()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "shipping_address"
*/
public function testPropertyShippingAddress()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "status"
*/
public function testPropertyStatus()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "intent"
*/
public function testPropertyIntent()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* SessionReadTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* SessionReadTest Class Doc Comment
*
* @category Class
* @description SessionRead
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class SessionReadTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "SessionRead"
*/
public function testSessionRead()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "acquiring_channel"
*/
public function testPropertyAcquiringChannel()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "attachment"
*/
public function testPropertyAttachment()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "authorization_token"
*/
public function testPropertyAuthorizationToken()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "billing_address"
*/
public function testPropertyBillingAddress()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "client_token"
*/
public function testPropertyClientToken()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "custom_payment_method_ids"
*/
public function testPropertyCustomPaymentMethodIds()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "customer"
*/
public function testPropertyCustomer()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "design"
*/
public function testPropertyDesign()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "expires_at"
*/
public function testPropertyExpiresAt()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "locale"
*/
public function testPropertyLocale()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "merchant_data"
*/
public function testPropertyMerchantData()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "merchant_reference1"
*/
public function testPropertyMerchantReference1()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "merchant_reference2"
*/
public function testPropertyMerchantReference2()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "merchant_urls"
*/
public function testPropertyMerchantUrls()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "options"
*/
public function testPropertyOptions()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "order_amount"
*/
public function testPropertyOrderAmount()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "order_lines"
*/
public function testPropertyOrderLines()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "order_tax_amount"
*/
public function testPropertyOrderTaxAmount()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "payment_method_categories"
*/
public function testPropertyPaymentMethodCategories()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "purchase_country"
*/
public function testPropertyPurchaseCountry()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "purchase_currency"
*/
public function testPropertyPurchaseCurrency()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "shipping_address"
*/
public function testPropertyShippingAddress()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "status"
*/
public function testPropertyStatus()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "intent"
*/
public function testPropertyIntent()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* SessionTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* SessionTest Class Doc Comment
*
* @category Class
* @description Session
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class SessionTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "Session"
*/
public function testSession()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "acquiring_channel"
*/
public function testPropertyAcquiringChannel()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "attachment"
*/
public function testPropertyAttachment()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "authorization_token"
*/
public function testPropertyAuthorizationToken()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "billing_address"
*/
public function testPropertyBillingAddress()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "client_token"
*/
public function testPropertyClientToken()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "custom_payment_method_ids"
*/
public function testPropertyCustomPaymentMethodIds()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "customer"
*/
public function testPropertyCustomer()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "design"
*/
public function testPropertyDesign()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "expires_at"
*/
public function testPropertyExpiresAt()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "locale"
*/
public function testPropertyLocale()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "merchant_data"
*/
public function testPropertyMerchantData()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "merchant_reference1"
*/
public function testPropertyMerchantReference1()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "merchant_reference2"
*/
public function testPropertyMerchantReference2()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "merchant_urls"
*/
public function testPropertyMerchantUrls()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "options"
*/
public function testPropertyOptions()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "order_amount"
*/
public function testPropertyOrderAmount()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "order_lines"
*/
public function testPropertyOrderLines()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "order_tax_amount"
*/
public function testPropertyOrderTaxAmount()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "payment_method_categories"
*/
public function testPropertyPaymentMethodCategories()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "purchase_country"
*/
public function testPropertyPurchaseCountry()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "purchase_currency"
*/
public function testPropertyPurchaseCurrency()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "shipping_address"
*/
public function testPropertyShippingAddress()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "status"
*/
public function testPropertyStatus()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "intent"
*/
public function testPropertyIntent()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
<?php
/**
* SubscriptionTest
*
* PHP version 7.4
*
* @category Class
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
/**
* Klarna Payments API V1
*
* The payments API is used to create a session to offer Klarna's payment methods as part of your checkout. As soon as the purchase is completed the order should be read and handled using the [`Order Management API`](https://docs.klarna.com/api/ordermanagement). **Note:** Examples provided in this section includes full payloads, including all supported fields, required and optionals. In order to implement a best in class request we recommend you don't include customer details when initiating a payment session. Refer to [Initiate a payment](https://docs.klarna.com/klarna-payments/integrate-with-klarna-payments/step-1-initiate-a-payment/) section for further details. Read more on [Klarna payments](https://docs.klarna.com/klarna-payments/).
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://openapi-generator.tech
* Generator version: 7.12.0
*/
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Please update the test case below to test the model.
*/
namespace KlarnaPayments\Client\Test\Model;
use PHPUnit\Framework\TestCase;
/**
* SubscriptionTest Class Doc Comment
*
* @category Class
* @description Subscription
* @package KlarnaPayments\Client
* @author OpenAPI Generator team
* @link https://openapi-generator.tech
*/
class SubscriptionTest extends TestCase
{
/**
* Setup before running any test case
*/
public static function setUpBeforeClass(): void
{
}
/**
* Setup before running each test case
*/
public function setUp(): void
{
}
/**
* Clean up after running each test case
*/
public function tearDown(): void
{
}
/**
* Clean up after running all test cases
*/
public static function tearDownAfterClass(): void
{
}
/**
* Test "Subscription"
*/
public function testSubscription()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "name"
*/
public function testPropertyName()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "interval"
*/
public function testPropertyInterval()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
/**
* Test attribute "interval_count"
*/
public function testPropertyIntervalCount()
{
// TODO: implement
self::markTestIncomplete('Not implemented');
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment