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

# Bulk import orders via CSV

> Upload a CSV file to validate and preview order creation. Returns a row-by-row result — valid rows and any errors. Use `/api/vendor/v1/orders/csv-template` to download the correct format first.

**Note:** This endpoint validates and returns results; it does not create orders automatically. Use the JSON `/api/vendor/v1/orders/bulk` endpoint to actually create orders, or use the vendor dashboard UI for a guided import flow.



## OpenAPI

````yaml /openapi.json post /api/vendor/v1/orders/import-csv
openapi: 3.1.0
info:
  title: UrbnBox integration API
  version: 1.0.0
  description: >-
    Create and track delivery orders, send parcels between pickup points, and
    connect Shopify.
servers:
  - url: https://portal.urbnbox.io
    description: UrbnBox production and test-key server
security: []
tags:
  - name: Shipments
    description: Quote, create, and retrieve pickup-point shipments.
  - name: Checkout sessions
    description: Hold lockers for partner checkout sessions.
  - name: Public bookings
    description: Create browser-based locker bookings.
  - name: Store discovery
    description: Find active UrbnBox stores.
  - name: Shopify
    description: Callbacks called by Shopify.
  - name: Vendor API
    description: >-
      Vendor-authenticated endpoints for delivery orders, pickup-point shipments
      and webhooks. All require an X-API-Key header with a vendor key.
paths:
  /api/vendor/v1/orders/import-csv:
    post:
      tags:
        - Vendor API
      summary: Bulk import orders via CSV
      description: >-
        Upload a CSV file to validate and preview order creation. Returns a
        row-by-row result — valid rows and any errors. Use
        `/api/vendor/v1/orders/csv-template` to download the correct format
        first.


        **Note:** This endpoint validates and returns results; it does not
        create orders automatically. Use the JSON `/api/vendor/v1/orders/bulk`
        endpoint to actually create orders, or use the vendor dashboard UI for a
        guided import flow.
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              required:
                - file
              properties:
                file:
                  type: string
                  format: binary
                  description: CSV file. First row must be the header row.
      responses:
        '200':
          description: Validation result with per-row status
          content:
            application/json:
              schema:
                type: object
                properties:
                  valid_count:
                    type: integer
                    description: Number of rows that passed validation
                  error_count:
                    type: integer
                    description: Number of rows with errors
                  total_count:
                    type: integer
                  rows:
                    type: array
                    items:
                      type: object
                      properties:
                        row_num:
                          type: integer
                        external_reference:
                          type: string
                        client_name:
                          type: string
                        client_phone:
                          type: string
                        description:
                          type: string
                        quantity:
                          type: integer
                        unit_price_kes:
                          type: integer
                        pickup_type:
                          type: string
                        error:
                          type: string
                          description: Only present if this row failed validation
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
      security:
        - ApiKeyAuth: []
components:
  responses:
    BadRequest:
      description: The request body, date, field, or query parameter is invalid.
      content:
        text/plain:
          schema:
            type: string
    Unauthorized:
      description: The credential is missing, invalid, or inactive.
      content:
        text/plain:
          schema:
            type: string
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-API-Key
      description: >-
        Vendor API key. Keys begin with the ubx_ prefix and identify vendor
        accounts.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.