Look up eBay category IDs by name and list top-level departments for a marketplace domain.
View all eBay Product Listings & Seller Data endpoints →Returns the eBay category tree for one marketplace domain as structured JSON. Send an optional query to filter categories by a case-insensitive name or slug substring, so a plain-language name such as cell phones resolves to the numeric category_id that the search operation's category parameter expects; leave query empty to receive the full top-level tree. domain selects one of 13 verified eBay sites (com, co.uk, de, com.au, ca, fr, it, es, nl, at, ch, ie, pl) and max_results limits how many categories come back, up to 240. The response uses an ok/meta/data envelope: data.categories[] holds category_id, name and slug, and data.groups[] holds the top-level department names. Observed in a live probe (query cell phones, domain com, max_results 5): one category was returned (category_id 15032, name Cell Phones & Accessories, slug Cell-Phones-Smart-Watches-Accessories) together with 18 department names such as Electronics, Collectibles & Art and Home & Garden, and meta reported domain com, query cell phones and record_count 1.
API Features
Live API Demo
🔒 Sign in to try it live
Log in to call this API with your own API key. New accounts get 100 free credits — no card required.
Log in / Sign upNo active API key found. Create one in your Dashboard, then reload this page. Dashboard →
/api/project/ebay/categories API Response (JSON)
{} curl -X POST 'https://api.opendata-api.com/api/project/ebay/categories?key=<API_KEY>'
Query Result
Use Cases
- Resolve a category name such as cell phones to its numeric ID once, cache it, and reuse it in scheduled search jobs
- Populate a category dropdown in an internal search or price-alert interface from categories[] and groups[]
- Map an internal product taxonomy to eBay category IDs separately for each marketplace domain
- Seed a department-by-department scanning job from the groups[] list of top-level departments
- Re-check on a schedule that a saved category name still resolves to the same category_id before a monitor runs
Frequently asked questions
How do I find the category ID for a category name?
Send a POST with query set to the name (for example cell phones) and the domain you care about, then read data.categories[].category_id. In the observed probe this returned category_id 15032 for Cell Phones & Accessories, which is the kind of value the search operation's category parameter accepts.
Do I have to send a query?
No. domain, max_results and query are all optional. With an empty query the call returns the full top-level tree, and data.groups[] lists the top-level department names (18 were observed for the com domain).
How does the query filter match?
It is a case-insensitive substring match on the category name or slug, so short, plain terms work best. The probe query cell phones matched a single category, and meta.record_count reported 1.
Which marketplaces can I query?
The domain dropdown lists 13 verified sites: com, co.uk, de, com.au, ca, fr, it, es, nl, at, ch, ie and pl. Other eBay country sites such as com.sg or com.hk are reported as accepted but are not in the verified list, so test them before relying on them.
How many categories can one call return?
max_results accepts 1 to 240, and larger values are capped at 240. The observed probe asked for 5 and received the one category that matched the query.
Should I cache the result?
Yes, category IDs change rarely, and the probe calls took roughly 1.5 seconds each. Resolve names once per marketplace, store the category_id, and only refresh on a schedule.