🔒 Enterprise Security
System-level JWT authentication with predefined queries for maximum security
Complete API reference for the Customer-Vibes Analytics API. Provides secure access to customer profile and vehicle data from the Customer Database through a high-performance API gateway. Built on a proven 3-step async pattern with intelligent caching for optimal performance.
🔒 Enterprise Security
System-level JWT authentication with predefined queries for maximum security
⚡ Real-time Processing
Daily data updates with 24-hour delta queries for incremental sync
# Submit analytics querycurl -X POST https://public-api.dev2.steercrm.dev/api/data/v1/analytics/customer-vibes \ -H "Content-Type: application/json" \ -H "X-API-Key: YOUR_API_KEY" \ -d '{}'
# Check status (replace with actual queryId)curl https://public-api.dev2.steercrm.dev/api/data/v1/analytics/{queryId}/status \ -H "X-API-Key: YOUR_API_KEY"
# Get resultscurl https://public-api.dev2.steercrm.dev/api/data/v1/analytics/{queryId}/results?partition=0 \ -H "X-API-Key: YOUR_API_KEY"// Submit query and get resultsasync function fetchAnalytics() { // Step 1: Submit query const response = await fetch('/api/data/v1/analytics/customer-vibes', { method: 'POST', headers: { 'Content-Type': 'application/json', 'X-API-Key': 'YOUR_API_KEY' }, body: '{}' }); const { queryId } = await response.json();
// Step 2: Poll for completion let status; do { const statusResponse = await fetch(`/api/data/v1/analytics/${queryId}/status`, { headers: { 'X-API-Key': 'YOUR_API_KEY' } }); ({ status } = await statusResponse.json()); if (status === 'RUNNING') await new Promise(r => setTimeout(r, 1000)); } while (status === 'RUNNING');
// Step 3: Get results if (status === 'SUCCESS') { const resultsResponse = await fetch(`/api/data/v1/analytics/${queryId}/results?partition=0`, { headers: { 'X-API-Key': 'YOUR_API_KEY' } }); return await resultsResponse.json(); }}import requestsimport time
def fetch_analytics(): headers = {'X-API-Key': 'YOUR_API_KEY'}
# Submit query response = requests.post('https://public-api.dev2.steercrm.dev/api/data/v1/analytics/customer-vibes', json={}, headers=headers) query_id = response.json()['queryId']
# Poll for completion while True: status_response = requests.get(f'https://public-api.dev2.steercrm.dev/api/data/v1/analytics/{query_id}/status', headers=headers) status = status_response.json()['status']
if status == 'SUCCESS': break elif status == 'RUNNING': time.sleep(1) else: raise Exception(f'Query failed with status: {status}')
# Get results results_response = requests.get(f'https://public-api.dev2.steercrm.dev/api/data/v1/analytics/{query_id}/results', params={'partition': 0}, headers=headers) return results_response.json()API Base URL
Development: https://public-api.dev2.steercrm.dev
Production: https://api-prod.example.com
🔐 API Key Authentication
Authentication Method:
X-API-Key header for all API requestsX-API-Key: your-api-key-hereGet information about all available predefined analytics queries.
GET /api/data/v1/analytics/types{ "availableQueries": [ { "description": "Customer profiles for Vibes integration", "endpoint": "/api/data/v1/analytics/customer-vibes", "type": "customer-vibes" }, { "description": "Customer profiles updated within last 24 hours", "endpoint": "/api/data/v1/analytics/customer-vibes-delta-24h", "type": "customer-vibes-delta-24h" } ], "message": "Only predefined queries are allowed for security"}Retrieve complete customer profiles and vehicle data for initial data loads or complete snapshots.
POST /api/data/v1/analytics/customer-vibesContent-Type: application/json
{}{ "description": "Customer profiles for Vibes integration", "links": { "results": "/api/data/v1/analytics/01bf6563-0003-9701-0006-874e00e6507e/results", "status": "/api/data/v1/analytics/01bf6563-0003-9701-0006-874e00e6507e/status" }, "message": "Query submitted successfully", "queryId": "01bf6563-0003-9701-0006-874e00e6507e", "queryType": "customer-vibes", "status": "RUNNING", "success": true}Use Cases:
Retrieve only records updated within the last 24 hours for efficient incremental updates.
POST /api/data/v1/analytics/customer-vibes-delta-24hContent-Type: application/json
{}{ "description": "Customer profiles updated within last 24 hours", "links": { "results": "/api/data/v1/analytics/01bf6563-0003-96b3-0006-874e00e6407a/results", "status": "/api/data/v1/analytics/01bf6563-0003-96b3-0006-874e00e6407a/status" }, "message": "Query submitted successfully", "queryId": "01bf6563-0003-96b3-0006-874e00e6407a", "queryType": "customer-vibes-delta-24h", "status": "RUNNING", "success": true}When no records have been updated in the last 24 hours:
{ "success": true, "queryId": "01bf6563-0003-96b3-0006-874e00e6407a", "queryType": "customer-vibes-delta-24h", "partition": 0, "totalPartitions": 1, "rowCount": 0, "data": [], "metadata": { "format": "jsonv2", "numRows": 0, "partitionInfo": [ { "rowCount": 0, "uncompressedSize": 0 } ] }}Use Cases:
Retrieve the complete organizational structure showing relationships between brands, tenants, and shops.
POST /api/data/v1/analytics/business360-hierarchyContent-Type: application/json
{}{ "description": "Business360 organizational hierarchy", "links": { "results": "/api/data/v1/analytics/01bf6563-0003-9701-0006-874e00e6507e/results", "status": "/api/data/v1/analytics/01bf6563-0003-9701-0006-874e00e6507e/status" }, "message": "Query submitted successfully", "queryId": "01bf6563-0003-9701-0006-874e00e6507e", "queryType": "business360-hierarchy", "status": "RUNNING", "success": true}Description: Returns complete organizational structure with brand, tenant, and shop relationships for navigation and filtering.
Retrieve aggregated KPIs and performance metrics at the brand level for executive dashboards.
POST /api/data/v1/analytics/business360-insights-brandContent-Type: application/json
{ "brand_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"}Body Parameters:
brand_id (required): Brand UUID for filtering insights{ "description": "Brand-level aggregated insights", "links": { "results": "/api/data/v1/analytics/01bf6563-0003-9701-0006-874e00e6507e/results", "status": "/api/data/v1/analytics/01bf6563-0003-9701-0006-874e00e6507e/status" }, "message": "Query submitted successfully", "queryId": "01bf6563-0003-9701-0006-874e00e6507e", "queryType": "business360-insights-brand", "status": "RUNNING", "success": true}Description: Provides high-level executive insights with brand-level KPIs aggregated across all tenants and shops.
Retrieve aggregated performance metrics at the tenant level for operational management.
POST /api/data/v1/analytics/business360-insights-tenantContent-Type: application/json
{ "tenant_id": "f2e3d4c5-b6a7-8901-2345-6789abcdef01"}Body Parameters:
tenant_id (required): Tenant UUID for filtering insights{ "description": "Tenant-level aggregated insights", "links": { "results": "/api/data/v1/analytics/01bf6563-0003-9701-0006-874e00e6507e/results", "status": "/api/data/v1/analytics/01bf6563-0003-9701-0006-874e00e6507e/status" }, "message": "Query submitted successfully", "queryId": "01bf6563-0003-9701-0006-874e00e6507e", "queryType": "business360-insights-tenant", "status": "RUNNING", "success": true}Description: Operational management insights with performance metrics rolled up across all shops within a tenant.
Retrieve granular performance data at the shop location level for detailed analysis.
POST /api/data/v1/analytics/business360-insights-shopContent-Type: application/json
{ "shop_id": "c3d4e5f6-a7b8-9012-3456-789abcdef012"}Body Parameters:
shop_id (required): Shop UUID for filtering insights{ "description": "Shop-level granular insights", "links": { "results": "/api/data/v1/analytics/01bf6563-0003-9701-0006-874e00e6507e/results", "status": "/api/data/v1/analytics/01bf6563-0003-9701-0006-874e00e6507e/status" }, "message": "Query submitted successfully", "queryId": "01bf6563-0003-9701-0006-874e00e6507e", "queryType": "business360-insights-shop", "status": "RUNNING", "success": true}Description: Detailed KPIs for individual shop locations with granular performance metrics.
Monitor the execution progress of submitted queries with real-time status updates.
GET /api/data/v1/analytics/{queryId}/status{ "message": "Statement executed successfully.", "queryId": "01bf6563-0003-9701-0006-874e00e6507e", "queryType": "customer-vibes", "resultSetMetaData": { "format": "jsonv2", "numRows": 25921, "partitionInfo": [ { "compressedSize": 28566, "rowCount": 255, "uncompressedSize": 100216 }, { "compressedSize": 117829, "rowCount": 1071, "uncompressedSize": 417859 } // ... variable number of partitions based on dataset size ], "rowType": [ { "name": "STEER_CUSTOMER_ID", "type": "text", "nullable": true, "database": "DATAMART_DEV", "schema": "DWH_PRODUCT", "table": "DM_CUSTOMER" }, { "name": "VAST_CUSTOMER_ID", "type": "text", "nullable": true, "database": "DATAMART_DEV", "schema": "DWH_PRODUCT", "table": "DM_INTEGRATION" }, { "name": "CUSTOMER_TYPE", "type": "text", "nullable": true }, { "name": "CUSTOMER_STAGE", "type": "text", "nullable": false } // ... complete schema with 28 fields total ] }, "stats": { "createdOn": 1759231895424 }, "status": "SUCCESS", "submittedAt": "2025-09-30T11:31:35.717Z"}RUNNING
Query is currently executing on the database
SUCCESS
Query completed successfully, results are available
FAILED
Query execution failed, check error details
Retrieve the processed data from completed queries with support for large dataset partitioning.
GET /api/data/v1/analytics/{queryId}/results?partition=0Parameters:
partition (optional): Partition number (0-based). Default: 0{ "success": true, "queryId": "01bf6563-0003-9701-0006-874e00e6507e", "queryType": "customer-vibes", "partition": 0, "totalPartitions": 24, // varies by dataset size "rowCount": 255, "data": [ [ "4b62d36a-a5d6-4308-8d40-af6358104775", "0015069558", "Person", "Customer", "John", "Smith", null, "Houston", "Texas", "77001", null, null, "Eligible", "john.smith@example.com", "Eligible", "f154d8db-cbe1-461e-bc7b-5fae9eeeead2", "15000171790", "Chevrolet", "2020", "Impala", "CHEVROLET", "IMPALA", "2020", "Downtown Service Center", "Premier Auto Services", "1701457200.000000000", null, "1750254263.614000000" ] // ... additional records as arrays ]}Test the API quickly and efficiently with our pre-configured Postman collection. Get started in minutes with ready-to-use requests and environment configurations.
📦 Complete Collection
Pre-configured requests for all API endpoints including:
🔧 Environment Setup
Development Environment
Ready-to-use environment configuration with:
https://public-api.dev2.steercrm.dev)Get testing in 3 steps:
Step-by-step setup instructions:
Download Files
Import into Postman
Configure API Key
api_key variable to your actual API keyTest the Integration
Advanced features included:
🔄 Automated Workflows
🎯 Smart Testing
📊 Environment Management
For comprehensive data model specifications including field definitions, business rules, consent management, and integration considerations, please refer to the dedicated Data Model documentation.
⚡ Database Processing
Variable timing Initial query execution depends on data size and complexity
🚀 Cached Results
Redis Caching Cached results for identical queries delivered instantly
⏱️ Result Cache TTL
1 hour Results cached for optimal performance
🔄 Status Cache TTL
5 minutes Running query status cached briefly
For large datasets, the database automatically creates partitions when needed. The number of partitions varies based on dataset size and complexity.
📊 Partition Strategy
Automatic Partitioning
📊 Full Dataset
Complete Records All available customer and vehicle records from source systems
⏰ 24-Hour Delta
Recent Updates Records updated within the last 24 hours (based on Unix timestamp comparison)
🔄 Update Frequency
Daily Updates Source system updates processed once every 24 hours
🌐 Global Sync
Multi-tenant Supports multiple tenant environments and regions