ebay-mcp 1.4.3

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.
Files changed (205) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +586 -0
  3. package/build/api/account-management/account.d.ts +216 -0
  4. package/build/api/account-management/account.js +305 -0
  5. package/build/api/analytics-and-report/analytics.d.ts +33 -0
  6. package/build/api/analytics-and-report/analytics.js +102 -0
  7. package/build/api/client.d.ts +89 -0
  8. package/build/api/client.js +343 -0
  9. package/build/api/communication/feedback.d.ts +45 -0
  10. package/build/api/communication/feedback.js +119 -0
  11. package/build/api/communication/message.d.ts +55 -0
  12. package/build/api/communication/message.js +131 -0
  13. package/build/api/communication/negotiation.d.ts +39 -0
  14. package/build/api/communication/negotiation.js +97 -0
  15. package/build/api/communication/notification.d.ts +128 -0
  16. package/build/api/communication/notification.js +373 -0
  17. package/build/api/index.d.ts +96 -0
  18. package/build/api/index.js +121 -0
  19. package/build/api/listing-management/inventory.d.ts +216 -0
  20. package/build/api/listing-management/inventory.js +633 -0
  21. package/build/api/listing-metadata/metadata.d.ts +154 -0
  22. package/build/api/listing-metadata/metadata.js +485 -0
  23. package/build/api/listing-metadata/taxonomy.d.ts +38 -0
  24. package/build/api/listing-metadata/taxonomy.js +58 -0
  25. package/build/api/marketing-and-promotions/marketing.d.ts +395 -0
  26. package/build/api/marketing-and-promotions/marketing.js +565 -0
  27. package/build/api/marketing-and-promotions/recommendation.d.ts +20 -0
  28. package/build/api/marketing-and-promotions/recommendation.js +32 -0
  29. package/build/api/order-management/dispute.d.ts +65 -0
  30. package/build/api/order-management/dispute.js +69 -0
  31. package/build/api/order-management/fulfillment.d.ts +80 -0
  32. package/build/api/order-management/fulfillment.js +89 -0
  33. package/build/api/other/compliance.d.ts +26 -0
  34. package/build/api/other/compliance.js +47 -0
  35. package/build/api/other/edelivery.d.ts +153 -0
  36. package/build/api/other/edelivery.js +219 -0
  37. package/build/api/other/identity.d.ts +17 -0
  38. package/build/api/other/identity.js +24 -0
  39. package/build/api/other/translation.d.ts +14 -0
  40. package/build/api/other/translation.js +22 -0
  41. package/build/api/other/vero.d.ts +30 -0
  42. package/build/api/other/vero.js +48 -0
  43. package/build/auth/oauth-metadata.d.ts +46 -0
  44. package/build/auth/oauth-metadata.js +59 -0
  45. package/build/auth/oauth-middleware.d.ts +35 -0
  46. package/build/auth/oauth-middleware.js +99 -0
  47. package/build/auth/oauth-types.d.ts +66 -0
  48. package/build/auth/oauth-types.js +4 -0
  49. package/build/auth/oauth.d.ts +93 -0
  50. package/build/auth/oauth.js +383 -0
  51. package/build/auth/scope-utils.d.ts +70 -0
  52. package/build/auth/scope-utils.js +304 -0
  53. package/build/auth/token-verifier.d.ts +57 -0
  54. package/build/auth/token-verifier.js +172 -0
  55. package/build/config/environment.d.ts +61 -0
  56. package/build/config/environment.js +260 -0
  57. package/build/index.d.ts +1 -0
  58. package/build/index.js +98 -0
  59. package/build/schemas/account-management/account.d.ts +5324 -0
  60. package/build/schemas/account-management/account.js +366 -0
  61. package/build/schemas/analytics/analytics.d.ts +167 -0
  62. package/build/schemas/analytics/analytics.js +191 -0
  63. package/build/schemas/communication/messages.d.ts +1872 -0
  64. package/build/schemas/communication/messages.js +348 -0
  65. package/build/schemas/fulfillment/orders.d.ts +4655 -0
  66. package/build/schemas/fulfillment/orders.js +317 -0
  67. package/build/schemas/index.d.ts +2100 -0
  68. package/build/schemas/index.js +68 -0
  69. package/build/schemas/inventory-management/inventory.d.ts +6419 -0
  70. package/build/schemas/inventory-management/inventory.js +450 -0
  71. package/build/schemas/marketing/marketing.d.ts +14181 -0
  72. package/build/schemas/marketing/marketing.js +1088 -0
  73. package/build/schemas/metadata/metadata.d.ts +5259 -0
  74. package/build/schemas/metadata/metadata.js +614 -0
  75. package/build/schemas/other/other-apis.d.ts +257 -0
  76. package/build/schemas/other/other-apis.js +372 -0
  77. package/build/schemas/taxonomy/taxonomy.d.ts +215 -0
  78. package/build/schemas/taxonomy/taxonomy.js +571 -0
  79. package/build/scripts/auto-setup.d.ts +12 -0
  80. package/build/scripts/auto-setup.js +277 -0
  81. package/build/scripts/diagnostics.d.ts +8 -0
  82. package/build/scripts/diagnostics.js +299 -0
  83. package/build/scripts/download-specs.d.ts +1 -0
  84. package/build/scripts/download-specs.js +116 -0
  85. package/build/scripts/interactive-setup.d.ts +21 -0
  86. package/build/scripts/interactive-setup.js +723 -0
  87. package/build/server-http.d.ts +11 -0
  88. package/build/server-http.js +361 -0
  89. package/build/tools/definitions/account-with-schemas.d.ts +39 -0
  90. package/build/tools/definitions/account-with-schemas.js +170 -0
  91. package/build/tools/definitions/account.d.ts +12 -0
  92. package/build/tools/definitions/account.js +428 -0
  93. package/build/tools/definitions/analytics.d.ts +25 -0
  94. package/build/tools/definitions/analytics.js +66 -0
  95. package/build/tools/definitions/communication.d.ts +12 -0
  96. package/build/tools/definitions/communication.js +151 -0
  97. package/build/tools/definitions/fulfillment.d.ts +12 -0
  98. package/build/tools/definitions/fulfillment.js +326 -0
  99. package/build/tools/definitions/index.d.ts +25 -0
  100. package/build/tools/definitions/index.js +37 -0
  101. package/build/tools/definitions/inventory.d.ts +12 -0
  102. package/build/tools/definitions/inventory.js +429 -0
  103. package/build/tools/definitions/marketing.d.ts +12 -0
  104. package/build/tools/definitions/marketing.js +1095 -0
  105. package/build/tools/definitions/metadata.d.ts +12 -0
  106. package/build/tools/definitions/metadata.js +188 -0
  107. package/build/tools/definitions/other.d.ts +13 -0
  108. package/build/tools/definitions/other.js +309 -0
  109. package/build/tools/definitions/taxonomy.d.ts +25 -0
  110. package/build/tools/definitions/taxonomy.js +64 -0
  111. package/build/tools/definitions/token-management.d.ts +35 -0
  112. package/build/tools/definitions/token-management.js +103 -0
  113. package/build/tools/index.d.ts +11 -0
  114. package/build/tools/index.js +1003 -0
  115. package/build/tools/schemas.d.ts +14764 -0
  116. package/build/tools/schemas.js +667 -0
  117. package/build/tools/tool-definitions.d.ts +35 -0
  118. package/build/tools/tool-definitions.js +3534 -0
  119. package/build/types/application-settings/developerAnalyticsV1BetaOas3.d.ts +197 -0
  120. package/build/types/application-settings/developerAnalyticsV1BetaOas3.js +5 -0
  121. package/build/types/application-settings/developerClientRegistrationV1Oas3.d.ts +155 -0
  122. package/build/types/application-settings/developerClientRegistrationV1Oas3.js +5 -0
  123. package/build/types/application-settings/developerKeyManagementV1Oas3.d.ts +246 -0
  124. package/build/types/application-settings/developerKeyManagementV1Oas3.js +5 -0
  125. package/build/types/ebay-enums.d.ts +1204 -0
  126. package/build/types/ebay-enums.js +1330 -0
  127. package/build/types/ebay.d.ts +143 -0
  128. package/build/types/ebay.js +123 -0
  129. package/build/types/index.d.ts +6 -0
  130. package/build/types/index.js +10 -0
  131. package/build/types/sell-apps/account-management/sellAccountV1Oas3.d.ts +2579 -0
  132. package/build/types/sell-apps/account-management/sellAccountV1Oas3.js +5 -0
  133. package/build/types/sell-apps/analytics-and-report/sellAnalyticsV1Oas3.d.ts +446 -0
  134. package/build/types/sell-apps/analytics-and-report/sellAnalyticsV1Oas3.js +5 -0
  135. package/build/types/sell-apps/communication/commerceFeedbackV1BetaOas3.d.ts +705 -0
  136. package/build/types/sell-apps/communication/commerceFeedbackV1BetaOas3.js +5 -0
  137. package/build/types/sell-apps/communication/commerceMessageV1Oas3.d.ts +590 -0
  138. package/build/types/sell-apps/communication/commerceMessageV1Oas3.js +5 -0
  139. package/build/types/sell-apps/communication/commerceNotificationV1Oas3.d.ts +1276 -0
  140. package/build/types/sell-apps/communication/commerceNotificationV1Oas3.js +5 -0
  141. package/build/types/sell-apps/communication/sellNegotiationV1Oas3.d.ts +277 -0
  142. package/build/types/sell-apps/communication/sellNegotiationV1Oas3.js +5 -0
  143. package/build/types/sell-apps/listing-management/sellInventoryV1Oas3.d.ts +3133 -0
  144. package/build/types/sell-apps/listing-management/sellInventoryV1Oas3.js +5 -0
  145. package/build/types/sell-apps/listing-metadata/sellMetadataV1Oas3.d.ts +2289 -0
  146. package/build/types/sell-apps/listing-metadata/sellMetadataV1Oas3.js +5 -0
  147. package/build/types/sell-apps/markeitng-and-promotions/sellMarketingV1Oas3.d.ts +6650 -0
  148. package/build/types/sell-apps/markeitng-and-promotions/sellMarketingV1Oas3.js +5 -0
  149. package/build/types/sell-apps/markeitng-and-promotions/sellRecommendationV1Oas3.d.ts +172 -0
  150. package/build/types/sell-apps/markeitng-and-promotions/sellRecommendationV1Oas3.js +5 -0
  151. package/build/types/sell-apps/order-management/sellFulfillmentV1Oas3.d.ts +1869 -0
  152. package/build/types/sell-apps/order-management/sellFulfillmentV1Oas3.js +5 -0
  153. package/build/types/sell-apps/other-apis/commerceIdentityV1Oas3.d.ts +178 -0
  154. package/build/types/sell-apps/other-apis/commerceIdentityV1Oas3.js +5 -0
  155. package/build/types/sell-apps/other-apis/commerceTranslationV1BetaOas3.d.ts +128 -0
  156. package/build/types/sell-apps/other-apis/commerceTranslationV1BetaOas3.js +5 -0
  157. package/build/types/sell-apps/other-apis/commerceVeroV1Oas3.d.ts +417 -0
  158. package/build/types/sell-apps/other-apis/commerceVeroV1Oas3.js +5 -0
  159. package/build/types/sell-apps/other-apis/sellComplianceV1Oas3.d.ts +273 -0
  160. package/build/types/sell-apps/other-apis/sellComplianceV1Oas3.js +5 -0
  161. package/build/types/sell-apps/other-apis/sellEdeliveryInternationalShippingOas3.d.ts +2537 -0
  162. package/build/types/sell-apps/other-apis/sellEdeliveryInternationalShippingOas3.js +5 -0
  163. package/build/types/sell-apps/other-apis/sellMarketingV1Oas3.d.ts +6650 -0
  164. package/build/types/sell-apps/other-apis/sellMarketingV1Oas3.js +5 -0
  165. package/build/types/sell-apps/other-apis/sellRecommendationV1Oas3.d.ts +172 -0
  166. package/build/types/sell-apps/other-apis/sellRecommendationV1Oas3.js +5 -0
  167. package/build/utils/account-management/account.d.ts +1094 -0
  168. package/build/utils/account-management/account.js +831 -0
  169. package/build/utils/communication/feedback.d.ts +152 -0
  170. package/build/utils/communication/feedback.js +216 -0
  171. package/build/utils/communication/message.d.ts +174 -0
  172. package/build/utils/communication/message.js +242 -0
  173. package/build/utils/communication/negotiation.d.ts +123 -0
  174. package/build/utils/communication/negotiation.js +150 -0
  175. package/build/utils/communication/notification.d.ts +370 -0
  176. package/build/utils/communication/notification.js +369 -0
  177. package/build/utils/date-converter.d.ts +59 -0
  178. package/build/utils/date-converter.js +160 -0
  179. package/build/utils/llm-client-detector.d.ts +54 -0
  180. package/build/utils/llm-client-detector.js +318 -0
  181. package/build/utils/oauth-helper.d.ts +37 -0
  182. package/build/utils/oauth-helper.js +315 -0
  183. package/build/utils/order-management/dispute.d.ts +346 -0
  184. package/build/utils/order-management/dispute.js +369 -0
  185. package/build/utils/order-management/fulfillment.d.ts +200 -0
  186. package/build/utils/order-management/fulfillment.js +205 -0
  187. package/build/utils/other/compliance.d.ts +49 -0
  188. package/build/utils/other/compliance.js +76 -0
  189. package/build/utils/other/edelivery.d.ts +310 -0
  190. package/build/utils/other/edelivery.js +241 -0
  191. package/build/utils/other/identity.d.ts +13 -0
  192. package/build/utils/other/identity.js +13 -0
  193. package/build/utils/other/translation.d.ts +28 -0
  194. package/build/utils/other/translation.js +41 -0
  195. package/build/utils/other/vero.d.ts +61 -0
  196. package/build/utils/other/vero.js +90 -0
  197. package/build/utils/scope-helper.d.ts +49 -0
  198. package/build/utils/scope-helper.js +207 -0
  199. package/build/utils/security-checker.d.ts +46 -0
  200. package/build/utils/security-checker.js +248 -0
  201. package/build/utils/setup-validator.d.ts +25 -0
  202. package/build/utils/setup-validator.js +305 -0
  203. package/build/utils/token-utils.d.ts +40 -0
  204. package/build/utils/token-utils.js +40 -0
  205. package/package.json +115 -0
