# cancelOutboundShipment

## Overview

Cancels a DRAFT outbound shipment (出庫), an `OutboundShipment`, transitioning its status to CANCELLED. Only DRAFT outbound shipments can be cancelled; a POSTED outbound shipment is terminal and cannot be cancelled. Cancellation does not affect stock (a DRAFT outbound shipment has never posted an inventory ledger entry). Thin wrapper over the native `outbound-shipment` cancel command.

Input: `id`.

## Modules Commands Used

- [outbound-shipment] CancelOutboundShipment

## Exception Handling

| Error Code | Description |
| --- | --- |
| OUTBOUND_SHIPMENT_INVALID_STATUS | The outbound shipment does not exist or is not in DRAFT status and cannot be cancelled. |
