Skip to content

Commit

Permalink
Release 1.4.22
Browse files Browse the repository at this point in the history
  • Loading branch information
philippe-kinow committed Dec 3, 2020
1 parent 89591bc commit 9615bb7
Show file tree
Hide file tree
Showing 469 changed files with 2,299 additions and 481 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -277,6 +277,7 @@ Class | Method | HTTP request | Description
*GiftsApi* | [**getGiftInCart**](docs/Api/GiftsApi.md#getgiftincart) | **GET** /carts/{cart_id}/gift |
*GiftsApi* | [**getGiftToken**](docs/Api/GiftsApi.md#getgifttoken) | **GET** /gifts/{gift_id}/token |
*GiftsApi* | [**getGifts**](docs/Api/GiftsApi.md#getgifts) | **GET** /gifts |
*GiftsApi* | [**getGiftsInCart**](docs/Api/GiftsApi.md#getgiftsincart) | **GET** /carts/{cart_id}/gifts |
*GiftsApi* | [**sendGift**](docs/Api/GiftsApi.md#sendgift) | **POST** /gifts/{gift_id}/send |
*GiftsApi* | [**updateGift**](docs/Api/GiftsApi.md#updategift) | **PUT** /gifts/{gift_id} |
*GroupsApi* | [**attachCustomerToGroup**](docs/Api/GroupsApi.md#attachcustomertogroup) | **POST** /groups/{group_id}/customers |
Expand Down Expand Up @@ -478,6 +479,7 @@ Class | Method | HTTP request | Description
- [Cart2](docs/Model/Cart2.md)
- [CartIDList](docs/Model/CartIDList.md)
- [CartPrice](docs/Model/CartPrice.md)
- [CartProduct](docs/Model/CartProduct.md)
- [CartRule](docs/Model/CartRule.md)
- [CartRuleRestrictionGroup](docs/Model/CartRuleRestrictionGroup.md)
- [CartRuleRestrictionGroupItem](docs/Model/CartRuleRestrictionGroupItem.md)
Expand Down
2 changes: 1 addition & 1 deletion autoload.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
*
* Client API for Kinow back-office
*
* OpenAPI spec version: 1.4.21
* OpenAPI spec version: 1.4.22
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*
Expand Down
12 changes: 8 additions & 4 deletions docs/Api/CartsApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Method | HTTP request | Description


## **addProductToCart**
> \Kinow\Client\Model\Cart addProductToCart($cart_id, $product_id, $product_attribute_id, $switch_subscription_id, $is_gift, $ip_address)
> \Kinow\Client\Model\Cart addProductToCart($cart_id, $product_id, $product_attribute_id, $gift_id, $switch_subscription_id, $is_gift, $ip_address)


Expand All @@ -41,12 +41,13 @@ $api_instance = new Kinow\Client\Api\CartsApi();
$cart_id = 789; // int | Cart ID to fetch
$product_id = 789; // int | Product ID to add to cart
$product_attribute_id = 789; // int | ProductAttribute ID, required to add product to cart if product is not a subscription
$gift_id = 789; // int | Gift ID linked to the item in cart
$switch_subscription_id = 789; // int | When customer want to switch subscription, switch_subscription_id is the product access ID that match with the subscription to cancel
$is_gift = false; // bool | Allows bypass of access check (in case the current user already bought the product and it cannot be reordered)
$ip_address = "ip_address_example"; // string | IP address

try {
$result = $api_instance->addProductToCart($cart_id, $product_id, $product_attribute_id, $switch_subscription_id, $is_gift, $ip_address);
$result = $api_instance->addProductToCart($cart_id, $product_id, $product_attribute_id, $gift_id, $switch_subscription_id, $is_gift, $ip_address);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling CartsApi->addProductToCart: ', $e->getMessage(), PHP_EOL;
Expand All @@ -61,6 +62,7 @@ Name | Type | Description | Notes
**cart_id** | **int**| Cart ID to fetch |
**product_id** | **int**| Product ID to add to cart |
**product_attribute_id** | **int**| ProductAttribute ID, required to add product to cart if product is not a subscription | [optional]
**gift_id** | **int**| Gift ID linked to the item in cart | [optional]
**switch_subscription_id** | **int**| When customer want to switch subscription, switch_subscription_id is the product access ID that match with the subscription to cancel | [optional]
**is_gift** | **bool**| Allows bypass of access check (in case the current user already bought the product and it cannot be reordered) | [optional] [default to false]
**ip_address** | **string**| IP address | [optional]
Expand Down Expand Up @@ -253,7 +255,7 @@ No authorization required
- **Accept**: Not defined

## **deleteProductFromCart**
> deleteProductFromCart($cart_id, $product_id, $product_attribute_id)
> deleteProductFromCart($cart_id, $product_id, $product_attribute_id, $gift_id)


Expand All @@ -268,9 +270,10 @@ $api_instance = new Kinow\Client\Api\CartsApi();
$cart_id = 789; // int | Cart ID to fetch
$product_id = 789; // int | Product ID to delete from cart
$product_attribute_id = 789; // int | Product attribute ID, required to add product to cart if product is not a subscription
$gift_id = 789; // int | Gift ID linked to the item in cart

try {
$api_instance->deleteProductFromCart($cart_id, $product_id, $product_attribute_id);
$api_instance->deleteProductFromCart($cart_id, $product_id, $product_attribute_id, $gift_id);
} catch (Exception $e) {
echo 'Exception when calling CartsApi->deleteProductFromCart: ', $e->getMessage(), PHP_EOL;
}
Expand All @@ -284,6 +287,7 @@ Name | Type | Description | Notes
**cart_id** | **int**| Cart ID to fetch |
**product_id** | **int**| Product ID to delete from cart |
**product_attribute_id** | **int**| Product attribute ID, required to add product to cart if product is not a subscription | [optional]
**gift_id** | **int**| Gift ID linked to the item in cart | [optional]

### Return type

Expand Down
44 changes: 44 additions & 0 deletions docs/Api/GiftsApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ Method | HTTP request | Description
[**getGiftInCart**](#getGiftInCart) | **GET** /carts/{cart_id}/gift |
[**getGiftToken**](#getGiftToken) | **GET** /gifts/{gift_id}/token |
[**getGifts**](#getGifts) | **GET** /gifts |
[**getGiftsInCart**](#getGiftsInCart) | **GET** /carts/{cart_id}/gifts |
[**sendGift**](#sendGift) | **POST** /gifts/{gift_id}/send |
[**updateGift**](#updateGift) | **PUT** /gifts/{gift_id} |

Expand Down Expand Up @@ -360,6 +361,49 @@ Name | Type | Description | Notes

No authorization required

### HTTP request headers

- **Content-Type**: Not defined
- **Accept**: Not defined

## **getGiftsInCart**
> \Kinow\Client\Model\Gift[] getGiftsInCart($cart_id)


Get Gifts in cart

### Example
```php
<?php
require_once(__DIR__ . '/vendor/autoload.php');

$api_instance = new Kinow\Client\Api\GiftsApi();
$cart_id = 789; // int | Cart ID to fetch

try {
$result = $api_instance->getGiftsInCart($cart_id);
print_r($result);
} catch (Exception $e) {
echo 'Exception when calling GiftsApi->getGiftsInCart: ', $e->getMessage(), PHP_EOL;
}
?>
```

### Parameters

Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**cart_id** | **int**| Cart ID to fetch |

### Return type

[**\Kinow\Client\Model\Gift[]**](#Gift)

### Authorization

No authorization required

### HTTP request headers

- **Content-Type**: Not defined
Expand Down
2 changes: 1 addition & 1 deletion docs/Model/Cart.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,6 @@ Name | Type | Description | Notes
**total_trial** | **float** | | [optional]
**available_checkout_processes** | **string[]** | | [optional]
**cart_rules** | [**\Kinow\Client\Model\CartRule[]**](#CartRule) | | [optional]
**products** | [**\Kinow\Client\Model\Product[]**](#Product) | | [optional]
**products** | [**\Kinow\Client\Model\CartProduct[]**](#CartProduct) | | [optional]


45 changes: 45 additions & 0 deletions docs/Model/CartProduct.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
## CartProduct

### Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**id_gift** | **int** | | [optional]
**id** | **int** | | [optional]
**reference** | **string** | | [optional]
**date_from** | **string** | | [optional]
**date_to** | **string** | | [optional]
**visible_before_publication** | **bool** | | [optional]
**visible_after_publication** | **bool** | | [optional]
**price** | **float** | | [optional]
**price_mode** | **float** | | [optional]
**position** | **int** | | [optional]
**active** | **bool** | | [optional]
**available_for_order** | **bool** | | [optional]
**date_add** | **string** | | [optional]
**date_upd** | **string** | | [optional]
**id_category_default** | **int** | | [optional]
**images** | [**\Kinow\Client\Model\Image[]**](#Image) | | [optional]
**attributes** | [**\Kinow\Client\Model\ProductAttribute[]**](#ProductAttribute) | | [optional]
**meta_description** | [**\Kinow\Client\Model\I18nField[]**](#I18nField) | | [optional]
**meta_keywords** | [**\Kinow\Client\Model\I18nField[]**](#I18nField) | | [optional]
**meta_title** | [**\Kinow\Client\Model\I18nField[]**](#I18nField) | | [optional]
**link_rewrite** | [**\Kinow\Client\Model\I18nField[]**](#I18nField) | | [optional]
**name** | [**\Kinow\Client\Model\I18nField[]**](#I18nField) | | [optional]
**description** | [**\Kinow\Client\Model\I18nField[]**](#I18nField) | | [optional]
**description_short** | [**\Kinow\Client\Model\I18nField[]**](#I18nField) | | [optional]
**tags** | [**\Kinow\Client\Model\Tag[]**](#Tag) | | [optional]
**can_buy** | **bool** | | [optional]
**available_in_subscriptions** | **bool** | | [optional]
**duration** | **int** | | [optional]
**type** | **string** | | [optional]
**sub** | **bool** | DEPRECATED (use type) | [optional]
**has_group_restriction** | **bool** | DEPRECATED (use group_restriction_behavior) | [optional]
**group_restriction_behavior** | **int** | | [optional]
**geoloc_enabled** | **bool** | | [optional]
**behavior_detected_countries** | **string** | | [optional]
**behavior_non_detected_countries** | **string** | | [optional]
**id_product_attribute** | **int** | Only available when the product is in a cart | [optional]
**roles** | **string** | | [optional]
**categories** | [**\Kinow\Client\Model\ProductCategories[]**](#ProductCategories) | | [optional]


1 change: 1 addition & 0 deletions docs/Model/Gift2.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,6 @@ Name | Type | Description | Notes
**message** | **string** | Message for the recipient |
**custom** | **string** | Custom data | [optional]
**date_send** | **string** | Date to send the Gift to the recipient | [optional]
**auto_link** | **bool** | Auto-link Gift to an existing Product in Cart with same IDs - true by default | [optional]


2 changes: 1 addition & 1 deletion lib/Api/ActorsApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
*
* Client API for Kinow back-office
*
* OpenAPI spec version: 1.4.21
* OpenAPI spec version: 1.4.22
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*
Expand Down
2 changes: 1 addition & 1 deletion lib/Api/AddressApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
*
* Client API for Kinow back-office
*
* OpenAPI spec version: 1.4.21
* OpenAPI spec version: 1.4.22
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*
Expand Down
2 changes: 1 addition & 1 deletion lib/Api/AttributesApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
*
* Client API for Kinow back-office
*
* OpenAPI spec version: 1.4.21
* OpenAPI spec version: 1.4.22
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*
Expand Down
2 changes: 1 addition & 1 deletion lib/Api/BlogCategoriesApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
*
* Client API for Kinow back-office
*
* OpenAPI spec version: 1.4.21
* OpenAPI spec version: 1.4.22
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*
Expand Down
2 changes: 1 addition & 1 deletion lib/Api/BlogPagesApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
*
* Client API for Kinow back-office
*
* OpenAPI spec version: 1.4.21
* OpenAPI spec version: 1.4.22
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*
Expand Down
2 changes: 1 addition & 1 deletion lib/Api/BookmarksApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
*
* Client API for Kinow back-office
*
* OpenAPI spec version: 1.4.21
* OpenAPI spec version: 1.4.22
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*
Expand Down
2 changes: 1 addition & 1 deletion lib/Api/CMSCategoriesApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
*
* Client API for Kinow back-office
*
* OpenAPI spec version: 1.4.21
* OpenAPI spec version: 1.4.22
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*
Expand Down
2 changes: 1 addition & 1 deletion lib/Api/CMSPagesApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
*
* Client API for Kinow back-office
*
* OpenAPI spec version: 1.4.21
* OpenAPI spec version: 1.4.22
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*
Expand Down
2 changes: 1 addition & 1 deletion lib/Api/CartRulesApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
*
* Client API for Kinow back-office
*
* OpenAPI spec version: 1.4.21
* OpenAPI spec version: 1.4.22
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*
Expand Down
26 changes: 19 additions & 7 deletions lib/Api/CartsApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
*
* Client API for Kinow back-office
*
* OpenAPI spec version: 1.4.21
* OpenAPI spec version: 1.4.22
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*
Expand Down Expand Up @@ -96,15 +96,16 @@ public function setApiClient(\Kinow\Client\ApiClient $apiClient)
* @param int $cart_id Cart ID to fetch (required)
* @param int $product_id Product ID to add to cart (required)
* @param int $product_attribute_id ProductAttribute ID, required to add product to cart if product is not a subscription (optional)
* @param int $gift_id Gift ID linked to the item in cart (optional)
* @param int $switch_subscription_id When customer want to switch subscription, switch_subscription_id is the product access ID that match with the subscription to cancel (optional)
* @param bool $is_gift Allows bypass of access check (in case the current user already bought the product and it cannot be reordered) (optional, default to false)
* @param string $ip_address IP address (optional)
* @throws \Kinow\Client\ApiException on non-2xx response
* @return \Kinow\Client\Model\Cart
*/
public function addProductToCart($cart_id, $product_id, $product_attribute_id = null, $switch_subscription_id = null, $is_gift = null, $ip_address = null)
public function addProductToCart($cart_id, $product_id, $product_attribute_id = null, $gift_id = null, $switch_subscription_id = null, $is_gift = null, $ip_address = null)
{
list($response) = $this->addProductToCartWithHttpInfo($cart_id, $product_id, $product_attribute_id, $switch_subscription_id, $is_gift, $ip_address);
list($response) = $this->addProductToCartWithHttpInfo($cart_id, $product_id, $product_attribute_id, $gift_id, $switch_subscription_id, $is_gift, $ip_address);
return $response;
}

Expand All @@ -116,13 +117,14 @@ public function addProductToCart($cart_id, $product_id, $product_attribute_id =
* @param int $cart_id Cart ID to fetch (required)
* @param int $product_id Product ID to add to cart (required)
* @param int $product_attribute_id ProductAttribute ID, required to add product to cart if product is not a subscription (optional)
* @param int $gift_id Gift ID linked to the item in cart (optional)
* @param int $switch_subscription_id When customer want to switch subscription, switch_subscription_id is the product access ID that match with the subscription to cancel (optional)
* @param bool $is_gift Allows bypass of access check (in case the current user already bought the product and it cannot be reordered) (optional, default to false)
* @param string $ip_address IP address (optional)
* @throws \Kinow\Client\ApiException on non-2xx response
* @return array of \Kinow\Client\Model\Cart, HTTP status code, HTTP response headers (array of strings)
*/
public function addProductToCartWithHttpInfo($cart_id, $product_id, $product_attribute_id = null, $switch_subscription_id = null, $is_gift = null, $ip_address = null)
public function addProductToCartWithHttpInfo($cart_id, $product_id, $product_attribute_id = null, $gift_id = null, $switch_subscription_id = null, $is_gift = null, $ip_address = null)
{
// verify the required parameter 'cart_id' is set
if ($cart_id === null) {
Expand Down Expand Up @@ -165,6 +167,10 @@ public function addProductToCartWithHttpInfo($cart_id, $product_id, $product_att
$formParams['product_attribute_id'] = $this->apiClient->getSerializer()->toFormValue($product_attribute_id);
}
// form params
if ($gift_id !== null) {
$formParams['gift_id'] = $this->apiClient->getSerializer()->toFormValue($gift_id);
}
// form params
if ($switch_subscription_id !== null) {
$formParams['switch_subscription_id'] = $this->apiClient->getSerializer()->toFormValue($switch_subscription_id);
}
Expand Down Expand Up @@ -569,12 +575,13 @@ public function deleteCartWithHttpInfo($cart_id)
* @param int $cart_id Cart ID to fetch (required)
* @param int $product_id Product ID to delete from cart (required)
* @param int $product_attribute_id Product attribute ID, required to add product to cart if product is not a subscription (optional)
* @param int $gift_id Gift ID linked to the item in cart (optional)
* @throws \Kinow\Client\ApiException on non-2xx response
* @return void
*/
public function deleteProductFromCart($cart_id, $product_id, $product_attribute_id = null)
public function deleteProductFromCart($cart_id, $product_id, $product_attribute_id = null, $gift_id = null)
{
list($response) = $this->deleteProductFromCartWithHttpInfo($cart_id, $product_id, $product_attribute_id);
list($response) = $this->deleteProductFromCartWithHttpInfo($cart_id, $product_id, $product_attribute_id, $gift_id);
return $response;
}

Expand All @@ -586,10 +593,11 @@ public function deleteProductFromCart($cart_id, $product_id, $product_attribute_
* @param int $cart_id Cart ID to fetch (required)
* @param int $product_id Product ID to delete from cart (required)
* @param int $product_attribute_id Product attribute ID, required to add product to cart if product is not a subscription (optional)
* @param int $gift_id Gift ID linked to the item in cart (optional)
* @throws \Kinow\Client\ApiException on non-2xx response
* @return array of null, HTTP status code, HTTP response headers (array of strings)
*/
public function deleteProductFromCartWithHttpInfo($cart_id, $product_id, $product_attribute_id = null)
public function deleteProductFromCartWithHttpInfo($cart_id, $product_id, $product_attribute_id = null, $gift_id = null)
{
// verify the required parameter 'cart_id' is set
if ($cart_id === null) {
Expand Down Expand Up @@ -620,6 +628,10 @@ public function deleteProductFromCartWithHttpInfo($cart_id, $product_id, $produc
if ($product_attribute_id !== null) {
$queryParams['product_attribute_id'] = $this->apiClient->getSerializer()->toQueryValue($product_attribute_id);
}
// query params
if ($gift_id !== null) {
$queryParams['gift_id'] = $this->apiClient->getSerializer()->toQueryValue($gift_id);
}
// path params
if ($cart_id !== null) {
$resourcePath = str_replace(
Expand Down
2 changes: 1 addition & 1 deletion lib/Api/CategoriesApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
*
* Client API for Kinow back-office
*
* OpenAPI spec version: 1.4.21
* OpenAPI spec version: 1.4.22
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*
Expand Down
2 changes: 1 addition & 1 deletion lib/Api/CategoryVideosApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
*
* Client API for Kinow back-office
*
* OpenAPI spec version: 1.4.21
* OpenAPI spec version: 1.4.22
*
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*
Expand Down
Loading

0 comments on commit 9615bb7

Please sign in to comment.