{
  "openapi": "3.1.0",
  "info": {
    "title": "Vehicle Load and Bin Packing API",
    "description": "Packs parcels into a vehicle within weight and volume limits and reports utilisation. Pre-launch design; endpoints are not live yet.",
    "version": "0.1.0",
    "x-planned-pricing": {
      "model": "free tier for evaluation, paid tiers by volume",
      "status": "planned; nothing charged before launch"
    }
  },
  "servers": [
    {
      "url": "https://openapiregistry.com/api/v1/load-builder",
      "description": "Pre-launch: endpoints are not live yet and answer 503."
    }
  ],
  "security": [
    {
      "ApiKeyAuth": []
    }
  ],
  "paths": {
    "/loads/build": {
      "post": {
        "summary": "Pack parcels into a vehicle",
        "description": "Returns whether a set of parcels fits a vehicle and the utilisation achieved.",
        "tags": [
          "logistics"
        ],
        "operationId": "load-builder-post-loads-build",
        "parameters": [],
        "responses": {
          "200": {
            "description": "Load built.",
            "content": {
              "application/json": {
                "example": {
                  "packed": true,
                  "usedKg": 380,
                  "usedM3": 2.1,
                  "unplaced": []
                },
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "422": {
            "description": "Cannot fit all parcels."
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "parcels",
                  "vehicle"
                ],
                "properties": {
                  "parcels": {
                    "type": "array"
                  },
                  "vehicle": {
                    "type": "string"
                  }
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "ApiKeyAuth": {
        "type": "apiKey",
        "in": "header",
        "name": "X-API-Key",
        "description": "Planned for launch: an API key issued on request. Free tier for evaluation, paid tiers by volume; nothing is charged before launch."
      }
    }
  }
}
