Nara Lens/Docs

POST /analyze

Analyze an image using a programmable perception.

POST/v1/analyze

Analyze an image using a programmable perception query.

Headers

AuthorizationstringRequired

Bearer token with your API key

Content-TypestringRequired

application/json

Request Body

imagestringRequired

Image URL or base64-encoded image data

perceptionstringRequired

Perception query (e.g., 'detect:person,vehicle')

optionsobject

Additional configuration options

Example Request

Bash
curl -X POST https://api.naralens.com/v1/analyze \
  -H "Authorization: Bearer $NARA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "image": "https://example.com/image.jpg",
    "perception": "detect:person,vehicle"
  }'

Response

200Successful analysis
{
  "id": "req_abc123xyz",
  "objects": [
    {
      "label": "person",
      "confidence": 0.98,
      "bbox": [100, 150, 200, 400],
      "attributes": {}
    }
  ],
  "processing_time_ms": 127,
  "model_version": "v2.1"
}