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,428 @@
1
+ import { MarketplaceId } from '../../types/ebay-enums.js';
2
+ import { z } from 'zod';
3
+ import { zodToJsonSchema } from 'zod-to-json-schema';
4
+ import { bulkSalesTaxRequestSchema, customPolicySchema, fulfillmentPolicySchema, paymentPolicySchema, programRequestSchema, returnPolicySchema, salesTaxBaseSchema, } from '../schemas.js';
5
+ import { customPolicyResponseSchema, getFulfillmentPoliciesOutputSchema, createFulfillmentPolicyOutputSchema, fulfillmentPolicyResponseSchema, getPaymentPoliciesOutputSchema, createPaymentPolicyOutputSchema, paymentPolicyResponseSchema, getReturnPoliciesOutputSchema, createReturnPolicyOutputSchema, returnPolicyResponseSchema, createCustomPolicyOutputSchema, getSalesTaxesOutputSchema, salesTaxSchema, kycOutputSchema, privilegesOutputSchema, programsOutputSchema, } from '../../schemas/account-management/account.js';
6
+ export const accountTools = [
7
+ {
8
+ name: 'ebay_get_custom_policies',
9
+ description: 'Retrieve custom policies defined for the seller account',
10
+ inputSchema: {
11
+ policyTypes: z
12
+ .string()
13
+ .optional()
14
+ .describe('Comma-delimited list of policy types to retrieve'),
15
+ },
16
+ outputSchema: zodToJsonSchema(customPolicyResponseSchema, {
17
+ name: 'CustomPoliciesResponse',
18
+ $refStrategy: 'none',
19
+ }),
20
+ },
21
+ {
22
+ name: 'ebay_get_fulfillment_policies',
23
+ description: 'Get fulfillment policies for the seller.\n\nRequired OAuth Scope: sell.account.readonly or sell.account\nMinimum Scope: https://api.ebay.com/oauth/api_scope/sell.account.readonly',
24
+ inputSchema: {
25
+ marketplaceId: z.nativeEnum(MarketplaceId).describe('Required: eBay marketplace ID'),
26
+ },
27
+ outputSchema: zodToJsonSchema(getFulfillmentPoliciesOutputSchema, {
28
+ name: 'FulfillmentPoliciesResponse',
29
+ $refStrategy: 'none',
30
+ }),
31
+ },
32
+ {
33
+ name: 'ebay_get_payment_policies',
34
+ description: 'Get payment policies for the seller',
35
+ inputSchema: {
36
+ marketplaceId: z.nativeEnum(MarketplaceId).describe('Required: eBay marketplace ID'),
37
+ },
38
+ outputSchema: zodToJsonSchema(getPaymentPoliciesOutputSchema, {
39
+ name: 'PaymentPoliciesResponse',
40
+ $refStrategy: 'none',
41
+ }),
42
+ },
43
+ {
44
+ name: 'ebay_get_return_policies',
45
+ description: 'Get return policies for the seller',
46
+ inputSchema: {
47
+ marketplaceId: z.nativeEnum(MarketplaceId).describe('Required: eBay marketplace ID'),
48
+ },
49
+ outputSchema: zodToJsonSchema(getReturnPoliciesOutputSchema, {
50
+ name: 'ReturnPoliciesResponse',
51
+ $refStrategy: 'none',
52
+ }),
53
+ },
54
+ // Fulfillment Policy CRUD
55
+ {
56
+ name: 'ebay_create_fulfillment_policy',
57
+ description: 'Create a new fulfillment policy.\n\nRequired OAuth Scope: sell.account\nMinimum Scope: https://api.ebay.com/oauth/api_scope/sell.account',
58
+ inputSchema: {
59
+ policy: fulfillmentPolicySchema.describe('Fulfillment policy details'),
60
+ },
61
+ outputSchema: zodToJsonSchema(createFulfillmentPolicyOutputSchema, {
62
+ name: 'CreateFulfillmentPolicyResponse',
63
+ $refStrategy: 'none',
64
+ }),
65
+ },
66
+ {
67
+ name: 'ebay_get_fulfillment_policy',
68
+ description: 'Get a specific fulfillment policy by ID',
69
+ inputSchema: {
70
+ fulfillmentPolicyId: z.string().describe('The fulfillment policy ID'),
71
+ },
72
+ outputSchema: zodToJsonSchema(fulfillmentPolicyResponseSchema, {
73
+ name: 'FulfillmentPolicyResponse',
74
+ $refStrategy: 'none',
75
+ }),
76
+ },
77
+ {
78
+ name: 'ebay_get_fulfillment_policy_by_name',
79
+ description: 'Get a fulfillment policy by name',
80
+ inputSchema: {
81
+ marketplaceId: z.nativeEnum(MarketplaceId).describe('eBay marketplace ID'),
82
+ name: z.string().describe('Policy name'),
83
+ },
84
+ outputSchema: zodToJsonSchema(fulfillmentPolicyResponseSchema, {
85
+ name: 'FulfillmentPolicyResponse',
86
+ $refStrategy: 'none',
87
+ }),
88
+ },
89
+ {
90
+ name: 'ebay_update_fulfillment_policy',
91
+ description: 'Update an existing fulfillment policy',
92
+ inputSchema: {
93
+ fulfillmentPolicyId: z.string().describe('The fulfillment policy ID'),
94
+ policy: fulfillmentPolicySchema.describe('Updated fulfillment policy details'),
95
+ },
96
+ outputSchema: zodToJsonSchema(createFulfillmentPolicyOutputSchema, {
97
+ name: 'UpdateFulfillmentPolicyResponse',
98
+ $refStrategy: 'none',
99
+ }),
100
+ },
101
+ {
102
+ name: 'ebay_delete_fulfillment_policy',
103
+ description: 'Delete a fulfillment policy',
104
+ inputSchema: {
105
+ fulfillmentPolicyId: z.string().describe('The fulfillment policy ID'),
106
+ },
107
+ outputSchema: {
108
+ type: 'object',
109
+ properties: {},
110
+ description: 'Empty response on successful deletion (HTTP 204)',
111
+ },
112
+ },
113
+ // Payment Policy CRUD
114
+ {
115
+ name: 'ebay_create_payment_policy',
116
+ description: 'Create a new payment policy',
117
+ inputSchema: {
118
+ policy: paymentPolicySchema.describe('Payment policy details'),
119
+ },
120
+ outputSchema: zodToJsonSchema(createPaymentPolicyOutputSchema, {
121
+ name: 'CreatePaymentPolicyResponse',
122
+ $refStrategy: 'none',
123
+ }),
124
+ },
125
+ {
126
+ name: 'ebay_get_payment_policy',
127
+ description: 'Get a specific payment policy by ID',
128
+ inputSchema: {
129
+ paymentPolicyId: z.string().describe('The payment policy ID'),
130
+ },
131
+ outputSchema: zodToJsonSchema(paymentPolicyResponseSchema, {
132
+ name: 'PaymentPolicyResponse',
133
+ $refStrategy: 'none',
134
+ }),
135
+ },
136
+ {
137
+ name: 'ebay_get_payment_policy_by_name',
138
+ description: 'Get a payment policy by name',
139
+ inputSchema: {
140
+ marketplaceId: z.nativeEnum(MarketplaceId).describe('eBay marketplace ID'),
141
+ name: z.string().describe('Policy name'),
142
+ },
143
+ outputSchema: zodToJsonSchema(paymentPolicyResponseSchema, {
144
+ name: 'PaymentPolicyResponse',
145
+ $refStrategy: 'none',
146
+ }),
147
+ },
148
+ {
149
+ name: 'ebay_update_payment_policy',
150
+ description: 'Update an existing payment policy',
151
+ inputSchema: {
152
+ paymentPolicyId: z.string().describe('The payment policy ID'),
153
+ policy: paymentPolicySchema.describe('Updated payment policy details'),
154
+ },
155
+ outputSchema: zodToJsonSchema(createPaymentPolicyOutputSchema, {
156
+ name: 'UpdatePaymentPolicyResponse',
157
+ $refStrategy: 'none',
158
+ }),
159
+ },
160
+ {
161
+ name: 'ebay_delete_payment_policy',
162
+ description: 'Delete a payment policy',
163
+ inputSchema: {
164
+ paymentPolicyId: z.string().describe('The payment policy ID'),
165
+ },
166
+ outputSchema: {
167
+ type: 'object',
168
+ properties: {},
169
+ description: 'Empty response on successful deletion (HTTP 204)',
170
+ },
171
+ },
172
+ // Return Policy CRUD
173
+ {
174
+ name: 'ebay_create_return_policy',
175
+ description: 'Create a new return policy',
176
+ inputSchema: {
177
+ policy: returnPolicySchema.describe('Return policy details'),
178
+ },
179
+ outputSchema: zodToJsonSchema(createReturnPolicyOutputSchema, {
180
+ name: 'CreateReturnPolicyResponse',
181
+ $refStrategy: 'none',
182
+ }),
183
+ },
184
+ {
185
+ name: 'ebay_get_return_policy',
186
+ description: 'Get a specific return policy by ID',
187
+ inputSchema: {
188
+ returnPolicyId: z.string().describe('The return policy ID'),
189
+ },
190
+ outputSchema: zodToJsonSchema(returnPolicyResponseSchema, {
191
+ name: 'ReturnPolicyResponse',
192
+ $refStrategy: 'none',
193
+ }),
194
+ },
195
+ {
196
+ name: 'ebay_get_return_policy_by_name',
197
+ description: 'Get a return policy by name',
198
+ inputSchema: {
199
+ marketplaceId: z.nativeEnum(MarketplaceId).describe('eBay marketplace ID'),
200
+ name: z.string().describe('Policy name'),
201
+ },
202
+ outputSchema: zodToJsonSchema(returnPolicyResponseSchema, {
203
+ name: 'ReturnPolicyResponse',
204
+ $refStrategy: 'none',
205
+ }),
206
+ },
207
+ {
208
+ name: 'ebay_update_return_policy',
209
+ description: 'Update an existing return policy',
210
+ inputSchema: {
211
+ returnPolicyId: z.string().describe('The return policy ID'),
212
+ policy: returnPolicySchema.describe('Updated return policy details'),
213
+ },
214
+ outputSchema: zodToJsonSchema(createReturnPolicyOutputSchema, {
215
+ name: 'UpdateReturnPolicyResponse',
216
+ $refStrategy: 'none',
217
+ }),
218
+ },
219
+ {
220
+ name: 'ebay_delete_return_policy',
221
+ description: 'Delete a return policy',
222
+ inputSchema: {
223
+ returnPolicyId: z.string().describe('The return policy ID'),
224
+ },
225
+ outputSchema: {
226
+ type: 'object',
227
+ properties: {},
228
+ description: 'Empty response on successful deletion (HTTP 204)',
229
+ },
230
+ },
231
+ // Custom Policy CRUD
232
+ {
233
+ name: 'ebay_create_custom_policy',
234
+ description: 'Create a new custom policy',
235
+ inputSchema: {
236
+ policy: customPolicySchema.describe('Custom policy details'),
237
+ },
238
+ outputSchema: zodToJsonSchema(createCustomPolicyOutputSchema, {
239
+ name: 'CreateCustomPolicyResponse',
240
+ $refStrategy: 'none',
241
+ }),
242
+ },
243
+ {
244
+ name: 'ebay_get_custom_policy',
245
+ description: 'Get a specific custom policy by ID',
246
+ inputSchema: {
247
+ customPolicyId: z.string().describe('The custom policy ID'),
248
+ },
249
+ outputSchema: zodToJsonSchema(createCustomPolicyOutputSchema, {
250
+ name: 'CustomPolicyResponse',
251
+ $refStrategy: 'none',
252
+ }),
253
+ },
254
+ {
255
+ name: 'ebay_update_custom_policy',
256
+ description: 'Update an existing custom policy',
257
+ inputSchema: {
258
+ customPolicyId: z.string().describe('The custom policy ID'),
259
+ policy: customPolicySchema.describe('Updated custom policy details'),
260
+ },
261
+ outputSchema: zodToJsonSchema(createCustomPolicyOutputSchema, {
262
+ name: 'UpdateCustomPolicyResponse',
263
+ $refStrategy: 'none',
264
+ }),
265
+ },
266
+ {
267
+ name: 'ebay_delete_custom_policy',
268
+ description: 'Delete a custom policy',
269
+ inputSchema: {
270
+ customPolicyId: z.string().describe('The custom policy ID'),
271
+ },
272
+ outputSchema: {
273
+ type: 'object',
274
+ properties: {},
275
+ description: 'Empty response on successful deletion (HTTP 204)',
276
+ },
277
+ },
278
+ // KYC, Payments, Programs, Sales Tax, Subscription
279
+ {
280
+ name: 'ebay_get_kyc',
281
+ description: 'Get seller KYC (Know Your Customer) status',
282
+ inputSchema: {},
283
+ outputSchema: zodToJsonSchema(kycOutputSchema, {
284
+ name: 'KYCResponse',
285
+ $refStrategy: 'none',
286
+ }),
287
+ },
288
+ {
289
+ name: 'ebay_opt_in_to_payments_program',
290
+ description: 'Opt-in to a payments program',
291
+ inputSchema: {
292
+ marketplaceId: z.nativeEnum(MarketplaceId).describe('eBay marketplace ID'),
293
+ paymentsProgramType: z.string().describe('Payments program type'),
294
+ },
295
+ },
296
+ {
297
+ name: 'ebay_get_payments_program_status',
298
+ description: 'Get payments program status',
299
+ inputSchema: {
300
+ marketplaceId: z.nativeEnum(MarketplaceId).describe('eBay marketplace ID'),
301
+ paymentsProgramType: z.string().describe('Payments program type'),
302
+ },
303
+ },
304
+ {
305
+ name: 'ebay_get_rate_tables',
306
+ description: 'Get seller rate tables',
307
+ inputSchema: {},
308
+ },
309
+ {
310
+ name: 'ebay_create_or_replace_sales_tax',
311
+ description: 'Create or replace sales tax table for a jurisdiction',
312
+ inputSchema: {
313
+ countryCode: z.string().describe('Two-letter ISO 3166 country code'),
314
+ jurisdictionId: z.string().describe('Tax jurisdiction ID'),
315
+ salesTaxBase: salesTaxBaseSchema.describe('Sales tax details'),
316
+ },
317
+ },
318
+ {
319
+ name: 'ebay_bulk_create_or_replace_sales_tax',
320
+ description: 'Bulk create or replace sales tax tables',
321
+ inputSchema: {
322
+ requests: bulkSalesTaxRequestSchema.describe('Array of sales tax requests'),
323
+ },
324
+ },
325
+ {
326
+ name: 'ebay_delete_sales_tax',
327
+ description: 'Delete sales tax table for a jurisdiction',
328
+ inputSchema: {
329
+ countryCode: z.string().describe('Two-letter ISO 3166 country code'),
330
+ jurisdictionId: z.string().describe('Tax jurisdiction ID'),
331
+ },
332
+ },
333
+ {
334
+ name: 'ebay_get_sales_tax',
335
+ description: 'Get sales tax table for a jurisdiction',
336
+ inputSchema: {
337
+ countryCode: z.string().describe('Two-letter ISO 3166 country code'),
338
+ jurisdictionId: z.string().describe('Tax jurisdiction ID'),
339
+ },
340
+ outputSchema: zodToJsonSchema(salesTaxSchema, {
341
+ name: 'SalesTaxResponse',
342
+ $refStrategy: 'none',
343
+ }),
344
+ },
345
+ {
346
+ name: 'ebay_get_sales_taxes',
347
+ description: 'Get all sales tax tables for a country',
348
+ inputSchema: {
349
+ countryCode: z.string().describe('Required: Two-letter ISO 3166-1 country code'),
350
+ },
351
+ outputSchema: zodToJsonSchema(getSalesTaxesOutputSchema, {
352
+ name: 'GetSalesTaxesResponse',
353
+ $refStrategy: 'none',
354
+ }),
355
+ },
356
+ {
357
+ name: 'ebay_get_subscription',
358
+ description: 'Get seller subscription information',
359
+ inputSchema: {
360
+ limitType: z.string().optional().describe('Optional limit type filter'),
361
+ },
362
+ },
363
+ {
364
+ name: 'ebay_opt_in_to_program',
365
+ description: 'Opt-in to a seller program',
366
+ inputSchema: {
367
+ request: programRequestSchema.describe('Program opt-in request'),
368
+ },
369
+ },
370
+ {
371
+ name: 'ebay_opt_out_of_program',
372
+ description: 'Opt-out of a seller program',
373
+ inputSchema: {
374
+ request: programRequestSchema.describe('Program opt-out request'),
375
+ },
376
+ },
377
+ {
378
+ name: 'ebay_get_opted_in_programs',
379
+ description: 'Get seller programs the account is opted into',
380
+ inputSchema: {},
381
+ outputSchema: zodToJsonSchema(programsOutputSchema, {
382
+ name: 'ProgramsResponse',
383
+ $refStrategy: 'none',
384
+ }),
385
+ },
386
+ {
387
+ name: 'ebay_get_privileges',
388
+ description: "Get seller's current set of privileges, including whether or not the seller's eBay registration has been completed, as well as the details of their site-wide sellingLimit (the maximum dollar value and quantity of items a seller can sell per day).\n\nRequired OAuth Scope: sell.account.readonly or sell.account",
389
+ inputSchema: {},
390
+ outputSchema: zodToJsonSchema(privilegesOutputSchema, {
391
+ name: 'PrivilegesResponse',
392
+ $refStrategy: 'none',
393
+ }),
394
+ },
395
+ {
396
+ name: 'ebay_get_advertising_eligibility',
397
+ description: 'Check the seller eligibility status for eBay advertising programs. This allows developers to determine if a seller is eligible for various advertising programs on eBay.\n\nRequired OAuth Scope: sell.account.readonly or sell.account',
398
+ inputSchema: {
399
+ marketplaceId: z
400
+ .nativeEnum(MarketplaceId)
401
+ .describe('eBay marketplace ID to check eligibility for'),
402
+ programTypes: z
403
+ .string()
404
+ .optional()
405
+ .describe('Optional comma-separated list of program types to check eligibility for'),
406
+ },
407
+ },
408
+ {
409
+ name: 'ebay_get_payments_program',
410
+ description: 'Get payments program status for a marketplace. Note: This method is deprecated as all seller accounts globally have been enabled for the new eBay payment and checkout flow.\n\nRequired OAuth Scope: sell.account.readonly or sell.account',
411
+ inputSchema: {
412
+ marketplaceId: z.nativeEnum(MarketplaceId).describe('The eBay marketplace ID'),
413
+ paymentsProgramType: z
414
+ .string()
415
+ .describe('The type of payments program (e.g., EBAY_PAYMENTS)'),
416
+ },
417
+ },
418
+ {
419
+ name: 'ebay_get_payments_program_onboarding',
420
+ description: 'Get payments program onboarding information. Note: This method is deprecated as all seller accounts globally have been enabled for the new eBay payment and checkout flow.\n\nRequired OAuth Scope: sell.account.readonly or sell.account',
421
+ inputSchema: {
422
+ marketplaceId: z.nativeEnum(MarketplaceId).describe('The eBay marketplace ID'),
423
+ paymentsProgramType: z
424
+ .string()
425
+ .describe('The type of payments program (e.g., EBAY_PAYMENTS)'),
426
+ },
427
+ },
428
+ ];
@@ -0,0 +1,25 @@
1
+ import { z } from 'zod';
2
+ export interface OutputArgs {
3
+ [x: string]: unknown;
4
+ type: 'object';
5
+ properties?: Record<string, object>;
6
+ required?: string[];
7
+ }
8
+ export interface ToolAnnotations {
9
+ [x: string]: unknown;
10
+ title?: string;
11
+ readOnlyHint?: boolean;
12
+ destructiveHint?: boolean;
13
+ idempotentHint?: boolean;
14
+ openWorldHint?: boolean;
15
+ }
16
+ export interface ToolDefinition {
17
+ name: string;
18
+ description: string;
19
+ inputSchema: Record<string, z.ZodTypeAny>;
20
+ title?: string;
21
+ outputSchema?: OutputArgs;
22
+ annotations?: ToolAnnotations;
23
+ _meta?: Record<string, unknown>;
24
+ }
25
+ export declare const analyticsTools: ToolDefinition[];
@@ -0,0 +1,66 @@
1
+ import { z } from 'zod';
2
+ export const analyticsTools = [
3
+ {
4
+ name: 'ebay_get_traffic_report',
5
+ description: 'Get traffic report for listings',
6
+ inputSchema: {
7
+ dimension: z.string().describe('Dimension for the report (e.g., LISTING, DAY)'),
8
+ filter: z.string().describe('Filter criteria'),
9
+ metric: z.string().describe('Metrics to retrieve (e.g., CLICK_THROUGH_RATE, IMPRESSION)'),
10
+ sort: z.string().optional().describe('Sort order'),
11
+ },
12
+ outputSchema: {
13
+ type: 'object',
14
+ properties: {
15
+ records: { type: 'array' },
16
+ warnings: { type: 'array' },
17
+ },
18
+ description: 'Traffic report data',
19
+ },
20
+ },
21
+ {
22
+ name: 'ebay_find_seller_standards_profiles',
23
+ description: 'Find all seller standards profiles',
24
+ inputSchema: {},
25
+ outputSchema: {
26
+ type: 'object',
27
+ properties: {
28
+ standards: { type: 'array' },
29
+ },
30
+ description: 'Seller standards profiles',
31
+ },
32
+ },
33
+ {
34
+ name: 'ebay_get_seller_standards_profile',
35
+ description: 'Get a specific seller standards profile',
36
+ inputSchema: {
37
+ program: z.string().describe('The program (e.g., CUSTOMER_SERVICE)'),
38
+ cycle: z.string().describe('The cycle (e.g., CURRENT)'),
39
+ },
40
+ outputSchema: {
41
+ type: 'object',
42
+ properties: {
43
+ program: { type: 'string' },
44
+ cycle: { type: 'object' },
45
+ metrics: { type: 'array' },
46
+ },
47
+ description: 'Seller standards profile data',
48
+ },
49
+ },
50
+ {
51
+ name: 'ebay_get_customer_service_metric',
52
+ description: 'Get customer service metrics',
53
+ inputSchema: {
54
+ customerServiceMetricType: z.string().describe('Type of metric'),
55
+ evaluationType: z.string().describe('Evaluation type'),
56
+ evaluationMarketplaceId: z.string().describe('Marketplace ID for evaluation'),
57
+ },
58
+ outputSchema: {
59
+ type: 'object',
60
+ properties: {
61
+ metrics: { type: 'array' },
62
+ },
63
+ description: 'Customer service metric data',
64
+ },
65
+ },
66
+ ];
@@ -0,0 +1,12 @@
1
+ import { z } from 'zod';
2
+ import { OutputArgs, ToolAnnotations } from '../tool-definitions.js';
3
+ export interface ToolDefinition {
4
+ name: string;
5
+ description: string;
6
+ inputSchema: Record<string, z.ZodTypeAny>;
7
+ title?: string;
8
+ outputSchema?: OutputArgs;
9
+ annotations?: ToolAnnotations;
10
+ _meta?: Record<string, unknown>;
11
+ }
12
+ export declare const communicationTools: ToolDefinition[];
@@ -0,0 +1,151 @@
1
+ import { z } from 'zod';
2
+ import { feedbackDataSchema, notificationConfigSchema, notificationDestinationSchema, offerToBuyersSchema, } from '../schemas.js';
3
+ export const communicationTools = [
4
+ // Negotiation API
5
+ {
6
+ name: 'ebay_get_offers_to_buyers',
7
+ description: 'Get offers to buyers (Best Offers) for the seller',
8
+ inputSchema: {
9
+ filter: z.string().optional().describe('Filter criteria for offers'),
10
+ limit: z.number().optional().describe('Number of offers to return'),
11
+ offset: z.number().optional().describe('Number of offers to skip'),
12
+ },
13
+ },
14
+ {
15
+ name: 'ebay_send_offer_to_interested_buyers',
16
+ description: 'Send offer to interested buyers',
17
+ inputSchema: {
18
+ offerId: z.string().describe('The offer ID'),
19
+ offerData: offerToBuyersSchema.describe('Offer details to send to buyers'),
20
+ },
21
+ },
22
+ // Message API
23
+ {
24
+ name: 'ebay_search_messages',
25
+ description: 'Search for buyer-seller messages',
26
+ inputSchema: {
27
+ filter: z.string().optional().describe('Filter criteria for messages'),
28
+ limit: z.number().optional().describe('Number of messages to return'),
29
+ offset: z.number().optional().describe('Number of messages to skip'),
30
+ },
31
+ },
32
+ {
33
+ name: 'ebay_get_message',
34
+ description: 'Get a specific message by ID',
35
+ inputSchema: {
36
+ messageId: z.string().describe('The message ID'),
37
+ },
38
+ },
39
+ {
40
+ name: 'ebay_send_message',
41
+ description: 'Send a direct message to a buyer regarding a specific transaction or inquiry. Use this to communicate about orders, answer questions, resolve issues, or provide updates.',
42
+ inputSchema: {
43
+ messageData: z
44
+ .object({
45
+ conversationId: z
46
+ .string()
47
+ .optional()
48
+ .describe('Optional conversation ID to reply to an existing thread. Use getConversations to retrieve conversation IDs. Required if replying to existing conversation.'),
49
+ messageText: z
50
+ .string()
51
+ .describe('REQUIRED. The text of the message to send (max 2000 characters).'),
52
+ otherPartyUsername: z
53
+ .string()
54
+ .optional()
55
+ .describe('eBay username of the other party (buyer or seller). Required when starting a new conversation.'),
56
+ emailCopyToSender: z
57
+ .boolean()
58
+ .optional()
59
+ .describe('If true, a copy of the message will be emailed to the sender.'),
60
+ reference: z
61
+ .object({
62
+ referenceId: z
63
+ .string()
64
+ .optional()
65
+ .describe('The ID of the listing or order to reference (e.g., item ID or order ID)'),
66
+ referenceType: z
67
+ .string()
68
+ .optional()
69
+ .describe('Type of reference. Valid values: "LISTING" (for item listings) or "ORDER" (for orders)'),
70
+ })
71
+ .optional()
72
+ .describe('Optional reference to associate message with a listing or order.'),
73
+ messageMedia: z
74
+ .array(z.object({
75
+ mediaUrl: z.string().optional().describe('URL of the media to attach'),
76
+ mediaType: z
77
+ .string()
78
+ .optional()
79
+ .describe('MIME type of the media (e.g., "image/jpeg")'),
80
+ }))
81
+ .optional()
82
+ .describe('Optional array of media attachments (max 5 per message)'),
83
+ })
84
+ .describe('Message details including recipient and content. Must include messageText (required), and either conversationId (for replies) OR otherPartyUsername (for new messages).'),
85
+ },
86
+ },
87
+ {
88
+ name: 'ebay_reply_to_message',
89
+ description: 'Reply to a buyer message in an existing conversation thread',
90
+ inputSchema: {
91
+ messageId: z.string().describe('The conversation/message ID to reply to'),
92
+ messageContent: z.string().describe('The reply message content'),
93
+ },
94
+ },
95
+ // Notification API
96
+ {
97
+ name: 'ebay_get_notification_config',
98
+ description: 'Get notification configuration',
99
+ inputSchema: {},
100
+ },
101
+ {
102
+ name: 'ebay_update_notification_config',
103
+ description: 'Update notification configuration',
104
+ inputSchema: {
105
+ config: notificationConfigSchema.describe('Notification configuration settings'),
106
+ },
107
+ },
108
+ {
109
+ name: 'ebay_get_notification_destinations',
110
+ description: 'Get all notification destinations (paginated)',
111
+ inputSchema: {
112
+ limit: z
113
+ .number()
114
+ .optional()
115
+ .describe('Maximum number of destinations to return (10-100, default: 20)'),
116
+ continuationToken: z.string().optional().describe('Token to retrieve next page of results'),
117
+ },
118
+ },
119
+ {
120
+ name: 'ebay_create_notification_destination',
121
+ description: 'Create a notification destination',
122
+ inputSchema: {
123
+ destination: notificationDestinationSchema.describe('Destination configuration'),
124
+ },
125
+ },
126
+ // Feedback API
127
+ {
128
+ name: 'ebay_get_feedback',
129
+ description: 'Get feedback for a transaction',
130
+ inputSchema: {
131
+ transactionId: z.string().describe('The transaction ID'),
132
+ },
133
+ },
134
+ {
135
+ name: 'ebay_leave_feedback_for_buyer',
136
+ description: 'Leave feedback for a buyer',
137
+ inputSchema: {
138
+ feedbackData: feedbackDataSchema.describe('Feedback details including rating and comment'),
139
+ },
140
+ },
141
+ {
142
+ name: 'ebay_get_feedback_summary',
143
+ description: 'Get feedback summary for the seller',
144
+ inputSchema: {},
145
+ outputSchema: {
146
+ type: 'object',
147
+ properties: {},
148
+ description: 'Success response',
149
+ },
150
+ },
151
+ ];