ebay-api 9.4.0 → 9.4.1
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/README.md +1 -1
- package/dist/api/apiFactory.js +5 -5
- package/dist/api/restful/buy/browse/index.js +9 -9
- package/dist/api/restful/buy/deal/index.js +3 -3
- package/dist/api/restful/buy/feed/index.js +4 -4
- package/dist/api/restful/buy/marketing/index.js +3 -3
- package/dist/api/restful/buy/marketplaceInsights/index.d.ts +1 -1
- package/dist/api/restful/buy/marketplaceInsights/index.js +3 -3
- package/dist/api/restful/buy/order/index.js +3 -3
- package/dist/api/restful/commerce/catalog/index.js +4 -4
- package/dist/api/restful/commerce/charity/index.js +2 -2
- package/dist/api/restful/commerce/identity/index.js +1 -1
- package/dist/api/restful/commerce/message/index.js +6 -6
- package/dist/api/restful/commerce/notification/index.js +7 -7
- package/dist/api/restful/commerce/taxonomy/index.d.ts +1 -1
- package/dist/api/restful/commerce/taxonomy/index.js +4 -3
- package/dist/api/restful/commerce/translation/index.js +1 -1
- package/dist/api/restful/developer/analytics/index.js +2 -2
- package/dist/api/restful/developer/keyManagement/index.js +2 -2
- package/dist/api/restful/index.js +1 -1
- package/dist/api/restful/postOrder/cancellation/index.js +3 -3
- package/dist/api/restful/postOrder/case/index.js +1 -1
- package/dist/api/restful/postOrder/inquiry/index.js +3 -3
- package/dist/api/restful/postOrder/return/index.js +7 -7
- package/dist/api/restful/sell/account/v1.js +21 -21
- package/dist/api/restful/sell/account/v2.js +1 -1
- package/dist/api/restful/sell/analytics/index.js +2 -2
- package/dist/api/restful/sell/compliance/index.js +3 -3
- package/dist/api/restful/sell/feed/index.d.ts +3 -3
- package/dist/api/restful/sell/feed/index.js +16 -16
- package/dist/api/restful/sell/finances/index.d.ts +3 -3
- package/dist/api/restful/sell/finances/index.js +14 -14
- package/dist/api/restful/sell/fulfillment/index.d.ts +1 -1
- package/dist/api/restful/sell/fulfillment/index.js +4 -4
- package/dist/api/restful/sell/inventory/index.d.ts +3 -3
- package/dist/api/restful/sell/inventory/index.js +22 -22
- package/dist/api/restful/sell/listing/index.js +1 -1
- package/dist/api/restful/sell/logistics/index.js +2 -2
- package/dist/api/restful/sell/marketing/index.js +21 -21
- package/dist/api/restful/sell/negotiation/index.js +2 -2
- package/dist/api/restful/sell/recommendation/index.js +1 -1
- package/dist/api/traditional/XMLRequest.d.ts +1 -3
- package/dist/api/traditional/XMLRequest.js +2 -4
- package/dist/auth/oAuth2.js +1 -1
- package/dist/ebay-api.min.mjs +1 -1
- package/dist/errors/index.js +2 -2
- package/dist/types/restful/specs/buy_browse_v1_oas3.d.ts +561 -111
- package/dist/types/restful/specs/buy_deal_v1_oas3.d.ts +171 -30
- package/dist/types/restful/specs/buy_feed_v1_beta_oas3.d.ts +200 -28
- package/dist/types/restful/specs/buy_marketing_v1_beta_oas3.d.ts +114 -20
- package/dist/types/restful/specs/buy_marketplace_insights_v1_beta_oas3.d.ts +52 -17
- package/dist/types/restful/specs/buy_offer_v1_beta_oas3.d.ts +84 -12
- package/dist/types/restful/specs/buy_order_v1_beta_oas3.d.ts +1478 -179
- package/dist/types/restful/specs/cancellation_oas3.d.ts +179 -9
- package/dist/types/restful/specs/case_oas3.d.ts +173 -9
- package/dist/types/restful/specs/commerce_catalog_v1_beta_oas3.d.ts +323 -75
- package/dist/types/restful/specs/commerce_charity_v1_oas3.d.ts +110 -13
- package/dist/types/restful/specs/commerce_identity_v1_oas3.d.ts +39 -6
- package/dist/types/restful/specs/commerce_media_v1_beta_oas3.d.ts +150 -23
- package/dist/types/restful/specs/commerce_notification_v1_oas3.d.ts +623 -72
- package/dist/types/restful/specs/commerce_taxonomy_v1_oas3.d.ts +339 -45
- package/dist/types/restful/specs/commerce_translation_v1_beta_oas3.d.ts +40 -8
- package/dist/types/restful/specs/developer_analytics_v1_beta_oas3.d.ts +67 -11
- package/dist/types/restful/specs/developer_key_management_v1_oas3.d.ts +134 -18
- package/dist/types/restful/specs/inquiry_oas3.d.ts +271 -13
- package/dist/types/restful/specs/return_oas3.d.ts +761 -35
- package/dist/types/restful/specs/sell_account_v1_oas3.d.ts +1503 -187
- package/dist/types/restful/specs/sell_account_v2_oas3.d.ts +155 -21
- package/dist/types/restful/specs/sell_analytics_v1_oas3.d.ts +174 -32
- package/dist/types/restful/specs/sell_compliance_v1_oas3.d.ts +128 -21
- package/dist/types/restful/specs/sell_feed_v1_oas3.d.ts +880 -103
- package/dist/types/restful/specs/sell_finances_v1_oas3.d.ts +261 -28
- package/dist/types/restful/specs/sell_fulfillment_v1_oas3.d.ts +618 -98
- package/dist/types/restful/specs/sell_inventory_v1_oas3.d.ts +1257 -210
- package/dist/types/restful/specs/sell_listing_v1_beta_oas3.d.ts +38 -9
- package/dist/types/restful/specs/sell_logistics_v1_oas3.d.ts +255 -36
- package/dist/types/restful/specs/sell_marketing_v1_oas3.d.ts +3201 -435
- package/dist/types/restful/specs/sell_metadata_v1_oas3.d.ts +361 -63
- package/dist/types/restful/specs/sell_negotiation_v1_oas3.d.ts +82 -14
- package/dist/types/restful/specs/sell_recommendation_v1_oas3.d.ts +43 -10
- package/lib/api/apiFactory.js +4 -4
- package/lib/api/restful/buy/browse/index.js +9 -9
- package/lib/api/restful/buy/deal/index.js +3 -3
- package/lib/api/restful/buy/feed/index.js +4 -4
- package/lib/api/restful/buy/marketing/index.js +3 -3
- package/lib/api/restful/buy/marketplaceInsights/index.d.ts +1 -1
- package/lib/api/restful/buy/marketplaceInsights/index.js +3 -3
- package/lib/api/restful/buy/order/index.js +3 -3
- package/lib/api/restful/commerce/catalog/index.js +4 -4
- package/lib/api/restful/commerce/charity/index.js +2 -2
- package/lib/api/restful/commerce/identity/index.js +1 -1
- package/lib/api/restful/commerce/message/index.js +6 -6
- package/lib/api/restful/commerce/notification/index.js +7 -7
- package/lib/api/restful/commerce/taxonomy/index.d.ts +1 -1
- package/lib/api/restful/commerce/taxonomy/index.js +4 -3
- package/lib/api/restful/commerce/translation/index.js +1 -1
- package/lib/api/restful/developer/analytics/index.js +2 -2
- package/lib/api/restful/developer/keyManagement/index.js +2 -2
- package/lib/api/restful/index.js +1 -1
- package/lib/api/restful/postOrder/cancellation/index.js +3 -3
- package/lib/api/restful/postOrder/case/index.js +1 -1
- package/lib/api/restful/postOrder/inquiry/index.js +3 -3
- package/lib/api/restful/postOrder/return/index.js +7 -7
- package/lib/api/restful/sell/account/v1.js +21 -21
- package/lib/api/restful/sell/account/v2.js +1 -1
- package/lib/api/restful/sell/analytics/index.js +2 -2
- package/lib/api/restful/sell/compliance/index.js +3 -3
- package/lib/api/restful/sell/feed/index.d.ts +3 -3
- package/lib/api/restful/sell/feed/index.js +16 -16
- package/lib/api/restful/sell/finances/index.d.ts +3 -3
- package/lib/api/restful/sell/finances/index.js +14 -14
- package/lib/api/restful/sell/fulfillment/index.d.ts +1 -1
- package/lib/api/restful/sell/fulfillment/index.js +4 -4
- package/lib/api/restful/sell/inventory/index.d.ts +3 -3
- package/lib/api/restful/sell/inventory/index.js +22 -22
- package/lib/api/restful/sell/listing/index.js +1 -1
- package/lib/api/restful/sell/logistics/index.js +2 -2
- package/lib/api/restful/sell/marketing/index.js +21 -21
- package/lib/api/restful/sell/negotiation/index.js +2 -2
- package/lib/api/restful/sell/recommendation/index.js +1 -1
- package/lib/api/traditional/XMLRequest.d.ts +1 -3
- package/lib/api/traditional/XMLRequest.js +2 -4
- package/lib/auth/oAuth2.js +1 -1
- package/lib/ebay-api.min.js +2 -2
- package/lib/errors/index.js +2 -2
- package/lib/types/restful/specs/buy_browse_v1_oas3.d.ts +561 -111
- package/lib/types/restful/specs/buy_deal_v1_oas3.d.ts +171 -30
- package/lib/types/restful/specs/buy_feed_v1_beta_oas3.d.ts +200 -28
- package/lib/types/restful/specs/buy_marketing_v1_beta_oas3.d.ts +114 -20
- package/lib/types/restful/specs/buy_marketplace_insights_v1_beta_oas3.d.ts +52 -17
- package/lib/types/restful/specs/buy_offer_v1_beta_oas3.d.ts +84 -12
- package/lib/types/restful/specs/buy_order_v1_beta_oas3.d.ts +1478 -179
- package/lib/types/restful/specs/cancellation_oas3.d.ts +179 -9
- package/lib/types/restful/specs/case_oas3.d.ts +173 -9
- package/lib/types/restful/specs/commerce_catalog_v1_beta_oas3.d.ts +323 -75
- package/lib/types/restful/specs/commerce_charity_v1_oas3.d.ts +110 -13
- package/lib/types/restful/specs/commerce_identity_v1_oas3.d.ts +39 -6
- package/lib/types/restful/specs/commerce_media_v1_beta_oas3.d.ts +150 -23
- package/lib/types/restful/specs/commerce_notification_v1_oas3.d.ts +623 -72
- package/lib/types/restful/specs/commerce_taxonomy_v1_oas3.d.ts +339 -45
- package/lib/types/restful/specs/commerce_translation_v1_beta_oas3.d.ts +40 -8
- package/lib/types/restful/specs/developer_analytics_v1_beta_oas3.d.ts +67 -11
- package/lib/types/restful/specs/developer_key_management_v1_oas3.d.ts +134 -18
- package/lib/types/restful/specs/inquiry_oas3.d.ts +271 -13
- package/lib/types/restful/specs/return_oas3.d.ts +761 -35
- package/lib/types/restful/specs/sell_account_v1_oas3.d.ts +1503 -187
- package/lib/types/restful/specs/sell_account_v2_oas3.d.ts +155 -21
- package/lib/types/restful/specs/sell_analytics_v1_oas3.d.ts +174 -32
- package/lib/types/restful/specs/sell_compliance_v1_oas3.d.ts +128 -21
- package/lib/types/restful/specs/sell_feed_v1_oas3.d.ts +880 -103
- package/lib/types/restful/specs/sell_finances_v1_oas3.d.ts +261 -28
- package/lib/types/restful/specs/sell_fulfillment_v1_oas3.d.ts +618 -98
- package/lib/types/restful/specs/sell_inventory_v1_oas3.d.ts +1257 -210
- package/lib/types/restful/specs/sell_listing_v1_beta_oas3.d.ts +38 -9
- package/lib/types/restful/specs/sell_logistics_v1_oas3.d.ts +255 -36
- package/lib/types/restful/specs/sell_marketing_v1_oas3.d.ts +3201 -435
- package/lib/types/restful/specs/sell_metadata_v1_oas3.d.ts +361 -63
- package/lib/types/restful/specs/sell_negotiation_v1_oas3.d.ts +82 -14
- package/lib/types/restful/specs/sell_recommendation_v1_oas3.d.ts +43 -10
- package/package.json +10 -9
package/README.md
CHANGED
|
@@ -75,7 +75,7 @@ For more examples, check out the [examples directory](./examples).
|
|
|
75
75
|
|
|
76
76
|
## Changelog
|
|
77
77
|
|
|
78
|
-
* `v9.4.
|
|
78
|
+
* `v9.4.1` is the latest release.
|
|
79
79
|
* See [here](https://github.com/hendt/ebay-api/blob/master/CHANGELOG.md) for the full changelog.
|
|
80
80
|
|
|
81
81
|
## Implementation status
|
package/dist/api/apiFactory.js
CHANGED
|
@@ -2,7 +2,7 @@ import Api from './index.js';
|
|
|
2
2
|
import { Browse, Deal, Feed, Marketing as BuyMarketing, MarketplaceInsights, Offer, Order } from './restful/buy/index.js';
|
|
3
3
|
import { Catalog, Charity, Identity, Media, Message, Notification, Taxonomy, Translation } from './restful/commerce/index.js';
|
|
4
4
|
import { Analytics as DeveloperAnalytics, KeyManagement } from './restful/developer/index.js';
|
|
5
|
-
import { Cancellation, Case, Inquiry, Return
|
|
5
|
+
import { Cancellation, Case, Inquiry, Return } from './restful/postOrder/index.js';
|
|
6
6
|
import { AccountV1, AccountV2, Analytics as SellAnalytics, Compliance, Feed as SellFeed, Finances, Fulfillment, Inventory, Listing, Logistics, Marketing as SellMarketing, Metadata, Negotiation, Recommendation } from './restful/sell/index.js';
|
|
7
7
|
import Traditional from './traditional/index.js';
|
|
8
8
|
export default class ApiFactory extends Api {
|
|
@@ -18,7 +18,7 @@ export default class ApiFactory extends Api {
|
|
|
18
18
|
offer: this.createRestfulApi(Offer),
|
|
19
19
|
order: this.createRestfulApi(Order),
|
|
20
20
|
deal: this.createRestfulApi(Deal),
|
|
21
|
-
marketplaceInsights: this.createRestfulApi(MarketplaceInsights)
|
|
21
|
+
marketplaceInsights: this.createRestfulApi(MarketplaceInsights)
|
|
22
22
|
};
|
|
23
23
|
}
|
|
24
24
|
createCommerceApi() {
|
|
@@ -36,7 +36,7 @@ export default class ApiFactory extends Api {
|
|
|
36
36
|
createDeveloperApi() {
|
|
37
37
|
return {
|
|
38
38
|
analytics: this.createRestfulApi(DeveloperAnalytics),
|
|
39
|
-
keyManagement: this.createRestfulApi(KeyManagement)
|
|
39
|
+
keyManagement: this.createRestfulApi(KeyManagement)
|
|
40
40
|
};
|
|
41
41
|
}
|
|
42
42
|
createPostOrderApi() {
|
|
@@ -44,7 +44,7 @@ export default class ApiFactory extends Api {
|
|
|
44
44
|
cancellation: this.createRestfulApi(Cancellation),
|
|
45
45
|
case: this.createRestfulApi(Case),
|
|
46
46
|
inquiry: this.createRestfulApi(Inquiry),
|
|
47
|
-
return: this.createRestfulApi(Return)
|
|
47
|
+
return: this.createRestfulApi(Return)
|
|
48
48
|
};
|
|
49
49
|
}
|
|
50
50
|
createSellApi() {
|
|
@@ -62,7 +62,7 @@ export default class ApiFactory extends Api {
|
|
|
62
62
|
feed: this.createRestfulApi(SellFeed),
|
|
63
63
|
logistics: this.createRestfulApi(Logistics),
|
|
64
64
|
negotiation: this.createRestfulApi(Negotiation),
|
|
65
|
-
listing: this.createRestfulApi(Listing)
|
|
65
|
+
listing: this.createRestfulApi(Listing)
|
|
66
66
|
};
|
|
67
67
|
}
|
|
68
68
|
get traditional() {
|
|
@@ -4,17 +4,17 @@ class Browse extends Restful {
|
|
|
4
4
|
return '/buy/browse/v1';
|
|
5
5
|
}
|
|
6
6
|
search(params) {
|
|
7
|
-
return this.get(
|
|
7
|
+
return this.get('/item_summary/search', {
|
|
8
8
|
params
|
|
9
9
|
});
|
|
10
10
|
}
|
|
11
11
|
searchByImage(params, body) {
|
|
12
|
-
return this.post(
|
|
12
|
+
return this.post('/item_summary/search_by_image', body, {
|
|
13
13
|
params
|
|
14
14
|
});
|
|
15
15
|
}
|
|
16
16
|
getItems(params) {
|
|
17
|
-
return this.get(
|
|
17
|
+
return this.get('/item/', {
|
|
18
18
|
params
|
|
19
19
|
});
|
|
20
20
|
}
|
|
@@ -27,12 +27,12 @@ class Browse extends Restful {
|
|
|
27
27
|
});
|
|
28
28
|
}
|
|
29
29
|
getItemByLegacyId(params) {
|
|
30
|
-
return this.get(
|
|
30
|
+
return this.get('/item/get_item_by_legacy_id', {
|
|
31
31
|
params
|
|
32
32
|
});
|
|
33
33
|
}
|
|
34
34
|
getItemsByItemGroup(itemGroupId) {
|
|
35
|
-
return this.get(
|
|
35
|
+
return this.get('/item/get_items_by_item_group', {
|
|
36
36
|
params: {
|
|
37
37
|
item_group_id: itemGroupId
|
|
38
38
|
}
|
|
@@ -43,16 +43,16 @@ class Browse extends Restful {
|
|
|
43
43
|
return this.post(`/item/${id}/check_compatibility`, body);
|
|
44
44
|
}
|
|
45
45
|
addItem(item) {
|
|
46
|
-
return this.post(
|
|
46
|
+
return this.post('/shopping_cart/add_item', item);
|
|
47
47
|
}
|
|
48
48
|
getShoppingCart() {
|
|
49
|
-
return this.get(
|
|
49
|
+
return this.get('/shopping_cart/');
|
|
50
50
|
}
|
|
51
51
|
removeItem(item) {
|
|
52
|
-
return this.post(
|
|
52
|
+
return this.post('/shopping_cart/remove_item', item);
|
|
53
53
|
}
|
|
54
54
|
updateQuantity(item) {
|
|
55
|
-
return this.post(
|
|
55
|
+
return this.post('/shopping_cart/update_quantity', item);
|
|
56
56
|
}
|
|
57
57
|
}
|
|
58
58
|
Browse.id = 'Browse';
|
|
@@ -4,7 +4,7 @@ class Deal extends Restful {
|
|
|
4
4
|
return '/buy/deal/v1';
|
|
5
5
|
}
|
|
6
6
|
getDealItems({ categoryIds, commissionable, deliveryCountry, limit, offset }) {
|
|
7
|
-
return this.get(
|
|
7
|
+
return this.get('/deal_item', {
|
|
8
8
|
params: {
|
|
9
9
|
category_ids: categoryIds,
|
|
10
10
|
commissionable,
|
|
@@ -19,7 +19,7 @@ class Deal extends Restful {
|
|
|
19
19
|
return this.get(`/event/${eventId}`);
|
|
20
20
|
}
|
|
21
21
|
getEvents({ limit, offset }) {
|
|
22
|
-
return this.get(
|
|
22
|
+
return this.get('/event', {
|
|
23
23
|
params: {
|
|
24
24
|
limit,
|
|
25
25
|
offset
|
|
@@ -27,7 +27,7 @@ class Deal extends Restful {
|
|
|
27
27
|
});
|
|
28
28
|
}
|
|
29
29
|
getEventItems(eventIds, { categoryIds, deliveryCountry, limit, offset } = {}) {
|
|
30
|
-
return this.get(
|
|
30
|
+
return this.get('/event_item', {
|
|
31
31
|
params: {
|
|
32
32
|
event_ids: eventIds,
|
|
33
33
|
limit,
|
|
@@ -4,7 +4,7 @@ class Feed extends Restful {
|
|
|
4
4
|
return '/buy/feed/v1_beta';
|
|
5
5
|
}
|
|
6
6
|
getItemFeed(params, range) {
|
|
7
|
-
return this.get(
|
|
7
|
+
return this.get('/item', {
|
|
8
8
|
params,
|
|
9
9
|
headers: {
|
|
10
10
|
'Range': range
|
|
@@ -12,7 +12,7 @@ class Feed extends Restful {
|
|
|
12
12
|
});
|
|
13
13
|
}
|
|
14
14
|
getItemGroupFeed(params, range) {
|
|
15
|
-
return this.get(
|
|
15
|
+
return this.get('/item_group', {
|
|
16
16
|
params,
|
|
17
17
|
headers: {
|
|
18
18
|
'Range': range
|
|
@@ -20,7 +20,7 @@ class Feed extends Restful {
|
|
|
20
20
|
});
|
|
21
21
|
}
|
|
22
22
|
getItemSnapshotFeed(params, snapshotDate, range) {
|
|
23
|
-
return this.get(
|
|
23
|
+
return this.get('/item_snapshot', {
|
|
24
24
|
params: {
|
|
25
25
|
...params,
|
|
26
26
|
snapshot_date: snapshotDate
|
|
@@ -31,7 +31,7 @@ class Feed extends Restful {
|
|
|
31
31
|
});
|
|
32
32
|
}
|
|
33
33
|
getProductFeed(params, snapshotDate, range) {
|
|
34
|
-
return this.get(
|
|
34
|
+
return this.get('/product', {
|
|
35
35
|
params: {
|
|
36
36
|
...params,
|
|
37
37
|
snapshot_date: snapshotDate
|
|
@@ -4,17 +4,17 @@ class Marketing extends Restful {
|
|
|
4
4
|
return '/buy/marketing/v1_beta';
|
|
5
5
|
}
|
|
6
6
|
getAlsoBoughtByProduct(params) {
|
|
7
|
-
return this.get(
|
|
7
|
+
return this.get('/merchandised_product/get_also_bought_products', {
|
|
8
8
|
params
|
|
9
9
|
});
|
|
10
10
|
}
|
|
11
11
|
getAlsoViewedByProduct(params) {
|
|
12
|
-
return this.get(
|
|
12
|
+
return this.get('/merchandised_product/get_also_viewed_products', {
|
|
13
13
|
params
|
|
14
14
|
});
|
|
15
15
|
}
|
|
16
16
|
getMerchandisedProducts(params) {
|
|
17
|
-
return this.get(
|
|
17
|
+
return this.get('/merchandised_product', {
|
|
18
18
|
params
|
|
19
19
|
});
|
|
20
20
|
}
|
|
@@ -4,5 +4,5 @@ import Restful, { OpenApi } from '../../index.js';
|
|
|
4
4
|
export default class MarketplaceInsights extends Restful implements OpenApi<operations> {
|
|
5
5
|
static id: string;
|
|
6
6
|
get basePath(): string;
|
|
7
|
-
search({ aspectFilter, categoryIds, epid, fieldgroups, filter, gtin, limit, offset, q, sort
|
|
7
|
+
search({ aspectFilter, categoryIds, epid, fieldgroups, filter, gtin, limit, offset, q, sort }: MarketingInsightsSearchParams): Promise<any>;
|
|
8
8
|
}
|
|
@@ -3,8 +3,8 @@ class MarketplaceInsights extends Restful {
|
|
|
3
3
|
get basePath() {
|
|
4
4
|
return '/buy/marketplace_insights/v1_beta';
|
|
5
5
|
}
|
|
6
|
-
search({ aspectFilter, categoryIds, epid, fieldgroups, filter, gtin, limit, offset, q, sort
|
|
7
|
-
return this.get(
|
|
6
|
+
search({ aspectFilter, categoryIds, epid, fieldgroups, filter, gtin, limit, offset, q, sort }) {
|
|
7
|
+
return this.get('/item_sales/search', {
|
|
8
8
|
params: {
|
|
9
9
|
aspect_filter: aspectFilter,
|
|
10
10
|
category_ids: categoryIds,
|
|
@@ -15,7 +15,7 @@ class MarketplaceInsights extends Restful {
|
|
|
15
15
|
limit,
|
|
16
16
|
offset,
|
|
17
17
|
q,
|
|
18
|
-
sort
|
|
18
|
+
sort
|
|
19
19
|
}
|
|
20
20
|
});
|
|
21
21
|
}
|
|
@@ -12,7 +12,7 @@ class Order extends Api {
|
|
|
12
12
|
return this.get(`/checkout_session/${checkoutSessionId}`);
|
|
13
13
|
}
|
|
14
14
|
initiateCheckoutSession(body) {
|
|
15
|
-
return this.post(
|
|
15
|
+
return this.post('/checkout_session/initiate', body);
|
|
16
16
|
}
|
|
17
17
|
placeOrder(checkoutSessionId) {
|
|
18
18
|
checkoutSessionId = encodeURIComponent(checkoutSessionId);
|
|
@@ -51,7 +51,7 @@ class Order extends Api {
|
|
|
51
51
|
return this.get(`/guest_checkout_session/${checkoutSessionId}`);
|
|
52
52
|
}
|
|
53
53
|
initiateGuestCheckoutSession(body) {
|
|
54
|
-
return this.post(
|
|
54
|
+
return this.post('/guest_checkout_session/initiate', body);
|
|
55
55
|
}
|
|
56
56
|
initiateGuestPayment(checkoutSessionId, body) {
|
|
57
57
|
checkoutSessionId = encodeURIComponent(checkoutSessionId);
|
|
@@ -90,7 +90,7 @@ class Order extends Api {
|
|
|
90
90
|
return this.get(`/proxy_guest_checkout_session/${checkoutSessionId}`);
|
|
91
91
|
}
|
|
92
92
|
initiateProxyGuestCheckoutSession(body) {
|
|
93
|
-
return this.post(
|
|
93
|
+
return this.post('/proxy_guest_checkout_session/initiate', body);
|
|
94
94
|
}
|
|
95
95
|
placeProxyGuestOrder(checkoutSessionId, body) {
|
|
96
96
|
checkoutSessionId = encodeURIComponent(checkoutSessionId);
|
|
@@ -7,7 +7,7 @@ class Catalog extends Restful {
|
|
|
7
7
|
return this.get(`/change_request/${changeRequestId}`);
|
|
8
8
|
}
|
|
9
9
|
getChangeRequests({ filter, limit, offset } = {}) {
|
|
10
|
-
return this.get(
|
|
10
|
+
return this.get('/change_request', {
|
|
11
11
|
params: {
|
|
12
12
|
filter,
|
|
13
13
|
limit,
|
|
@@ -20,12 +20,12 @@ class Catalog extends Restful {
|
|
|
20
20
|
return this.get(`/product/${e}`);
|
|
21
21
|
}
|
|
22
22
|
search(params) {
|
|
23
|
-
return this.get(
|
|
23
|
+
return this.get('/product_summary/search', {
|
|
24
24
|
params
|
|
25
25
|
});
|
|
26
26
|
}
|
|
27
27
|
getProductMetadata(epid, { otherApplicableCategoryIds, primaryCategoryId } = {}) {
|
|
28
|
-
return this.get(
|
|
28
|
+
return this.get('/get_product_metadata', {
|
|
29
29
|
params: {
|
|
30
30
|
epid,
|
|
31
31
|
other_applicable_category_ids: otherApplicableCategoryIds,
|
|
@@ -34,7 +34,7 @@ class Catalog extends Restful {
|
|
|
34
34
|
});
|
|
35
35
|
}
|
|
36
36
|
getProductMetadataForCategories(primaryCategoryId, otherApplicableCategoryIds) {
|
|
37
|
-
return this.get(
|
|
37
|
+
return this.get('/get_product_metadata_for_categories', {
|
|
38
38
|
params: {
|
|
39
39
|
primary_category_id: primaryCategoryId,
|
|
40
40
|
other_applicable_category_ids: otherApplicableCategoryIds
|
|
@@ -8,7 +8,7 @@ class Charity extends Restful {
|
|
|
8
8
|
return this.get(`/charity_org/${charityOrgId}`);
|
|
9
9
|
}
|
|
10
10
|
getCharityOrgs({ limit, offset, q, registrationIds }) {
|
|
11
|
-
return this.get(
|
|
11
|
+
return this.get('/charity_org', {
|
|
12
12
|
params: {
|
|
13
13
|
limit,
|
|
14
14
|
offset,
|
|
@@ -18,7 +18,7 @@ class Charity extends Restful {
|
|
|
18
18
|
});
|
|
19
19
|
}
|
|
20
20
|
getCharityOrgByLegacyId(legacyCharityOrgId) {
|
|
21
|
-
return this.get(
|
|
21
|
+
return this.get('/charity_org/get_charity_org_by_legacy_id', {
|
|
22
22
|
params: {
|
|
23
23
|
legacy_charity_org_id: legacyCharityOrgId
|
|
24
24
|
}
|
|
@@ -4,7 +4,7 @@ class Message extends Restful {
|
|
|
4
4
|
return '/commerce/message/v1';
|
|
5
5
|
}
|
|
6
6
|
getConversations({ limit, offset, conversationStatus, conversationType, referenceId, referenceType, startTime, endTime, otherPartyUsername } = {}) {
|
|
7
|
-
return this.get(
|
|
7
|
+
return this.get('/conversation', {
|
|
8
8
|
params: {
|
|
9
9
|
limit,
|
|
10
10
|
offset,
|
|
@@ -14,7 +14,7 @@ class Message extends Restful {
|
|
|
14
14
|
reference_type: referenceType,
|
|
15
15
|
start_time: startTime,
|
|
16
16
|
end_time: endTime,
|
|
17
|
-
other_party_username: otherPartyUsername
|
|
17
|
+
other_party_username: otherPartyUsername
|
|
18
18
|
}
|
|
19
19
|
});
|
|
20
20
|
}
|
|
@@ -23,18 +23,18 @@ class Message extends Restful {
|
|
|
23
23
|
params: {
|
|
24
24
|
conversation_type: conversationType,
|
|
25
25
|
limit,
|
|
26
|
-
offset
|
|
26
|
+
offset
|
|
27
27
|
}
|
|
28
28
|
});
|
|
29
29
|
}
|
|
30
30
|
updateConversation(body) {
|
|
31
|
-
return this.post(
|
|
31
|
+
return this.post('/update_conversation', body);
|
|
32
32
|
}
|
|
33
33
|
bulkUpdateConversation(body) {
|
|
34
|
-
return this.post(
|
|
34
|
+
return this.post('/bulk_update_conversation', body);
|
|
35
35
|
}
|
|
36
36
|
sendMessage(body) {
|
|
37
|
-
return this.post(
|
|
37
|
+
return this.post('/send_message', body);
|
|
38
38
|
}
|
|
39
39
|
;
|
|
40
40
|
}
|
|
@@ -12,7 +12,7 @@ class Notification extends Restful {
|
|
|
12
12
|
return this.get(`/topic/${topicId}`);
|
|
13
13
|
}
|
|
14
14
|
getTopics({ limit, continuationToken: continuation_token }) {
|
|
15
|
-
return this.get(
|
|
15
|
+
return this.get('/topic', {
|
|
16
16
|
params: {
|
|
17
17
|
limit,
|
|
18
18
|
continuation_token
|
|
@@ -20,7 +20,7 @@ class Notification extends Restful {
|
|
|
20
20
|
});
|
|
21
21
|
}
|
|
22
22
|
getSubscriptions({ limit, continuationToken: continuation_token }) {
|
|
23
|
-
return this.get(
|
|
23
|
+
return this.get('/subscription', {
|
|
24
24
|
params: {
|
|
25
25
|
limit,
|
|
26
26
|
continuation_token
|
|
@@ -28,7 +28,7 @@ class Notification extends Restful {
|
|
|
28
28
|
});
|
|
29
29
|
}
|
|
30
30
|
createSubscription(body) {
|
|
31
|
-
return this.post(
|
|
31
|
+
return this.post('/subscription', body);
|
|
32
32
|
}
|
|
33
33
|
getSubscription(subscriptionId) {
|
|
34
34
|
subscriptionId = encodeURIComponent(subscriptionId);
|
|
@@ -55,7 +55,7 @@ class Notification extends Restful {
|
|
|
55
55
|
return this.post(`/subscription/${subscriptionId}/test`);
|
|
56
56
|
}
|
|
57
57
|
getDestinations({ limit, continuationToken: continuation_token }) {
|
|
58
|
-
return this.get(
|
|
58
|
+
return this.get('/destination', {
|
|
59
59
|
params: {
|
|
60
60
|
limit,
|
|
61
61
|
continuation_token
|
|
@@ -63,7 +63,7 @@ class Notification extends Restful {
|
|
|
63
63
|
});
|
|
64
64
|
}
|
|
65
65
|
createDestination(body) {
|
|
66
|
-
return this.post(
|
|
66
|
+
return this.post('/destination', body);
|
|
67
67
|
}
|
|
68
68
|
getDestination(destinationId) {
|
|
69
69
|
destinationId = encodeURIComponent(destinationId);
|
|
@@ -78,10 +78,10 @@ class Notification extends Restful {
|
|
|
78
78
|
return this.delete(`/destination/${destinationId}`);
|
|
79
79
|
}
|
|
80
80
|
getConfig() {
|
|
81
|
-
return this.get(
|
|
81
|
+
return this.get('/config');
|
|
82
82
|
}
|
|
83
83
|
updateConfig(body) {
|
|
84
|
-
return this.put(
|
|
84
|
+
return this.put('/config', body);
|
|
85
85
|
}
|
|
86
86
|
}
|
|
87
87
|
Notification.id = 'Notification';
|
|
@@ -10,6 +10,6 @@ export default class Taxonomy extends Restful implements OpenApi<operations> {
|
|
|
10
10
|
getCategorySuggestions(categoryTreeId: string, q: string): Promise<any>;
|
|
11
11
|
getItemAspectsForCategory(categoryTreeId: string, categoryId: string): Promise<any>;
|
|
12
12
|
getCompatibilityProperties(categoryTreeId: string, categoryId: string): Promise<any>;
|
|
13
|
-
getCompatibilityPropertyValues(categoryTreeId: string, categoryId: string, compatibilityProperty: string): Promise<any>;
|
|
13
|
+
getCompatibilityPropertyValues(categoryTreeId: string, categoryId: string, compatibilityProperty: string, filter?: string): Promise<any>;
|
|
14
14
|
fetchItemAspects(categoryTreeId: string): Promise<Buffer>;
|
|
15
15
|
}
|
|
@@ -4,7 +4,7 @@ class Taxonomy extends Restful {
|
|
|
4
4
|
return '/commerce/taxonomy/v1';
|
|
5
5
|
}
|
|
6
6
|
getDefaultCategoryTreeId(marketplaceId) {
|
|
7
|
-
return this.get(
|
|
7
|
+
return this.get('/get_default_category_tree_id', {
|
|
8
8
|
params: {
|
|
9
9
|
marketplace_id: marketplaceId
|
|
10
10
|
}
|
|
@@ -45,12 +45,13 @@ class Taxonomy extends Restful {
|
|
|
45
45
|
}
|
|
46
46
|
});
|
|
47
47
|
}
|
|
48
|
-
getCompatibilityPropertyValues(categoryTreeId, categoryId, compatibilityProperty) {
|
|
48
|
+
getCompatibilityPropertyValues(categoryTreeId, categoryId, compatibilityProperty, filter) {
|
|
49
49
|
categoryTreeId = encodeURIComponent(categoryTreeId);
|
|
50
50
|
return this.get(`/category_tree/${categoryTreeId}/get_compatibility_property_values`, {
|
|
51
51
|
params: {
|
|
52
52
|
category_id: categoryId,
|
|
53
|
-
compatibility_property: compatibilityProperty
|
|
53
|
+
compatibility_property: compatibilityProperty,
|
|
54
|
+
filter
|
|
54
55
|
}
|
|
55
56
|
});
|
|
56
57
|
}
|
|
@@ -4,7 +4,7 @@ class Analytics extends Restful {
|
|
|
4
4
|
return '/developer/analytics/v1_beta';
|
|
5
5
|
}
|
|
6
6
|
getRateLimits(apiContext, apiName) {
|
|
7
|
-
return this.get(
|
|
7
|
+
return this.get('/rate_limit/', {
|
|
8
8
|
params: {
|
|
9
9
|
api_context: apiContext,
|
|
10
10
|
api_name: apiName
|
|
@@ -12,7 +12,7 @@ class Analytics extends Restful {
|
|
|
12
12
|
});
|
|
13
13
|
}
|
|
14
14
|
getUserRateLimits(apiContext, apiName) {
|
|
15
|
-
return this.get(
|
|
15
|
+
return this.get('/user_rate_limit/', {
|
|
16
16
|
params: {
|
|
17
17
|
api_context: apiContext,
|
|
18
18
|
api_name: apiName
|
|
@@ -7,10 +7,10 @@ class KeyManagement extends Restful {
|
|
|
7
7
|
return '/developer/key_management/v1';
|
|
8
8
|
}
|
|
9
9
|
getSigningKeys() {
|
|
10
|
-
return this.get(
|
|
10
|
+
return this.get('/signing_key');
|
|
11
11
|
}
|
|
12
12
|
createSigningKey(signingKeyCipher) {
|
|
13
|
-
return this.post(
|
|
13
|
+
return this.post('/signing_key', {
|
|
14
14
|
signingKeyCipher
|
|
15
15
|
});
|
|
16
16
|
}
|
|
@@ -11,7 +11,7 @@ const additionalHeaders = {
|
|
|
11
11
|
marketplaceId: 'X-EBAY-C-MARKETPLACE-ID',
|
|
12
12
|
endUserCtx: 'X-EBAY-C-ENDUSERCTX',
|
|
13
13
|
acceptLanguage: 'Accept-Language',
|
|
14
|
-
contentLanguage: 'Content-Language'
|
|
14
|
+
contentLanguage: 'Content-Language'
|
|
15
15
|
};
|
|
16
16
|
export default class Restful extends Api {
|
|
17
17
|
constructor(config, req, auth, apiConfig = {}) {
|
|
@@ -11,7 +11,7 @@ class Cancellation extends Restful {
|
|
|
11
11
|
return this.post(`/cancellation/${cancelId}/approve`);
|
|
12
12
|
}
|
|
13
13
|
checkCancellationEligibility(legacyOrderId) {
|
|
14
|
-
return this.post(
|
|
14
|
+
return this.post('/cancellation/check_eligibility', {
|
|
15
15
|
legacyOrderId
|
|
16
16
|
});
|
|
17
17
|
}
|
|
@@ -20,7 +20,7 @@ class Cancellation extends Restful {
|
|
|
20
20
|
return this.post(`/cancellation/${cancelId}/confirm`, payload);
|
|
21
21
|
}
|
|
22
22
|
createCancellation(payload) {
|
|
23
|
-
return this.post(
|
|
23
|
+
return this.post('/cancellation', payload);
|
|
24
24
|
}
|
|
25
25
|
getCancellation(cancelId, fieldGroups) {
|
|
26
26
|
cancelId = encodeURIComponent(cancelId);
|
|
@@ -35,7 +35,7 @@ class Cancellation extends Restful {
|
|
|
35
35
|
return this.post(`/cancellation/${cancelId}/reject`, payload);
|
|
36
36
|
}
|
|
37
37
|
search(params) {
|
|
38
|
-
return this.get(
|
|
38
|
+
return this.get('/cancellation/search', {
|
|
39
39
|
params
|
|
40
40
|
});
|
|
41
41
|
}
|
|
@@ -7,7 +7,7 @@ class Inquiry extends Restful {
|
|
|
7
7
|
return true;
|
|
8
8
|
}
|
|
9
9
|
checkInquiryEligibility(payload) {
|
|
10
|
-
return this.post(
|
|
10
|
+
return this.post('/inquiry/check_eligibility', payload);
|
|
11
11
|
}
|
|
12
12
|
closeInquiry(inquiryId, payload) {
|
|
13
13
|
inquiryId = encodeURIComponent(inquiryId);
|
|
@@ -24,7 +24,7 @@ class Inquiry extends Restful {
|
|
|
24
24
|
if (typeof payload.desiredOutcome === 'string') {
|
|
25
25
|
payload.desiredOutcome = payload.desiredOutcome.trim();
|
|
26
26
|
}
|
|
27
|
-
return this.post(
|
|
27
|
+
return this.post('/inquiry', payload);
|
|
28
28
|
}
|
|
29
29
|
escalateInquiry(inquiryId, payload) {
|
|
30
30
|
inquiryId = encodeURIComponent(inquiryId);
|
|
@@ -48,7 +48,7 @@ class Inquiry extends Restful {
|
|
|
48
48
|
return this.post(`/inquiry/${inquiryId}/provide_shipment_info`, payload);
|
|
49
49
|
}
|
|
50
50
|
search(params) {
|
|
51
|
-
return this.get(
|
|
51
|
+
return this.get('/inquiry/search', {
|
|
52
52
|
params
|
|
53
53
|
});
|
|
54
54
|
}
|
|
@@ -18,17 +18,17 @@ class Return extends Restful {
|
|
|
18
18
|
return this.post(`/return/${id}/cancel`, payload);
|
|
19
19
|
}
|
|
20
20
|
checkReturnEligibility(payload) {
|
|
21
|
-
return this.post(
|
|
21
|
+
return this.post('/return/check_eligibility', payload);
|
|
22
22
|
}
|
|
23
23
|
checkShippingLabelEligibility(returnId) {
|
|
24
24
|
const id = encodeURIComponent(returnId);
|
|
25
25
|
return this.get(`/return/${id}/check_label_print_eligibility`);
|
|
26
26
|
}
|
|
27
27
|
createReturnDraft(payload) {
|
|
28
|
-
return this.post(
|
|
28
|
+
return this.post('/return/draft', payload);
|
|
29
29
|
}
|
|
30
30
|
createReturnRequest(payload, fieldGroups) {
|
|
31
|
-
return this.post(
|
|
31
|
+
return this.post('/return', payload, {
|
|
32
32
|
params: {
|
|
33
33
|
fieldgroups: fieldGroups
|
|
34
34
|
}
|
|
@@ -64,14 +64,14 @@ class Return extends Restful {
|
|
|
64
64
|
return this.get(`/return/draft/${id}/files`);
|
|
65
65
|
}
|
|
66
66
|
getReturnEstimate(payload) {
|
|
67
|
-
return this.post(
|
|
67
|
+
return this.post('/return/estimate', payload);
|
|
68
68
|
}
|
|
69
69
|
getReturnFiles(returnId) {
|
|
70
70
|
const id = encodeURIComponent(returnId);
|
|
71
71
|
return this.get(`/return/${id}/files`);
|
|
72
72
|
}
|
|
73
73
|
getReturnPreferences() {
|
|
74
|
-
return this.get(
|
|
74
|
+
return this.get('/return/preference');
|
|
75
75
|
}
|
|
76
76
|
getReturnShippingLabel(returnId) {
|
|
77
77
|
returnId = encodeURIComponent(returnId);
|
|
@@ -111,7 +111,7 @@ class Return extends Restful {
|
|
|
111
111
|
return this.post(`/return/${returnId}/decide`, payload);
|
|
112
112
|
}
|
|
113
113
|
search(params) {
|
|
114
|
-
return this.get(
|
|
114
|
+
return this.get('/return/search', {
|
|
115
115
|
params
|
|
116
116
|
});
|
|
117
117
|
}
|
|
@@ -128,7 +128,7 @@ class Return extends Restful {
|
|
|
128
128
|
});
|
|
129
129
|
}
|
|
130
130
|
setReturnPreferences(rmaRequired) {
|
|
131
|
-
return this.post(
|
|
131
|
+
return this.post('/return/preference', {
|
|
132
132
|
rmaRequired
|
|
133
133
|
});
|
|
134
134
|
}
|