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

# Analyze a cannabis product label image



## OpenAPI

````yaml /api-reference/openapi.json post /api/v1/scanner/analyze-label
openapi: 3.1.0
info:
  title: High IQ API
  description: Cannabis intelligence API powering the High IQ mobile app and TIWIH website
  version: 1.0.0
servers:
  - url: https://api.thisiswhyimhigh.com
    description: Production
  - url: http://localhost:3001
    description: Local Development
security: []
tags:
  - name: Strains
    description: Strain database search, filtering, and retrieval
  - name: Scanner
    description: Cannabis label scanning with AI vision
  - name: Receipts
    description: Receipt parsing with AI
  - name: Notebooks
    description: AI-generated notebook streaming (SSE)
  - name: Discover
    description: High Families and curated highlight lists
  - name: Blog
    description: Blog article listing and retrieval
  - name: Research
    description: Research articles and menu extraction
  - name: Research Papers
    description: Cannabis research paper database
  - name: Deep Research
    description: AI-powered deep cannabis research
  - name: Meta
    description: System metadata and freshness signals
  - name: Chat
    description: Professor High AI cannabis assistant
  - name: Dispensaries
    description: Dispensary metadata such as crowdsourced email domains
  - name: Hero Images
    description: AI hero image generation and management for landing/content pages
  - name: Mascot
    description: Professor High mascot image generation and status (admin)
  - name: Shopping
    description: Dispensary shopping menus, scans, and strain matching
  - name: Social
    description: Social content drafts and stats for Professor High channels
  - name: App Landing
    description: High IQ app landing page content and configuration
paths:
  /api/v1/scanner/analyze-label:
    post:
      tags:
        - Scanner
      summary: Analyze a cannabis product label image
      operationId: postApiV1ScannerAnalyzeLabel
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                imageBase64:
                  description: Base64-encoded image data (JPEG, PNG, WebP, HEIC)
                  type: string
                  maxLength: 10000000
                imageUrl:
                  description: URL to the image (must be publicly accessible)
                  type: string
                  format: uri
                hints:
                  type: object
                  properties:
                    expectedStrainName:
                      description: Hint for expected strain name if known
                      type: string
                    dispensaryName:
                      description: Dispensary where product was purchased
                      type: string
                    productType:
                      description: Product type if known
                      type: string
                      enum:
                        - flower
                        - preroll
                        - concentrate
                        - vape
                        - edible
                        - tincture
                        - topical
                        - unknown
                attribution:
                  description: >-
                    Device/browser attribution for analytics (collected
                    client-side)
                  type: object
                  properties:
                    userAgent:
                      description: Browser user agent string
                      type: string
                    screenWidth:
                      description: Screen width in pixels
                      type: integer
                      exclusiveMinimum: 0
                      maximum: 9007199254740991
                    screenHeight:
                      description: Screen height in pixels
                      type: integer
                      exclusiveMinimum: 0
                      maximum: 9007199254740991
                    timezone:
                      description: Browser timezone (IANA format)
                      type: string
                    language:
                      description: Browser language preference
                      type: string
                    referrer:
                      description: HTTP referrer URL
                      type: string
                    utmSource:
                      description: UTM source parameter
                      type: string
                    utmMedium:
                      description: UTM medium parameter
                      type: string
                    utmCampaign:
                      description: UTM campaign parameter
                      type: string
                    sessionId:
                      description: Anonymous session ID
                      type: string
      responses:
        '200':
          description: Label analysis result with strain classification
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    const: true
                  data: {}
                  meta:
                    type: object
                    properties:
                      pagination:
                        type: object
                        properties:
                          limit:
                            type: integer
                            minimum: -9007199254740991
                            maximum: 9007199254740991
                          offset:
                            type: integer
                            minimum: -9007199254740991
                            maximum: 9007199254740991
                          total:
                            type: integer
                            minimum: -9007199254740991
                            maximum: 9007199254740991
                          hasMore:
                            type: boolean
                        required:
                          - limit
                          - offset
                          - total
                      timestamp:
                        type: string
                        format: date-time
                        pattern: >-
                          ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
                      requestId:
                        type: string
                    additionalProperties: {}
                required:
                  - success
                  - data
        '400':
          description: Bad request or validation error
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    const: false
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      details: {}
                      stack:
                        type: string
                    required:
                      - code
                      - message
                  meta:
                    type: object
                    properties:
                      timestamp:
                        type: string
                        format: date-time
                        pattern: >-
                          ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
                      requestId:
                        type: string
                      path:
                        type: string
                      method:
                        type: string
                required:
                  - success
                  - error
        '429':
          description: Rate limit exceeded
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    const: false
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      details: {}
                      stack:
                        type: string
                    required:
                      - code
                      - message
                  meta:
                    type: object
                    properties:
                      timestamp:
                        type: string
                        format: date-time
                        pattern: >-
                          ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
                      requestId:
                        type: string
                      path:
                        type: string
                      method:
                        type: string
                required:
                  - success
                  - error
        '503':
          description: Internal server error
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    const: false
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      details: {}
                      stack:
                        type: string
                    required:
                      - code
                      - message
                  meta:
                    type: object
                    properties:
                      timestamp:
                        type: string
                        format: date-time
                        pattern: >-
                          ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
                      requestId:
                        type: string
                      path:
                        type: string
                      method:
                        type: string
                required:
                  - success
                  - error
        '504':
          description: Internal server error
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    const: false
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                      message:
                        type: string
                      details: {}
                      stack:
                        type: string
                    required:
                      - code
                      - message
                  meta:
                    type: object
                    properties:
                      timestamp:
                        type: string
                        format: date-time
                        pattern: >-
                          ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
                      requestId:
                        type: string
                      path:
                        type: string
                      method:
                        type: string
                required:
                  - success
                  - error

````