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

# Testing: Order Status

> Hardcoded test accounts for exercising every order and contract state without creating real orders.

The Partner API provides a set of **hardcoded test accounts** in the [test environment](/introduction#access-to-the-api). Each account is pinned to a single point in the order and contract lifecycle, so you can build and verify your integration against every state — including error and edge cases — without submitting real orders or triggering any grid operation processes.

For every test account, the **customer number and contract number are identical** and include the state suffix (for example `D0000004_Delivery`). Pass the full value, suffix and all, wherever an endpoint expects a `customerNumber` or `contractNumber`.

<Info>
  Test accounts return deterministic, synthetic data. They exist only in the test environment (`test-api.rabot-charge.de`) and never appear in production.
</Info>

***

## Available Accounts

Each account maps to one order state and its corresponding delivery state. The **Scenario** column describes what the account is designed to help you test.

| Account (`customerNumber` = `contractNumber`) | `order.state` | `deliveryState.state` | `denialReason` | Scenario |
| - | - | - | - | - |
| `D0000001_Open` | `Open` | `null` | – | Order received, blocked on missing data (e.g. meter number) |
| `D0000002_Processing` | `Processing` | `null` | – | Market communication (MaKo) ongoing |
| `D0000003_PendingDelivery` | `PendingDelivery` | `DeliveryPending` | – | Confirmed, delivery start date set, supply not yet started |
| `D0000004_Delivery` | `Delivery` | `Delivery` | – | Active supply — happy path |
| `D0000005_InChangeProcess` | `Processing` | `InChangeProcess` | – | Active contract mid supplier change |
| `D0000006_Cancelled` | `Cancelled` | `Cancelled` | – | Termination received, end-of-delivery date set |
| `D0000007_Rejected` | `Rejected` | `Denied` | `InsufficientSolvency` | Order denied (e.g. failed credit check) |
| `D0000008_Revoked` | `Revoked` | `Revoked` | – | Customer revoked the order |
| `D0000009_Unspecified` | `Unspecified` | `Unknown` | – | Unknown state from market communication — edge-case handling |

<Note>
  For `GET /partner/v1/orders` and `GET /partner/v1/orders/{contractNumber}`, the **Scenario** text above is returned in the response-envelope `message` field, so you can confirm which account you are hitting. The `/contracts`, `/metrics`, and `dayaheadworkingprice` endpoints keep their own `message` semantics.
</Note>

***

## Supported Endpoints

The test accounts resolve on the following read endpoints:

| Endpoint | Notes |
| - | - |
| `GET /partner/v1/orders?filter.customerNumber={customerNumber}` | See the [API Reference](/api-reference/orders/get_orders). |
| `GET /partner/v1/orders/{contractNumber}` | See the [API Reference](/api-reference/orders/get_order). |
| `GET /partner/v1/customers/{customerNumber}/contracts` | Returns the contract for the account. See the [API Reference](/api-reference/customers/get_contracts). |

<Warning>
  Test orders are only returned from `GET /partner/v1/orders/:contractNumber` when you **explicitly filter by a test account's contract number**. They never appear in unfiltered order lists, so they won't pollute your normal integration flows.
</Warning>

***

## Behaviour Notes

#### Null delivery state

For `D0000001_Open` and `D0000002_Processing`, the order has been exported but no delivery state has been reported yet. On these accounts the entire `deliveryState` object is `null` — not just `deliveryState.state`. Handle the object being absent, not merely a null inner field.

#### End of delivery

`endDateOfDelivery` is only populated for `D0000006_Cancelled` (`2026-09-30`). All other accounts return `null`.

***

## Quick Start

Fetch the happy-path contract to confirm your credentials and base URL are wired up correctly:

```shell theme={null}
curl -L "https://test-api.rabot-charge.de/partner/v1/customers/D0000004_Delivery/contracts" \
-H "Authorization: Bearer {{ACCESS_TOKEN}}"
```

From there, swap the account in the path to walk through each order state your integration needs to handle — `D0000007_Rejected` for the denial path, `D0000006_Cancelled` for terminations, `D0000009_Unspecified` for defensive edge-case handling.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.