> ## Documentation Index
> Fetch the complete documentation index at: https://docs.steerai.autos/llms.txt
> Use this file to discover all available pages before exploring further.

# API Integration Overview

> Flexible RESTful APIs for custom automotive inspection and pricing solutions

## Why Choose API Integration?

Perfect for developers and businesses that need maximum flexibility and custom integrations. Get up and running in 48 hours with no setup fees.

<CardGroup cols={2}>
  <Card title="Key Benefits" icon="check-circle">
    • **No setup fee** - Start building immediately
    • **48-hour deployment** - Fastest API integration
    • **RESTful APIs** - Standard, predictable endpoints
    • **Maximum flexibility** - Build exactly what you need
    • **Scalable pricing** - Pay only for what you use
  </Card>

  <Card title="Best For" icon="star">
    • Development teams with API experience
    • Custom application integrations
    • High-volume inspection processing
    • Unique workflow requirements
    • Existing application enhancement
  </Card>
</CardGroup>

## Core API Capabilities

### Vehicle Inspection APIs

* **Mechanical Inspection:** AI-powered diagnostic analysis
* **Visual Inspection:** 360° damage detection and assessment
* **Image Processing:** Advanced computer vision for damage identification
* **Inspection Reports:** Comprehensive PDF and JSON reports

### Pricing & Valuation APIs

* **Market Valuation:** Real-time market price analysis
* **Damage Assessment:** Impact calculation on vehicle value
* **Repair Estimation:** Accurate repair cost predictions
* **Regional Pricing:** Location-based price adjustments

### Business Integration APIs

* **Lead Management:** CRM integration capabilities
* **Inventory Sync:** Real-time inventory management
* **Contract Generation:** Automated document creation
* **Marketing Integration:** Multi-platform marketing tools

## Quick Start

### 1. Get Your API Keys

```bash theme={null}
# Sign up and get your API keys
curl -X POST "https://api.steerai.autos/v1/auth/register" \
  -H "Content-Type: application/json" \
  -d '{
    "email": "your-email@company.com",
    "company": "Your Company Name"
  }'
```

### 2. Make Your First API Call

```bash theme={null}
# Test your authentication
curl -X GET "https://api.steerai.autos/v1/auth/test" \
  -H "Authorization: Bearer YOUR_API_KEY"
```

### 3. Create Your First Inspection

```bash theme={null}
# Submit vehicle images for inspection
curl -X POST "https://api.steerai.autos/v1/inspections" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "vehicle": {
      "vin": "1HGBH41JXMN109186",
      "year": 2021,
      "make": "Honda",
      "model": "Civic"
    },
    "images": [
      "https://your-storage.com/image1.jpg",
      "https://your-storage.com/image2.jpg"
    ]
  }'
```

## API Architecture

### Base URLs

* **Production:** `https://api.steerai.autos/v1`
* **Sandbox:** `https://api-sandbox.steerai.autos/v1`

### Authentication

All API requests require authentication via Bearer token in the Authorization header.

### Response Format

All endpoints return JSON with consistent structure:

```json theme={null}
{
  "status": "success|error",
  "data": { ... },
  "meta": {
    "request_id": "req_1234567890",
    "timestamp": "2024-01-15T10:30:00Z",
    "processing_time": 1.23
  }
}
```

## Rate Limits

| Plan             | Requests/Hour | Concurrent | Burst Limit |
| ---------------- | ------------- | ---------- | ----------- |
| **Free**         | 1,000         | 5          | 50          |
| **Starter**      | 10,000        | 20         | 200         |
| **Professional** | 100,000       | 100        | 1,000       |
| **Enterprise**   | Unlimited     | Custom     | Custom      |

### Rate Limit Headers

```http theme={null}
X-RateLimit-Limit: 1000
X-RateLimit-Remaining: 999
X-RateLimit-Reset: 1640995200
X-Retry-After: 60
```

## SDK Support

<CardGroup cols={2}>
  <Card title="Python SDK" icon="python" href="/sdks/python">
    ```python theme={null}
    pip install steer-ai
    ```

    Full-featured Python SDK with async support
  </Card>

  <Card title="JavaScript SDK" icon="js" href="/sdks/javascript">
    ```bash theme={null}
    npm install @steerai/sdk
    ```

    TypeScript-ready SDK for Node.js and browsers
  </Card>
</CardGroup>

## Example Integrations

