idosell 0.1.7 → 0.1.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/gates.def.js +89 -51
- package/dist/gates.js +10 -8
- package/dist/helpers.js +8 -0
- package/dist/methods/getPackages.js +6 -0
- package/dist/methods/getProductsAuctions.js +1 -1
- package/dist/methods/getProductsDeliveryTime.js +5 -0
- package/dist/methods/getProductsMarketingZones.js +10 -0
- package/dist/methods/getProductsOmnibusPrices.js +9 -0
- package/dist/methods/getProductsStrikethroughPrices.js +10 -0
- package/dist/methods/postReturns.js +11 -0
- package/dist/params.js +3 -1
- package/package.json +1 -1
- package/tests/getPackages.test.js +17 -0
- package/tests/getProductsDeliveryTime.test.js +17 -0
- package/tests/getProductsMarketingZones.test.js +17 -0
- package/tests/getProductsOmnibusPrices.test.js +17 -0
- package/tests/getProductsStrikethroughPrices.test.js +17 -0
- package/tests/postReturns.test.js +12 -0
package/dist/gates.def.js
CHANGED
|
@@ -1434,6 +1434,9 @@
|
|
|
1434
1434
|
* @property {(deliveryPackageNumbers: Array<String>) => GetPackagesRequest} deliveryPackageNumbers Consignments numbers.
|
|
1435
1435
|
* @property {(events: Array<Object>) => GetPackagesRequest} events Element, package is assigned to
|
|
1436
1436
|
* @property {(returnLabels: Boolean) => GetPackagesRequest} returnLabels Return parcel labels.
|
|
1437
|
+
* @property {(orderSerialNumbers: Array<Integer>) => GetPackagesRequest} orders Set type to orders with given order serial numbers
|
|
1438
|
+
* @property {(rmaIds: Array<Integer>) => GetPackagesRequest} rma Set type to rma with given rma Ids
|
|
1439
|
+
* @property {(returnIds: Array<Integer>) => GetPackagesRequest} returns Set type to returns with given return Ids
|
|
1437
1440
|
* @property {function} exec Excecute request
|
|
1438
1441
|
*/
|
|
1439
1442
|
|
|
@@ -1581,6 +1584,30 @@
|
|
|
1581
1584
|
* @property {function} exec Excecute request
|
|
1582
1585
|
*/
|
|
1583
1586
|
|
|
1587
|
+
/**
|
|
1588
|
+
* @typedef {Object} GetProductsBrandsFilterRequest
|
|
1589
|
+
* @property {(shopId: Integer) => GetProductsBrandsFilterRequest} shopId Shop Id
|
|
1590
|
+
* @property {(languageId: String) => GetProductsBrandsFilterRequest} languageId Language ID (code in ISO 639-2).
|
|
1591
|
+
* @property {(producerId: Integer) => GetProductsBrandsFilterRequest} producerId Brand ID
|
|
1592
|
+
* @property {function} exec Excecute request
|
|
1593
|
+
*/
|
|
1594
|
+
|
|
1595
|
+
/**
|
|
1596
|
+
* @typedef {Object} PutProductsBrandsFilterRequest
|
|
1597
|
+
* @property {(shopId: Integer) => PutProductsBrandsFilterRequest} shopId Shop Id
|
|
1598
|
+
* @property {(languageId: String) => PutProductsBrandsFilterRequest} languageId Language ID (code in ISO 639-2).
|
|
1599
|
+
* @property {(producerId: Integer) => PutProductsBrandsFilterRequest} producerId Brand ID
|
|
1600
|
+
* @property {(filterForNodeIsDefault: 'y'|'n') => PutProductsBrandsFilterRequest} filterForNodeIsDefault
|
|
1601
|
+
* @property {(filtersActive: Array<Object>) => PutProductsBrandsFilterRequest} filtersActive Active filters.
|
|
1602
|
+
* @property {(filterId: String) => PutProductsBrandsFilterRequest} filterId Menu filter ID.
|
|
1603
|
+
* @property {(filterName: String) => PutProductsBrandsFilterRequest} filterName Filter name on page.
|
|
1604
|
+
* @property {(filterDisplay: 'name'|'gfx'|'namegfx') => PutProductsBrandsFilterRequest} filterDisplay Display as: "name" - text, "gfx" - graphics, "namegfx" - text and graphics.
|
|
1605
|
+
* @property {(filterValueSort: 'y'|'n'|'priority') => PutProductsBrandsFilterRequest} filterValueSort Sort by: "y" - alfabetically, "n" - by frequency and order of occurrence of indicated parameter value in found products, "priority" - according to value sequence in parameter.
|
|
1606
|
+
* @property {(filterDefaultEnabled: 'y'|'n') => PutProductsBrandsFilterRequest} filterDefaultEnabled Enabled by default .
|
|
1607
|
+
* @property {function} append Append current data to array and start modifying next row
|
|
1608
|
+
* @property {function} exec Excecute request
|
|
1609
|
+
*/
|
|
1610
|
+
|
|
1584
1611
|
/**
|
|
1585
1612
|
* @typedef {Object} GetProductsBrandsRequest
|
|
1586
1613
|
* @property {(results_page: Integer) => GetProductsBrandsRequest} results_page Result page number.
|
|
@@ -1610,30 +1637,6 @@
|
|
|
1610
1637
|
* @property {function} exec Excecute request
|
|
1611
1638
|
*/
|
|
1612
1639
|
|
|
1613
|
-
/**
|
|
1614
|
-
* @typedef {Object} GetProductsBrandsFilterRequest
|
|
1615
|
-
* @property {(shopId: Integer) => GetProductsBrandsFilterRequest} shopId Shop Id
|
|
1616
|
-
* @property {(languageId: String) => GetProductsBrandsFilterRequest} languageId Language ID (code in ISO 639-2).
|
|
1617
|
-
* @property {(producerId: Integer) => GetProductsBrandsFilterRequest} producerId Brand ID
|
|
1618
|
-
* @property {function} exec Excecute request
|
|
1619
|
-
*/
|
|
1620
|
-
|
|
1621
|
-
/**
|
|
1622
|
-
* @typedef {Object} PutProductsBrandsFilterRequest
|
|
1623
|
-
* @property {(shopId: Integer) => PutProductsBrandsFilterRequest} shopId Shop Id
|
|
1624
|
-
* @property {(languageId: String) => PutProductsBrandsFilterRequest} languageId Language ID (code in ISO 639-2).
|
|
1625
|
-
* @property {(producerId: Integer) => PutProductsBrandsFilterRequest} producerId Brand ID
|
|
1626
|
-
* @property {(filterForNodeIsDefault: 'y'|'n') => PutProductsBrandsFilterRequest} filterForNodeIsDefault
|
|
1627
|
-
* @property {(filtersActive: Array<Object>) => PutProductsBrandsFilterRequest} filtersActive Active filters.
|
|
1628
|
-
* @property {(filterId: String) => PutProductsBrandsFilterRequest} filterId Menu filter ID.
|
|
1629
|
-
* @property {(filterName: String) => PutProductsBrandsFilterRequest} filterName Filter name on page.
|
|
1630
|
-
* @property {(filterDisplay: 'name'|'gfx'|'namegfx') => PutProductsBrandsFilterRequest} filterDisplay Display as: "name" - text, "gfx" - graphics, "namegfx" - text and graphics.
|
|
1631
|
-
* @property {(filterValueSort: 'y'|'n'|'priority') => PutProductsBrandsFilterRequest} filterValueSort Sort by: "y" - alfabetically, "n" - by frequency and order of occurrence of indicated parameter value in found products, "priority" - according to value sequence in parameter.
|
|
1632
|
-
* @property {(filterDefaultEnabled: 'y'|'n') => PutProductsBrandsFilterRequest} filterDefaultEnabled Enabled by default .
|
|
1633
|
-
* @property {function} append Append current data to array and start modifying next row
|
|
1634
|
-
* @property {function} exec Excecute request
|
|
1635
|
-
*/
|
|
1636
|
-
|
|
1637
1640
|
/**
|
|
1638
1641
|
* @typedef {Object} PostProductsBundlesRequest
|
|
1639
1642
|
* @property {(params: Array<Object>) => PostProductsBundlesRequest} params Parameters transmitted to method
|
|
@@ -1774,6 +1777,12 @@
|
|
|
1774
1777
|
* @typedef {Object} GetProductsDeliveryTimeRequest
|
|
1775
1778
|
* @property {(stockId: Integer) => GetProductsDeliveryTimeRequest} stockId Stock ID
|
|
1776
1779
|
* @property {(isCollectionInPerson: Boolean) => GetProductsDeliveryTimeRequest} isCollectionInPerson Should products be prepared for personal collection?
|
|
1780
|
+
* @property {(products: Array<Object>) => GetProductsDeliveryTimeRequest} products
|
|
1781
|
+
* @property {(productId: Integer) => GetProductsDeliveryTimeRequest} productId Product Id
|
|
1782
|
+
* @property {(sizeId: Integer) => GetProductsDeliveryTimeRequest} sizeId Size identifier
|
|
1783
|
+
* @property {(sizePanelName: String) => GetProductsDeliveryTimeRequest} sizePanelName Size name
|
|
1784
|
+
* @property {(productIndex: String) => GetProductsDeliveryTimeRequest} productIndex Product IAI code
|
|
1785
|
+
* @property {(productSizeQuantity: Integer) => GetProductsDeliveryTimeRequest} productSizeQuantity Product quantity.
|
|
1777
1786
|
* @property {function} exec Excecute request
|
|
1778
1787
|
*/
|
|
1779
1788
|
|
|
@@ -1917,6 +1926,7 @@
|
|
|
1917
1926
|
/**
|
|
1918
1927
|
* @typedef {Object} GetProductsMarketingZonesRequest
|
|
1919
1928
|
* @property {(products: Array<Object>) => GetProductsMarketingZonesRequest} products Products list.
|
|
1929
|
+
* @property {(productId: Integer, sizeId: Integer|String, type: 'id'|'index'|'codeExtern'|'codeProducer') => GetProductsStrikethroughPricesRequest} productId Set product and size identifiers
|
|
1920
1930
|
* @property {function} exec Excecute request
|
|
1921
1931
|
*/
|
|
1922
1932
|
|
|
@@ -1937,6 +1947,7 @@
|
|
|
1937
1947
|
/**
|
|
1938
1948
|
* @typedef {Object} GetProductsOmnibusPricesRequest
|
|
1939
1949
|
* @property {(products: Array<Object>) => GetProductsOmnibusPricesRequest} products Products list.
|
|
1950
|
+
* @property {(productId: Integer, sizeId: Integer|String, type: 'id'|'index'|'codeExtern'|'codeProducer') => GetProductsStrikethroughPricesRequest} productId Set product and size identifiers
|
|
1940
1951
|
* @property {function} exec Excecute request
|
|
1941
1952
|
*/
|
|
1942
1953
|
|
|
@@ -2041,6 +2052,7 @@
|
|
|
2041
2052
|
* @property {(item_text_ids: Array<Object>) => PutProductsParametersRequest} item_text_ids Element text ID - can be entered instead of "id". Recognized save format: "section" (without backslash), "parameter\" (parameter without assigned value).
|
|
2042
2053
|
* @property {(names: Array<Object>) => PutProductsParametersRequest} names Names of section, parameter or value.
|
|
2043
2054
|
* @property {(descriptions: Array<Object>) => PutProductsParametersRequest} descriptions Descriptions of section, parameter or value.
|
|
2055
|
+
* @property {(search_description: Array<Object>) => PutProductsParametersRequest} search_description Search descriptions of parameter value.
|
|
2044
2056
|
* @property {(card_icons: Array<Object>) => PutProductsParametersRequest} card_icons Icons of section, parameter or value to display on the product card.
|
|
2045
2057
|
* @property {(link_icons: Array<Object>) => PutProductsParametersRequest} link_icons Icons of section, parameter or value to display on the list of products.
|
|
2046
2058
|
* @property {(context_id: String) => PutProductsParametersRequest} context_id Parameter's additional feature. 1. Status: context_id = "CONTEXT_STATE" Takes values context_value_id: - CONTEXT_STATE_NEW - New, - CONTEXT_STATE_USED - Used, - CONTEXT_STATE_REFURBISHED_BY_PRODUCER - Renewed by a manufacturer, - CONTEXT_STATE_REFURBISHED_BY_SELLER - Renewed by a seller, - CONTEXT_STATE_FOR_PARTS_OR_BROKEN - In parts or damaged. 2. Product weight in grams: context_id = "CONTEXT_STD_UNIT_WEIGHT" Takes values context_value_id: - Value of additional feature is set automatically basing on the parameter's value. 3. A product's value in milliliters: context_id = "CONTEXT_STD_UNIT_VOLUME" Takes values context_value_id: - Value of additional feature is set automatically basing on the parameter's value. 4. Sex: context_id = "CONTEXT_SEX" Takes values context_value_id: - CONTEXT_SEX_MAN - Man, - CONTEXT_SEX_WOMAN - Woman, - CONTEXT_SEX_UNISEX - Unisex. 5. Age group: context_id = "CONTEXT_AGE_GROUP" Takes values context_value_id: - CONTEXT_AGE_GROUP_ADULT - Adults, - CONTEXT_AGE_GROUP_MINOR - Children. 6. Maximum number of products in an order: context_id = "CONTEXT_MAX_QUANTITY_PER_RETAIL_ORDER" Takes values context_value_id: - Value of additional feature is set automatically basing on the parameter's value. 7. Maximum number of products in a wholesale order: context_id = "CONTEXT_MAX_QUANTITY_PER_WHOLESALE_ORDER" Takes values context_value_id: - Value of additional feature is set automatically basing on the parameter's value. 8. Minimal number of products in an order: context_id = "CONTEXT_MIN_QUANTITY_PER_RETAIL_ORDER" Takes values context_value_id: - Value of additional feature is set automatically basing on the parameter's value. 9. Minimum number of products in a wholesale order: context_id = "CONTEXT_MIN_QUANTITY_PER_WHOLESALE_ORDER" Takes values context_value_id: - Value of additional feature is set automatically basing on the parameter's value. 10. Maximal number of a single size in an order: context_id = "CONTEXT_MAX_SIZE_QUANTITY_PER_RETAIL_ORDER" Takes values context_value_id: - Value of additional feature is set automatically basing on the parameter's value. 11. Maximal number of a single size in a wholesale order: context_id = "CONTEXT_MAX_SIZE_QUANTITY_PER_WHOLESALE_ORDER" Takes values context_value_id: - Value of additional feature is set automatically basing on the parameter's value. 12. Minimal number of a single size in an order: context_id = "CONTEXT_MIN_SIZE_QUANTITY_PER_RETAIL_ORDER" Takes values context_value_id: - Value of additional feature is set automatically basing on the parameter's value. 13. Minimal number of a single size in a wholesale order: context_id = "CONTEXT_MIN_SIZE_QUANTITY_PER_WHOLESALE_ORDER" Takes values context_value_id: - Value of additional feature is set automatically basing on the parameter's value. 14. Net weight: context_id = "CONTEXT_WEIGHT_NET" Takes values context_value_id: - Value of additional feature is set automatically basing on the parameter's value. 15. Color: context_id = "CONTEXT_COLOR" Takes values context_value_id: - Value of additional feature is set automatically basing on the parameter's value. 16. #!TylkoDlaDoroslych!#: context_id = "CONTEXT_ONLY_ADULTS" Takes values context_value_id: - CONTEXT_ONLY_ADULTS_YES - yes, - CONTEXT_ONLY_ADULTS_NO - no. 17. Prescription drug: context_id = "CONTEXT_PRESCRIPTION_MEDICINE" Takes values context_value_id: - CONTEXT_PRESCRIPTION_MEDICINE_YES - yes, - CONTEXT_PRESCRIPTION_MEDICINE_NO - no. 18. Season Rate: context_id = "CONTEXT_SEASON" Takes values context_value_id: - CONTEXT_SEASON_SPRING - Spring, - CONTEXT_SEASON_SUMMER - Summer, - CONTEXT_SEASON_FALL - Autumn, - CONTEXT_SEASON_WINTER - Winter, - CONTEXT_SEASON_SPRING_SUMMER - Spring/Summer, - CONTEXT_SEASON_FALL_WINTER - Autumn/Winter.
|
|
@@ -2462,29 +2474,6 @@
|
|
|
2462
2474
|
* @property {function} exec Excecute request
|
|
2463
2475
|
*/
|
|
2464
2476
|
|
|
2465
|
-
/**
|
|
2466
|
-
* @typedef {Object} GetProductsSeriesRequest
|
|
2467
|
-
* @property {(return_last_changed_time: String) => GetProductsSeriesRequest} return_last_changed_time With "y" value it returns the last series modification date in YYYY-MM-DD HH:MM:SS format.
|
|
2468
|
-
* @property {(ids: Array<Integer>) => GetProductsSeriesRequest} ids IDs
|
|
2469
|
-
* @property {(names: Array<String>) => GetProductsSeriesRequest} names Names
|
|
2470
|
-
* @property {(languagesIds: Array<String>) => GetProductsSeriesRequest} languagesIds List of languages
|
|
2471
|
-
* @property {(resultsPage: Integer) => GetProductsSeriesRequest} resultsPage Page with results number. Numeration starts from 0
|
|
2472
|
-
* @property {(resultsLimit: Integer) => GetProductsSeriesRequest} resultsLimit Number of results on page. Value from 1 to 100
|
|
2473
|
-
* @property {(page: Integer, limit: Integer) => GetProductsSeriesRequest} page Define page number and maximum results per page
|
|
2474
|
-
* @property {() => Integer} count Returns total numer of results
|
|
2475
|
-
* @property {function} exec Excecute request
|
|
2476
|
-
*/
|
|
2477
|
-
|
|
2478
|
-
/**
|
|
2479
|
-
* @typedef {Object} PutProductsSeriesRequest
|
|
2480
|
-
* @property {(series: Array<Object>) => PutProductsSeriesRequest} series Series list.
|
|
2481
|
-
* @property {(id: Integer) => PutProductsSeriesRequest} id Id
|
|
2482
|
-
* @property {(nameInPanel: String) => PutProductsSeriesRequest} nameInPanel Name in panel
|
|
2483
|
-
* @property {(shopsConfigurations: Array<Object>) => PutProductsSeriesRequest} shopsConfigurations
|
|
2484
|
-
* @property {function} append Append current data to array and start modifying next row
|
|
2485
|
-
* @property {function} exec Excecute request
|
|
2486
|
-
*/
|
|
2487
|
-
|
|
2488
2477
|
/**
|
|
2489
2478
|
* @typedef {Object} GetProductsSeriesFilterRequest
|
|
2490
2479
|
* @property {(shopId: Integer) => GetProductsSeriesFilterRequest} shopId Shop Id
|
|
@@ -2509,6 +2498,29 @@
|
|
|
2509
2498
|
* @property {function} exec Excecute request
|
|
2510
2499
|
*/
|
|
2511
2500
|
|
|
2501
|
+
/**
|
|
2502
|
+
* @typedef {Object} GetProductsSeriesRequest
|
|
2503
|
+
* @property {(return_last_changed_time: String) => GetProductsSeriesRequest} return_last_changed_time With "y" value it returns the last series modification date in YYYY-MM-DD HH:MM:SS format.
|
|
2504
|
+
* @property {(ids: Array<Integer>) => GetProductsSeriesRequest} ids IDs
|
|
2505
|
+
* @property {(names: Array<String>) => GetProductsSeriesRequest} names Names
|
|
2506
|
+
* @property {(languagesIds: Array<String>) => GetProductsSeriesRequest} languagesIds List of languages
|
|
2507
|
+
* @property {(resultsPage: Integer) => GetProductsSeriesRequest} resultsPage Page with results number. Numeration starts from 0
|
|
2508
|
+
* @property {(resultsLimit: Integer) => GetProductsSeriesRequest} resultsLimit Number of results on page. Value from 1 to 100
|
|
2509
|
+
* @property {(page: Integer, limit: Integer) => GetProductsSeriesRequest} page Define page number and maximum results per page
|
|
2510
|
+
* @property {() => Integer} count Returns total numer of results
|
|
2511
|
+
* @property {function} exec Excecute request
|
|
2512
|
+
*/
|
|
2513
|
+
|
|
2514
|
+
/**
|
|
2515
|
+
* @typedef {Object} PutProductsSeriesRequest
|
|
2516
|
+
* @property {(series: Array<Object>) => PutProductsSeriesRequest} series Series list.
|
|
2517
|
+
* @property {(id: Integer) => PutProductsSeriesRequest} id Id
|
|
2518
|
+
* @property {(nameInPanel: String) => PutProductsSeriesRequest} nameInPanel Name in panel
|
|
2519
|
+
* @property {(shopsConfigurations: Array<Object>) => PutProductsSeriesRequest} shopsConfigurations
|
|
2520
|
+
* @property {function} append Append current data to array and start modifying next row
|
|
2521
|
+
* @property {function} exec Excecute request
|
|
2522
|
+
*/
|
|
2523
|
+
|
|
2512
2524
|
/**
|
|
2513
2525
|
* @typedef {Object} DeleteProductsSizesRequest
|
|
2514
2526
|
* @property {(mode: 'delete_by_size'|'delete_all') => DeleteProductsSizesRequest} mode Edition mode
|
|
@@ -2574,6 +2586,7 @@
|
|
|
2574
2586
|
/**
|
|
2575
2587
|
* @typedef {Object} GetProductsStrikethroughPricesRequest
|
|
2576
2588
|
* @property {(products: Array<Object>) => GetProductsStrikethroughPricesRequest} products Products list.
|
|
2589
|
+
* @property {(productId: Integer, sizeId: Integer|String, type: 'id'|'index'|'codeExtern'|'codeProducer') => GetProductsStrikethroughPricesRequest} productId Set product and size identifiers
|
|
2577
2590
|
* @property {function} exec Excecute request
|
|
2578
2591
|
*/
|
|
2579
2592
|
|
|
@@ -2721,6 +2734,30 @@
|
|
|
2721
2734
|
* @property {function} exec Excecute request
|
|
2722
2735
|
*/
|
|
2723
2736
|
|
|
2737
|
+
/**
|
|
2738
|
+
* @typedef {Object} PostReturnsRequest
|
|
2739
|
+
* @property {(order_sn: Integer) => PostReturnsRequest} order_sn Order serial number
|
|
2740
|
+
* @property {(stock_id: Integer) => PostReturnsRequest} stock_id
|
|
2741
|
+
* @property {(products: Array<Object>) => PostReturnsRequest} products Products list.
|
|
2742
|
+
* @property {(status: Integer) => PostReturnsRequest} status
|
|
2743
|
+
* @property {(client_received: Boolean) => PostReturnsRequest} client_received
|
|
2744
|
+
* @property {(change_status: Boolean) => PostReturnsRequest} change_status
|
|
2745
|
+
* @property {(courier_id: Integer) => PostReturnsRequest} courier_id
|
|
2746
|
+
* @property {(return_operator: String) => PostReturnsRequest} return_operator
|
|
2747
|
+
* @property {(tryCorrectInvoice: Boolean) => PostReturnsRequest} tryCorrectInvoice
|
|
2748
|
+
* @property {(include_shipping_cost: String) => PostReturnsRequest} include_shipping_cost
|
|
2749
|
+
* @property {(additional_payment_cost: String) => PostReturnsRequest} additional_payment_cost
|
|
2750
|
+
* @property {(emptyReturn: 'n'|'y') => PostReturnsRequest} emptyReturn
|
|
2751
|
+
* @property {(id: Integer) => PostReturnsRequest} id
|
|
2752
|
+
* @property {(size: String) => PostReturnsRequest} size
|
|
2753
|
+
* @property {(quantity: Number) => PostReturnsRequest} quantity
|
|
2754
|
+
* @property {(price: Number) => PostReturnsRequest} price Price.
|
|
2755
|
+
* @property {(serialNumbers: Array<String>) => PostReturnsRequest} serialNumbers
|
|
2756
|
+
* @property {(productOrderAdditional: String) => PostReturnsRequest} productOrderAdditional Additional information.
|
|
2757
|
+
* @property {function} append Append current data to array and start modifying next row
|
|
2758
|
+
* @property {function} exec Excecute request
|
|
2759
|
+
*/
|
|
2760
|
+
|
|
2724
2761
|
/**
|
|
2725
2762
|
* @typedef {Object} PutReturnsRequest
|
|
2726
2763
|
* @property {(returns: Array<Object>) => PutReturnsRequest} returns
|
|
@@ -3403,11 +3440,11 @@
|
|
|
3403
3440
|
* @property {PutProductsAttachmentsRequest} putProductsAttachments Method that enables adding and editing product attachments.
|
|
3404
3441
|
* @property {GetProductsAuctionsRequest} getProductsAuctions Allows for downloading information about auctions and auction categories to which the product has been assigned (for a maximum of 100 products in one request)
|
|
3405
3442
|
* @property {DeleteProductsBrandsRequest} deleteProductsBrands The method allows you to remove brands from the administration panel.
|
|
3443
|
+
* @property {GetProductsBrandsFilterRequest} getProductsBrandsFilter The method allows you to download a list of filters for brands (manufacturers) available in the IdoSell administration panel.
|
|
3444
|
+
* @property {PutProductsBrandsFilterRequest} putProductsBrandsFilter The method allows you to manage filter settings for brands (manufacturers).
|
|
3406
3445
|
* @property {GetProductsBrandsRequest} getProductsBrands Method that returns information about brands available in the IdoSell Shop administration panel.
|
|
3407
3446
|
* @property {PostProductsBrandsRequest} postProductsBrands The method allows you to update brands information available in the administration panel.
|
|
3408
3447
|
* @property {PutProductsBrandsRequest} putProductsBrands The method allows you to update brands information available in the administration panel.
|
|
3409
|
-
* @property {GetProductsBrandsFilterRequest} getProductsBrandsFilter The method allows you to download a list of filters for brands (manufacturers) available in the IdoSell administration panel.
|
|
3410
|
-
* @property {PutProductsBrandsFilterRequest} putProductsBrandsFilter The method allows you to manage filter settings for brands (manufacturers).
|
|
3411
3448
|
* @property {PostProductsBundlesRequest} postProductsBundles createBundle method allows to create a new product with a type: set and to assign existing products as a set components. Products added via this gate are hidden from the shop customer by default. To change the visibility of created products use the gate setProducts or set it on a product card in the shop administration panel
|
|
3412
3449
|
* @property {DeleteProductsBundlesProductsRequest} deleteProductsBundlesProducts removeProductsFromBundle method allows to remove indicated set components
|
|
3413
3450
|
* @property {PostProductsBundlesProductsRequest} postProductsBundlesProducts addProductsToBundle method allows to add components to existing sets in the administration panel
|
|
@@ -3462,10 +3499,10 @@
|
|
|
3462
3499
|
* @property {GetProductsReservationsRequest} getProductsReservations It allows to download information about product reservations in orders (for up to 100 products in one request).
|
|
3463
3500
|
* @property {PostProductsRestoreRequest} postProductsRestore The method is used to restore deleted products
|
|
3464
3501
|
* @property {DeleteProductsSeriesRequest} deleteProductsSeries Method allows you to delete a series of products available in the IdoSell administration panel.
|
|
3465
|
-
* @property {GetProductsSeriesRequest} getProductsSeries Method returns information about the product series available in the IdoSell administration panel.
|
|
3466
|
-
* @property {PutProductsSeriesRequest} putProductsSeries Method allows you to update information about product series available in the IdoSell administration panel.
|
|
3467
3502
|
* @property {GetProductsSeriesFilterRequest} getProductsSeriesFilter Method allows you to retrieve a list of filters for a series of products available in the IdoSell administration panel..
|
|
3468
3503
|
* @property {PutProductsSeriesFilterRequest} putProductsSeriesFilter The method allows you to manage the filter settings for the series..
|
|
3504
|
+
* @property {GetProductsSeriesRequest} getProductsSeries Method returns information about the product series available in the IdoSell administration panel.
|
|
3505
|
+
* @property {PutProductsSeriesRequest} putProductsSeries Method allows you to update information about product series available in the IdoSell administration panel.
|
|
3469
3506
|
* @property {DeleteProductsSizesRequest} deleteProductsSizes The method is used to remove sizes
|
|
3470
3507
|
* @property {GetProductsSizesRequest} getProductsSizes Method that returns information about product sizes configured in the administration panel
|
|
3471
3508
|
* @property {PutProductsSizesRequest} putProductsSizes This method allows you to edit the size-dependent data
|
|
@@ -3488,6 +3525,7 @@
|
|
|
3488
3525
|
* @property {GetRefundsRetrieveRefundsListRequest} getRefundsRetrieveRefundsList Method returns a list of incomplete refunds.
|
|
3489
3526
|
* @property {PutRefundsUpdateRefundRequest} putRefundsUpdateRefund Method allows you to update refund.
|
|
3490
3527
|
* @property {GetReturnsRequest} getReturns Method that enables getting information about returns issued for orders in the administration panel.
|
|
3528
|
+
* @property {PostReturnsRequest} postReturns
|
|
3491
3529
|
* @property {PutReturnsRequest} putReturns Method that enables editing returns issued for orders in the administration panel.
|
|
3492
3530
|
* @property {PutReturnsSerialNumberRequest} putReturnsSerialNumber Method that enables setting serial numbers for products included in returns issued for orders in the administration panel.
|
|
3493
3531
|
* @property {GetReturnsStatusesRequest} getReturnsStatuses Allows to download all configurable return statuses
|
package/dist/gates.js
CHANGED
|
@@ -134,11 +134,11 @@ import getProductsSKUbyBarcode from "./methods/getProductsSKUbyBarcode.js";
|
|
|
134
134
|
import putProductsAttachments from "./methods/putProductsAttachments.js";
|
|
135
135
|
import getProductsAuctions from "./methods/getProductsAuctions.js";
|
|
136
136
|
import deleteProductsBrands from "./methods/deleteProductsBrands.js";
|
|
137
|
+
import getProductsBrandsFilter from "./methods/getProductsBrandsFilter.js";
|
|
138
|
+
import putProductsBrandsFilter from "./methods/putProductsBrandsFilter.js";
|
|
137
139
|
import getProductsBrands from "./methods/getProductsBrands.js";
|
|
138
140
|
import postProductsBrands from "./methods/postProductsBrands.js";
|
|
139
141
|
import putProductsBrands from "./methods/putProductsBrands.js";
|
|
140
|
-
import getProductsBrandsFilter from "./methods/getProductsBrandsFilter.js";
|
|
141
|
-
import putProductsBrandsFilter from "./methods/putProductsBrandsFilter.js";
|
|
142
142
|
import postProductsBundles from "./methods/postProductsBundles.js";
|
|
143
143
|
import deleteProductsBundlesProducts from "./methods/deleteProductsBundlesProducts.js";
|
|
144
144
|
import postProductsBundlesProducts from "./methods/postProductsBundlesProducts.js";
|
|
@@ -193,10 +193,10 @@ import putProductsQuestions from "./methods/putProductsQuestions.js";
|
|
|
193
193
|
import getProductsReservations from "./methods/getProductsReservations.js";
|
|
194
194
|
import postProductsRestore from "./methods/postProductsRestore.js";
|
|
195
195
|
import deleteProductsSeries from "./methods/deleteProductsSeries.js";
|
|
196
|
-
import getProductsSeries from "./methods/getProductsSeries.js";
|
|
197
|
-
import putProductsSeries from "./methods/putProductsSeries.js";
|
|
198
196
|
import getProductsSeriesFilter from "./methods/getProductsSeriesFilter.js";
|
|
199
197
|
import putProductsSeriesFilter from "./methods/putProductsSeriesFilter.js";
|
|
198
|
+
import getProductsSeries from "./methods/getProductsSeries.js";
|
|
199
|
+
import putProductsSeries from "./methods/putProductsSeries.js";
|
|
200
200
|
import deleteProductsSizes from "./methods/deleteProductsSizes.js";
|
|
201
201
|
import getProductsSizes from "./methods/getProductsSizes.js";
|
|
202
202
|
import putProductsSizes from "./methods/putProductsSizes.js";
|
|
@@ -219,6 +219,7 @@ import getRefundsGetRefundStatus from "./methods/getRefundsGetRefundStatus.js";
|
|
|
219
219
|
import getRefundsRetrieveRefundsList from "./methods/getRefundsRetrieveRefundsList.js";
|
|
220
220
|
import putRefundsUpdateRefund from "./methods/putRefundsUpdateRefund.js";
|
|
221
221
|
import getReturns from "./methods/getReturns.js";
|
|
222
|
+
import postReturns from "./methods/postReturns.js";
|
|
222
223
|
import putReturns from "./methods/putReturns.js";
|
|
223
224
|
import putReturnsSerialNumber from "./methods/putReturnsSerialNumber.js";
|
|
224
225
|
import getReturnsStatuses from "./methods/getReturnsStatuses.js";
|
|
@@ -409,11 +410,11 @@ const gates = {
|
|
|
409
410
|
putProductsAttachments,
|
|
410
411
|
getProductsAuctions,
|
|
411
412
|
deleteProductsBrands,
|
|
413
|
+
getProductsBrandsFilter,
|
|
414
|
+
putProductsBrandsFilter,
|
|
412
415
|
getProductsBrands,
|
|
413
416
|
postProductsBrands,
|
|
414
417
|
putProductsBrands,
|
|
415
|
-
getProductsBrandsFilter,
|
|
416
|
-
putProductsBrandsFilter,
|
|
417
418
|
postProductsBundles,
|
|
418
419
|
deleteProductsBundlesProducts,
|
|
419
420
|
postProductsBundlesProducts,
|
|
@@ -468,10 +469,10 @@ const gates = {
|
|
|
468
469
|
getProductsReservations,
|
|
469
470
|
postProductsRestore,
|
|
470
471
|
deleteProductsSeries,
|
|
471
|
-
getProductsSeries,
|
|
472
|
-
putProductsSeries,
|
|
473
472
|
getProductsSeriesFilter,
|
|
474
473
|
putProductsSeriesFilter,
|
|
474
|
+
getProductsSeries,
|
|
475
|
+
putProductsSeries,
|
|
475
476
|
deleteProductsSizes,
|
|
476
477
|
getProductsSizes,
|
|
477
478
|
putProductsSizes,
|
|
@@ -494,6 +495,7 @@ const gates = {
|
|
|
494
495
|
getRefundsRetrieveRefundsList,
|
|
495
496
|
putRefundsUpdateRefund,
|
|
496
497
|
getReturns,
|
|
498
|
+
postReturns,
|
|
497
499
|
putReturns,
|
|
498
500
|
putReturnsSerialNumber,
|
|
499
501
|
getReturnsStatuses,
|
package/dist/helpers.js
CHANGED
|
@@ -164,6 +164,14 @@ export const modifyPrice = (value, type, net, priceChangeMode = 'amount_set') =>
|
|
|
164
164
|
return params;
|
|
165
165
|
}
|
|
166
166
|
|
|
167
|
+
export const getProductIdent = (productId, sizeId, type = 'id') => {
|
|
168
|
+
const params = { ident: { type, value: productId }};
|
|
169
|
+
if (sizeId) {
|
|
170
|
+
params.sizes = [{ ident: { type, value: sizeId }}]
|
|
171
|
+
}
|
|
172
|
+
return params;
|
|
173
|
+
}
|
|
174
|
+
|
|
167
175
|
const TEXT_NODES = {
|
|
168
176
|
name: {
|
|
169
177
|
main: 'productNames',
|
|
@@ -2,6 +2,12 @@ import { paramsProxy } from "../params.js";
|
|
|
2
2
|
|
|
3
3
|
export default (object) => {
|
|
4
4
|
object.gate = { method: 'get', node: '/packages/packages' };
|
|
5
|
+
object.auth.version = 1;
|
|
6
|
+
object.custom = {
|
|
7
|
+
orders: (orderSerialNumbers) => ({ eventType: "order", eventsIds: Array.isArray(orderSerialNumbers) ? orderSerialNumbers : [orderSerialNumbers] }),
|
|
8
|
+
rma: (rmaIds) => ({ eventType: "rma", eventsIds: Array.isArray(rmaIds) ? rmaIds : [rmaIds] }),
|
|
9
|
+
returns: (returnIds) => ({ eventType: "return", eventsIds: Array.isArray(returnIds) ? returnIds : [returnIds] })
|
|
10
|
+
};
|
|
5
11
|
object.appendable = {
|
|
6
12
|
except: ["deliveryPackageNumbers","returnLabels"],
|
|
7
13
|
arrayNode: "events",
|
|
@@ -5,7 +5,7 @@ export default (object) => {
|
|
|
5
5
|
object.gate = { method: 'get', node: '/products/auctions' };
|
|
6
6
|
object.custom = {
|
|
7
7
|
ids: arrayOfObjects("products", "identValue", {"identType":"id"}),
|
|
8
|
-
fromAllegro: () => { const auctionSites = object.params.
|
|
8
|
+
fromAllegro: () => { const auctionSites = object.params[object.appendable.index]; console.log("auctionSites"); auctionSites.push("allegro"); return { auctionSites }},
|
|
9
9
|
page
|
|
10
10
|
};
|
|
11
11
|
return new Proxy(object, paramsProxy);
|
|
@@ -2,5 +2,10 @@ import { paramsProxy } from "../params.js";
|
|
|
2
2
|
|
|
3
3
|
export default (object) => {
|
|
4
4
|
object.gate = { method: 'get', node: '/products/deliveryTime' };
|
|
5
|
+
object.appendable = {
|
|
6
|
+
except: [],
|
|
7
|
+
arrayNode: "products",
|
|
8
|
+
index: 0
|
|
9
|
+
}
|
|
5
10
|
return new Proxy(object, paramsProxy);
|
|
6
11
|
}
|
|
@@ -1,6 +1,16 @@
|
|
|
1
1
|
import { paramsProxy } from "../params.js";
|
|
2
|
+
import { getProductIdent } from "../helpers.js";
|
|
2
3
|
|
|
3
4
|
export default (object) => {
|
|
4
5
|
object.gate = { method: 'get', node: '/products/marketingZones' };
|
|
6
|
+
object.auth.version = 1;
|
|
7
|
+
object.custom = {
|
|
8
|
+
productId: getProductIdent
|
|
9
|
+
};
|
|
10
|
+
object.appendable = {
|
|
11
|
+
except: [],
|
|
12
|
+
arrayNode: "products",
|
|
13
|
+
index: 0
|
|
14
|
+
}
|
|
5
15
|
return new Proxy(object, paramsProxy);
|
|
6
16
|
}
|
|
@@ -1,6 +1,15 @@
|
|
|
1
1
|
import { paramsProxy } from "../params.js";
|
|
2
|
+
import { getProductIdent } from "../helpers.js";
|
|
2
3
|
|
|
3
4
|
export default (object) => {
|
|
4
5
|
object.gate = { method: 'get', node: '/products/omnibusPrices' };
|
|
6
|
+
object.custom = {
|
|
7
|
+
productId: getProductIdent
|
|
8
|
+
};
|
|
9
|
+
object.appendable = {
|
|
10
|
+
except: [],
|
|
11
|
+
arrayNode: "products",
|
|
12
|
+
index: 0
|
|
13
|
+
}
|
|
5
14
|
return new Proxy(object, paramsProxy);
|
|
6
15
|
}
|
|
@@ -1,6 +1,16 @@
|
|
|
1
1
|
import { paramsProxy } from "../params.js";
|
|
2
|
+
import { getProductIdent } from "../helpers.js";
|
|
2
3
|
|
|
3
4
|
export default (object) => {
|
|
4
5
|
object.gate = { method: 'get', node: '/products/strikethroughPrices' };
|
|
6
|
+
object.auth.version = 1;
|
|
7
|
+
object.custom = {
|
|
8
|
+
productId: getProductIdent
|
|
9
|
+
};
|
|
10
|
+
object.appendable = {
|
|
11
|
+
except: [],
|
|
12
|
+
arrayNode: "products",
|
|
13
|
+
index: 0
|
|
14
|
+
}
|
|
5
15
|
return new Proxy(object, paramsProxy);
|
|
6
16
|
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { paramsProxy } from "../params.js";
|
|
2
|
+
|
|
3
|
+
export default (object) => {
|
|
4
|
+
object.gate = { method: 'post', node: '/returns/returns' };
|
|
5
|
+
object.appendable = {
|
|
6
|
+
except: ["order_sn","stock_id","status","client_received","change_status","courier_id","return_operator","tryCorrectInvoice","include_shipping_cost","additional_payment_cost","emptyReturn"],
|
|
7
|
+
arrayNode: "products",
|
|
8
|
+
index: 0
|
|
9
|
+
}
|
|
10
|
+
return new Proxy(object, paramsProxy);
|
|
11
|
+
}
|
package/dist/params.js
CHANGED
|
@@ -35,7 +35,9 @@ export const paramsProxy = {
|
|
|
35
35
|
const param = object.custom[property](...values);
|
|
36
36
|
Object.assign(object.params, param);
|
|
37
37
|
}
|
|
38
|
-
else
|
|
38
|
+
else if (property === 'params') {
|
|
39
|
+
object.params = params;
|
|
40
|
+
} else object.params[property] = values[0];
|
|
39
41
|
return new Proxy(object, paramsProxy);
|
|
40
42
|
}
|
|
41
43
|
}
|
package/package.json
CHANGED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import idosell from "./dist/index.js"
|
|
2
|
+
import { expect, test } from "vitest"
|
|
3
|
+
|
|
4
|
+
test("getPackagesOrders", () => {
|
|
5
|
+
const params = idosell().getPackages.orders([15,16]).getParams();
|
|
6
|
+
expect(params).toEqual({"events":[{"eventType":"order","eventsIds":[15,16]}]});
|
|
7
|
+
})
|
|
8
|
+
|
|
9
|
+
test("getPackagesReturns", () => {
|
|
10
|
+
const params = idosell().getPackages.returns([2]).getParams();
|
|
11
|
+
expect(params).toEqual({"events":[{"eventType":"return","eventsIds":[2]}]});
|
|
12
|
+
})
|
|
13
|
+
|
|
14
|
+
test("getPackagesRma", () => {
|
|
15
|
+
const params = idosell().getPackages.rma([1]).getParams();
|
|
16
|
+
expect(params).toEqual({"events":[{"eventType":"rma","eventsIds":[1]}]});
|
|
17
|
+
})
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import idosell from "./dist/index.js"
|
|
2
|
+
import { expect, test } from "vitest"
|
|
3
|
+
|
|
4
|
+
test("getProductsDeliveryTimeSizeId", () => {
|
|
5
|
+
const params = idosell().getProductsDeliveryTime.productId(15).sizeId(4).getParams();
|
|
6
|
+
expect(params).toEqual({"products":[{"productId":15,"sizeId":4}]});
|
|
7
|
+
})
|
|
8
|
+
|
|
9
|
+
test("getProductsDeliveryTimeProductSizeQuantity", () => {
|
|
10
|
+
const params = idosell().getProductsDeliveryTime.productId(15).sizeId(4).productSizeQuantity(3).getParams();
|
|
11
|
+
expect(params).toEqual({"products":[{"productId":15,"sizeId":4,"productSizeQuantity":3}]});
|
|
12
|
+
})
|
|
13
|
+
|
|
14
|
+
test("getProductsDeliveryTimeProductIndex", () => {
|
|
15
|
+
const params = idosell().getProductsDeliveryTime.productIndex("15-4").getParams();
|
|
16
|
+
expect(params).toEqual({"products":[{"productIndex":"15-4"}]});
|
|
17
|
+
})
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import idosell from "./dist/index.js"
|
|
2
|
+
import { expect, test } from "vitest"
|
|
3
|
+
|
|
4
|
+
test("getProductsMarketingZonesProductOnlyId", () => {
|
|
5
|
+
const params = idosell().getProductsMarketingZones.productId(33).getParams();
|
|
6
|
+
expect(params).toEqual({"products":[{"ident":{"type":"id","value":33}}]});
|
|
7
|
+
})
|
|
8
|
+
|
|
9
|
+
test("getProductsMarketingZonesSizeId", () => {
|
|
10
|
+
const params = idosell().getProductsMarketingZones.productId(15,4).getParams();
|
|
11
|
+
expect(params).toEqual({"products":[{"ident":{"type":"id","value":15},"sizes":[{"ident":{"type":"id","value":4}}]}]});
|
|
12
|
+
})
|
|
13
|
+
|
|
14
|
+
test("getProductsMarketingZonesProducts", () => {
|
|
15
|
+
const params = idosell().getProductsMarketingZones.products([{"ident":{"type":"id","value":15},"sizes":[{"ident":{"type":"id","value":4}}]}]).getParams();
|
|
16
|
+
expect(params).toEqual({"products":[{"ident":{"type":"id","value":15},"sizes":[{"ident":{"type":"id","value":4}}]}]});
|
|
17
|
+
})
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import idosell from "./dist/index.js"
|
|
2
|
+
import { expect, test } from "vitest"
|
|
3
|
+
|
|
4
|
+
test("getProductsOmnibusPricesProductOnlyId", () => {
|
|
5
|
+
const params = idosell().getProductsOmnibusPrices.productId(33).getParams();
|
|
6
|
+
expect(params).toEqual({"products":[{"ident":{"type":"id","value":33}}]});
|
|
7
|
+
})
|
|
8
|
+
|
|
9
|
+
test("getProductsOmnibusPricesProductId", () => {
|
|
10
|
+
const params = idosell().getProductsOmnibusPrices.productId(15,4).getParams();
|
|
11
|
+
expect(params).toEqual({"products":[{"ident":{"type":"id","value":15},"sizes":[{"ident":{"type":"id","value":4}}]}]});
|
|
12
|
+
})
|
|
13
|
+
|
|
14
|
+
test("getProductsOmnibusPricesProducts", () => {
|
|
15
|
+
const params = idosell().getProductsOmnibusPrices.products([{"ident":{"type":"id","value":15},"sizes":[{"ident":{"type":"id","value":4}}]}]).getParams();
|
|
16
|
+
expect(params).toEqual({"products":[{"ident":{"type":"id","value":15},"sizes":[{"ident":{"type":"id","value":4}}]}]});
|
|
17
|
+
})
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import idosell from "./dist/index.js"
|
|
2
|
+
import { expect, test } from "vitest"
|
|
3
|
+
|
|
4
|
+
test("getProductsStrikethroughPricesProductOnlyId", () => {
|
|
5
|
+
const params = idosell().getProductsStrikethroughPrices.productId(33).getParams();
|
|
6
|
+
expect(params).toEqual({"products":[{"ident":{"type":"id","value":33}}]});
|
|
7
|
+
})
|
|
8
|
+
|
|
9
|
+
test("getProductsStrikethroughPricesProductSizeId", () => {
|
|
10
|
+
const params = idosell().getProductsStrikethroughPrices.productId(15,4).getParams();
|
|
11
|
+
expect(params).toEqual({"products":[{"ident":{"type":"id","value":15},"sizes":[{"ident":{"type":"id","value":4}}]}]});
|
|
12
|
+
})
|
|
13
|
+
|
|
14
|
+
test("getProductsStrikethroughPricesProducts", () => {
|
|
15
|
+
const params = idosell().getProductsStrikethroughPrices.products([{"ident":{"type":"id","value":15},"sizes":[{"ident":{"type":"id","value":4}}]}]).getParams();
|
|
16
|
+
expect(params).toEqual({"products":[{"ident":{"type":"id","value":15},"sizes":[{"ident":{"type":"id","value":4}}]}]});
|
|
17
|
+
})
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import idosell from "./dist/index.js"
|
|
2
|
+
import { expect, test } from "vitest"
|
|
3
|
+
|
|
4
|
+
test("postReturnsStock_id", () => {
|
|
5
|
+
const params = idosell().postReturns.order_sn(4).stock_id(1).getParams();
|
|
6
|
+
expect(params).toEqual({"order_sn":4,"stock_id":1});
|
|
7
|
+
})
|
|
8
|
+
|
|
9
|
+
test("postReturnsQuantity", () => {
|
|
10
|
+
const params = idosell().postReturns.order_sn(4).stock_id(1).id(7).size("U").quantity(1).getParams();
|
|
11
|
+
expect(params).toEqual({"order_sn":4,"stock_id":1,"products":[{"id":7,"size":"U","quantity":1}]});
|
|
12
|
+
})
|