{
  "openapi": "3.1.0",
  "info": {
    "title": "X3D Studios Print API",
    "version": "1.0.0",
    "summary": "Quote, order and track real 3D prints from code.",
    "description": "X3D Studios is a 3D printing service and AI 3D model generator in Austin, Texas. This API prices a part, places a print order that is billed to the card on file and shipped to the address you send, and reports its status. There are no outbound webhooks: poll GET /api/print/orders/{code}. AI agents can use the same service as MCP tools at https://x3dstudios.com/api/mcp (https://x3dstudios.com/docs/api/mcp). Generated from the documentation at https://x3dstudios.com/docs/api, which is the reference.",
    "contact": {
      "name": "X3D Studios",
      "email": "contact@x3dstudios.com",
      "url": "https://x3dstudios.com/docs/integrations/support"
    },
    "termsOfService": "https://x3dstudios.com/pricing"
  },
  "externalDocs": {
    "description": "API documentation",
    "url": "https://x3dstudios.com/docs/api"
  },
  "servers": [
    {
      "url": "https://x3dstudios.com"
    }
  ],
  "tags": [
    {
      "name": "Printing",
      "description": "Place and follow a print order."
    },
    {
      "name": "Pricing",
      "description": "Estimate a price without an account."
    },
    {
      "name": "Models",
      "description": "Check a model before you order it."
    },
    {
      "name": "Farm",
      "description": "Live capacity and lead time."
    }
  ],
  "paths": {
    "/api/print/orders": {
      "post": {
        "operationId": "createPrintOrder",
        "tags": [
          "Printing"
        ],
        "summary": "Create a print order from an uploaded model, and charge the saved card.",
        "description": "POST a model, an address and print settings to /api/print/orders with your API key: X3D slices it, charges your card on file, and prints it. Documented at https://x3dstudios.com/docs/api/submit-order.",
        "externalDocs": {
          "url": "https://x3dstudios.com/docs/api/submit-order"
        },
        "security": [
          {
            "apiKey": []
          }
        ],
        "responses": {
          "201": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "code": {
                      "type": "string",
                      "description": "The public order code: X3D- followed by six uppercase characters from an alphabet with no 0, 1, I, L or O. This is the only handle you get, store it."
                    },
                    "estimatedCost": {
                      "type": "number",
                      "description": "Print plus postage, plus the second-AMS fee when it applies, in USD, rounded to the cent. This is the amount charged."
                    },
                    "currency": {
                      "type": "string",
                      "description": "Always \"USD\"."
                    },
                    "breakdown": {
                      "type": "object",
                      "properties": {
                        "print": {
                          "type": "number",
                          "description": "The print subtotal before postage: weight x rate x quality factor x quantity, with the bulk discount and the $1.00-per-part minimum applied, then rounded up to the whole dollar."
                        },
                        "shipping": {
                          "type": "number",
                          "description": "Postage, by the order's weight (breakdown.grams times quantity) inside the US: 7, 10 or 25 on standard, or 0 once breakdown.print reaches $150 at 2 kg or less; 15, 25 or 50 on express; 50, 80 or 100 on overnight. 30 or 0 internationally, at any weight."
                        },
                        "shippingSpeed": {
                          "type": "string",
                          "description": "Which service that postage bought, \"standard\", \"express\" or \"overnight\". Echoed back because the amount alone cannot say: $25 is express up to 2 kg, but it is also standard over 2 kg."
                        },
                        "grams": {
                          "type": "number",
                          "description": "Billable weight of one part, rounded up to the whole gram. Postage is priced on this times quantity."
                        },
                        "printHours": {
                          "type": "number",
                          "description": "Estimated machine hours. Informational, the only thing that adds cost on top of the per-gram rate is an already-sliced file whose measured time far exceeds what its weight implies."
                        },
                        "weighedBy": {
                          "type": "string",
                          "description": "Where breakdown.grams came from. \"slicer\": our slice of your STL or GLB, cut on the farm's printer with supports on and moved to the infill you sent. \"estimate\": the model could not be sliced while the request waited (about a minute) or the slicer refused it, so it was priced from its volume, 30% walls plus the infill, without supports; weighing then says what happens next. \"file\": an already-sliced .gcode or .gcode.3mf, priced from its own figures. Added 30 November 2026."
                        },
                        "secondAmsFee": {
                          "type": "number",
                          "description": "Present only when it is charged: 25, for a sliced .gcode.3mf whose plate uses five or more filaments. Once per order, whatever the quantity, and included in estimatedCost."
                        },
                        "colours": {
                          "type": "number",
                          "description": "Present only with secondAmsFee: how many filaments the plate uses."
                        },
                        "newColourFee": {
                          "type": "number",
                          "description": "Present only when it is charged: 20, for a color we do not stock (one of the twelve, or TPU's own four, is stock; multi-color prints from stock shades and pays nothing; custom-color pays it unless the file's colour is exactly one of ours; an order placed before 27 November with Default or no color was our choice of a stock spool). The spool we buy for your order, once, and included in estimatedCost."
                        }
                      }
                    },
                    "weighing": {
                      "type": "object",
                      "description": "Present only when weighedBy is estimate (since 1 December 2026): { status: \"pending\", until, message }. We keep weighing the model with its supports until the time in until, 30 minutes after the order. Once it is weighed, the difference is charged to your card on file or refunded (an unpaid order's payment link asks the new total instead), and every address on the order is emailed the new total. A difference under $0.50 is not charged. If it cannot be weighed by then, the estimate stands. GET /api/print/orders/{code} reports how it went."
                    },
                    "statusUrl": {
                      "type": "string",
                      "description": "Human-readable order page. It needs no login, so it is safe to hand to your own customer."
                    },
                    "apiStatusUrl": {
                      "type": "string",
                      "description": "The URL to poll with your key. See /docs/api/order-status."
                    },
                    "email": {
                      "type": "string",
                      "description": "The order's main contact: the first address you sent, or your account email when you sent none."
                    },
                    "notifyEmails": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "The other addresses that get every order email, in the order you sent them. An empty array when there is only the main contact."
                    },
                    "status": {
                      "type": "string",
                      "enum": [
                        "RECEIVED",
                        "PENDING_PAYMENT"
                      ],
                      "description": "RECEIVED when the card was charged, PENDING_PAYMENT when it was not or the charge could not be confirmed."
                    },
                    "paid": {
                      "type": "boolean",
                      "description": "Whether money has actually been taken."
                    },
                    "charged": {
                      "type": "number",
                      "description": "Present only on the paid branch: the amount taken from the card."
                    },
                    "paymentUrl": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "X3D payment page for an unpaid order. null when the order is already paid, and null if Stripe returned no link."
                    },
                    "checkoutUrl": {
                      "type": [
                        "string",
                        "null"
                      ],
                      "description": "Raw Stripe Checkout URL. Present only on the unpaid branch; absent entirely when the card was charged."
                    },
                    "chargeOutcome": {
                      "type": "string",
                      "enum": [
                        "not-charged",
                        "unknown"
                      ],
                      "description": "Present only on the unpaid branch. not-charged means the card was provably not charged: a decline, or no card on file. unknown means the charge may have gone through and only its confirmation was lost; read the order back before anyone pays again."
                    },
                    "message": {
                      "type": "string",
                      "description": "One sentence you can log or show. On the unpaid branch it quotes the decline reason verbatim, and when chargeOutcome is unknown it says the charge may have gone through."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/Error"
          },
          "401": {
            "$ref": "#/components/responses/Error"
          },
          "429": {
            "$ref": "#/components/responses/Error"
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "multipart/form-data": {
              "schema": {
                "type": "object",
                "properties": {
                  "file": {
                    "type": "string",
                    "format": "binary",
                    "description": "The model, as a multipart file part. Required unless you send modelUrl. Accepted extensions: .stl, .glb, .gcode, .3mf (a .gcode.3mf is treated as 3mf). Anything else is a 415. Maximum 100 MB; an empty part is a 400."
                  },
                  "modelUrl": {
                    "type": "string",
                    "description": "Alternative to file: the gs:// URI of a model X3D already holds for your account. It must be a managed X3D storage URI and it must belong to the calling account, a URI you do not own returns 403."
                  },
                  "material": {
                    "type": "string",
                    "enum": [
                      "pla",
                      "petg",
                      "abs",
                      "asa",
                      "tpu",
                      "tpu-85a",
                      "tpu-75a"
                    ],
                    "default": "pla",
                    "description": "Case-insensitive. Sets the per-gram rate and the density used to turn volume into weight: PLA $0.12/g, PETG $0.12/g, ABS $0.15/g, ASA $0.15/g, TPU 95A (tpu) $0.25/g, TPU 85A (tpu-85a) $0.35/g, TPU 75A (tpu-75a) $0.50/g. The two softer TPUs are bought in for the order. Anything else is a 400."
                  },
                  "quality": {
                    "type": "string",
                    "enum": [
                      "standard",
                      "premium"
                    ],
                    "default": "standard",
                    "description": "Sets the price factor only: standard is 1x the per-gram rate, premium is 1.8x (5x with nozzleDiameter 0.2). It does not change the layer height on this endpoint. That comes from layerHeight, which stays at its own default of 0.2 mm whichever quality you send. Anything else is a 400."
                  },
                  "quantity": {
                    "type": "integer",
                    "default": 1,
                    "description": "Clamped to 1 to 50, never rejected: a 0 or a non-number becomes 1, and 200 becomes 50. Five or more units take 5% off, ten or more take 10%."
                  },
                  "color": {
                    "type": "string",
                    "examples": [
                      "Black",
                      "White",
                      "Red",
                      "Cyan",
                      "Sakura Pink",
                      "Sunny Orange",
                      "Green",
                      "Yellow",
                      "Mint Green",
                      "Lavender",
                      "Silver",
                      "Brown"
                    ],
                    "description": "Required since 27 November 2026; an order without one is a 400. Send one of four things. A colour by name, matched case-insensitively: the twelve we stock (Black, White, Red, Cyan, Sakura Pink, Sunny Orange, Green, Yellow, Mint Green, Lavender, Silver, Brown; TPU in White, Black, Red or Blue). A colour code such as #00AE42. multi-color, for a sliced .gcode.3mf whose plate prints in two or more colours: it prints in the colours its slots set, from our nearest stock shades, and the order stores them (\"Multi-colour: #00AE42, #F5F5F5\"). custom-color, for a sliced .gcode.3mf in one colour: it prints in exactly the colour the file sets, and the order stores that code. Every colour prints at the material's own rate. One we do not stock (a name we do not carry, a code that is not one of ours, or the exact colour of custom-color) adds the $20 new colour fee once, for the spool we buy. multi-color and custom-color are refused for an STL or GLB, which sets no colour, and a colour name or code is refused for a sliced plate that prints in several colours."
                  },
                  "infill": {
                    "type": "integer",
                    "default": 20,
                    "description": "Percent. Clamped to 10 to 100, never rejected. Ignored for an already-sliced file, which is recorded as 100 because the slice already decided."
                  },
                  "nozzleDiameter": {
                    "type": "number",
                    "enum": [
                      0.2,
                      0.4,
                      0.6,
                      0.8
                    ],
                    "default": 0.4,
                    "description": "Millimetres. Any other value falls back to 0.4 silently, with no error, so check what came back on the order if it matters. 0.2 on a model you send unsliced prices at 4.5x the per-gram rate, 5x with quality premium; 0.4, 0.6 and 0.8 are 1x, and a sliced file prints on the nozzle it was sliced for at 1x."
                  },
                  "nozzleFlow": {
                    "type": "string",
                    "enum": [
                      "standard",
                      "high"
                    ],
                    "default": "standard",
                    "description": "high raises the modelled throughput by 1.6x, which shortens the estimated print time. Any value other than \"high\" is read as standard, silently."
                  },
                  "layerHeight": {
                    "type": "number",
                    "default": 0.2,
                    "description": "Millimetres. Clamped, never rejected, to 20 to 75% of the nozzle diameter: 0.08 to 0.30 mm on a 0.4 mm nozzle. Out-of-range values are pulled to the nearest end."
                  },
                  "note": {
                    "type": "string",
                    "description": "Free text for the operator: orientation, support preferences, anything a human should read before printing. Truncated to 1000 characters without warning."
                  },
                  "recipientName": {
                    "type": "string",
                    "description": "Name on the parcel. The alias name is accepted for the same field."
                  },
                  "street1": {
                    "type": "string",
                    "description": "Street address. The alias address1 is accepted."
                  },
                  "street2": {
                    "type": "string",
                    "description": "Apartment, suite, unit. The alias address2 is accepted. Stored as null when empty."
                  },
                  "city": {
                    "type": "string",
                    "description": "City."
                  },
                  "state": {
                    "type": "string",
                    "description": "State or province. Not validated against a list."
                  },
                  "zip": {
                    "type": "string",
                    "description": "Postal code. The alias postalCode is accepted. Not format-checked."
                  },
                  "country": {
                    "type": "string",
                    "enum": [
                      "US",
                      "AE",
                      "AT",
                      "AU",
                      "BE",
                      "CA",
                      "CH",
                      "DE",
                      "DK",
                      "ES",
                      "FI",
                      "FR",
                      "GB",
                      "IE",
                      "IN",
                      "IT",
                      "JP",
                      "MX",
                      "NL",
                      "NO",
                      "NZ",
                      "PT",
                      "SE",
                      "SG"
                    ],
                    "default": "US",
                    "description": "Uppercased before the check. Anywhere else returns 400. US postage goes by the order's weight, grams per part times quantity: standard is $7 up to 500 g, $10 up to 2 kg and $25 over 2 kg, free at a $150 subtotal up to 2 kg; everywhere else is $30 flat at any weight, free at $500 and standard service only."
                  },
                  "shippingSpeed": {
                    "type": "string",
                    "enum": [
                      "standard",
                      "express",
                      "overnight"
                    ],
                    "default": "standard",
                    "description": "By the order's weight, up to 500 g, up to 2 kg and over 2 kg: standard is $7, $10 or $25 and 4 to 5 business days in transit; express is $15, $25 or $50 and 2 to 3; overnight is $50, $80 or $100 and 1 to 2. Express and overnight are US only, and asking for either on a country other than US returns 400 rather than quietly shipping standard. This is the one order path that knows the destination before it prices. Any value other than standard, express or overnight is a 400 too. The service is echoed back in breakdown.shippingSpeed. It changes the postage only: the print itself is queued as Normal print, because Priority print is not sold through the API."
                  },
                  "email": {
                    "type": "string",
                    "default": "your account email",
                    "description": "One to five addresses that get the order emails: the confirmation, printed, shipped with tracking, and delivered. Repeat the field for each address, or separate them with commas or semicolons in one field. The first address is the main contact; every address gets every email. Lowercased, and repeats are dropped. Send the end customer's address if you are printing on their behalf."
                  },
                  "phone": {
                    "type": "string",
                    "description": "Optional, stored as-is for the carrier. Not validated."
                  }
                },
                "required": [
                  "file",
                  "color",
                  "recipientName",
                  "street1",
                  "city",
                  "state",
                  "zip"
                ]
              }
            }
          }
        }
      }
    },
    "/api/print/orders/{code}": {
      "get": {
        "operationId": "getPrintOrder",
        "tags": [
          "Printing"
        ],
        "summary": "Read one print order belonging to the calling account.",
        "description": "Read one print order back by its X3D- code: where it is in the queue, whether it is paid, and the carrier tracking number once the parcel is handed over. Documented at https://x3dstudios.com/docs/api/order-status.",
        "externalDocs": {
          "url": "https://x3dstudios.com/docs/api/order-status"
        },
        "security": [
          {
            "apiKey": []
          }
        ],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "code": {
                      "type": "string",
                      "description": "The order code, echoed back."
                    },
                    "status": {
                      "type": "string",
                      "description": "Machine-readable stage. Branch on this, not on statusLabel."
                    },
                    "statusLabel": {
                      "type": "string",
                      "description": "The same stage in words, safe to show a customer. Falls back to the raw status if we ever add a stage before this table catches up."
                    },
                    "paid": {
                      "type": "boolean",
                      "description": "Whether money has been taken. false means the order is waiting at PENDING_PAYMENT."
                    },
                    "fileName": {
                      "type": "string",
                      "description": "The file name as submitted."
                    },
                    "material": {
                      "type": "string",
                      "description": "Material key as ordered: pla, petg, abs, asa, tpu, tpu-85a or tpu-75a."
                    },
                    "color": {
                      "type": "string",
                      "description": "Colour as it prints: the name, the colour code, or \"Multi-colour: #00AE42, #F5F5F5\" with the sliced file's own colours. \"Default\" only on an order placed before 27 November 2026 without a colour."
                    },
                    "quality": {
                      "type": "string",
                      "description": "standard or premium."
                    },
                    "quantity": {
                      "type": "number",
                      "description": "Units ordered."
                    },
                    "estimatedCost": {
                      "type": "number",
                      "description": "Total in USD: print plus postage, plus the $25 second-AMS fee on a sliced plate of five or more filaments. This is the amount charged."
                    },
                    "currency": {
                      "type": "string",
                      "description": "Always \"USD\"."
                    },
                    "tracking": {
                      "type": [
                        "object",
                        "null"
                      ],
                      "description": "null until the parcel is handed over. Then { number, carrier }, where carrier can itself be null if it was not recorded."
                    },
                    "shipTo": {
                      "type": "object",
                      "description": "name, city, state, country only. The street and postal code are deliberately not returned."
                    },
                    "email": {
                      "type": "string",
                      "description": "The order's main contact, the first address sent with the order. It gets every order email."
                    },
                    "notifyEmails": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      },
                      "description": "The other addresses that get a copy of every order email: the confirmation, printed, shipped with tracking, and delivered. An empty array when there are none. Set them when you submit; see /docs/api/submit-order."
                    },
                    "createdAt": {
                      "type": "string",
                      "description": "ISO 8601 timestamp of submission."
                    },
                    "updatedAt": {
                      "type": "string",
                      "description": "ISO 8601 timestamp of the last change. Use it to detect movement between polls."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/Error"
          },
          "401": {
            "$ref": "#/components/responses/Error"
          },
          "404": {
            "$ref": "#/components/responses/Error"
          },
          "429": {
            "$ref": "#/components/responses/Error"
          }
        },
        "parameters": [
          {
            "name": "code",
            "in": "path",
            "required": true,
            "description": "The public order code from the submit response: X3D- followed by six uppercase characters. Matched exactly and case-sensitively, a lowercased code returns 404. The alphabet excludes 0, 1, I, L and O, so those characters never appear in a real code.",
            "schema": {
              "type": "string"
            }
          }
        ]
      }
    },
    "/api/price": {
      "post": {
        "operationId": "quotePrice",
        "tags": [
          "Pricing"
        ],
        "summary": "Price a part from its bounding box, material, quality and quantity.",
        "description": "Price a part before you order it: /api/price returns a full breakdown from a bounding box, and /api/slice-quote measures a stored model with a real slice, at 100% or at any size from 50% to 300%. Documented at https://x3dstudios.com/docs/api/quote.",
        "externalDocs": {
          "url": "https://x3dstudios.com/docs/api/quote"
        },
        "security": [],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "grams": {
                      "type": "number",
                      "description": "Billable weight, rounded up to the whole gram."
                    },
                    "printHours": {
                      "type": "number",
                      "description": "Estimated machine time. Informational unless machineCost is non-zero."
                    },
                    "materialCost": {
                      "type": "number",
                      "description": "grams x pricePerGram x the quality factor. On a single-colour part this is the whole price."
                    },
                    "machineCost": {
                      "type": "number",
                      "description": "Tool-change surcharge, at $1.50/hr. Always 0 from this endpoint: it has no colour input and prices one colour. A print in colour is priced on /print from a real slice of it in its colours, whose grams and hours already contain every change."
                    },
                    "perUnit": {
                      "type": "number",
                      "description": "Price of one unit, never below the $1.00 minimum. It is not rounded."
                    },
                    "subtotal": {
                      "type": "number",
                      "description": "perUnit x quantity with the bulk discount applied, floored at $1.00 per unit, then rounded up to the whole dollar. This is the print line as charged."
                    },
                    "roundUp": {
                      "type": "number",
                      "description": "What rounding the line up to the whole dollar added, already inside subtotal. 0 when the line was already whole."
                    },
                    "shipping": {
                      "type": "number",
                      "description": "US postage for the requested speed at shippingGrams: standard is $7 up to 500 g, $10 up to 2 kg and $25 over 2 kg, or 0 once subtotal reaches $150 at 2 kg or less; express is $15, $25 or $50 and overnight $50, $80 or $100, never free. It prices a US address and knows nothing about other countries."
                    },
                    "shippingGrams": {
                      "type": "number",
                      "description": "The weight postage was priced on: grams per part times quantity. Up to 500 g includes 500 g exactly."
                    },
                    "shippingSpeed": {
                      "type": "string",
                      "description": "Which service that rate buys, \"standard\", \"express\" or \"overnight\". Echoes back what you asked for, so a value this endpoint did not recognise is visible as \"standard\" rather than silently priced as one."
                    },
                    "baseFee": {
                      "type": "number",
                      "description": "Always 0. There is no order fee."
                    },
                    "total": {
                      "type": "number",
                      "description": "subtotal + shipping + baseFee + newColourFee. See the warning below before you show this to a customer."
                    },
                    "newColourFee": {
                      "type": "number",
                      "description": "20 when the colour is not one we stock, or the material is custom: the spool we buy for the order, once. 0 otherwise. Already inside total."
                    },
                    "pricePerGram": {
                      "type": "number",
                      "description": "The rate actually used: the material's own, in any colour."
                    },
                    "customColor": {
                      "type": "boolean",
                      "description": "true when the colour is not one we stock, which is why newColourFee is 20."
                    },
                    "filamentChanges": {
                      "type": "number",
                      "description": "Modelled filament changes. Always 0: colour prices come from a real slice, never from modelled changes, and the model that would fill this is switched off."
                    },
                    "multiColorGrams": {
                      "type": "number",
                      "description": "Purge waste attributed to those changes, in grams. Always 0, for the same reason."
                    },
                    "multiColorHours": {
                      "type": "number",
                      "description": "Tool-change time attributed to those changes, in hours. Always 0, for the same reason."
                    },
                    "color": {
                      "type": "string",
                      "description": "The colour that was priced. Omitted from the response when you sent none."
                    }
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/Error"
          },
          "429": {
            "$ref": "#/components/responses/Error"
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "bboxMm": {
                    "type": "object",
                    "properties": {
                      "x": {
                        "type": "number",
                        "description": "Width in millimetres. Must be a finite number greater than zero, a numeric string is rejected."
                      },
                      "y": {
                        "type": "number",
                        "description": "Depth in millimetres, same rules."
                      },
                      "z": {
                        "type": "number",
                        "description": "Height in millimetres, same rules."
                      }
                    },
                    "required": [
                      "x",
                      "y",
                      "z"
                    ]
                  },
                  "material": {
                    "type": "string",
                    "enum": [
                      "pla",
                      "petg",
                      "abs",
                      "asa",
                      "tpu",
                      "tpu-85a",
                      "tpu-75a"
                    ],
                    "default": "pla",
                    "description": "Sets the per-gram rate and the density used to turn volume into weight. tpu is TPU 95A; tpu-85a and tpu-75a are the softer TPUs. Anything else is a 400."
                  },
                  "quality": {
                    "type": "string",
                    "enum": [
                      "standard",
                      "premium"
                    ],
                    "default": "standard",
                    "description": "standard is 0.2 mm layers at 1x the rate; premium is 0.1 mm layers at 1.8x."
                  },
                  "nozzle": {
                    "type": "string",
                    "enum": [
                      "standard",
                      "premium"
                    ],
                    "default": "standard",
                    "description": "standard is the 0.4 mm nozzle; premium is the 0.2 mm nozzle at 4.5x the rate, 5x with premium layers. Anything else is a 400."
                  },
                  "quantity": {
                    "type": "number",
                    "default": 1,
                    "description": "Rounded, and floored at 1. Five or more units take 5% off, ten or more take 10%."
                  },
                  "color": {
                    "type": "string",
                    "description": "A stock spool name or hex. Trimmed to 64 characters and dropped entirely if it contains anything outside letters, digits, spaces and # ( ) , . _ -. Off-palette colours price at the material's own rate, and the response adds newColourFee ($20, the spool we buy) to total."
                  },
                  "shippingSpeed": {
                    "type": "string",
                    "enum": [
                      "standard",
                      "express",
                      "overnight"
                    ],
                    "default": "standard",
                    "description": "Postage goes by the quote's weight, grams per part times quantity: standard is $7 up to 500 g, $10 up to 2 kg and $25 over 2 kg, and 4 to 5 business days in transit; express is $15, $25 or $50 and 2 to 3; overnight is $50, $80 or $100 and 1 to 2. Express and overnight are US only services. Anything unrecognised is quoted as standard rather than refused, a quote is read-only, and the value comes back in shippingSpeed so you can see which was used."
                  }
                },
                "required": [
                  "bboxMm"
                ]
              }
            }
          }
        }
      }
    },
    "/api/printability": {
      "post": {
        "operationId": "analysePrintability",
        "tags": [
          "Models"
        ],
        "summary": "Analyse an uploaded STL, GLB or OBJ. multipart/form-data, one field.",
        "description": "POST a mesh to /api/printability and get back geometry: watertightness, holes, non-manifold edges, size, and a ready, warning or error verdict. Free, no key. Documented at https://x3dstudios.com/docs/api/printability.",
        "externalDocs": {
          "url": "https://x3dstudios.com/docs/api/printability"
        },
        "security": [],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/Error"
          },
          "429": {
            "$ref": "#/components/responses/Error"
          }
        },
        "requestBody": {
          "required": true,
          "content": {
            "multipart/form-data": {
              "schema": {
                "type": "object",
                "properties": {
                  "model": {
                    "type": "string",
                    "format": "binary",
                    "description": "The mesh. STL (binary or ASCII), GLB, GLTF, or OBJ. Format is detected from the glTF magic bytes first, then the file extension, then by sniffing the contents, so an extensionless upload still works. There are no other fields."
                  }
                },
                "required": [
                  "model"
                ]
              }
            }
          }
        }
      }
    },
    "/api/farm/capacity": {
      "get": {
        "operationId": "getFarmCapacity",
        "tags": [
          "Farm"
        ],
        "summary": "Live fleet counts, measured throughput and queue depth. No parameters.",
        "description": "How long a part actually takes: queue time, print time by part size, dispatch and transit, plus the public capacity endpoint that publishes live fleet numbers. Documented at https://x3dstudios.com/docs/farm/capacity.",
        "externalDocs": {
          "url": "https://x3dstudios.com/docs/farm/capacity"
        },
        "security": [],
        "responses": {
          "200": {
            "description": "Success.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/Error"
          },
          "429": {
            "$ref": "#/components/responses/Error"
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "apiKey": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "x3d_live_…",
        "description": "An API key from https://x3dstudios.com/profile, sent as Authorization: Bearer x3d_live_…. A card on file is required to create one; orders bill that card."
      }
    },
    "responses": {
      "Error": {
        "description": "A failure. Every error is a JSON object with one key, error, carrying the message.",
        "content": {
          "application/json": {
            "schema": {
              "type": "object",
              "required": [
                "error"
              ],
              "properties": {
                "error": {
                  "type": "string"
                },
                "code": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    }
  }
}