# GetChannelOrder

## Overview

GetChannelOrder retrieves one normalized channel order with mapping, linked sales-order, and troubleshooting context.

## Business Rules

- Lookup by id performs an exact channel-order match.
- The query returns any channel-order lifecycle status, including EXCEPTION and CANCELLED_BY_CHANNEL.

## Process Flow

```mermaid
flowchart TD
    A[Receive channel-order id] --> B[Query ChannelOrder]
    B --> C{Found?}
    C -->|No| D[Return null]
    C -->|Yes| E[Return channel order]
```

## External Dependencies

- None

## Error Scenarios

- None (returns null when no matching channel order exists)

## Test Cases

- returns channel order when found by id
- returns channel order with linked sales-order reference when converted
- returns null when channel order is not found
