ebay-mcp 1.8.10 → 1.9.0
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 +88 -504
- package/build/api/account-management/account.js +50 -49
- package/build/api/analytics-and-report/analytics.js +5 -24
- package/build/api/client-trading.js +25 -15
- package/build/api/client.js +158 -185
- package/build/api/communication/feedback.js +9 -23
- package/build/api/communication/message.js +4 -18
- package/build/api/communication/negotiation.js +3 -13
- package/build/api/communication/shared.js +1 -2
- package/build/api/developer/developer.js +7 -6
- package/build/api/listing-management/inventory.js +1 -2
- package/build/api/listing-metadata/taxonomy.js +14 -9
- package/build/api/marketing-and-promotions/marketing.js +149 -177
- package/build/api/marketing-and-promotions/recommendation.js +3 -2
- package/build/api/order-management/dispute.js +10 -9
- package/build/api/order-management/fulfillment.js +12 -11
- package/build/api/other/compliance.js +5 -4
- package/build/api/other/edelivery.js +30 -29
- package/build/api/other/identity.js +3 -2
- package/build/api/other/translation.js +3 -2
- package/build/api/other/vero.js +6 -5
- package/build/api/shared/query-params.js +0 -5
- package/build/api/shared/request.js +1 -6
- package/build/auth/oauth-middleware.js +2 -1
- package/build/auth/oauth.js +29 -20
- package/build/auth/token-verifier.js +13 -7
- package/build/config/environment.js +88 -15
- package/build/index.js +6 -1
- package/build/mcp/http-transport.js +2 -1
- package/build/mcp/runtime.js +3 -2
- package/build/scripts/dev-sync.js +56 -15
- package/build/scripts/diagnostics.js +3 -2
- package/build/scripts/download-specs.js +2 -2
- package/build/scripts/interactive-setup.js +2 -1
- package/build/scripts/setup-shared.js +30 -9
- package/build/scripts/setup.js +266 -169
- package/build/server-http.js +3 -0
- package/build/tools/{definitions → categories}/account.js +124 -83
- package/build/tools/{definitions → categories}/analytics.js +14 -9
- package/build/tools/categories/communication.js +497 -0
- package/build/tools/categories/connector.js +126 -0
- package/build/tools/{definitions → categories}/developer.js +31 -15
- package/build/tools/{definitions → categories}/fulfillment.js +59 -31
- package/build/tools/categories/index.js +42 -0
- package/build/tools/{definitions → categories}/inventory.js +111 -74
- package/build/tools/categories/marketing.js +39 -0
- package/build/tools/{definitions → categories}/metadata.js +72 -48
- package/build/tools/{definitions → categories}/other.js +138 -83
- package/build/tools/{definitions → categories}/taxonomy.js +14 -9
- package/build/tools/categories/token-management.js +367 -0
- package/build/tools/{definitions → categories}/trading.js +20 -13
- package/build/tools/define-tool.js +61 -0
- package/build/tools/definitions/marketing.js +87 -200
- package/build/tools/definitions/types.js +1 -0
- package/build/tools/registry.js +9 -25
- package/build/tools/tool-handlers/marketing.js +15 -87
- package/build/utils/api-status-feed.js +6 -5
- package/build/utils/errors.js +16 -0
- package/build/utils/http.js +215 -0
- package/build/utils/oauth-helper.js +131 -150
- package/build/utils/setup-validator.js +4 -3
- package/build/utils/setup-wizard.js +55 -51
- package/package.json +24 -24
- package/build/tools/definitions/communication.js +0 -395
- package/build/tools/definitions/index.js +0 -41
- package/build/tools/definitions/token-management.js +0 -149
- package/build/tools/tool-definitions.js +0 -3545
- package/build/tools/tool-handlers/account.js +0 -123
- package/build/tools/tool-handlers/analytics.js +0 -15
- package/build/tools/tool-handlers/chat.js +0 -76
- package/build/tools/tool-handlers/communication.js +0 -161
- package/build/tools/tool-handlers/developer.js +0 -40
- package/build/tools/tool-handlers/fulfillment.js +0 -54
- package/build/tools/tool-handlers/index.js +0 -29
- package/build/tools/tool-handlers/inventory.js +0 -111
- package/build/tools/tool-handlers/metadata.js +0 -72
- package/build/tools/tool-handlers/other.js +0 -120
- package/build/tools/tool-handlers/taxonomy.js +0 -15
- package/build/tools/tool-handlers/token-management.js +0 -246
- package/build/tools/tool-handlers/trading.js +0 -21
package/README.md
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
[](https://www.npmjs.com/package/ebay-mcp)
|
|
6
6
|
[](https://www.npmjs.com/package/ebay-mcp)
|
|
7
|
-
[](tests/)
|
|
8
8
|
[](src/tools/)
|
|
9
9
|
[](LICENSE)
|
|
10
10
|
[](CONTRIBUTING.md)
|
|
@@ -12,9 +12,9 @@
|
|
|
12
12
|
[](https://mseep.ai/app/yosefhayim-ebay-api-mcp-server)
|
|
13
13
|
<a href="https://www.buymeacoffee.com/yosefhayim" target="_blank"><img src="https://cdn.buymeacoffee.com/buttons/v2/default-yellow.png" alt="Buy Me A Coffee" style="height: 60px !important;width: 217px !important;" ></a>
|
|
14
14
|
|
|
15
|
-
A [Model Context Protocol (MCP)](https://modelcontextprotocol.io) server
|
|
15
|
+
A [Model Context Protocol (MCP)](https://modelcontextprotocol.io) server that gives AI assistants comprehensive access to eBay's Sell APIs — **322 tools** for inventory, order fulfillment, marketing, analytics, developer tools, and more.
|
|
16
16
|
|
|
17
|
-
**API Coverage:** 100% (270 unique eBay API endpoints)
|
|
17
|
+
**API Coverage:** 100% (270 unique eBay API endpoints) · **Runs locally** — no cloud relay.
|
|
18
18
|
|
|
19
19
|
</div>
|
|
20
20
|
|
|
@@ -22,7 +22,7 @@ A [Model Context Protocol (MCP)](https://modelcontextprotocol.io) server providi
|
|
|
22
22
|
|
|
23
23
|
## One-Click AI Setup
|
|
24
24
|
|
|
25
|
-
> **Let your AI assistant set this up for you
|
|
25
|
+
> **Let your AI assistant set this up for you.** Copy the prompt below and paste it into Claude, ChatGPT, or any AI assistant with MCP support.
|
|
26
26
|
|
|
27
27
|
<details>
|
|
28
28
|
<summary><strong>Click to copy the AI setup prompt</strong></summary>
|
|
@@ -52,119 +52,52 @@ If I don't have eBay credentials yet, guide me through creating a developer acco
|
|
|
52
52
|
|
|
53
53
|
</details>
|
|
54
54
|
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
## ⚠️ Disclaimer
|
|
58
|
-
|
|
59
|
-
**IMPORTANT: Please read this disclaimer carefully before using this software.**
|
|
60
|
-
|
|
61
|
-
This is an **open-source project** provided "as is" without warranty of any kind, either express or implied. By using this software, you acknowledge and agree to the following:
|
|
62
|
-
|
|
63
|
-
- **No Liability:** The authors, contributors, and maintainers of this project accept **NO responsibility or liability** for any damages, losses, or issues that may arise from using this software, including but not limited to:
|
|
64
|
-
- Data loss or corruption
|
|
65
|
-
- Financial losses
|
|
66
|
-
- Service disruptions
|
|
67
|
-
- eBay account suspension or termination
|
|
68
|
-
- Violations of eBay's Terms of Service or API usage policies
|
|
69
|
-
- Any other direct or indirect damages
|
|
70
|
-
|
|
71
|
-
- **eBay API Usage:** This project is an unofficial third-party implementation and is **NOT affiliated with, endorsed by, or sponsored by eBay Inc.** You are solely responsible for:
|
|
72
|
-
- Complying with [eBay's API Terms of Use](https://developer.ebay.com/join/api-license-agreement)
|
|
73
|
-
- Ensuring your usage stays within eBay's rate limits and policies
|
|
74
|
-
- Managing your eBay Developer credentials securely
|
|
75
|
-
- Understanding and complying with [eBay's data handling requirements](https://developer.ebay.com/api-docs/static/data-handling-update.html)
|
|
76
|
-
- Any actions performed through the API
|
|
77
|
-
|
|
78
|
-
- **Use at Your Own Risk:** This software is provided for educational and development purposes. Users must:
|
|
79
|
-
- Test thoroughly in eBay's sandbox environment before production use
|
|
80
|
-
- Understand the API calls being made on their behalf
|
|
81
|
-
- Maintain backups of critical data
|
|
82
|
-
- Monitor their API usage and account status
|
|
83
|
-
|
|
84
|
-
- **Security:** You are responsible for:
|
|
85
|
-
- Keeping your API credentials secure
|
|
86
|
-
- Properly configuring environment variables
|
|
87
|
-
- Understanding the security implications of MCP server usage
|
|
88
|
-
- Following security best practices
|
|
89
|
-
|
|
90
|
-
- **No Warranty:** This software is provided without any guarantees of functionality, reliability, or fitness for a particular purpose.
|
|
91
|
-
|
|
92
|
-
**By using this software, you accept all risks and agree to hold harmless the authors, contributors, and maintainers from any claims, damages, or liabilities.**
|
|
93
|
-
|
|
94
|
-
For official eBay API support, please refer to the [eBay Developer Program](https://developer.ebay.com/).
|
|
55
|
+
> **Disclaimer:** Unofficial, third-party project — **not affiliated with or endorsed by eBay Inc.** Provided "as is" without warranty; you are responsible for complying with [eBay's API Terms](https://developer.ebay.com/join/api-license-agreement) and [data-handling requirements](https://developer.ebay.com/api-docs/static/data-handling-update.html), keeping your credentials secure, and staying within rate limits. Test in sandbox before production. See [LICENSE](LICENSE), [SECURITY.md](SECURITY.md), and [EBAY_COMPLIANCE.md](EBAY_COMPLIANCE.md).
|
|
95
56
|
|
|
96
57
|
---
|
|
97
58
|
|
|
98
|
-
## Table of Contents
|
|
99
|
-
|
|
100
|
-
- [⚠️ Disclaimer](#️-disclaimer)
|
|
101
|
-
- [Features](#features)
|
|
102
|
-
- [Quick Start](#quick-start)
|
|
103
|
-
- [Demo](#demo)
|
|
104
|
-
- [Visual Setup Guide](#visual-setup-guide)
|
|
105
|
-
- [Configuration](#configuration)
|
|
106
|
-
- [Available Tools](#available-tools)
|
|
107
|
-
- [Usage Examples](#usage-examples)
|
|
108
|
-
- [Development](#development)
|
|
109
|
-
- [Contributing](#contributing)
|
|
110
|
-
- [Logging](#logging)
|
|
111
|
-
- [Troubleshooting](#troubleshooting)
|
|
112
|
-
- [Resources](#resources)
|
|
113
|
-
- [License](#license)
|
|
114
|
-
|
|
115
59
|
## Features
|
|
116
60
|
|
|
117
|
-
- **
|
|
118
|
-
- **9 AI Clients Supported**
|
|
119
|
-
- **OAuth 2.0
|
|
120
|
-
- **Type Safety**
|
|
121
|
-
- **
|
|
122
|
-
- **
|
|
123
|
-
- **
|
|
124
|
-
- **Interactive Setup Wizard** - Run `npm run setup` for guided configuration with auto browser-open for OAuth
|
|
125
|
-
- **Developer Analytics** - Rate limit monitoring and signing key management
|
|
61
|
+
- **322 eBay API Tools** — 100% coverage of eBay Sell APIs across inventory, orders, marketing, analytics, developer tools, and more
|
|
62
|
+
- **9 AI Clients Supported** — auto-configuration for Claude Desktop, Cursor, Zed, Cline, Continue.dev, Windsurf, Roo Code, Claude Code CLI, and Amazon Q
|
|
63
|
+
- **OAuth 2.0** — full user-token management with automatic refresh
|
|
64
|
+
- **Type Safety** — TypeScript, Zod validation, and OpenAPI-generated types
|
|
65
|
+
- **Smart Authentication** — automatic fallback from user tokens (10k–50k req/day) to client credentials (1k req/day)
|
|
66
|
+
- **Well Tested** — 1005+ tests
|
|
67
|
+
- **Interactive Setup Wizard** — `npm run setup` for guided config with auto browser-open for OAuth
|
|
126
68
|
|
|
127
69
|
## Quick Start
|
|
128
70
|
|
|
129
|
-
### 1. Get eBay
|
|
71
|
+
### 1. Get eBay credentials
|
|
130
72
|
|
|
131
|
-
1. Create a free [eBay Developer Account](https://developer.ebay.com/)
|
|
132
|
-
2. Generate application keys in the [Developer Portal](https://developer.ebay.com/my/keys)
|
|
133
|
-
3. Save your **Client ID** and **Client Secret
|
|
73
|
+
1. Create a free [eBay Developer Account](https://developer.ebay.com/).
|
|
74
|
+
2. Generate application keys in the [Developer Portal](https://developer.ebay.com/my/keys).
|
|
75
|
+
3. Save your **Client ID** and **Client Secret**.
|
|
134
76
|
|
|
135
77
|
### 2. Install
|
|
136
78
|
|
|
137
|
-
**Option A: Install from npm (Recommended)**
|
|
138
|
-
|
|
139
79
|
```bash
|
|
140
|
-
npm install -g ebay-mcp
|
|
80
|
+
npm install -g ebay-mcp # from npm (recommended)
|
|
141
81
|
```
|
|
142
82
|
|
|
143
|
-
|
|
83
|
+
Or from source:
|
|
144
84
|
|
|
145
85
|
```bash
|
|
146
86
|
git clone https://github.com/YosefHayim/ebay-mcp.git
|
|
147
|
-
cd ebay-mcp
|
|
148
|
-
npm install
|
|
149
|
-
npm run build
|
|
87
|
+
cd ebay-mcp && npm install && npm run build
|
|
150
88
|
```
|
|
151
89
|
|
|
152
|
-
### 3. Run
|
|
153
|
-
|
|
154
|
-
The interactive setup wizard handles everything for you:
|
|
90
|
+
### 3. Run the setup wizard
|
|
155
91
|
|
|
156
92
|
```bash
|
|
157
93
|
npm run setup
|
|
158
94
|
```
|
|
159
95
|
|
|
160
|
-
|
|
96
|
+
The wizard configures your eBay credentials, sets up OAuth (for higher rate limits), auto-detects and configures your MCP client, and saves everything automatically.
|
|
161
97
|
|
|
162
|
-
|
|
98
|
+
### 4. Use
|
|
163
99
|
|
|
164
|
-
|
|
165
|
-
- Set up OAuth authentication (for higher rate limits)
|
|
166
|
-
- Auto-detect and configure your MCP client (Claude Desktop, etc.)
|
|
167
|
-
- Save all configuration automatically
|
|
100
|
+
Restart your MCP client (Claude Desktop, etc.) and start using eBay tools through your AI assistant.
|
|
168
101
|
|
|
169
102
|
---
|
|
170
103
|
|
|
@@ -178,480 +111,131 @@ https://github.com/user-attachments/assets/0173c8df-221c-4943-a4ce-cd20bce79f4b
|
|
|
178
111
|
|
|
179
112
|
## Visual Setup Guide
|
|
180
113
|
|
|
181
|
-
The setup wizard (`npm run setup`) handles OAuth
|
|
182
|
-
|
|
183
|
-
### Finding Your Credentials
|
|
114
|
+
The setup wizard (`npm run setup`) handles OAuth automatically. Here's where to find your credentials in the eBay Developer Portal:
|
|
184
115
|
|
|
185
|
-
**Step 1
|
|
116
|
+
**Step 1** — In the [Developer Portal](https://developer.ebay.com/my/keys), copy your **App ID (Client ID)** and **Cert ID (Client Secret)**:
|
|
186
117
|
|
|
187
118
|

|
|
188
119
|
|
|
189
|
-
**Step 2
|
|
120
|
+
**Step 2** — In your app's **User Tokens** settings, copy the **RuName** (eBay Redirect URL):
|
|
190
121
|
|
|
191
122
|

|
|
192
123
|
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
Run `npm run setup` and enter your credentials when prompted. The wizard will:
|
|
196
|
-
|
|
197
|
-
1. Open your browser for OAuth login automatically
|
|
198
|
-
2. Guide you through the eBay sign-in process
|
|
124
|
+
**Step 3** — Run `npm run setup`. It opens your browser for OAuth login and guides you through eBay sign-in:
|
|
199
125
|
|
|
200
126
|

|
|
201
127
|
|
|
202
|
-
|
|
128
|
+
**Step 4** — Paste the authorization code from the callback URL when prompted:
|
|
203
129
|
|
|
204
130
|

|
|
205
131
|
|
|
206
|
-
|
|
207
|
-
5. Configure your MCP client (Claude Desktop, etc.)
|
|
208
|
-
|
|
209
|
-
**Success!** You now have user token authentication with 10k-50k requests/day instead of the default 1k/day.
|
|
132
|
+
The wizard exchanges the code for tokens, saves them, and configures your MCP client. You now have user-token authentication (10k–50k requests/day instead of the default 1k/day).
|
|
210
133
|
|
|
211
134
|
---
|
|
212
135
|
|
|
213
|
-
### 4. Use
|
|
214
|
-
|
|
215
|
-
Restart your MCP client (Claude Desktop, etc.) and start using eBay tools through your AI assistant.
|
|
216
|
-
|
|
217
136
|
## Configuration
|
|
218
137
|
|
|
219
|
-
> 📖
|
|
220
|
-
|
|
221
|
-
### Environment Variables
|
|
222
|
-
|
|
223
|
-
The setup wizard (`npm run setup`) automatically creates and configures your `.env` file. For reference, these are the environment variables used:
|
|
138
|
+
> 📖 Full reference — every environment variable, OAuth step, and scope — is in the [Configuration Guide](docs/auth/CONFIGURATION.md). `npm run setup` writes the `.env` for you; the variables below are for reference.
|
|
224
139
|
|
|
225
140
|
```bash
|
|
226
141
|
EBAY_CLIENT_ID=your_client_id
|
|
227
142
|
EBAY_CLIENT_SECRET=your_client_secret
|
|
228
|
-
EBAY_ENVIRONMENT=sandbox
|
|
143
|
+
EBAY_ENVIRONMENT=sandbox # or "production"
|
|
229
144
|
EBAY_REDIRECT_URI=your_runame
|
|
230
|
-
EBAY_MARKETPLACE_ID=EBAY_US
|
|
231
|
-
EBAY_CONTENT_LANGUAGE=en-US
|
|
232
|
-
EBAY_USER_REFRESH_TOKEN=
|
|
233
|
-
```
|
|
234
|
-
|
|
235
|
-
### OAuth Authentication
|
|
236
|
-
|
|
237
|
-
**Client Credentials (Default):** 1,000 requests/day - works automatically with just Client ID and Secret.
|
|
238
|
-
|
|
239
|
-
**User Tokens (Recommended):** 10,000-50,000 requests/day - the setup wizard handles the OAuth flow automatically. Tokens refresh automatically.
|
|
240
|
-
|
|
241
|
-
For detailed OAuth setup and comprehensive configuration guide, see the [Configuration Documentation](docs/auth/CONFIGURATION.md).
|
|
242
|
-
|
|
243
|
-
### MCP Client Compatibility
|
|
244
|
-
|
|
245
|
-
This server supports **9 AI clients** with auto-configuration via `npm run setup`:
|
|
246
|
-
|
|
247
|
-
| Client | Platform | Config Path | Status |
|
|
248
|
-
| ---------------------- | --------------------- | ---------------------------------------------------------------------------- | ------------------ |
|
|
249
|
-
| **Claude Desktop** | macOS, Windows, Linux | `~/Library/Application Support/Claude/claude_desktop_config.json` | ✅ Auto-configured |
|
|
250
|
-
| **Cursor IDE** | macOS, Windows, Linux | `~/.cursor/mcp.json` | ✅ Auto-configured |
|
|
251
|
-
| **Zed Editor** | macOS, Windows, Linux | `~/.config/zed/settings.json` | ✅ Auto-configured |
|
|
252
|
-
| **Cline** | VSCode Extension | `~/...globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json` | ✅ Auto-configured |
|
|
253
|
-
| **Continue.dev** | VSCode, JetBrains | `~/.continue/config.json` | ✅ Auto-configured |
|
|
254
|
-
| **Windsurf (Codeium)** | macOS, Windows, Linux | `~/.codeium/windsurf/mcp_config.json` | ✅ Auto-configured |
|
|
255
|
-
| **Roo Code** | VSCode Extension | `~/...globalStorage/rooveterinaryinc.roo-cline/settings/mcp_settings.json` | ✅ Auto-configured |
|
|
256
|
-
| **Claude Code CLI** | Terminal | `~/.claude.json` | ✅ Auto-configured |
|
|
257
|
-
| **Amazon Q Developer** | AWS | `~/.aws/amazonq/mcp.json` | ✅ Auto-configured |
|
|
258
|
-
|
|
259
|
-
**Configuration Requirements:**
|
|
260
|
-
|
|
261
|
-
- MCP Protocol version: 1.0+
|
|
262
|
-
- Transport: STDIO (default) or HTTP
|
|
263
|
-
- Node.js runtime: 18.0.0 or higher
|
|
264
|
-
|
|
265
|
-
**Quick Setup for Any Client:**
|
|
266
|
-
|
|
267
|
-
```bash
|
|
268
|
-
npm install -g ebay-mcp
|
|
269
|
-
npx ebay-mcp setup # Interactive setup wizard - auto-detects installed clients
|
|
145
|
+
EBAY_MARKETPLACE_ID=EBAY_US # default marketplace (overridable per tool)
|
|
146
|
+
EBAY_CONTENT_LANGUAGE=en-US # default request content language
|
|
147
|
+
EBAY_USER_REFRESH_TOKEN=your_token # for higher rate limits
|
|
270
148
|
```
|
|
271
149
|
|
|
272
|
-
|
|
150
|
+
### Authentication & rate limits
|
|
273
151
|
|
|
274
|
-
|
|
152
|
+
| Mode | Daily limit | Best for | Setup |
|
|
153
|
+
| ------------------------------- | ----------------- | ------------------------- | ---------------------------------- |
|
|
154
|
+
| **Client credentials** (default) | 1,000 req/day | Development, testing | Automatic with Client ID + Secret |
|
|
155
|
+
| **User token** (recommended) | 10k–50k req/day | Production, high volume | OAuth via `npm run setup` |
|
|
275
156
|
|
|
276
|
-
|
|
157
|
+
User-token limits vary by account tier (Individual 10k · Commercial 25k · Enterprise 50k+). On a 429, the server retries with exponential backoff and surfaces the error. See the [Configuration Guide](docs/auth/CONFIGURATION.md) and [OAuth Quick Reference](docs/auth/OAUTH_QUICK_REFERENCE.md) for details, and monitor usage in the [Developer Portal](https://developer.ebay.com/my/api_usage).
|
|
277
158
|
|
|
278
|
-
|
|
159
|
+
### MCP client compatibility
|
|
279
160
|
|
|
280
|
-
-
|
|
281
|
-
- **Best For:** Development, testing, low-volume operations
|
|
282
|
-
- **Setup:** Automatic with just Client ID and Secret
|
|
161
|
+
Auto-configured by `npm run setup`. Requires Node.js ≥ 18 and MCP protocol 1.0+ over STDIO (default) or HTTP.
|
|
283
162
|
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
**
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
**Rate Limit Best Practices:**
|
|
297
|
-
|
|
298
|
-
1. Use user tokens for production workloads
|
|
299
|
-
2. Implement exponential backoff on rate limit errors
|
|
300
|
-
3. Cache responses when possible
|
|
301
|
-
4. Monitor your usage in the eBay Developer Portal
|
|
302
|
-
5. Batch operations when the API supports it
|
|
303
|
-
6. Consider upgrading your developer account tier for higher limits
|
|
304
|
-
|
|
305
|
-
**Handling Rate Limits:**
|
|
306
|
-
|
|
307
|
-
When you hit a rate limit, the API returns a 429 status code. The server will:
|
|
308
|
-
|
|
309
|
-
- Automatically retry with exponential backoff
|
|
310
|
-
- Inform you of rate limit errors
|
|
311
|
-
- Suggest upgrading to user token authentication
|
|
312
|
-
|
|
313
|
-
**Check Current Usage:**
|
|
314
|
-
|
|
315
|
-
Monitor your API usage in the [eBay Developer Portal](https://developer.ebay.com/my/api_usage).
|
|
163
|
+
| Client | Platform | Config Path |
|
|
164
|
+
| ---------------------- | --------------------- | ---------------------------------------------------------------------------- |
|
|
165
|
+
| **Claude Desktop** | macOS, Windows, Linux | `~/Library/Application Support/Claude/claude_desktop_config.json` |
|
|
166
|
+
| **Cursor IDE** | macOS, Windows, Linux | `~/.cursor/mcp.json` |
|
|
167
|
+
| **Zed Editor** | macOS, Windows, Linux | `~/.config/zed/settings.json` |
|
|
168
|
+
| **Cline** | VSCode Extension | `~/...globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json` |
|
|
169
|
+
| **Continue.dev** | VSCode, JetBrains | `~/.continue/config.json` |
|
|
170
|
+
| **Windsurf (Codeium)** | macOS, Windows, Linux | `~/.codeium/windsurf/mcp_config.json` |
|
|
171
|
+
| **Roo Code** | VSCode Extension | `~/...globalStorage/rooveterinaryinc.roo-cline/settings/mcp_settings.json` |
|
|
172
|
+
| **Claude Code CLI** | Terminal | `~/.claude.json` |
|
|
173
|
+
| **Amazon Q Developer** | AWS | `~/.aws/amazonq/mcp.json` |
|
|
316
174
|
|
|
317
175
|
## Available Tools
|
|
318
176
|
|
|
319
|
-
|
|
177
|
+
**322 tools**, 100% API coverage, organized by category:
|
|
320
178
|
|
|
321
|
-
- **Account
|
|
322
|
-
- **Inventory
|
|
323
|
-
- **Order Fulfillment**
|
|
324
|
-
- **Marketing & Promotions**
|
|
325
|
-
- **Analytics**
|
|
326
|
-
- **Communication**
|
|
327
|
-
- **Metadata & Taxonomy**
|
|
328
|
-
- **
|
|
329
|
-
- **
|
|
179
|
+
- **Account** — policies, programs, subscriptions, sales tax
|
|
180
|
+
- **Inventory** — items, offers, locations, bulk operations, SKU location mapping
|
|
181
|
+
- **Order Fulfillment** — orders, shipping, refunds, disputes, payment dispute evidence
|
|
182
|
+
- **Marketing & Promotions** — campaigns, ads, promotions, bidding, bulk operations
|
|
183
|
+
- **Analytics** — traffic reports, seller standards, metrics
|
|
184
|
+
- **Communication** — buyer-seller messaging, negotiations, notifications, feedback
|
|
185
|
+
- **Metadata & Taxonomy** — categories, item aspects, policies
|
|
186
|
+
- **Trading (legacy XML)** — fixed-price listing create, revise, relist, end
|
|
187
|
+
- **Developer Tools** — rate limits, signing keys, client registration
|
|
188
|
+
- **Token Management** — OAuth URL generation and token management
|
|
330
189
|
|
|
331
|
-
**Example
|
|
190
|
+
**Example tools:** `ebay_get_inventory_items`, `ebay_get_orders`, `ebay_create_offer`, `ebay_get_campaigns`, `ebay_get_oauth_url`.
|
|
332
191
|
|
|
333
|
-
|
|
334
|
-
- `ebay_get_orders` - Retrieve seller orders
|
|
335
|
-
- `ebay_create_offer` - Create new listing offer
|
|
336
|
-
- `ebay_get_campaigns` - Get marketing campaigns
|
|
337
|
-
- `ebay_get_oauth_url` - Generate OAuth authorization URL
|
|
338
|
-
|
|
339
|
-
For the complete tool list, see [src/tools/definitions/](src/tools/definitions/).
|
|
192
|
+
For the complete list, see [`src/tools/definitions/`](src/tools/definitions/) or the [llms.txt index](llms.txt).
|
|
340
193
|
|
|
341
194
|
## Usage Examples
|
|
342
195
|
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
### Setting Up OAuth for Higher Rate Limits
|
|
346
|
-
|
|
347
|
-
**User:** "Can you help me set up OAuth authentication for my eBay account?"
|
|
348
|
-
|
|
349
|
-
**Assistant:** Uses `ebay_get_oauth_url` tool to generate an authorization URL. You visit the URL, grant permissions, and the assistant helps you configure the refresh token in your `.env` file.
|
|
350
|
-
|
|
351
|
-
**Result:** Access to 10,000-50,000 API requests per day instead of 1,000.
|
|
352
|
-
|
|
353
|
-
### Managing Inventory
|
|
354
|
-
|
|
355
|
-
**User:** "Show me all my active listings on eBay"
|
|
356
|
-
|
|
357
|
-
**Assistant:** Uses `ebay_get_inventory_items` to retrieve all inventory items.
|
|
358
|
-
|
|
359
|
-
**Result:** Displays a formatted list of all your products with SKUs, quantities, and status.
|
|
360
|
-
|
|
361
|
-
### Processing Orders
|
|
362
|
-
|
|
363
|
-
**User:** "Get all unfulfilled orders from the last 7 days"
|
|
364
|
-
|
|
365
|
-
**Assistant:** Uses `ebay_get_orders` with date filters and fulfillment status parameters.
|
|
366
|
-
|
|
367
|
-
**Result:** Returns a list of pending orders ready for shipment processing.
|
|
368
|
-
|
|
369
|
-
### Creating Marketing Campaigns
|
|
370
|
-
|
|
371
|
-
**User:** "Create a promoted listing campaign for my electronics category"
|
|
372
|
-
|
|
373
|
-
**Assistant:** Uses `ebay_create_campaign` and related marketing tools to set up ad campaigns.
|
|
374
|
-
|
|
375
|
-
**Result:** New campaign created with specified budget and target items.
|
|
376
|
-
|
|
377
|
-
### Bulk Operations
|
|
378
|
-
|
|
379
|
-
**User:** "Update prices for all items in category 'Vintage Watches' with a 10% discount"
|
|
380
|
-
|
|
381
|
-
**Assistant:** Combines `ebay_get_inventory_items`, filters by category, and uses `ebay_update_offer` to apply bulk pricing changes.
|
|
382
|
-
|
|
383
|
-
**Result:** All matching items updated with new pricing.
|
|
384
|
-
|
|
385
|
-
## Development
|
|
386
|
-
|
|
387
|
-
### Prerequisites
|
|
388
|
-
|
|
389
|
-
- Node.js >= 18.0.0
|
|
390
|
-
- npm or pnpm
|
|
391
|
-
- eBay Developer Account
|
|
392
|
-
|
|
393
|
-
### Quick Start for Contributors
|
|
394
|
-
|
|
395
|
-
```bash
|
|
396
|
-
git clone https://github.com/YOUR_USERNAME/ebay-mcp.git
|
|
397
|
-
cd ebay-mcp
|
|
398
|
-
npm install
|
|
399
|
-
npm run setup # Interactive setup wizard
|
|
400
|
-
npm run build
|
|
401
|
-
npm test
|
|
402
|
-
```
|
|
403
|
-
|
|
404
|
-
### Commands Reference
|
|
405
|
-
|
|
406
|
-
| Command | Description |
|
|
407
|
-
| ------------------ | -------------------------------------------------- |
|
|
408
|
-
| `npm run build` | Compile TypeScript to JavaScript |
|
|
409
|
-
| `npm start` | Run the MCP server |
|
|
410
|
-
| `npm run dev` | Run server with hot reload |
|
|
411
|
-
| `npm test` | Run test suite |
|
|
412
|
-
| `npm run setup` | Interactive setup wizard |
|
|
413
|
-
| `npm run sync` | Sync specs, generate types, find missing endpoints |
|
|
414
|
-
| `npm run diagnose` | Check configuration and connectivity |
|
|
415
|
-
| `npm run check` | Run typecheck + lint + format check |
|
|
416
|
-
| `npm run fix` | Auto-fix lint and format issues |
|
|
417
|
-
|
|
418
|
-
### Adding New API Endpoints
|
|
419
|
-
|
|
420
|
-
When eBay releases new API endpoints, use the sync tool to identify what's missing:
|
|
421
|
-
|
|
422
|
-
```bash
|
|
423
|
-
npm run sync
|
|
424
|
-
```
|
|
425
|
-
|
|
426
|
-
This single command will:
|
|
427
|
-
|
|
428
|
-
1. Download latest OpenAPI specs from eBay
|
|
429
|
-
2. Generate TypeScript types from specs
|
|
430
|
-
3. Analyze which endpoints are implemented
|
|
431
|
-
4. Report missing endpoints that need tools
|
|
432
|
-
|
|
433
|
-
**Workflow for adding a new endpoint:**
|
|
196
|
+
Common tasks, phrased as you'd ask your AI assistant:
|
|
434
197
|
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
6. Run `npm run check && npm test`
|
|
198
|
+
- **Set up OAuth** — *"Help me set up OAuth for my eBay account."* → generates an authorization URL via `ebay_get_oauth_url`, then configures the refresh token. Unlocks 10k–50k req/day.
|
|
199
|
+
- **Manage inventory** — *"Show me all my active listings."* → `ebay_get_inventory_items` returns SKUs, quantities, and status.
|
|
200
|
+
- **Process orders** — *"Get all unfulfilled orders from the last 7 days."* → `ebay_get_orders` with date and fulfillment-status filters.
|
|
201
|
+
- **Create campaigns** — *"Create a promoted-listing campaign for electronics."* → `ebay_create_campaign` and related marketing tools.
|
|
202
|
+
- **Bulk operations** — *"Apply a 10% discount to all 'Vintage Watches' items."* → `ebay_get_inventory_items` + `ebay_update_offer` across matches.
|
|
441
203
|
|
|
442
|
-
|
|
204
|
+
## Logging & Troubleshooting
|
|
443
205
|
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
├── src/
|
|
447
|
-
│ ├── index.ts # MCP server entry point
|
|
448
|
-
│ ├── api/ # eBay API implementations
|
|
449
|
-
│ ├── auth/ # OAuth & token management
|
|
450
|
-
│ ├── tools/ # MCP tool definitions
|
|
451
|
-
│ ├── types/ # TypeScript types (auto-generated)
|
|
452
|
-
│ ├── scripts/ # CLI tools (setup, sync, diagnose)
|
|
453
|
-
│ └── utils/ # Shared utilities
|
|
454
|
-
├── docs/ # OpenAPI specs (auto-downloaded)
|
|
455
|
-
├── tests/ # Test suite
|
|
456
|
-
└── build/ # Compiled output
|
|
457
|
-
```
|
|
458
|
-
|
|
459
|
-
### Docker Support
|
|
460
|
-
|
|
461
|
-
```bash
|
|
462
|
-
docker-compose up -d # Start container
|
|
463
|
-
docker-compose logs -f # View logs
|
|
464
|
-
docker-compose down # Stop container
|
|
465
|
-
```
|
|
466
|
-
|
|
467
|
-
For detailed contribution guidelines, see [CONTRIBUTING.md](CONTRIBUTING.md).
|
|
206
|
+
- **Logging** — Winston-based, written to stderr (MCP-safe) with optional file output. See [docs/logging.md](docs/logging.md).
|
|
207
|
+
- **Troubleshooting** — server not appearing, auth errors, rate limits, empty results. Start with `npm run diagnose`, then see [docs/troubleshooting.md](docs/troubleshooting.md).
|
|
468
208
|
|
|
469
209
|
## Contributing
|
|
470
210
|
|
|
471
|
-
Contributions
|
|
472
|
-
|
|
473
|
-
1. Fork the repository
|
|
474
|
-
2. Create a feature branch: `git checkout -b feature/my-feature`
|
|
475
|
-
3. Make your changes and add tests
|
|
476
|
-
4. Run quality checks: `npm run check && npm test`
|
|
477
|
-
5. Commit using [Conventional Commits](https://www.conventionalcommits.org/)
|
|
478
|
-
6. Push to your fork and open a Pull Request
|
|
479
|
-
|
|
480
|
-
**Before submitting:**
|
|
481
|
-
|
|
482
|
-
- Ensure all tests pass
|
|
483
|
-
- Follow TypeScript best practices
|
|
484
|
-
- Update documentation as needed
|
|
485
|
-
- Maintain test coverage
|
|
211
|
+
Contributions welcome. Fork → branch → add tests → `npm run check && npm test` → commit with [Conventional Commits](https://www.conventionalcommits.org/) → open a PR.
|
|
486
212
|
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
## Logging
|
|
490
|
-
|
|
491
|
-
The server includes Winston-based logging for easier debugging. Logs are output to stderr (compatible with MCP protocol) and optionally to files.
|
|
492
|
-
|
|
493
|
-
### Log Levels
|
|
494
|
-
|
|
495
|
-
Set the log level via environment variable:
|
|
496
|
-
|
|
497
|
-
```bash
|
|
498
|
-
EBAY_LOG_LEVEL=debug # Options: error, warn, info, http, verbose, debug, silly
|
|
499
|
-
```
|
|
500
|
-
|
|
501
|
-
### File Logging
|
|
502
|
-
|
|
503
|
-
Enable file logging for persistent logs:
|
|
504
|
-
|
|
505
|
-
```bash
|
|
506
|
-
EBAY_ENABLE_FILE_LOGGING=true
|
|
507
|
-
```
|
|
508
|
-
|
|
509
|
-
Log files are stored in `~/.ebay-mcp/logs/`:
|
|
510
|
-
|
|
511
|
-
- `error.log` - Error-level messages only
|
|
512
|
-
- `combined.log` - All log messages
|
|
513
|
-
- `debug.log` - Debug and verbose messages
|
|
514
|
-
|
|
515
|
-
### Log Output Example
|
|
516
|
-
|
|
517
|
-
```
|
|
518
|
-
[2024-01-15 10:30:45] [INFO] [Server] Starting eBay API MCP Server
|
|
519
|
-
[2024-01-15 10:30:45] [INFO] [Auth] Loading tokens from environment variables
|
|
520
|
-
[2024-01-15 10:30:46] [INFO] [Auth] Access token refreshed successfully
|
|
521
|
-
[2024-01-15 10:30:46] [HTTP] [API] Request: GET https://api.ebay.com/sell/inventory/v1/inventory_item
|
|
522
|
-
[2024-01-15 10:30:47] [HTTP] [API] Response: 200 OK
|
|
523
|
-
```
|
|
524
|
-
|
|
525
|
-
---
|
|
526
|
-
|
|
527
|
-
## Troubleshooting
|
|
528
|
-
|
|
529
|
-
### Common Issues
|
|
530
|
-
|
|
531
|
-
#### Server Not Appearing in Claude Desktop
|
|
532
|
-
|
|
533
|
-
**Problem:** The eBay MCP server doesn't show up in your MCP client.
|
|
534
|
-
|
|
535
|
-
**Solutions:**
|
|
536
|
-
|
|
537
|
-
1. Verify the config file path is correct for your OS
|
|
538
|
-
2. Check JSON syntax is valid (use a JSON validator)
|
|
539
|
-
3. Ensure environment variables are properly set
|
|
540
|
-
4. Restart Claude Desktop completely
|
|
541
|
-
5. Check Claude Desktop logs for error messages
|
|
542
|
-
|
|
543
|
-
#### Authentication Errors
|
|
544
|
-
|
|
545
|
-
**Problem:** "Invalid credentials" or "Authentication failed" errors.
|
|
546
|
-
|
|
547
|
-
**Solutions:**
|
|
548
|
-
|
|
549
|
-
1. Verify your `EBAY_CLIENT_ID` and `EBAY_CLIENT_SECRET` are correct
|
|
550
|
-
2. Ensure you're using the right environment (sandbox vs production)
|
|
551
|
-
3. Check if your app keys are active in the eBay Developer Portal
|
|
552
|
-
4. For user tokens, verify your `EBAY_USER_REFRESH_TOKEN` is valid
|
|
553
|
-
5. Run `npm run diagnose` to check your configuration
|
|
554
|
-
|
|
555
|
-
#### Rate Limit Errors
|
|
556
|
-
|
|
557
|
-
**Problem:** "Rate limit exceeded" errors.
|
|
558
|
-
|
|
559
|
-
**Solutions:**
|
|
560
|
-
|
|
561
|
-
1. Upgrade to user token authentication (10k-50k requests/day)
|
|
562
|
-
2. Implement request throttling in your usage
|
|
563
|
-
3. Check your current rate limit in the Developer Portal
|
|
564
|
-
4. Consider upgrading your eBay Developer account tier
|
|
565
|
-
|
|
566
|
-
#### Tools Not Working Correctly
|
|
567
|
-
|
|
568
|
-
**Problem:** Tools return unexpected errors or empty results.
|
|
569
|
-
|
|
570
|
-
**Solutions:**
|
|
571
|
-
|
|
572
|
-
1. Verify you're using the correct environment (sandbox vs production)
|
|
573
|
-
2. Ensure you have proper permissions/scopes for the operation
|
|
574
|
-
3. Check current API status with the `ebay_get_api_status` tool or the [eBay API Status](https://developer.ebay.com/support/api-status) page
|
|
575
|
-
4. Run `npm run diagnose` to check your configuration
|
|
576
|
-
5. Review the [eBay API documentation](https://developer.ebay.com/docs) for endpoint requirements
|
|
577
|
-
|
|
578
|
-
### Diagnostic Tools
|
|
579
|
-
|
|
580
|
-
Run diagnostics to troubleshoot configuration issues:
|
|
581
|
-
|
|
582
|
-
```bash
|
|
583
|
-
# Interactive diagnostics
|
|
584
|
-
npm run diagnose
|
|
585
|
-
|
|
586
|
-
# Export diagnostic report
|
|
587
|
-
npm run diagnose:export
|
|
588
|
-
```
|
|
589
|
-
|
|
590
|
-
The diagnostic tool checks:
|
|
591
|
-
|
|
592
|
-
- Environment variable configuration
|
|
593
|
-
- eBay API connectivity
|
|
594
|
-
- Authentication status
|
|
595
|
-
- Token validity
|
|
596
|
-
- Available scopes and permissions
|
|
597
|
-
|
|
598
|
-
### Getting Help
|
|
599
|
-
|
|
600
|
-
If you're still experiencing issues:
|
|
601
|
-
|
|
602
|
-
1. Check existing [GitHub Issues](https://github.com/YosefHayim/ebay-mcp/issues)
|
|
603
|
-
2. Create a new issue with:
|
|
604
|
-
- Your diagnostic report (`npm run diagnose:export`)
|
|
605
|
-
- Steps to reproduce the problem
|
|
606
|
-
- Error messages or logs
|
|
607
|
-
- Your environment (OS, Node version, MCP client)
|
|
213
|
+
- Working on the codebase or with a coding agent? Start with **[AGENTS.md](AGENTS.md)** — build/test commands, module map, and the add-an-endpoint workflow.
|
|
214
|
+
- Full guidelines: **[CONTRIBUTING.md](CONTRIBUTING.md)**.
|
|
608
215
|
|
|
609
216
|
## Resources
|
|
610
217
|
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
- [
|
|
616
|
-
- [API Status
|
|
617
|
-
-
|
|
618
|
-
- [
|
|
619
|
-
|
|
620
|
-
### Documentation
|
|
621
|
-
|
|
622
|
-
- [eBay Developer Portal](https://developer.ebay.com/) - API documentation and credentials
|
|
623
|
-
- [eBay API License Agreement](https://developer.ebay.com/join/api-license-agreement) - Terms of use and compliance requirements
|
|
624
|
-
- [eBay Data Handling Requirements](https://developer.ebay.com/api-docs/static/data-handling-update.html) - Important data protection and privacy guidelines
|
|
625
|
-
- [MCP Documentation](https://modelcontextprotocol.io/) - Model Context Protocol specification
|
|
626
|
-
- [OAuth Quick Reference](docs/auth/OAUTH_QUICK_REFERENCE.md) - **Complete OAuth authentication guide with scopes, troubleshooting, and examples**
|
|
627
|
-
- [OAuth Setup Guide](docs/auth/) - Detailed authentication configuration
|
|
628
|
-
- [Contributing Guidelines](CONTRIBUTING.md) - How to contribute to this project
|
|
629
|
-
- [Code of Conduct](CODE_OF_CONDUCT.md) - Community guidelines and expectations
|
|
630
|
-
- [Changelog](CHANGELOG.md) - Version history and release notes
|
|
631
|
-
- [Security Policy](SECURITY.md) - Vulnerability reporting guidelines
|
|
632
|
-
|
|
633
|
-
### Support
|
|
634
|
-
|
|
635
|
-
- [Issue Tracker](https://github.com/YosefHayim/ebay-mcp/issues) - Bug reports and feature requests
|
|
636
|
-
- [Bug Report Template](BUG_REPORT.md) - Detailed bug reporting guide
|
|
218
|
+
- [eBay Developer Portal](https://developer.ebay.com/) — API docs and credentials
|
|
219
|
+
- [eBay API License Agreement](https://developer.ebay.com/join/api-license-agreement) — terms and compliance
|
|
220
|
+
- [eBay Data Handling Requirements](https://developer.ebay.com/api-docs/static/data-handling-update.html) — data protection and privacy
|
|
221
|
+
- [MCP Documentation](https://modelcontextprotocol.io/) — Model Context Protocol spec
|
|
222
|
+
- [OAuth Quick Reference](docs/auth/OAUTH_QUICK_REFERENCE.md) — scopes, troubleshooting, examples
|
|
223
|
+
- [eBay API Status](https://developer.ebay.com/support/api-status) — official status page (also via the `ebay_get_api_status` tool and the [in-repo snapshot](docs/API_STATUS.md))
|
|
224
|
+
- [CHANGELOG.md](CHANGELOG.md) · [SECURITY.md](SECURITY.md) · [CODE_OF_CONDUCT.md](CODE_OF_CONDUCT.md)
|
|
225
|
+
- [Issue Tracker](https://github.com/YosefHayim/ebay-mcp/issues) — bug reports and feature requests
|
|
637
226
|
|
|
638
227
|
## License
|
|
639
228
|
|
|
640
|
-
|
|
229
|
+
MIT — see [LICENSE](LICENSE).
|
|
641
230
|
|
|
642
231
|
## Contributors
|
|
643
232
|
|
|
644
|
-
Thanks to
|
|
233
|
+
Thanks to everyone who has helped make this project better! 🎉
|
|
645
234
|
|
|
646
235
|
<a href="https://github.com/YosefHayim/ebay-mcp/graphs/contributors">
|
|
647
236
|
<img src="https://contrib.rocks/image?repo=YosefHayim/ebay-mcp" alt="Contributors" />
|
|
648
237
|
</a>
|
|
649
238
|
|
|
650
|
-
## Acknowledgments
|
|
651
|
-
|
|
652
|
-
- [eBay Developers Program](https://developer.ebay.com/) for API access
|
|
653
|
-
- [Model Context Protocol](https://modelcontextprotocol.io/) for the MCP specification
|
|
654
|
-
|
|
655
239
|
---
|
|
656
240
|
|
|
657
241
|
<div align="center">
|