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

# Obtener una orden de compra

> Devuelve detalle completo de una orden de compra incluyendo todas las líneas y estado de cumplimiento.

<ParamField header="x-api-key" type="string" required>
  API key de BOH con scope `inventory:read`.
</ParamField>

<ParamField path="vendorId" type="string" required>UUID del vendor.</ParamField>
<ParamField path="orderId" type="string" required>UUID de la orden de compra.</ParamField>

<ResponseField name="purchase_order" type="object">Detalle completo con líneas.</ResponseField>

<ResponseExample>
  ```json 200 theme={null}
  {
    "purchase_order": {
      "id": "po_01...",
      "status": "CONFIRMED",
      "supplier_id": "sup_01...",
      "store_id": "str_principal_01...",
      "expected_delivery_date": "2026-08-10",
      "lines": [
        {
          "id": "pol_01...",
          "item_id": "itm_01...",
          "quantity": 20,
          "unit_id": "unit_kg_01...",
          "unit_cost": 25.00,
          "quantity_received": 0
        }
      ]
    }
  }
  ```

  ```json 404 theme={null}
  {
    "error": {
      "kind": "purchase_order_not_found",
      "message": "Purchase order not found"
    }
  }
  ```
</ResponseExample>
