Gap APIgap.com ↗
Access Gap.com product search, category browsing, product details, customer reviews, store finder, recommendations, and navigation via a single API.
What is the Gap API?
The Gap.com API covers 7 endpoints that expose Gap's full product catalog, store locations, and site navigation. The search_products endpoint returns paginated listings with price ranges, review scores, and color swatches for any keyword query. Additional endpoints handle category browsing by CID, detailed product data, customer reviews, store lookup by ZIP code, related product recommendations, and the complete category tree.
curl -X GET 'https://api.parse.bot/scraper/0b7da48b-19ee-4b5e-9262-531ac2c04c30/search_products?page=0&limit=10&query=jeans' \ -H 'X-API-Key: $PARSE_API_KEY'
Typed, relational, agent-ready
A generated client with real types, enums, and the links between objects — the structure a flat JSON response can't carry. Autocompletes in your editor and reads cleanly to coding agents.
- Fully typed · autocompletes
- Objects link to objects
- Typed errors & pagination
Typed Python client. Set up the SDK in your uv project, then pull this API’s typed client:
uv add parse-sdk uv run parse init uv run parse add --marketplace gap-com-api
uv run parse add --marketplace pulls a pinned snapshot of this canonical API — it won’t change underneath you. To customize it, subscribe and swap to your own copy.
"""Walkthrough: Gap.com SDK — search products, browse categories, get details and recommendations."""
from parse_apis.gap_com_api import Gap, ProductNotFound
client = Gap()
# Search for jeans — limit caps total items fetched across all pages.
for product in client.products.search(query="jeans", limit=3):
print(product.name, product.review_score, product.price_range)
# Drill into the first result's recommendations.
product = client.products.search(query="shirt", limit=1).first()
if product:
for rec in product.get_recommendations(limit=3):
print(rec.model_copy, rec.schema_name)
# Browse a category by ID (5664 = Women's Jeans).
for item in client.categoryproducts.browse(cid="5664", limit=3):
print(item.style_name, item.review_count)
# Find stores near a ZIP code.
for store in client.stores.find_nearby(zip="10001", limit=3):
print(store.store_name, store.distance, store.phone_number)
# Typed error handling: catch ProductNotFound on a bad product ID.
try:
detail = client.products.search(query="nonexistent_xyz_99999", limit=1).first()
if detail:
reviews = detail.get_reviews(limit=1).first()
if reviews:
print(reviews.page_id, reviews.rollup.average_rating)
except ProductNotFound as exc:
print(f"Product not found: {exc.pid}")
print("exercised: products.search / get_recommendations / categoryproducts.browse / stores.find_nearby / get_reviews")Full-text search over Gap.com product catalog by keyword. Returns paginated product listings with names, prices, color swatches, review scores, and facets. Pagination is 0-indexed. Each product contains multiple color variants with pricing and images.
| Param | Type | Description |
|---|---|---|
| page | integer | Page number (0-indexed) |
| limit | integer | Number of products per page (max 120) |
| queryrequired | string | Search keyword (e.g. 'jeans', 'shirt', 'dress') |
{
"type": "object",
"fields": {
"products": "array of product objects with id, name, priceRange, salePriceRange, reviewScore, reviewCount, colors",
"pagination": "object with pageSize, currentPage, pageNumberTotal",
"totalProducts": "string total number of products matching the query"
},
"sample": {
"data": {
"products": [
{
"id": "406725",
"name": "High Rise Stride Wide-Leg Jeans",
"colors": [
{
"id": "406725002",
"name": "Blue",
"priceType": "P",
"regularPrice": "89.95",
"percentageOff": "61",
"effectivePrice": "35.0",
"shortDescription": "Dark wash"
}
],
"priceRange": [
"79.95",
"99.95"
],
"reviewCount": 183,
"reviewScore": 4.62,
"salePriceRange": [
"35.0",
"74.99"
]
}
],
"pagination": {
"pageSize": 10,
"currentPage": 0,
"pageNumberTotal": 74
},
"totalProducts": "740"
},
"status": "success"
}
}About the Gap API
Product Search and Category Browsing
The search_products endpoint accepts a required query string plus optional page (0-indexed) and limit parameters. Each product object in the response includes id, name, priceRange, reviewScore, reviewCount, and a colors array. A pagination object (pageSize, currentPage, pageNumberTotal) and a totalProducts string let you page through large result sets. For browsing by department instead of keyword, get_category_products takes a cid string (for example, '5664' for Women's Jeans) and returns a categories array with categoryId, categoryName, and a ccList of color variants, alongside a totalColors count.
Product Details and Reviews
get_product_details takes a pid string and returns id, brand, title, description, and productName for the matched item. For review data, get_product_reviews accepts a style-level pid (e.g., '728822' rather than a full product ID) and returns a paging object with total_results, pages_total, page_size, and current_page_number, plus a results array that includes both rollup statistics and individual review records.
Stores, Recommendations, and Navigation
find_stores takes a zip parameter and returns an array of store objects, each containing id, storeName, address, phoneNumber, hours, distance, latitude, and longitude. get_recommendations accepts a product pid and returns recommendation_containers, each group carrying a model_type, model_copy label (such as 'Customers also viewed'), and a recommended_products array. Finally, get_navigation requires no inputs and returns the full category tree — id, name, type, and recursive children with link values — covering all divisions like Women, Men, Girls, and Boys.
The Gap API is a managed, monitored endpoint for gap.com — not a raw scraper you maintain. Every endpoint is automatically health-checked on a schedule, and when gap.com changes and a check fails, the API is automatically queued for repair and re-verified. It is built to keep working as the site underneath it changes.
This isn't an official gap.com API — it's an independent, maintained REST wrapper over public data. Where the source has no official API (or only a limited one), Parse gives you a stable contract over a source that never promised one, and keeps it current. Need a new endpoint or field? You can revise it yourself in plain English and the agent rebuilds it against the live site in minutes — contributing the change back to the shared API is free.
Will this API break when the source site changes?+
Is this an official API from the source site?+
Can I fix or extend this API myself if I need a new endpoint or field?+
What happens if I call an endpoint that has an issue?+
- Build a Gap product search widget that surfaces price ranges and review scores by keyword.
- Sync a product catalog tool with Gap category listings using CID-based pagination from
get_category_products. - Display customer review summaries and ratings on a fashion comparison site using
get_product_reviews. - Power a store-locator feature by querying
find_storeswith a user's ZIP code to show nearby Gap locations with hours and distance. - Drive a 'You might also like' recommendation rail by feeding
get_recommendationsoutput into a product detail page. - Map Gap's full department and subcategory structure by parsing the
childrentree fromget_navigationto build faceted browsing. - Track price range changes for specific Gap product IDs over time using
get_product_details.
| Tier | Price | Credits/month | Rate limit |
|---|---|---|---|
| Free | $0/mo | 100 | 5 req/min |
| Hobby | $30/mo | 1,000 | 20 req/min |
| Developer | $100/mo | 5,000 | 100 req/min |
One credit = one API call regardless of which marketplace API you call. Exceeding the rate limit returns a 429 response. Authenticate with the X-API-Key header.
Does Gap have an official public developer API?+
What does `get_product_reviews` return and how is it paginated?+
get_product_reviews accepts a style-level pid (not a full product ID) and an optional 0-indexed page parameter. The response includes a paging object with total_results, pages_total, page_size, and current_page_number, plus a results array containing both aggregate rollup stats and individual review records with ratings and comments.Does `get_product_details` return available sizes or inventory levels?+
get_product_details endpoint currently returns id, brand, title, description, and productName. Size availability and inventory levels are not included in the current response shape. You can fork this API on Parse and revise it to add an endpoint that surfaces size and inventory data.How do I find the category ID (CID) to use with `get_category_products`?+
get_navigation first — it returns the full category tree with id fields at each node. Those id values are the CIDs you pass to get_category_products. For example, Women's Jeans uses CID '5664'.