POST /scan/image

Create a scan job for image-based food analysis.

Request body

  • Name
    clientId
    Type
    string
    Description

    Identifies the tenant or customer.

  • Name
    contentType
    Type
    string
    Description

    MIME type of the image.

Example request

curl -X POST "https://api.macrofy.com/scan/image" \
  -H "x-api-key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"clientId": "my-app", "contentType": "image/jpeg"}'

Example response

{
  "jobId": "scan_abc123",
  "uploadUrl": "https://storage.googleapis.com/..."
}

Next steps

  1. Upload image bytes to uploadUrl via PUT request
  2. Poll GET /scan/image/:jobId until status is complete

Was this page helpful?