API Reference
SGEScore API
Integrate AI visibility tracking directly into your applications. Our REST API provides programmatic access to all SGEScore features.
RESTful API
Standard REST architecture with JSON responses. Easy to integrate with any language or framework.
Secure by Default
All API requests require authentication via API keys. HTTPS-only endpoints for data security.
Rate Limiting
Generous rate limits based on your plan. Enterprise customers can request increased limits.
Authentication
Authenticate your API requests by including your API key in the Authorization header.
// Authentication
const response = await fetch('https://api.sgescore.com/v1/websites', {
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
}
});Note: Keep your API keys secure. Never expose them in client-side code or public repositories.
API Endpoints
| Method | Endpoint | Description |
|---|---|---|
| GET | /api/v1/websites | List all tracked websites for the authenticated user |
| POST | /api/v1/websites | Add a new website to track |
| GET | /api/v1/websites/:id/score | Get the AI visibility score for a website |
| GET | /api/v1/prompts | List all tracking prompts |
| POST | /api/v1/prompts | Create a new tracking prompt |
| POST | /api/v1/prompts/:id/run | Execute a prompt across all AI platforms |
| GET | /api/v1/reports/share-of-voice | Get Share of Voice analytics |
| GET | /api/v1/reports/citations | Get citation tracking data |
Code Examples
Add a Website
// Add a website to track
const response = await fetch('https://api.sgescore.com/v1/websites', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
url: 'https://yoursite.com',
name: 'Your Brand Name'
})
});
const data = await response.json();
console.log(data.websiteId);Run a Tracking Prompt
// Run a tracking prompt
const response = await fetch('https://api.sgescore.com/v1/prompts/prompt_123/run', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
}
});
const results = await response.json();
// Results include responses from ChatGPT, Claude, Gemini, and PerplexityRate Limits
| Plan | Requests/min | Requests/day |
|---|---|---|
| Starter | 60 | 1,000 |
| Growth | 120 | 5,000 |
| Pro | 300 | 20,000 |
| Enterprise | Custom | Custom |