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

# Verify Pot Sizes

> Unified endpoint for resolving plant specifications. Accepts input as: (1) JSON body with items array, (2) JSON body with file_url from TUS upload, or (3) multipart form-data with direct file upload. Supported file formats: JSON, XLSX, XLS, PDF, TXT, PNG, JPG, JPEG, GIF, WEBP. Authentication: Basic/Pro plans use X-API-Key header; Teams plans with platform integration require Authorization Bearer token.

Classify plant pot sizes and specifications using Growth Equivalent logic. Maps raw text labels to a stage of maturity (0-5) to determine if items are swappable.

## Input Options

This endpoint accepts input in three ways:

### 1. JSON Body with Items Array

```bash theme={"theme":"github-dark"}
curl -X POST https://api.superseeded.ai/v1/verify/pot-sizes \
  -H "X-API-Key: sk_..." \
  -H "Content-Type: application/json" \
  -d '{"items": ["400mm AS", "20L Planter Bag"]}'
```

### 2. JSON Body with File URL (TUS Upload)

For files uploaded via TUS protocol:

```bash theme={"theme":"github-dark"}
curl -X POST https://api.superseeded.ai/v1/verify/pot-sizes \
  -H "Authorization: Bearer <delegation_token>" \
  -H "Content-Type: application/json" \
  -d '{"file_url": "https://secure.superseeded.ai/files/abc123", "filename": "data.xlsx"}'
```

### 3. Direct File Upload (Multipart)

Upload files directly without TUS - reduces round trips for Basic/Pro plans:

```bash theme={"theme":"github-dark"}
curl -X POST https://api.superseeded.ai/v1/verify/pot-sizes \
  -H "X-API-Key: sk_..." \
  -F "file=@data.xlsx" \
  -F "extraction_type=pot_sizes"
```

## Request Body (JSON)

<ParamField body="items" type="string[]">
  An array of raw plant specification strings to be resolved. Takes precedence over file inputs.
</ParamField>

<ParamField body="file_url" type="file">
  URL to a previously uploaded file (from TUS storage). Must be from `secure.superseeded.ai` or `api.superseeded.ai`.

  **Tip:** You can use the file input dialog in this playground to test with a local file.
</ParamField>

<ParamField body="filename" type="string">
  Optional filename hint for format detection when using `file_url`.
</ParamField>

<ParamField body="extraction_type" type="string" default="pot_sizes">
  What to extract from files: `pot_sizes`, `species`, or `generic`.
</ParamField>

## Form Fields (Multipart)

<ParamField body="file" type="file">
  Direct file upload. Supported formats: JSON, XLSX, XLS, PDF, TXT, PNG, JPG, JPEG, GIF, WEBP.
</ParamField>

<ParamField body="extraction_type" type="string" default="pot_sizes">
  What to extract from the file.
</ParamField>

## Authentication

| Plan             | Auth Method      | Header                          |
| ---------------- | ---------------- | ------------------------------- |
| Basic/Pro        | API Key          | `X-API-Key: sk_...`             |
| Teams (platform) | Delegation Token | `Authorization: Bearer <token>` |

**Basic/Pro plans** can use direct API key authentication for all input methods including direct file upload.

**Teams plans with platform integration** require a delegation token obtained via `POST /v1/auth/delegate-upload`. This ensures each request is attributed to the correct merchant for billing.

## Supported File Formats

| Format | Extensions                               | Processing                    |
| ------ | ---------------------------------------- | ----------------------------- |
| JSON   | `.json`                                  | Direct parsing of items array |
| Excel  | `.xlsx`, `.xls`                          | Text extraction from cells    |
| PDF    | `.pdf`                                   | Text extraction               |
| Text   | `.txt`                                   | Direct text processing        |
| Images | `.png`, `.jpg`, `.jpeg`, `.gif`, `.webp` | AI vision extraction          |

<ResponseExample>
  ```json theme={"theme":"github-dark"}
  {
    "results": [
      {
        "input_label": "400mm AS",
        "match_confidence": "Medium",
        "standard_data": {
          "id": "3.2",
          "evergreen_connect_potsize_id": [606, 693, 707, 838, 753, 775, 509, 832, 556, 533, 755, 541, 560, 786, 780, 656],
          "type": "Pot - Square",
          "stage_order": 3,
          "stage_name": "Retail & Small Production",
          "is_biological": true,
          "matching_strategy": "Volume/Width",
          "logistics": {
            "tier": "Pallet",
            "is_stackable": false,
            "freight_efficiency": "Medium-High"
          },
          "quality_profile": {
            "transplant_shock_risk": "Low",
            "seasonal_restriction": "None",
            "inspection_focus": "Root Circling"
          },
          "customer_note": "More volume efficient than round pots; fits tighter on pallets."
        },
        "external_ids": null
      },
      {
        "input_label": "20L Planter Bag",
        "match_confidence": "High",
        "standard_data": {
          "id": "4.2",
          "evergreen_connect_potsize_id": [730],
          "type": "Planter Bag",
          "stage_order": 4,
          "stage_name": "Advanced Production",
          "is_biological": true,
          "matching_strategy": "Volume",
          "logistics": {
            "tier": "Pallet",
            "is_stackable": false,
            "freight_efficiency": "High"
          },
          "quality_profile": {
            "transplant_shock_risk": "Low",
            "seasonal_restriction": "None",
            "inspection_focus": "Weeds/Slugs"
          },
          "customer_note": "Cheaper equivalent to pots; bags can be squashed during transit."
        },
        "external_ids": null
      }
    ]
  }
  ```
</ResponseExample>