@@ -0,0 +1,565 @@
1
+ /**
2
+ * Marketing API - Marketing campaigns and promotions
3
+ * Based on: docs/sell-apps/marketing-and-promotions/sell_marketing_v1_oas3.json
4
+ */
5
+ export class MarketingApi {
6
+ client;
7
+ basePath = '/sell/marketing/v1';
8
+ constructor(client) {
9
+ this.client = client;
10
+ }
11
+ /**
12
+ * Get campaigns
13
+ */
14
+ async getCampaigns(campaignStatus, marketplaceId, limit) {
15
+ const params = {};
16
+ if (campaignStatus)
17
+ params.campaign_status = campaignStatus;
18
+ if (marketplaceId)
19
+ params.marketplace_id = marketplaceId;
20
+ if (limit)
21
+ params.limit = limit;
22
+ return await this.client.get(`${this.basePath}/ad_campaign`, params);
23
+ }
24
+ /**
25
+ * Get a specific campaign
26
+ */
27
+ async getCampaign(campaignId) {
28
+ return await this.client.get(`${this.basePath}/ad_campaign/${campaignId}`);
29
+ }
30
+ /**
31
+ * Create a campaign
32
+ */
33
+ async createCampaign(campaign) {
34
+ return await this.client.post(`${this.basePath}/ad_campaign`, campaign);
35
+ }
36
+ /**
37
+ * Get promotions
38
+ */
39
+ async getPromotions(marketplaceId, limit) {
40
+ const params = {};
41
+ if (marketplaceId)
42
+ params.marketplace_id = marketplaceId;
43
+ if (limit)
44
+ params.limit = limit;
45
+ return await this.client.get(`${this.basePath}/promotion`, params);
46
+ }
47
+ /**
48
+ * Create a promotion (item promotion)
49
+ */
50
+ async createPromotion(promotion) {
51
+ return await this.client.post(`${this.basePath}/item_promotion`, promotion);
52
+ }
53
+ /**
54
+ * Get ads for a campaign
55
+ */
56
+ async getAds(campaignId, adGroupIds, adStatus, limit, listingIds, offset) {
57
+ const params = {};
58
+ if (adGroupIds)
59
+ params.ad_group_ids = adGroupIds;
60
+ if (adStatus)
61
+ params.ad_status = adStatus;
62
+ if (limit)
63
+ params.limit = limit;
64
+ if (listingIds)
65
+ params.listing_ids = listingIds;
66
+ if (offset)
67
+ params.offset = offset;
68
+ return await this.client.get(`${this.basePath}/ad_campaign/${campaignId}/ad`, params);
69
+ }
70
+ /**
71
+ * Create an ad for a campaign
72
+ */
73
+ async createAd(campaignId, ad) {
74
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/ad`, ad);
75
+ }
76
+ /**
77
+ * Create ads by inventory reference for a campaign
78
+ */
79
+ async createAdsByInventoryReference(campaignId, ads) {
80
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/create_ads_by_inventory_reference`, ads);
81
+ }
82
+ /**
83
+ * Get a specific ad for a campaign
84
+ */
85
+ async getAd(campaignId, adId) {
86
+ return await this.client.get(`${this.basePath}/ad_campaign/${campaignId}/ad/${adId}`);
87
+ }
88
+ /**
89
+ * Delete a specific ad from a campaign
90
+ */
91
+ async deleteAd(campaignId, adId) {
92
+ return await this.client.delete(`${this.basePath}/ad_campaign/${campaignId}/ad/${adId}`);
93
+ }
94
+ /**
95
+ * Clone an ad for a campaign
96
+ */
97
+ async cloneAd(campaignId, adId, ad) {
98
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/ad/${adId}/clone`, ad);
99
+ }
100
+ /**
101
+ * Get ads by inventory reference for a campaign
102
+ */
103
+ async getAdsByInventoryReference(campaignId, inventoryReferenceId, inventoryReferenceType) {
104
+ const params = {
105
+ inventory_reference_id: inventoryReferenceId,
106
+ inventory_reference_type: inventoryReferenceType,
107
+ };
108
+ return await this.client.get(`${this.basePath}/ad_campaign/${campaignId}/get_ads_by_inventory_reference`, params);
109
+ }
110
+ /**
111
+ * Get ads by listing ID for a campaign
112
+ */
113
+ async getAdsByListingId(campaignId, listingId) {
114
+ const params = {
115
+ listing_id: listingId,
116
+ };
117
+ return await this.client.get(`${this.basePath}/ad_campaign/${campaignId}/get_ads_by_listing_id`, params);
118
+ }
119
+ /**
120
+ * Update the bid for an ad in a campaign
121
+ */
122
+ async updateBid(campaignId, adId, bid) {
123
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/ad/${adId}/update_bid`, bid);
124
+ }
125
+ /**
126
+ * Clone a campaign
127
+ */
128
+ async cloneCampaign(campaignId, campaign) {
129
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/clone`, campaign);
130
+ }
131
+ /**
132
+ * End a campaign
133
+ */
134
+ async endCampaign(campaignId) {
135
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/end`, {});
136
+ }
137
+ /**
138
+ * Get campaign by name
139
+ */
140
+ async getCampaignByName(campaignName) {
141
+ const params = {
142
+ campaign_name: campaignName,
143
+ };
144
+ return await this.client.get(`${this.basePath}/ad_campaign/get_campaign_by_name`, params);
145
+ }
146
+ /**
147
+ * Bulk create ads by inventory reference
148
+ */
149
+ async bulkCreateAdsByInventoryReference(campaignId, body) {
150
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/bulk_create_ads_by_inventory_reference`, body);
151
+ }
152
+ /**
153
+ * Bulk create ads by listing id
154
+ */
155
+ async bulkCreateAdsByListingId(campaignId, body) {
156
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/bulk_create_ads_by_listing_id`, body);
157
+ }
158
+ /**
159
+ * Bulk delete ads by inventory reference
160
+ */
161
+ async bulkDeleteAdsByInventoryReference(campaignId, body) {
162
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/bulk_delete_ads_by_inventory_reference`, body);
163
+ }
164
+ /**
165
+ * Bulk delete ads by listing id
166
+ */
167
+ async bulkDeleteAdsByListingId(campaignId, body) {
168
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/bulk_delete_ads_by_listing_id`, body);
169
+ }
170
+ /**
171
+ * Bulk update ads bid by inventory reference
172
+ */
173
+ async bulkUpdateAdsBidByInventoryReference(campaignId, body) {
174
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/bulk_update_ads_bid_by_inventory_reference`, body);
175
+ }
176
+ /**
177
+ * Bulk update ads bid by listing id
178
+ */
179
+ async bulkUpdateAdsBidByListingId(campaignId, body) {
180
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/bulk_update_ads_bid_by_listing_id`, body);
181
+ }
182
+ /**
183
+ * Bulk update ads status
184
+ */
185
+ async bulkUpdateAdsStatus(campaignId, body) {
186
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/bulk_update_ads_status`, body);
187
+ }
188
+ /**
189
+ * Bulk update ads status by listing id
190
+ */
191
+ async bulkUpdateAdsStatusByListingId(campaignId, body) {
192
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/bulk_update_ads_status_by_listing_id`, body);
193
+ }
194
+ /**
195
+ * Pause a campaign
196
+ */
197
+ async pauseCampaign(campaignId) {
198
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/pause`, {});
199
+ }
200
+ /**
201
+ * Resume a campaign
202
+ */
203
+ async resumeCampaign(campaignId) {
204
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/resume`, {});
205
+ }
206
+ /**
207
+ * Update campaign identification
208
+ */
209
+ async updateCampaignIdentification(campaignId, body) {
210
+ return await this.client.put(`${this.basePath}/ad_campaign/${campaignId}/update_campaign_identification`, body);
211
+ }
212
+ /**
213
+ * Create an ad group
214
+ */
215
+ async createAdGroup(campaignId, body) {
216
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/ad_group`, body);
217
+ }
218
+ /**
219
+ * Clone an ad group
220
+ */
221
+ async cloneAdGroup(campaignId, adGroupId, body) {
222
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/ad_group/${adGroupId}/clone`, body);
223
+ }
224
+ /**
225
+ * Get ad groups
226
+ */
227
+ async getAdGroups(campaignId, adGroupStatus, limit, offset) {
228
+ const params = {};
229
+ if (adGroupStatus)
230
+ params.ad_group_status = adGroupStatus;
231
+ if (limit)
232
+ params.limit = limit;
233
+ if (offset)
234
+ params.offset = offset;
235
+ return await this.client.get(`${this.basePath}/ad_campaign/${campaignId}/ad_group`, params);
236
+ }
237
+ /**
238
+ * Get an ad group
239
+ */
240
+ async getAdGroup(campaignId, adGroupId) {
241
+ return await this.client.get(`${this.basePath}/ad_campaign/${campaignId}/ad_group/${adGroupId}`);
242
+ }
243
+ /**
244
+ * Suggest bids for an ad group
245
+ */
246
+ async suggestBids(campaignId, adGroupId) {
247
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/ad_group/${adGroupId}/suggest_bids`, {});
248
+ }
249
+ /**
250
+ * Update ad group bids
251
+ */
252
+ async updateAdGroupBids(campaignId, adGroupId, body) {
253
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/ad_group/${adGroupId}/update_ad_group_bids`, body);
254
+ }
255
+ /**
256
+ * Update ad group keywords
257
+ */
258
+ async updateAdGroupKeywords(campaignId, adGroupId, body) {
259
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/ad_group/${adGroupId}/update_ad_group_keywords`, body);
260
+ }
261
+ /**
262
+ * Suggest keywords
263
+ */
264
+ async suggestKeywords(campaignId, adGroupId, body) {
265
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/ad_group/${adGroupId}/suggest_keywords`, body);
266
+ }
267
+ /**
268
+ * Get keywords
269
+ */
270
+ async getKeywords(campaignId, adGroupId, keywordStatus, limit, offset) {
271
+ const params = {};
272
+ if (keywordStatus)
273
+ params.keyword_status = keywordStatus;
274
+ if (limit)
275
+ params.limit = limit;
276
+ if (offset)
277
+ params.offset = offset;
278
+ return await this.client.get(`${this.basePath}/ad_campaign/${campaignId}/ad_group/${adGroupId}/keyword`, params);
279
+ }
280
+ /**
281
+ * Bulk create keywords
282
+ */
283
+ async bulkCreateKeywords(campaignId, adGroupId, body) {
284
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/ad_group/${adGroupId}/bulk_create_keywords`, body);
285
+ }
286
+ /**
287
+ * Bulk delete keywords
288
+ */
289
+ async bulkDeleteKeywords(campaignId, adGroupId, body) {
290
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/ad_group/${adGroupId}/bulk_delete_keywords`, body);
291
+ }
292
+ /**
293
+ * Bulk update keyword bids
294
+ */
295
+ async bulkUpdateKeywordBids(campaignId, adGroupId, body) {
296
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/ad_group/${adGroupId}/bulk_update_keyword_bids`, body);
297
+ }
298
+ /**
299
+ * Create a keyword
300
+ */
301
+ async createKeyword(campaignId, adGroupId, body) {
302
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/ad_group/${adGroupId}/create_keyword`, body);
303
+ }
304
+ /**
305
+ * Get a keyword
306
+ */
307
+ async getKeyword(campaignId, adGroupId, keywordId) {
308
+ return await this.client.get(`${this.basePath}/ad_campaign/${campaignId}/ad_group/${adGroupId}/keyword/${keywordId}`);
309
+ }
310
+ /**
311
+ * Delete a keyword
312
+ */
313
+ async deleteKeyword(campaignId, adGroupId, keywordId) {
314
+ return await this.client.delete(`${this.basePath}/ad_campaign/${campaignId}/ad_group/${adGroupId}/keyword/${keywordId}`);
315
+ }
316
+ /**
317
+ * Update a keyword's bid
318
+ */
319
+ async updateKeywordBid(campaignId, adGroupId, keywordId, body) {
320
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/ad_group/${adGroupId}/keyword/${keywordId}/update_bid`, body);
321
+ }
322
+ /**
323
+ * Get ad report
324
+ */
325
+ async getAdReport(dimension, metric, startDate, endDate, sort, listingIds, marketplaceId) {
326
+ const params = {
327
+ dimension,
328
+ metric,
329
+ start_date: startDate,
330
+ end_date: endDate,
331
+ };
332
+ if (sort)
333
+ params.sort = sort;
334
+ if (listingIds)
335
+ params.listing_ids = listingIds;
336
+ if (marketplaceId)
337
+ params.marketplace_id = marketplaceId;
338
+ return await this.client.get(`${this.basePath}/ad_report`, params);
339
+ }
340
+ /**
341
+ * Get ad report metadata
342
+ */
343
+ async getAdReportMetadata() {
344
+ return await this.client.get(`${this.basePath}/ad_report_metadata`);
345
+ }
346
+ /**
347
+ * Get ad report metadata for a report type
348
+ */
349
+ async getAdReportMetadataForReportType(reportType) {
350
+ return await this.client.get(`${this.basePath}/ad_report_metadata/${reportType}`);
351
+ }
352
+ /**
353
+ * Create a report task
354
+ */
355
+ async createReportTask(body) {
356
+ return await this.client.post(`${this.basePath}/ad_report_task`, body);
357
+ }
358
+ /**
359
+ * Get report tasks
360
+ */
361
+ async getReportTasks(reportTaskStatuses, limit, offset) {
362
+ const params = {};
363
+ if (reportTaskStatuses)
364
+ params.report_task_statuses = reportTaskStatuses;
365
+ if (limit)
366
+ params.limit = limit;
367
+ if (offset)
368
+ params.offset = offset;
369
+ return await this.client.get(`${this.basePath}/ad_report_task`, params);
370
+ }
371
+ /**
372
+ * Get a report task
373
+ */
374
+ async getReportTask(reportTaskId) {
375
+ return await this.client.get(`${this.basePath}/ad_report_task/${reportTaskId}`);
376
+ }
377
+ /**
378
+ * Get an item promotion
379
+ */
380
+ async getItemPromotion(promotionId) {
381
+ return await this.client.get(`${this.basePath}/item_promotion/${promotionId}`);
382
+ }
383
+ /**
384
+ * Delete an item promotion
385
+ */
386
+ async deleteItemPromotion(promotionId) {
387
+ return await this.client.delete(`${this.basePath}/item_promotion/${promotionId}`);
388
+ }
389
+ /**
390
+ * Pause an item promotion
391
+ */
392
+ async pauseItemPromotion(promotionId) {
393
+ return await this.client.post(`${this.basePath}/item_promotion/${promotionId}/pause`, {});
394
+ }
395
+ /**
396
+ * Resume an item promotion
397
+ */
398
+ async resumeItemPromotion(promotionId) {
399
+ return await this.client.post(`${this.basePath}/item_promotion/${promotionId}/resume`, {});
400
+ }
401
+ /**
402
+ * Update an item promotion
403
+ */
404
+ async updateItemPromotion(promotionId, body) {
405
+ return await this.client.put(`${this.basePath}/item_promotion/${promotionId}`, body);
406
+ }
407
+ /**
408
+ * Get a promotion report
409
+ */
410
+ async getPromotionReport(marketplaceId, promotionStatus, limit, offset) {
411
+ const params = {
412
+ marketplace_id: marketplaceId,
413
+ };
414
+ if (promotionStatus)
415
+ params.promotion_status = promotionStatus;
416
+ if (limit)
417
+ params.limit = limit;
418
+ if (offset)
419
+ params.offset = offset;
420
+ return await this.client.get(`${this.basePath}/promotion_report`, params);
421
+ }
422
+ /**
423
+ * Get a promotion summary report
424
+ */
425
+ async getPromotionSummaryReport(marketplaceId) {
426
+ const params = { marketplace_id: marketplaceId };
427
+ return await this.client.get(`${this.basePath}/promotion_summary_report`, params);
428
+ }
429
+ /**
430
+ * Get promotion summary (alias for getPromotionSummaryReport)
431
+ */
432
+ async getPromotionSummary(marketplaceId) {
433
+ return this.getPromotionSummaryReport(marketplaceId);
434
+ }
435
+ /**
436
+ * Get promotion reports (alias for getPromotionReport)
437
+ */
438
+ async getPromotionReports(marketplaceId, promotionStatus, limit, offset) {
439
+ return this.getPromotionReport(marketplaceId, promotionStatus, limit, offset);
440
+ }
441
+ /**
442
+ * Get targeting for a campaign
443
+ */
444
+ async getTargeting(campaignId) {
445
+ return await this.client.get(`${this.basePath}/ad_campaign/${campaignId}/targeting`);
446
+ }
447
+ /**
448
+ * Create targeting for a campaign
449
+ */
450
+ async createTargeting(campaignId, body) {
451
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/targeting`, body);
452
+ }
453
+ /**
454
+ * Update targeting for a campaign
455
+ */
456
+ async updateTargeting(campaignId, body) {
457
+ return await this.client.put(`${this.basePath}/ad_campaign/${campaignId}/targeting`, body);
458
+ }
459
+ /**
460
+ * Get negative keywords for a campaign
461
+ */
462
+ async getNegativeKeywords(campaignId, limit, offset) {
463
+ const params = {};
464
+ if (limit)
465
+ params.limit = limit;
466
+ if (offset)
467
+ params.offset = offset;
468
+ return await this.client.get(`${this.basePath}/ad_campaign/${campaignId}/negative_keyword`, params);
469
+ }
470
+ /**
471
+ * Create a negative keyword for a campaign
472
+ */
473
+ async createNegativeKeyword(campaignId, body) {
474
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/negative_keyword`, body);
475
+ }
476
+ /**
477
+ * Bulk create negative keywords for a campaign
478
+ */
479
+ async bulkCreateNegativeKeywords(campaignId, body) {
480
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/bulk_create_negative_keywords`, body);
481
+ }
482
+ /**
483
+ * Bulk delete negative keywords for a campaign
484
+ */
485
+ async bulkDeleteNegativeKeywords(campaignId, body) {
486
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/bulk_delete_negative_keywords`, body);
487
+ }
488
+ /**
489
+ * Bulk update negative keywords for a campaign
490
+ */
491
+ async bulkUpdateNegativeKeywords(campaignId, body) {
492
+ return await this.client.post(`${this.basePath}/ad_campaign/${campaignId}/bulk_update_negative_keywords`, body);
493
+ }
494
+ /**
495
+ * Get a negative keyword for a campaign
496
+ */
497
+ async getNegativeKeyword(campaignId, negativeKeywordId) {
498
+ return await this.client.get(`${this.basePath}/ad_campaign/${campaignId}/negative_keyword/${negativeKeywordId}`);
499
+ }
500
+ /**
501
+ * Delete a negative keyword for a campaign
502
+ */
503
+ async deleteNegativeKeyword(campaignId, negativeKeywordId) {
504
+ return await this.client.delete(`${this.basePath}/ad_campaign/${campaignId}/negative_keyword/${negativeKeywordId}`);
505
+ }
506
+ /**
507
+ * Update a negative keyword for a campaign
508
+ */
509
+ async updateNegativeKeyword(campaignId, negativeKeywordId, body) {
510
+ return await this.client.put(`${this.basePath}/ad_campaign/${campaignId}/negative_keyword/${negativeKeywordId}`, body);
511
+ }
512
+ /**
513
+ * Get negative keywords for an ad group
514
+ */
515
+ async getNegativeKeywordsForAdGroup(adGroupId, limit, offset) {
516
+ const params = {};
517
+ if (limit)
518
+ params.limit = limit;
519
+ if (offset)
520
+ params.offset = offset;
521
+ return await this.client.get(`${this.basePath}/ad_group/${adGroupId}/negative_keyword`, params);
522
+ }
523
+ /**
524
+ * Create a negative keyword for an ad group
525
+ */
526
+ async createNegativeKeywordForAdGroup(adGroupId, body) {
527
+ return await this.client.post(`${this.basePath}/ad_group/${adGroupId}/negative_keyword`, body);
528
+ }
529
+ /**
530
+ * Bulk create negative keywords for an ad group
531
+ */
532
+ async bulkCreateNegativeKeywordsForAdGroup(adGroupId, body) {
533
+ return await this.client.post(`${this.basePath}/ad_group/${adGroupId}/bulk_create_negative_keywords`, body);
534
+ }
535
+ /**
536
+ * Bulk delete negative keywords for an ad group
537
+ */
538
+ async bulkDeleteNegativeKeywordsForAdGroup(adGroupId, body) {
539
+ return await this.client.post(`${this.basePath}/ad_group/${adGroupId}/bulk_delete_negative_keywords`, body);
540
+ }
541
+ /**
542
+ * Bulk update negative keywords for an ad group
543
+ */
544
+ async bulkUpdateNegativeKeywordsForAdGroup(adGroupId, body) {
545
+ return await this.client.post(`${this.basePath}/ad_group/${adGroupId}/bulk_update_negative_keywords`, body);
546
+ }
547
+ /**
548
+ * Get a negative keyword for an ad group
549
+ */
550
+ async getNegativeKeywordForAdGroup(adGroupId, negativeKeywordId) {
551
+ return await this.client.get(`${this.basePath}/ad_group/${adGroupId}/negative_keyword/${negativeKeywordId}`);
552
+ }
553
+ /**
554
+ * Delete a negative keyword for an ad group
555
+ */
556
+ async deleteNegativeKeywordForAdGroup(adGroupId, negativeKeywordId) {
557
+ return await this.client.delete(`${this.basePath}/ad_group/${adGroupId}/negative_keyword/${negativeKeywordId}`);
558
+ }
559
+ /**
560
+ * Update a negative keyword for an ad group
561
+ */
562
+ async updateNegativeKeywordForAdGroup(adGroupId, negativeKeywordId, body) {
563
+ return await this.client.put(`${this.basePath}/ad_group/${adGroupId}/negative_keyword/${negativeKeywordId}`, body);
564
+ }
565
+ }
@@ -0,0 +1,20 @@
1
+ import type { EbayApiClient } from '../../api/client.js';
2
+ import type { components } from '../../types/sell-apps/markeitng-and-promotions/sellRecommendationV1Oas3.js';
3
+ type PagedListingRecommendationCollection = components['schemas']['PagedListingRecommendationCollection'];
4
+ /**
5
+ * Recommendation API - Listing recommendations
6
+ * Based on: docs/sell-apps/marketing-and-promotions/sell_recommendation_v1_oas3.json
7
+ */
8
+ export declare class RecommendationApi {
9
+ private client;
10
+ private readonly basePath;
11
+ constructor(client: EbayApiClient);
12
+ /**
13
+ * Find listing recommendations
14
+ * Endpoint: POST /find
15
+ */
16
+ findListingRecommendations(requestBody?: {
17
+ listingIds?: string[];
18
+ }, filter?: string, limit?: number, offset?: number, marketplaceId?: string): Promise<PagedListingRecommendationCollection>;
19
+ }
20
+ export {};
@@ -0,0 +1,32 @@
1
+ /**
2
+ * Recommendation API - Listing recommendations
3
+ * Based on: docs/sell-apps/marketing-and-promotions/sell_recommendation_v1_oas3.json
4
+ */
5
+ export class RecommendationApi {
6
+ client;
7
+ basePath = '/sell/recommendation/v1';
8
+ constructor(client) {
9
+ this.client = client;
10
+ }
11
+ /**
12
+ * Find listing recommendations
13
+ * Endpoint: POST /find
14
+ */
15
+ async findListingRecommendations(requestBody, filter, limit, offset, marketplaceId) {
16
+ const params = {};
17
+ if (filter)
18
+ params.filter = filter;
19
+ if (limit)
20
+ params.limit = limit;
21
+ if (offset)
22
+ params.offset = offset;
23
+ const headers = {};
24
+ if (marketplaceId) {
25
+ headers['X-EBAY-C-MARKETPLACE-ID'] = marketplaceId;
26
+ }
27
+ return await this.client.post(`${this.basePath}/find`, requestBody || {}, {
28
+ params,
29
+ headers,
30
+ });
31
+ }
32
+ }
@@ -0,0 +1,65 @@
1
+ import type { EbayApiClient } from '../../api/client.js';
2
+ import type { components } from '../../types/sell-apps/order-management/sellFulfillmentV1Oas3.js';
3
+ type AcceptPaymentDisputeRequest = components['schemas']['AcceptPaymentDisputeRequest'];
4
+ type ContestPaymentDisputeRequest = components['schemas']['ContestPaymentDisputeRequest'];
5
+ type DisputeSummaryResponse = components['schemas']['DisputeSummaryResponse'];
6
+ type PaymentDispute = components['schemas']['PaymentDispute'];
7
+ type PaymentDisputeActivityHistory = components['schemas']['PaymentDisputeActivityHistory'];
8
+ type FileEvidence = components['schemas']['FileEvidence'];
9
+ type AddEvidencePaymentDisputeRequest = components['schemas']['AddEvidencePaymentDisputeRequest'];
10
+ type AddEvidencePaymentDisputeResponse = components['schemas']['AddEvidencePaymentDisputeResponse'];
11
+ type UpdateEvidencePaymentDisputeRequest = components['schemas']['UpdateEvidencePaymentDisputeRequest'];
12
+ /**
13
+ * Dispute API - Manage payment disputes
14
+ * Based on: docs/sell-apps/order-management/sell_fulfillment_v1_oas3.json
15
+ */
16
+ export declare class DisputeApi {
17
+ private client;
18
+ private readonly basePath;
19
+ constructor(client: EbayApiClient);
20
+ /**
21
+ * Get payment dispute details
22
+ */
23
+ getPaymentDispute(paymentDisputeId: string): Promise<PaymentDispute>;
24
+ /**
25
+ * Get payment dispute evidence file
26
+ */
27
+ fetchEvidenceContent(paymentDisputeId: string, evidenceId: string, fileId: string): Promise<ArrayBuffer>;
28
+ /**
29
+ * Get payment dispute activity
30
+ */
31
+ getActivities(paymentDisputeId: string): Promise<PaymentDisputeActivityHistory>;
32
+ /**
33
+ * Search for payment disputes
34
+ */
35
+ getPaymentDisputeSummaries(params?: {
36
+ order_id?: string;
37
+ buyer_username?: string;
38
+ open_date_from?: string;
39
+ open_date_to?: string;
40
+ payment_dispute_status?: string;
41
+ limit?: number;
42
+ offset?: number;
43
+ }): Promise<DisputeSummaryResponse>;
44
+ /**
45
+ * Contest a payment dispute
46
+ */
47
+ contestPaymentDispute(paymentDisputeId: string, body?: ContestPaymentDisputeRequest): Promise<void>;
48
+ /**
49
+ * Accept a payment dispute
50
+ */
51
+ acceptPaymentDispute(paymentDisputeId: string, body?: AcceptPaymentDisputeRequest): Promise<void>;
52
+ /**
53
+ * Upload an evidence file
54
+ */
55
+ uploadEvidenceFile(paymentDisputeId: string, body: ArrayBuffer): Promise<FileEvidence>;
56
+ /**
57
+ * Add an evidence file
58
+ */
59
+ addEvidence(paymentDisputeId: string, body: AddEvidencePaymentDisputeRequest): Promise<AddEvidencePaymentDisputeResponse>;
60
+ /**
61
+ * Update an evidence file
62
+ */
63
+ updateEvidence(paymentDisputeId: string, body: UpdateEvidencePaymentDisputeRequest): Promise<void>;
64
+ }
65
+ export {};