Complete reference of all available endpoints
All API endpoints are protected with API key authentication. You must include a valid API key in the Authorization header with each request. Email us and we’ll help you get set up.
To authenticate with the API, include your API key in the Authorization
header of your requests.
curl -X GET "https://api.new-gen.ai/v1/products/search?q=shoes" \
-H "Authorization: YOUR_API_KEY"
If you’re using a client library:
// JavaScript example
const response = await fetch(
"https://api.new-gen.ai/v1/products/search?q=shoes",
{
headers: {
Authorization: "YOUR_API_KEY",
},
},
);
# Python example
import requests
headers = {
'Authorization': 'YOUR_API_KEY'
}
response = requests.get('https://api.new-gen.ai/v1/products/search?q=shoes', headers=headers)
Email us to obtain an API key and we’ll help you get set up. API keys should be kept secure and not shared.
curl GET /api/v1/products/search
Search for products using text queries and LLM reranking.
Parameter | Type | Description |
---|---|---|
q | string | Search query text (required) |
brand_url | string | Base brand URL to filter by, e.g., nike.com (optional) |
limit | number | Maximum number of results (default: 20) |
include_raw_data | boolean | Include raw html/json data from pdp (default: false) |
curl GET /api/v1/products/:id
Retrieve a product by its ID.
Parameter | Type | Description |
---|---|---|
id | string | Product ID |
Parameter | Type | Description |
---|---|---|
include_raw_data | boolean | Include raw html/json data from pdp (default: false) |
curl GET /api/v1/products?url={url}
Retrieve a product by its URL.
Parameter | Type | Description |
---|---|---|
url | string | The product URL to fetch |
include_raw_data | boolean | Include raw html/json data from pdp (default: false) |
GET /health
Check API health status.