## OpenAPI

````yaml POST /verify/pot-sizes
openapi: 3.1.0
info:
  title: Superseeded API
  description: >-
    Modern nursery industry API for reconciling plant specifications, resolving
    equivalence and assessing logistical risks for plant stock.
  version: 1.0.0
  license:
    name: MIT
  contact:
    name: Superseeded Support
servers:
  - url: https://api.superseeded.ai/v1
    description: Production Server
security: []
tags:
  - name: Resolvers
    description: Endpoints for cleaning, normalizing, and interpreting messy nursery data.
  - name: Validation
    description: >-
      Endpoints for validating botanical species names against taxonomic
      databases.
  - name: Flowers
    description: >-
      Search flowers by color using spectral reflectance data from the Floral
      Reflectance Database (FReD).
  - name: System
    description: Health checks and service status.
  - name: Images
    description: Resolve public catalog image URLs for storefront and product integrations.
paths:
  /verify/pot-sizes:
    post:
      tags:
        - Resolvers
      summary: Resolve Specs
      description: >-
        Unified endpoint for resolving plant specifications. Accepts input as:
        (1) JSON body with items array, (2) JSON body with file_url from TUS
        upload, or (3) multipart form-data with direct file upload. Supported
        file formats: JSON, XLSX, XLS, PDF, TXT, PNG, JPG, JPEG, GIF, WEBP.
        Authentication: Basic/Pro plans use X-API-Key header; Teams plans with
        platform integration require Authorization Bearer token.
      operationId: resolveSpecs
      requestBody:
        description: >-
          Object containing a list of raw spec strings to be resolved, file
          reference, or direct file upload.
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                file:
                  type: string
                  format: binary
                  description: >-
                    File to upload. Supported formats: JSON, XLSX, XLS, PDF,
                    TXT, PNG, JPG, JPEG, GIF, WEBP.
                extraction_type:
                  type: string
                  default: pot_sizes
                  enum:
                    - pot_sizes
                    - species
                    - generic
                  description: What to extract from the file.
          application/json:
            schema:
              $ref: '#/components/schemas/ResolveSpecsRequest'
      responses:
        '200':
          description: Successful resolution with detailed hierarchy data.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ResolveSpecsResponse'
        '400':
          description: Bad Request - Invalid JSON format.
        '401':
          description: Unauthorized - Missing API Key.
        '403':
          description: Forbidden - Invalid API Key.
      security:
        - ApiKeyAuth: []
components:
  schemas:
    ResolveSpecsRequest:
      type: object
      description: >-
        Request body for /verify/pot-sizes. Accepts items array, file_url, or
        multipart file upload.
      properties:
        items:
          type: array
          description: >-
            An array of raw strings representing pot sizes or plant states.
            Takes precedence over file inputs.
          items:
            type: string
        file_url:
          type: string
          format: binary
          description: >-
            URL to a previously uploaded file (from TUS storage). Must be from
            secure.superseeded.ai or api.superseeded.ai.
        filename:
          type: string
          description: Optional filename hint for format detection when using file_url.
        extraction_type:
          type: string
          description: 'What to extract from files: pot_sizes, species, or generic.'
          default: pot_sizes
      example:
        items:
          - 140mm
          - 400mm AS
          - 20L Bag
          - Ex-Ground
    ResolveSpecsResponse:
      type: object
      properties:
        results:
          type: array
          items:
            $ref: '#/components/schemas/ResolvedItem'
    ResolvedItem:
      type: object
      properties:
        input_label:
          type: string
          description: The original raw string provided in the request.
          example: 400mm AS
        match_confidence:
          type: string
          enum:
            - Exact
            - High
            - Medium
            - Low
            - None
          description: The confidence level of the semantic match.
          example: High
        external_ids:
          type: object
          nullable: true
          description: A map of foreign key IDs from external systems.
          properties:
            evergreenconnect_potsize_id:
              type: integer
              description: The precise Evergreen Connect ID if an exact match is found.
              example: 823
        standard_data:
          $ref: '#/components/schemas/ContainerProfile'
    ContainerProfile:
      type: object
      description: >-
        The standardized biological and logistical profile for this container
        type.
      properties:
        type:
          type: string
          description: The standardized unique key for this container type.
          example: Pot - Air Pruning
        stage_order:
          type: integer
          description: >-
            Numeric sort order for biological maturity (0=Seed, 5=Mature,
            99=Non-Plant).
          example: 4
        stage_name:
          type: string
          description: Human-readable category of the production stage.
          example: Advanced Production
        is_biological:
          type: boolean
          description: Indicates if the item is a living plant vs hard goods.
          example: true
        matching_strategy:
          type: string
          description: >-
            Hint for how to compare stock of this type (e.g., Volume vs
            Diameter).
          example: Volume
        logistics:
          type: object
          properties:
            tier:
              type: string
              enum:
                - Parcel
                - Pallet
                - Specialized
                - N/A
              example: Pallet
            is_stackable:
              type: boolean
              description: If true, items can be stacked vertically, reducing freight cost.
              example: false
            freight_efficiency:
              type: string
              example: Medium
        quality_profile:
          type: object
          properties:
            transplant_shock_risk:
              type: string
              example: Very Low
            seasonal_restriction:
              type: string
              example: None
            inspection_focus:
              type: string
              description: The primary attribute to check during quality inspection.
              example: Desiccation
        customer_note:
          type: string
          description: User-friendly note explaining the pros/cons of this type.
          example: >-
            Superior root structure; requires more frequent watering until
            planted.
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-API-Key
      description: Standard API Key authentication.

````