All URIs are relative to https://api.api2cart.local.com/v1.1
| Method | HTTP request | Description |
|---|---|---|
| cartCatalogPriceRulesCount | GET /cart.catalog_price_rules.count.json | cart.catalog_price_rules.count |
| cartCatalogPriceRulesCountWithHttpInfo | GET /cart.catalog_price_rules.count.json | cart.catalog_price_rules.count |
| cartCatalogPriceRulesList | GET /cart.catalog_price_rules.list.json | cart.catalog_price_rules.list |
| cartCatalogPriceRulesListWithHttpInfo | GET /cart.catalog_price_rules.list.json | cart.catalog_price_rules.list |
| cartCouponAdd | POST /cart.coupon.add.json | cart.coupon.add |
| cartCouponAddWithHttpInfo | POST /cart.coupon.add.json | cart.coupon.add |
| cartCouponConditionAdd | POST /cart.coupon.condition.add.json | cart.coupon.condition.add |
| cartCouponConditionAddWithHttpInfo | POST /cart.coupon.condition.add.json | cart.coupon.condition.add |
| cartCouponCount | GET /cart.coupon.count.json | cart.coupon.count |
| cartCouponCountWithHttpInfo | GET /cart.coupon.count.json | cart.coupon.count |
| cartCouponDelete | DELETE /cart.coupon.delete.json | cart.coupon.delete |
| cartCouponDeleteWithHttpInfo | DELETE /cart.coupon.delete.json | cart.coupon.delete |
| cartCouponList | GET /cart.coupon.list.json | cart.coupon.list |
| cartCouponListWithHttpInfo | GET /cart.coupon.list.json | cart.coupon.list |
| cartDelete | DELETE /cart.delete.json | cart.delete |
| cartDeleteWithHttpInfo | DELETE /cart.delete.json | cart.delete |
| cartGiftcardAdd | POST /cart.giftcard.add.json | cart.giftcard.add |
| cartGiftcardAddWithHttpInfo | POST /cart.giftcard.add.json | cart.giftcard.add |
| cartGiftcardCount | GET /cart.giftcard.count.json | cart.giftcard.count |
| cartGiftcardCountWithHttpInfo | GET /cart.giftcard.count.json | cart.giftcard.count |
| cartGiftcardDelete | DELETE /cart.giftcard.delete.json | cart.giftcard.delete |
| cartGiftcardDeleteWithHttpInfo | DELETE /cart.giftcard.delete.json | cart.giftcard.delete |
| cartGiftcardList | GET /cart.giftcard.list.json | cart.giftcard.list |
| cartGiftcardListWithHttpInfo | GET /cart.giftcard.list.json | cart.giftcard.list |
| cartInfo | GET /cart.info.json | cart.info |
| cartInfoWithHttpInfo | GET /cart.info.json | cart.info |
| cartMetaDataList | GET /cart.meta_data.list.json | cart.meta_data.list |
| cartMetaDataListWithHttpInfo | GET /cart.meta_data.list.json | cart.meta_data.list |
| cartMetaDataSet | POST /cart.meta_data.set.json | cart.meta_data.set |
| cartMetaDataSetWithHttpInfo | POST /cart.meta_data.set.json | cart.meta_data.set |
| cartMetaDataUnset | DELETE /cart.meta_data.unset.json | cart.meta_data.unset |
| cartMetaDataUnsetWithHttpInfo | DELETE /cart.meta_data.unset.json | cart.meta_data.unset |
| cartMethods | GET /cart.methods.json | cart.methods |
| cartMethodsWithHttpInfo | GET /cart.methods.json | cart.methods |
| cartPluginList | GET /cart.plugin.list.json | cart.plugin.list |
| cartPluginListWithHttpInfo | GET /cart.plugin.list.json | cart.plugin.list |
| cartScriptAdd | POST /cart.script.add.json | cart.script.add |
| cartScriptAddWithHttpInfo | POST /cart.script.add.json | cart.script.add |
| cartScriptDelete | DELETE /cart.script.delete.json | cart.script.delete |
| cartScriptDeleteWithHttpInfo | DELETE /cart.script.delete.json | cart.script.delete |
| cartScriptList | GET /cart.script.list.json | cart.script.list |
| cartScriptListWithHttpInfo | GET /cart.script.list.json | cart.script.list |
| cartShippingZonesList | GET /cart.shipping_zones.list.json | cart.shipping_zones.list |
| cartShippingZonesListWithHttpInfo | GET /cart.shipping_zones.list.json | cart.shipping_zones.list |
| cartValidate | GET /cart.validate.json | cart.validate |
| cartValidateWithHttpInfo | GET /cart.validate.json | cart.validate |
cartCatalogPriceRulesCount(): ApiRequest[CartCatalogPriceRulesCount200Response]
cart.catalog_price_rules.count
Get count of cart catalog price rules discounts.
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val request = apiInstance.cartCatalogPriceRulesCount()
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartCatalogPriceRulesCount")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartCatalogPriceRulesCount")
exception.printStackTrace();
}
}This endpoint does not need any parameter.
ApiRequest[CartCatalogPriceRulesCount200Response]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartCatalogPriceRulesList(cartCatalogPriceRulesListRequest): ApiRequest[ModelResponseCartCatalogPriceRulesList]
cart.catalog_price_rules.list
Get cart catalog price rules discounts.
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val start: Int = 0 // Int | This parameter sets the number from which you want to get entities
val count: Int = 20 // Int | This parameter sets the entity amount that has to be retrieved. Max allowed count=250
val pageCursor: String = // String | Used to retrieve entities via cursor-based pagination (it can't be used with any other filtering parameter)
val ids: String = 24,25 // String | Retrieves catalog_price_rules by ids
val responseFields: String = {result{catalog_price_rules_count,catalog_price_rules{id,type,name,avail,usage_count,actions,conditions}}} // String | Set this parameter in order to choose which entity fields you want to retrieve
val params: String = id,model,price,images // String | Set this parameter in order to choose which entity fields you want to retrieve
val exclude: String = false // String | Set this parameter in order to choose which entity fields you want to ignore. Works only if parameter `params` equal force_all
val request = apiInstance.cartCatalogPriceRulesList(start, count, pageCursor, ids, responseFields, params, exclude)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartCatalogPriceRulesList")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartCatalogPriceRulesList")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| start | Int | This parameter sets the number from which you want to get entities | [optional] |
| count | Int | This parameter sets the entity amount that has to be retrieved. Max allowed count=250 | [optional] |
| pageCursor | String | Used to retrieve entities via cursor-based pagination (it can't be used with any other filtering parameter) | [optional] |
| ids | String | Retrieves catalog_price_rules by ids | [optional] |
| responseFields | String | Set this parameter in order to choose which entity fields you want to retrieve | [optional] |
| params | String | Set this parameter in order to choose which entity fields you want to retrieve | [optional] |
| exclude | String | Set this parameter in order to choose which entity fields you want to ignore. Works only if parameter `params` equal force_all | [optional] |
ApiRequest[ModelResponseCartCatalogPriceRulesList]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartCouponAdd(cartCouponAddRequest): ApiRequest[CartCouponAdd200Response]
cart.coupon.add
Use this method to create a coupon with specified conditions.
// Import classes:
import
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val cartCouponAdd: CartCouponAdd = // CartCouponAdd |
val request = apiInstance.cartCouponAdd(cartCouponAdd)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartCouponAdd")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartCouponAdd")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| cartCouponAdd | CartCouponAdd |
ApiRequest[CartCouponAdd200Response]
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartCouponConditionAdd(cartCouponConditionAddRequest): ApiRequest[BasketLiveShippingServiceDelete200Response]
cart.coupon.condition.add
Use this method to add additional conditions for coupon application.
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val couponId: String = 45845 // String | Coupon Id
val entity: String = order // String | Defines condition entity type
val key: String = subtotal // String | Defines condition entity attribute key
val operator: String = == // String | Defines condition operator
val value: String = 2 // String | Defines condition value, can be comma separated according to the operator.
val target: String = coupon_action // String | Defines condition operator
val includeTax: Boolean = true // Boolean | Indicates whether to apply a discount for taxes.
val includeShipping: Boolean = true // Boolean | Indicates whether to apply a discount for shipping.
val storeId: String = 1 // String | Store Id
val idempotencyKey: String = 098f6bcd4621d373cade4e832627b4f6 // String | A unique identifier associated with a specific request. Repeated requests with the same <strong>idempotency_key</strong> return a cached response without re-executing the business logic. <strong>Please note that the cache lifetime is 15 minutes.</strong>
val request = apiInstance.cartCouponConditionAdd(couponId, entity, key, operator, value, target, includeTax, includeShipping, storeId, idempotencyKey)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartCouponConditionAdd")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartCouponConditionAdd")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| couponId | String | Coupon Id | |
| entity | String | Defines condition entity type | [enum: order, order_shipping_address, product, customer] |
| key | String | Defines condition entity attribute key | [enum: total, subtotal, shipping_total, total_quantity, total_weight, country, product_id, variant_id, category_id, customer_id, item_price, item_total_price, item_quantity, carrier_id] |
| operator | String | Defines condition operator | |
| value | String | Defines condition value, can be comma separated according to the operator. | |
| target | String | Defines condition operator | [optional] |
| includeTax | Boolean | Indicates whether to apply a discount for taxes. | [optional] |
| includeShipping | Boolean | Indicates whether to apply a discount for shipping. | [optional] |
| storeId | String | Store Id | [optional] |
| idempotencyKey | String | A unique identifier associated with a specific request. Repeated requests with the same <strong>idempotency_key</strong> return a cached response without re-executing the business logic. <strong>Please note that the cache lifetime is 15 minutes.</strong> | [optional] |
ApiRequest[BasketLiveShippingServiceDelete200Response]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartCouponCount(cartCouponCountRequest): ApiRequest[CartCouponCount200Response]
cart.coupon.count
This method allows you to get the number of coupons. On some platforms, you can filter the coupons by the date they were active.
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val storeId: String = 1 // String | Store Id
val avail: Boolean = false // Boolean | Defines category's visibility status
val dateStartFrom: String = 2016-12-29 16:44:30 // String | Filter entity by date_start (greater or equal)
val dateStartTo: String = 2016-12-29 16:44:30 // String | Filter entity by date_start (less or equal)
val dateEndFrom: String = 2016-12-29 16:44:30 // String | Filter entity by date_end (greater or equal)
val dateEndTo: String = 2016-12-29 16:44:30 // String | Filter entity by date_end (less or equal)
val request = apiInstance.cartCouponCount(storeId, avail, dateStartFrom, dateStartTo, dateEndFrom, dateEndTo)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartCouponCount")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartCouponCount")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| storeId | String | Store Id | [optional] |
| avail | Boolean | Defines category's visibility status | [optional] |
| dateStartFrom | String | Filter entity by date_start (greater or equal) | [optional] |
| dateStartTo | String | Filter entity by date_start (less or equal) | [optional] |
| dateEndFrom | String | Filter entity by date_end (greater or equal) | [optional] |
| dateEndTo | String | Filter entity by date_end (less or equal) | [optional] |
ApiRequest[CartCouponCount200Response]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartCouponDelete(cartCouponDeleteRequest): ApiRequest[AttributeDelete200Response]
cart.coupon.delete
Delete coupon
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val id: String = 10 // String | Entity id
val storeId: String = 1 // String | Store Id
val request = apiInstance.cartCouponDelete(id, storeId)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartCouponDelete")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartCouponDelete")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| id | String | Entity id | |
| storeId | String | Store Id | [optional] |
ApiRequest[AttributeDelete200Response]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartCouponList(cartCouponListRequest): ApiRequest[ModelResponseCartCouponList]
cart.coupon.list
Get cart coupon discounts.
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val start: Int = 0 // Int | This parameter sets the number from which you want to get entities
val count: Int = 20 // Int | This parameter sets the entity amount that has to be retrieved. Max allowed count=250
val pageCursor: String = // String | Used to retrieve entities via cursor-based pagination (it can't be used with any other filtering parameter)
val couponsIds: String = 1,2,3 // String | Filter coupons by ids
val storeId: String = 1 // String | Filter coupons by store id
val langId: String = 3 // String | Language id
val avail: Boolean = false // Boolean | Filter coupons by avail status
val status: String = disabled // String | Defines coupon's status
val dateStartFrom: String = 2016-12-29 16:44:30 // String | Filter entity by date_start (greater or equal)
val dateStartTo: String = 2016-12-29 16:44:30 // String | Filter entity by date_start (less or equal)
val dateEndFrom: String = 2016-12-29 16:44:30 // String | Filter entity by date_end (greater or equal)
val dateEndTo: String = 2016-12-29 16:44:30 // String | Filter entity by date_end (less or equal)
val responseFields: String = {pagination,result{coupon_count,coupon{id,code,name,conditions,actions{scope,amount,conditions{id,value,sub-conditions}},date_start,avail}}} // String | Set this parameter in order to choose which entity fields you want to retrieve
val params: String = id,code,type,amount // String | Set this parameter in order to choose which entity fields you want to retrieve
val exclude: String = usage_history,type // String | Set this parameter in order to choose which entity fields you want to ignore. Works only if parameter `params` equal force_all
val request = apiInstance.cartCouponList(start, count, pageCursor, couponsIds, storeId, langId, avail, status, dateStartFrom, dateStartTo, dateEndFrom, dateEndTo, responseFields, params, exclude)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartCouponList")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartCouponList")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| start | Int | This parameter sets the number from which you want to get entities | [optional] |
| count | Int | This parameter sets the entity amount that has to be retrieved. Max allowed count=250 | [optional] |
| pageCursor | String | Used to retrieve entities via cursor-based pagination (it can't be used with any other filtering parameter) | [optional] |
| couponsIds | String | Filter coupons by ids | [optional] |
| storeId | String | Filter coupons by store id | [optional] |
| langId | String | Language id | [optional] |
| avail | Boolean | Filter coupons by avail status | [optional] |
| status | String | Defines coupon's status | [optional] |
| dateStartFrom | String | Filter entity by date_start (greater or equal) | [optional] |
| dateStartTo | String | Filter entity by date_start (less or equal) | [optional] |
| dateEndFrom | String | Filter entity by date_end (greater or equal) | [optional] |
| dateEndTo | String | Filter entity by date_end (less or equal) | [optional] |
| responseFields | String | Set this parameter in order to choose which entity fields you want to retrieve | [optional] |
| params | String | Set this parameter in order to choose which entity fields you want to retrieve | [optional] |
| exclude | String | Set this parameter in order to choose which entity fields you want to ignore. Works only if parameter `params` equal force_all | [optional] |
ApiRequest[ModelResponseCartCouponList]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartDelete(cartDeleteRequest): ApiRequest[CartDelete200Response]
cart.delete
Remove store from API2Cart
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val deleteBridge: Boolean = true // Boolean | Identifies if there is a necessity to delete bridge
val request = apiInstance.cartDelete(deleteBridge)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartDelete")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartDelete")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| deleteBridge | Boolean | Identifies if there is a necessity to delete bridge | [optional] |
ApiRequest[CartDelete200Response]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartGiftcardAdd(cartGiftcardAddRequest): ApiRequest[CartGiftcardAdd200Response]
cart.giftcard.add
Use this method to create a gift card for a specified amount.
// Import classes:
import
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val amount: BigDecimal = 15.5 // BigDecimal | Defines the gift card amount value.
val code: String = GFT1 A4S5 AA11 RD61 // String | Gift card code
val ownerEmail: String = jubari@hannsgroup.com // String | Gift card owner email
val recipientEmail: String = jubari@hannsgroup.com // String | Gift card recipient email
val recipientName: String = John Doe // String | Gift card recipient name
val ownerName: String = John Doe // String | Gift card owner name
val idempotencyKey: String = 098f6bcd4621d373cade4e832627b4f6 // String | A unique identifier associated with a specific request. Repeated requests with the same <strong>idempotency_key</strong> return a cached response without re-executing the business logic. <strong>Please note that the cache lifetime is 15 minutes.</strong>
val request = apiInstance.cartGiftcardAdd(amount, code, ownerEmail, recipientEmail, recipientName, ownerName, idempotencyKey)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartGiftcardAdd")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartGiftcardAdd")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| amount | BigDecimal | Defines the gift card amount value. | |
| code | String | Gift card code | [optional] |
| ownerEmail | String | Gift card owner email | [optional] |
| recipientEmail | String | Gift card recipient email | [optional] |
| recipientName | String | Gift card recipient name | [optional] |
| ownerName | String | Gift card owner name | [optional] |
| idempotencyKey | String | A unique identifier associated with a specific request. Repeated requests with the same <strong>idempotency_key</strong> return a cached response without re-executing the business logic. <strong>Please note that the cache lifetime is 15 minutes.</strong> | [optional] |
ApiRequest[CartGiftcardAdd200Response]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartGiftcardCount(cartGiftcardCountRequest): ApiRequest[CartGiftcardCount200Response]
cart.giftcard.count
Get gift cards count.
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val storeId: String = 1 // String | Store Id
val request = apiInstance.cartGiftcardCount(storeId)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartGiftcardCount")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartGiftcardCount")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| storeId | String | Store Id | [optional] |
ApiRequest[CartGiftcardCount200Response]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartGiftcardDelete(cartGiftcardDeleteRequest): ApiRequest[AttributeDelete200Response]
cart.giftcard.delete
Delete giftcard
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val id: String = 10 // String | Entity id
val request = apiInstance.cartGiftcardDelete(id)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartGiftcardDelete")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartGiftcardDelete")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| id | String | Entity id |
ApiRequest[AttributeDelete200Response]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartGiftcardList(cartGiftcardListRequest): ApiRequest[ModelResponseCartGiftCardList]
cart.giftcard.list
Get gift cards list.
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val start: Int = 0 // Int | This parameter sets the number from which you want to get entities
val count: Int = 20 // Int | This parameter sets the entity amount that has to be retrieved. Max allowed count=250
val pageCursor: String = // String | Used to retrieve entities via cursor-based pagination (it can't be used with any other filtering parameter)
val storeId: String = 1 // String | Store Id
val responseFields: String = {pagination,result{gift_card{id,code,amount,status}}} // String | Set this parameter in order to choose which entity fields you want to retrieve
val params: String = id,model,price,images // String | Set this parameter in order to choose which entity fields you want to retrieve
val exclude: String = false // String | Set this parameter in order to choose which entity fields you want to ignore. Works only if parameter `params` equal force_all
val request = apiInstance.cartGiftcardList(start, count, pageCursor, storeId, responseFields, params, exclude)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartGiftcardList")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartGiftcardList")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| start | Int | This parameter sets the number from which you want to get entities | [optional] |
| count | Int | This parameter sets the entity amount that has to be retrieved. Max allowed count=250 | [optional] |
| pageCursor | String | Used to retrieve entities via cursor-based pagination (it can't be used with any other filtering parameter) | [optional] |
| storeId | String | Store Id | [optional] |
| responseFields | String | Set this parameter in order to choose which entity fields you want to retrieve | [optional] |
| params | String | Set this parameter in order to choose which entity fields you want to retrieve | [optional] |
| exclude | String | Set this parameter in order to choose which entity fields you want to ignore. Works only if parameter `params` equal force_all | [optional] |
ApiRequest[ModelResponseCartGiftCardList]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartInfo(cartInfoRequest): ApiRequest[CartInfo200Response]
cart.info
This method allows you to get various information about the store, including a list of stores (in the case of a multistore configuration), a list of supported languages, currencies, carriers, warehouses, and many other information. This information contains data that is relatively stable and rarely changes, so API2Cart can cache certain data to reduce the load on the store and speed up the execution of the request. We also recommend that you cache the response of this method on your side to save requests. If you need to clear the cache for a specific store, then use the cart.validate method.
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val storeId: String = 1 // String | Store Id
val responseFields: String = {result{name,url,stores_info{store_id,name,currency{id,iso3},store_owner_info}}} // String | Set this parameter in order to choose which entity fields you want to retrieve
val params: String = name,url // String | Set this parameter in order to choose which entity fields you want to retrieve
val exclude: String = name,url // String | Set this parameter in order to choose which entity fields you want to ignore. Works only if parameter `params` equal force_all
val request = apiInstance.cartInfo(storeId, responseFields, params, exclude)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartInfo")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartInfo")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| storeId | String | Store Id | [optional] |
| responseFields | String | Set this parameter in order to choose which entity fields you want to retrieve | [optional] |
| params | String | Set this parameter in order to choose which entity fields you want to retrieve | [optional] |
| exclude | String | Set this parameter in order to choose which entity fields you want to ignore. Works only if parameter `params` equal force_all | [optional] |
ApiRequest[CartInfo200Response]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartMetaDataList(cartMetaDataListRequest): ApiRequest[ModelResponseCartMetaDataList]
cart.meta_data.list
Using this method, you can get a list of metadata for various entities (products, options, customers, orders). Usually this is data created by third-party plugins.
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val entityId: String = 1 // String | Entity Id
val count: Int = 20 // Int | This parameter sets the entity amount that has to be retrieved. Max allowed count=250
val pageCursor: String = // String | Used to retrieve entities via cursor-based pagination (it can't be used with any other filtering parameter)
val entity: String = order // String | Entity
val storeId: String = 1 // String | Store Id
val langId: String = 3 // String | Language id
val key: String = subtotal // String | Key
val responseFields: String = {result{items{key,value}}} // String | Set this parameter in order to choose which entity fields you want to retrieve
val params: String = id,model,price,images // String | Set this parameter in order to choose which entity fields you want to retrieve
val exclude: String = false // String | Set this parameter in order to choose which entity fields you want to ignore. Works only if parameter `params` equal force_all
val request = apiInstance.cartMetaDataList(entityId, count, pageCursor, entity, storeId, langId, key, responseFields, params, exclude)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartMetaDataList")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartMetaDataList")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| entityId | String | Entity Id | |
| count | Int | This parameter sets the entity amount that has to be retrieved. Max allowed count=250 | [optional] |
| pageCursor | String | Used to retrieve entities via cursor-based pagination (it can't be used with any other filtering parameter) | [optional] |
| entity | String | Entity | [optional] |
| storeId | String | Store Id | [optional] |
| langId | String | Language id | [optional] |
| key | String | Key | [optional] |
| responseFields | String | Set this parameter in order to choose which entity fields you want to retrieve | [optional] |
| params | String | Set this parameter in order to choose which entity fields you want to retrieve | [optional] |
| exclude | String | Set this parameter in order to choose which entity fields you want to ignore. Works only if parameter `params` equal force_all | [optional] |
ApiRequest[ModelResponseCartMetaDataList]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartMetaDataSet(cartMetaDataSetRequest): ApiRequest[AttributeAdd200Response]
cart.meta_data.set
Set meta data for a specific entity
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val entityId: String = 1 // String | Entity Id
val key: String = subtotal // String | Key
val value: String = 2 // String | Value
val namespace: String = order // String | Metafield namespace
val entity: String = order // String | Entity
val storeId: String = 1 // String | Store Id
val langId: String = 3 // String | Language id
val idempotencyKey: String = 098f6bcd4621d373cade4e832627b4f6 // String | A unique identifier associated with a specific request. Repeated requests with the same <strong>idempotency_key</strong> return a cached response without re-executing the business logic. <strong>Please note that the cache lifetime is 15 minutes.</strong>
val request = apiInstance.cartMetaDataSet(entityId, key, value, namespace, entity, storeId, langId, idempotencyKey)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartMetaDataSet")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartMetaDataSet")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| entityId | String | Entity Id | |
| key | String | Key | |
| value | String | Value | |
| namespace | String | Metafield namespace | |
| entity | String | Entity | [optional] |
| storeId | String | Store Id | [optional] |
| langId | String | Language id | [optional] |
| idempotencyKey | String | A unique identifier associated with a specific request. Repeated requests with the same <strong>idempotency_key</strong> return a cached response without re-executing the business logic. <strong>Please note that the cache lifetime is 15 minutes.</strong> | [optional] |
ApiRequest[AttributeAdd200Response]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartMetaDataUnset(cartMetaDataUnsetRequest): ApiRequest[BasketLiveShippingServiceDelete200Response]
cart.meta_data.unset
Unset meta data for a specific entity
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val entityId: String = 1 // String | Entity Id
val key: String = subtotal // String | Key
val id: String = 10 // String | Entity id
val entity: String = order // String | Entity
val storeId: String = 1 // String | Store Id
val request = apiInstance.cartMetaDataUnset(entityId, key, id, entity, storeId)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartMetaDataUnset")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartMetaDataUnset")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| entityId | String | Entity Id | |
| key | String | Key | |
| id | String | Entity id | |
| entity | String | Entity | [optional] |
| storeId | String | Store Id | [optional] |
ApiRequest[BasketLiveShippingServiceDelete200Response]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartMethods(): ApiRequest[CartMethods200Response]
cart.methods
Returns a list of supported API methods.
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val request = apiInstance.cartMethods()
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartMethods")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartMethods")
exception.printStackTrace();
}
}This endpoint does not need any parameter.
ApiRequest[CartMethods200Response]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartPluginList(cartPluginListRequest): ApiRequest[CartPluginList200Response]
cart.plugin.list
Get a list of third-party plugins installed on the store.
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val start: Int = 0 // Int | This parameter sets the number from which you want to get entities
val count: Int = 20 // Int | This parameter sets the entity amount that has to be retrieved. Max allowed count=250
val storeId: String = 1 // String | Store Id
val request = apiInstance.cartPluginList(start, count, storeId)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartPluginList")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartPluginList")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| start | Int | This parameter sets the number from which you want to get entities | [optional] |
| count | Int | This parameter sets the entity amount that has to be retrieved. Max allowed count=250 | [optional] |
| storeId | String | Store Id | [optional] |
ApiRequest[CartPluginList200Response]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartScriptAdd(cartScriptAddRequest): ApiRequest[CartScriptAdd200Response]
cart.script.add
Add new script to the storefront
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val name: String = jQuery Minimized // String | The user-friendly script name
val description: String = The Write Less, Do More, JavaScript Library // String | The user-friendly description
val html: String = <script>alert('foo')</script> // String | An html string containing exactly one `script` tag.
val src: String = https://js-aplenty.com/foo.js // String | The URL of the remote script
val loadMethod: String = async // String | The load method to use for the script
val scope: String = all // String | The page or pages on the online store where the script should be included
val events: String = purchase_event // String | Event for run scripts
val storeId: String = 1 // String | Store Id
val idempotencyKey: String = 098f6bcd4621d373cade4e832627b4f6 // String | A unique identifier associated with a specific request. Repeated requests with the same <strong>idempotency_key</strong> return a cached response without re-executing the business logic. <strong>Please note that the cache lifetime is 15 minutes.</strong>
val request = apiInstance.cartScriptAdd(name, description, html, src, loadMethod, scope, events, storeId, idempotencyKey)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartScriptAdd")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartScriptAdd")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| name | String | The user-friendly script name | [optional] |
| description | String | The user-friendly description | [optional] |
| html | String | An html string containing exactly one `script` tag. | [optional] |
| src | String | The URL of the remote script | [optional] |
| loadMethod | String | The load method to use for the script | [optional] |
| scope | String | The page or pages on the online store where the script should be included | [optional] |
| events | String | Event for run scripts | [optional] |
| storeId | String | Store Id | [optional] |
| idempotencyKey | String | A unique identifier associated with a specific request. Repeated requests with the same <strong>idempotency_key</strong> return a cached response without re-executing the business logic. <strong>Please note that the cache lifetime is 15 minutes.</strong> | [optional] |
ApiRequest[CartScriptAdd200Response]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartScriptDelete(cartScriptDeleteRequest): ApiRequest[AttributeDelete200Response]
cart.script.delete
Remove script from the storefront
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val id: String = 10 // String | Entity id
val storeId: String = 1 // String | Store Id
val request = apiInstance.cartScriptDelete(id, storeId)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartScriptDelete")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartScriptDelete")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| id | String | Entity id | |
| storeId | String | Store Id | [optional] |
ApiRequest[AttributeDelete200Response]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartScriptList(cartScriptListRequest): ApiRequest[ModelResponseCartScriptList]
cart.script.list
Get scripts installed to the storefront
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val start: Int = 0 // Int | This parameter sets the number from which you want to get entities
val count: Int = 20 // Int | This parameter sets the entity amount that has to be retrieved. Max allowed count=250
val pageCursor: String = // String | Used to retrieve entities via cursor-based pagination (it can't be used with any other filtering parameter)
val scriptIds: String = 34023324,34024032 // String | Retrieves only scripts with specific ids
val storeId: String = 1 // String | Store Id
val createdFrom: String = 2010-07-29 13:45:52 // String | Retrieve entities from their creation date
val createdTo: String = 2100-08-29 13:45:52 // String | Retrieve entities to their creation date
val modifiedFrom: String = 2010-07-29 13:45:52 // String | Retrieve entities from their modification date
val modifiedTo: String = 2100-08-29 13:45:52 // String | Retrieve entities to their modification date
val responseFields: String = {pagination,result{total_count,scripts{id,name,src,created_time{value}}}} // String | Set this parameter in order to choose which entity fields you want to retrieve
val params: String = id,model,price,images // String | Set this parameter in order to choose which entity fields you want to retrieve
val exclude: String = false // String | Set this parameter in order to choose which entity fields you want to ignore. Works only if parameter `params` equal force_all
val request = apiInstance.cartScriptList(start, count, pageCursor, scriptIds, storeId, createdFrom, createdTo, modifiedFrom, modifiedTo, responseFields, params, exclude)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartScriptList")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartScriptList")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| start | Int | This parameter sets the number from which you want to get entities | [optional] |
| count | Int | This parameter sets the entity amount that has to be retrieved. Max allowed count=250 | [optional] |
| pageCursor | String | Used to retrieve entities via cursor-based pagination (it can't be used with any other filtering parameter) | [optional] |
| scriptIds | String | Retrieves only scripts with specific ids | [optional] |
| storeId | String | Store Id | [optional] |
| createdFrom | String | Retrieve entities from their creation date | [optional] |
| createdTo | String | Retrieve entities to their creation date | [optional] |
| modifiedFrom | String | Retrieve entities from their modification date | [optional] |
| modifiedTo | String | Retrieve entities to their modification date | [optional] |
| responseFields | String | Set this parameter in order to choose which entity fields you want to retrieve | [optional] |
| params | String | Set this parameter in order to choose which entity fields you want to retrieve | [optional] |
| exclude | String | Set this parameter in order to choose which entity fields you want to ignore. Works only if parameter `params` equal force_all | [optional] |
ApiRequest[ModelResponseCartScriptList]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartShippingZonesList(cartShippingZonesListRequest): ApiRequest[ModelResponseCartShippingZonesList]
cart.shipping_zones.list
Get list of shipping zones
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val start: Int = 0 // Int | This parameter sets the number from which you want to get entities
val count: Int = 20 // Int | This parameter sets the entity amount that has to be retrieved. Max allowed count=250
val storeId: String = 1 // String | Store Id
val responseFields: String = {result{id,name,enabled,countries,shipping_methods{name,rates}}} // String | Set this parameter in order to choose which entity fields you want to retrieve
val params: String = id,model,price,images // String | Set this parameter in order to choose which entity fields you want to retrieve
val exclude: String = false // String | Set this parameter in order to choose which entity fields you want to ignore. Works only if parameter `params` equal force_all
val request = apiInstance.cartShippingZonesList(start, count, storeId, responseFields, params, exclude)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartShippingZonesList")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartShippingZonesList")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| start | Int | This parameter sets the number from which you want to get entities | [optional] |
| count | Int | This parameter sets the entity amount that has to be retrieved. Max allowed count=250 | [optional] |
| storeId | String | Store Id | [optional] |
| responseFields | String | Set this parameter in order to choose which entity fields you want to retrieve | [optional] |
| params | String | Set this parameter in order to choose which entity fields you want to retrieve | [optional] |
| exclude | String | Set this parameter in order to choose which entity fields you want to ignore. Works only if parameter `params` equal force_all | [optional] |
ApiRequest[ModelResponseCartShippingZonesList]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |
cartValidate(cartValidateRequest): ApiRequest[CartValidate200Response]
cart.validate
This method clears the cache in API2Cart for a particular store and checks whether the connection to the store is available. Use this method if there have been any changes in the settings on the storе, for example, if a new plugin has been installed or removed.
// Import classes:
import
import org.openapitools.client.core._
import org.openapitools.client.core.CollectionFormats._
import org.openapitools.client.core.ApiKeyLocations._
import akka.actor.ActorSystem
import scala.concurrent.Future
import scala.util.{Failure, Success}
object Example extends App {
implicit val system: ActorSystem = ActorSystem()
import system.dispatcher
// Configure API key authorization: StoreKeyAuth
implicit val StoreKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
// Configure API key authorization: ApiKeyAuth
implicit val ApiKeyAuth: ApiKeyValue = ApiKeyValue("YOUR API KEY")
val apiInvoker = ApiInvoker()
val apiInstance = CartApi("https://api.api2cart.local.com/v1.1")
val validateVersion: Boolean = true // Boolean | Specify if api2cart should validate cart version
val request = apiInstance.cartValidate(validateVersion)
val response = apiInvoker.execute(request)
response.onComplete {
case Success(ApiResponse(code, content, headers)) =>
System.out.println(s"Status code: $code}")
System.out.println(s"Response headers: ${headers.mkString(", ")}")
System.out.println(s"Response body: $content")
case Failure(error @ ApiError(code, message, responseContent, cause, headers)) =>
System.err.println("Exception when calling CartApi#cartValidate")
System.err.println(s"Status code: $code}")
System.err.println(s"Reason: $responseContent")
System.err.println(s"Response headers: ${headers.mkString(", ")}")
error.printStackTrace();
case Failure(exception) =>
System.err.println("Exception when calling CartApi#cartValidate")
exception.printStackTrace();
}
}| Name | Type | Description | Notes |
|---|---|---|---|
| validateVersion | Boolean | Specify if api2cart should validate cart version | [optional] |
ApiRequest[CartValidate200Response]
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | successful operation | - |