### Basic Inspection Workflow

```python theme={null}
from steer_ai import SteerAI

# Initialize client
client = SteerAI(api_key="YOUR_API_KEY")

# Create inspection
inspection = client.inspections.create({
    "vehicle": {
        "vin": "1HGBH41JXMN109186",
        "year": 2021,
        "make": "Honda",
        "model": "Civic"
    },
    "images": ["image1.jpg", "image2.jpg"]
})

# Get results
result = client.inspections.get(inspection.id)
print(f"Inspection complete: {result.status}")
print(f"Damage detected: {result.damages}")
```

### Webhook Integration

```python theme={null}
from flask import Flask, request
import hmac
import hashlib

app = Flask(__name__)

@app.route('/webhooks/steerai', methods=['POST'])
def handle_webhook():
    # Verify webhook signature
    signature = request.headers.get('X-SteerAI-Signature')
    body = request.get_data()

    if verify_signature(body, signature):
        event = request.json

        if event['type'] == 'inspection.completed':
            # Handle completed inspection
            process_inspection_result(event['data'])

    return '', 200
```

## Error Handling

### Common Error Codes

| Code  | Description  | Resolution                               |
| ----- | ------------ | ---------------------------------------- |
| `400` | Bad Request  | Check request format and required fields |
| `401` | Unauthorized | Verify API key and permissions           |
| `403` | Forbidden    | Check plan limits and endpoint access    |
| `404` | Not Found    | Verify resource ID and endpoint URL      |
| `429` | Rate Limited | Implement exponential backoff            |
| `500` | Server Error | Retry request or contact support         |

### Error Response Format

```json theme={null}
{
  "status": "error",
  "error": {
    "code": "INVALID_VIN",
    "message": "The provided VIN is invalid",
    "type": "validation_error",
    "field": "vehicle.vin"
  },
  "meta": {
    "request_id": "req_1234567890"
  }
}
```

## Best Practices

<AccordionGroup>
  <Accordion icon="shield" title="Security">
    • Never expose API keys in client-side code
    • Use environment variables for API keys
    • Implement proper SSL certificate validation
    • Rotate API keys regularly (every 90 days)
    • Use IP whitelisting when possible
  </Accordion>

  <Accordion icon="zap" title="Performance">
    • Implement proper caching for repeated requests
    • Use batch endpoints for multiple operations
    • Handle rate limits with exponential backoff
    • Optimize image sizes before upload
    • Use compression for large payloads
  </Accordion>

  <Accordion icon="bug" title="Error Handling">
    • Always check response status codes
    • Implement retry logic for temporary failures
    • Log error details for debugging
    • Handle network timeouts gracefully
    • Provide meaningful error messages to users
  </Accordion>

  <Accordion icon="chart-line" title="Monitoring">
    • Track API usage and performance metrics
    • Monitor error rates and response times
    • Set up alerts for critical failures
    • Use request IDs for support tickets
    • Implement health checks for your integration
  </Accordion>
</AccordionGroup>

## Sample Applications

<CardGroup cols={2}>
  <Card title="Vehicle Inspection App" icon="mobile">
    Complete mobile app for field inspections

    [View on GitHub →](https://github.com/steerautos/mobile-inspector)
  </Card>

  <Card title="Dealership Integration" icon="building">
    Full dealership management system integration

    [View on GitHub →](https://github.com/steerautos/dealership-demo)
  </Card>
</CardGroup>

## Next Steps

<CardGroup cols={3}>
  <Card title="Authentication Setup" icon="key" href="/integration/api/authentication">
    Configure API keys and security
  </Card>

  <Card title="Rate Limits" icon="gauge" href="/integration/api/rate-limits">
    Understand usage limits and optimization
  </Card>

  <Card title="Error Handling" icon="triangle-exclamation" href="/integration/api/error-handling">
    Implement robust error handling
  </Card>
</CardGroup>

## Support

Need help with your API integration?

* **Documentation:** Complete API reference with examples
* **SDKs:** Official libraries for Python and JavaScript
* **Sample Code:** Real-world integration examples
* **Technical Support:** [support@steerai.autos](mailto:support@steerai.autos)
* **Community:** [Discord community](https://discord.gg/steerai)

<Tip>
  **Pro Tip:** Start with our sandbox environment to test your integration before going live. Most developers complete their first integration in under 4 hours.
</Tip>
