# Custom Orders

**Summary:** Endpoints for Custom Orders

- Role: [Developers](https://www.subrite.no/developers)
- Source: https://www.subrite.no/developers/custom-orders
- Updated: 2026-10-13
- Markdown index: https://www.subrite.no/developers/llms.txt

<a id="post-api-v1-custom-orders"></a>
## Create or update a custom order

`POST /api/v1/custom-orders`

**Authentication:** Bearer token (JWT)

### Request body

Content type: `application/json` · Required · `CreateCustomOrderDto`

| Name | Type | Description |
| --- | --- | --- |
| `sourceId` (Required) | `string (uuid)` |   |
| `sourceRef` (Required) | `string` | `maxLength`: `255` |
| `memberId` (Required) | `string` | `maxLength`: `255` |
| `totalPrice` (Required) | `number` |   |
| `totalPriceVat` (Required) | `number` |   |
| `currency` (Required) | `string` | `minLength`: `3`, `maxLength`: `3` |
| `orderTime` | `string` |   |
| `items` (Required) | `array of CreateCustomOrderItemDto` | `minItems`: `1` |
| `items[].productId` (Required when parent is present) | `string` | `maxLength`: `255` |
| `items[].productName` (Required when parent is present) | `string` | `maxLength`: `255` |
| `items[].categoryId` (Required when parent is present) | `string` | `maxLength`: `255` |
| `items[].categoryName` (Required when parent is present) | `string` | `maxLength`: `255` |
| `items[].quantity` (Required when parent is present) | `number` | `minimum`: `1` |
| `items[].price` (Required when parent is present) | `number` |   |
| `items[].priceVat` (Required when parent is present) | `number` |   |
| `items[].customPropertyValues` | `object` |   |
| `customPropertyValues` | `object` |   |

### Responses

#### 201

Content type: `application/json` · `CustomOrder`

Order created/updated successfully

| Name | Type | Description |
| --- | --- | --- |
| `orderTime` (Required) | `string (date-time)` |   |
| `memberId` (Required) | `string` |   |
| `sourceId` (Required) | `string` |   |
| `sourceRef` (Required) | `string` |   |
| `totalPrice` (Required) | `number` |   |
| `totalPriceVat` (Required) | `number` |   |
| `currency` (Required) | `string` |   |
| `tenantId` (Required) | `number` |   |
| `customPropertyValues` (Required) | `object` |   |
| `tenant` (Required) | `Tenant` | Nested fields omitted: field limit. |
| `source` (Required) | `CustomOrderSource` |   |
| `source.name` (Required) | `string` |   |
| `source.tenantId` (Required) | `number` |   |
| `source.tenant` (Required) | `Tenant` | Nested fields omitted: field limit. |
| `source.orders` (Required) | `array of CustomOrder` | Recursive schema; nested fields are not repeated. |
| `source.id` (Required) | `string` |   |
| `source.createdAt` (Required) | `string (date-time)` |   |
| `source.updatedAt` (Required) | `string (date-time)` |   |
| `source.deletedAt` (Required) | `string (date-time)` |   |
| `source.metaData` (Required) | `object` |   |
| `items` (Required) | `array of CustomOrderItem` |   |
| `items[].orderId` (Required when parent is present) | `string` |   |
| `items[].sequence` (Required when parent is present) | `number` |   |
| `items[].productId` (Required when parent is present) | `string` |   |
| `items[].productName` (Required when parent is present) | `string` |   |
| `items[].categoryId` (Required when parent is present) | `string` |   |
| `items[].categoryName` (Required when parent is present) | `string` |   |
| `items[].quantity` (Required when parent is present) | `number` |   |
| `items[].price` (Required when parent is present) | `number` |   |
| `items[].priceVat` (Required when parent is present) | `number` |   |
| `items[].customPropertyValues` (Required when parent is present) | `object` |   |
| `items[].tenantId` (Required when parent is present) | `number` |   |
| `items[].tenant` (Required when parent is present) | `Tenant` | Nested fields omitted: field limit. |
| `items[].order` (Required when parent is present) | `CustomOrder` | Recursive schema; nested fields are not repeated. |
| `items[].id` (Required when parent is present) | `string` |   |
| `items[].createdAt` (Required when parent is present) | `string (date-time)` |   |
| `items[].updatedAt` (Required when parent is present) | `string (date-time)` |   |
| `items[].deletedAt` (Required when parent is present) | `string (date-time)` |   |
| `items[].metaData` (Required when parent is present) | `object` |   |
| `feedProcessed` (Required) | `boolean` |   |
| `id` (Required) | `string` |   |
| `createdAt` (Required) | `string (date-time)` |   |
| `updatedAt` (Required) | `string (date-time)` |   |
| `deletedAt` (Required) | `string (date-time)` |   |
| `metaData` (Required) | `object` |   |

#### 400

Content type: `application/json` · `ErrorResponse`

badRequest, customOrderSourceNotFound

| Name | Type | Description |
| --- | --- | --- |
| `messageCode` (Required) | `string` | Allowed values: `"badRequest"`, `"customOrderSourceNotFound"` |
| `message` | `string` |   |
| `errors` (Required) | `array of FieldError` |   |
| `errors[].field` (Required when parent is present) | `string` |   |
| `errors[].fieldValue` (Required when parent is present) | `string` |   |
| `errors[].identifier` (Required when parent is present) | `string` |   |
| `errors[].identifierValue` (Required when parent is present) | `string` |   |
| `errors[].messageCode` (Required when parent is present) | `string` |   |
| `errors[].message` | `string` |   |
| `errors[].errorType` (Required when parent is present) | `string` |   |

**Example response**

`application/json`

```json
{
  "messageCode": "badRequest",
  "message": "string",
  "errors": [
    {}
  ]
}
```

#### 401

unauthorized

#### 403

Content type: `application/json` · `ErrorResponse`

forbiddenResource

| Name | Type | Description |
| --- | --- | --- |
| `messageCode` (Required) | `string` |   |
| `message` | `string` |   |
| `errors` (Required) | `array of FieldError` |   |
| `errors[].field` (Required when parent is present) | `string` |   |
| `errors[].fieldValue` (Required when parent is present) | `string` |   |
| `errors[].identifier` (Required when parent is present) | `string` |   |
| `errors[].identifierValue` (Required when parent is present) | `string` |   |
| `errors[].messageCode` (Required when parent is present) | `string` |   |
| `errors[].message` | `string` |   |
| `errors[].errorType` (Required when parent is present) | `string` |   |

**Example response**

`application/json`

```json
{
  "messageCode": "string",
  "message": "string",
  "errors": [
    {}
  ]
}
```

#### 500

Content type: `application/json` · `ErrorResponse`

internalServerError

Same fields as [Create or update a custom order (403)](https://www.subrite.no/developers/custom-orders?md=true#post-api-v1-custom-orders).

### Example request

```bash
curl https://api.subrite.no/api/v1/custom-orders \
  --request POST \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "sourceId": "797f5a94-3689-4ac8-82fd-d749511ea2b2",
  "sourceRef": "string",
  "memberId": "string",
  "totalPrice": 0,
  "totalPriceVat": 0,
  "currency": "str",
  "orderTime": "string",
  "items": [
    {
      "customPropertyValues": {}
    }
  ],
  "customPropertyValues": {}
}'
```

### Example response

201 · `application/json`

```json
{
  "orderTime": "2019-08-24T14:15:22Z",
  "memberId": "string",
  "sourceId": "string",
  "sourceRef": "string",
  "totalPrice": 0,
  "totalPriceVat": 0,
  "currency": "string",
  "tenantId": 0,
  "customPropertyValues": {},
  "tenant": {
    "market": "NO",
    "productName": "enterprise",
    "additionalFeatures": [],
    "disabledFeatures": [],
    "name": "string",
    "isActive": true,
    "defaultLanguage": "en",
    "hostName": "string",
    "logo": "string",
    "favicon": "string",
    "authLogo": "string",
    "authLogoHeight": 0,
    "siteUrl": "string",
    "termsUrl": "string",
    "privacyUrl": "string",
    "gtm": "string",
    "taxRates": [],
    "smsOtp": true,
    "emailProvider": "brevo",
    "tenantContact": "string",
    "registeredBusinessNo": "string",
    "bankAccountNo": "string",
    "swiftCode": "string",
    "iban": "<iban>",
    "defaultLogoutURL": "string",
    "postalAddress": "<postalAddress>",
    "otpTemplateId": {},
    "smsSenderId": 0,
    "emailSenderId": 0,
    "smsSender": {
      "metaData": {}
    },
    "emailSender": {
      "metaData": {}
    },
    "products": [],
    "users": [],
    "members": [],
    "roles": [],
    "subscriptionPlans": [],
    "packages": [],
    "invoices": [],
    "orders": [],
    "paymentProviders": [],
    "newslettersProviderConfig": [],
    "paymentProviderConfigs": [],
    "oidcClients": [],
    "oauthProviders": [],
    "activityLogs": [],
    "m2m_api_clients": [],
    "customProperties": [],
    "consents": [],
    "preference": {
      "inputFieldConfig": [],
      "customFieldsOnMemberCard": [],
      "customFieldsOnInvoice": [],
      "visibleAdditionalFieldsOnMypage": [],
      "metaData": {}
    },
    "settings": {
      "aiResidency": {},
      "metaData": {}
    },
    "communicationTemplates": [],
    "additionalHostnames": [],
    "exportHistory": [],
    "arReportHistory": [],
    "mypageCardsSettings": [],
    "webhooks": [],
    "customOrders": [],
    "customOrderSources": [],
    "brandKits": [],
    "communicationReceivers": [],
    "id": 0,
    "createdAt": "2019-08-24T14:15:22Z",
    "updatedAt": "2019-08-24T14:15:22Z",
    "deletedAt": "2019-08-24T14:15:22Z",
    "metaData": {}
  },
  "source": {
    "name": "string",
    "tenantId": 0,
    "tenant": {
      "additionalFeatures": [],
      "disabledFeatures": [],
      "taxRates": [],
      "products": [],
      "users": [],
      "members": [],
      "roles": [],
      "subscriptionPlans": [],
      "packages": [],
      "invoices": [],
      "orders": [],
      "paymentProviders": [],
      "newslettersProviderConfig": [],
      "paymentProviderConfigs": [],
      "oidcClients": [],
      "oauthProviders": [],
      "activityLogs": [],
      "m2m_api_clients": [],
      "customProperties": [],
      "consents": [],
      "communicationTemplates": [],
      "additionalHostnames": [],
      "exportHistory": [],
      "arReportHistory": [],
      "mypageCardsSettings": [],
      "webhooks": [],
      "customOrders": [],
      "customOrderSources": [],
      "brandKits": [],
      "communicationReceivers": [],
      "metaData": {}
    },
    "orders": [],
    "id": "string",
    "createdAt": "2019-08-24T14:15:22Z",
    "updatedAt": "2019-08-24T14:15:22Z",
    "deletedAt": "2019-08-24T14:15:22Z",
    "metaData": {}
  },
  "items": [
    {
      "customPropertyValues": {},
      "metaData": {}
    }
  ],
  "feedProcessed": true,
  "id": "string",
  "createdAt": "2019-08-24T14:15:22Z",
  "updatedAt": "2019-08-24T14:15:22Z",
  "deletedAt": "2019-08-24T14:15:22Z",
  "metaData": {}
}
```

<a id="get-api-v1-custom-orders-member-memberid"></a>
## List custom orders for a member (paginated)

`GET /api/v1/custom-orders/member/{memberId}`

**Authentication:** Bearer token (JWT)

### Parameters

| Name | In | Type | Description |
| --- | --- | --- | --- |
| `memberId` (Required) | path | `string` |   |
| `page` | query | `number` | Default: `1` · `minimum`: `1` |
| `take` | query | `number` | Default: `10` · `minimum`: `1`, `maximum`: `50` |
| `orderBy` | query | `string` | Allowed values: `"createdAt"`, `"id"`, `"updatedAt"` · Default: `"createdAt"` |
| `orderDirection` | query | `string` | Allowed values: `"asc"`, `"desc"` · Default: `"desc"` |

### Responses

#### 200

Content type: `application/json` · `CustomOrderResponseDtoPaginated`

| Name | Type | Description |
| --- | --- | --- |
| `items` (Required) | `array of CustomOrderResponseDto` |   |
| `items[].id` (Required when parent is present) | `string` |   |
| `items[].orderTime` (Required when parent is present) | `string (date-time)` |   |
| `items[].sourceRef` (Required when parent is present) | `string` |   |
| `items[].sourceName` (Required when parent is present) | `string` |   |
| `items[].totalPrice` (Required when parent is present) | `number` |   |
| `items[].totalPriceVat` (Required when parent is present) | `number` |   |
| `items[].currency` (Required when parent is present) | `string` |   |
| `items[].items` | `array of CustomOrderItemResponseDto` |   |
| `items[].items[].id` (Required when parent is present) | `string` |   |
| `items[].items[].productId` (Required when parent is present) | `string` |   |
| `items[].items[].productName` (Required when parent is present) | `string` |   |
| `items[].items[].categoryId` (Required when parent is present) | `string` |   |
| `items[].items[].categoryName` (Required when parent is present) | `string` |   |
| `items[].items[].quantity` (Required when parent is present) | `number` |   |
| `items[].items[].price` (Required when parent is present) | `number` |   |
| `items[].items[].priceVat` (Required when parent is present) | `number` |   |
| `meta` (Required) | `PageMeta` |   |
| `meta.page` (Required) | `number` |   |
| `meta.take` (Required) | `number` |   |
| `meta.count` (Required) | `number` |   |
| `meta.pageCount` (Required) | `number` |   |
| `meta.hasPreviousPage` (Required) | `boolean` |   |
| `meta.hasNextPage` (Required) | `boolean` |   |

#### 400

Content type: `application/json` · `ErrorResponse`

badRequest

| Name | Type | Description |
| --- | --- | --- |
| `messageCode` (Required) | `string` | Allowed values: `"badRequest"` |
| `message` | `string` |   |
| `errors` (Required) | `array of FieldError` |   |
| `errors[].field` (Required when parent is present) | `string` |   |
| `errors[].fieldValue` (Required when parent is present) | `string` |   |
| `errors[].identifier` (Required when parent is present) | `string` |   |
| `errors[].identifierValue` (Required when parent is present) | `string` |   |
| `errors[].messageCode` (Required when parent is present) | `string` |   |
| `errors[].message` | `string` |   |
| `errors[].errorType` (Required when parent is present) | `string` |   |

**Example response**

`application/json`

```json
{
  "messageCode": "badRequest",
  "message": "string",
  "errors": [
    {}
  ]
}
```

#### 401

unauthorized

#### 403

Content type: `application/json` · `ErrorResponse`

forbiddenResource

Same fields as [Create or update a custom order (403)](https://www.subrite.no/developers/custom-orders?md=true#post-api-v1-custom-orders).

**Example response**

`application/json`

```json
{
  "messageCode": "string",
  "message": "string",
  "errors": [
    {}
  ]
}
```

#### 500

Content type: `application/json` · `ErrorResponse`

internalServerError

Same fields as [Create or update a custom order (403)](https://www.subrite.no/developers/custom-orders?md=true#post-api-v1-custom-orders).

### Example request

```bash
curl 'https://api.subrite.no/api/v1/custom-orders/member/{memberId}' \
  --header 'Authorization: Bearer <token>'
```

### Example response

200 · `application/json`

```json
{
  "items": [
    {
      "items": []
    }
  ],
  "meta": {
    "page": 0,
    "take": 0,
    "count": 0,
    "pageCount": 0,
    "hasPreviousPage": true,
    "hasNextPage": true
  }
}
```

<a id="get-api-v1-custom-orders-member-memberid-orderid"></a>
## Get a single custom order with line items

`GET /api/v1/custom-orders/member/{memberId}/{orderId}`

**Authentication:** Bearer token (JWT)

### Parameters

| Name | In | Type | Description |
| --- | --- | --- | --- |
| `memberId` (Required) | path | `string` |   |
| `orderId` (Required) | path | `string` |   |

### Responses

#### 200

Content type: `application/json` · `CustomOrderResponseDto`

| Name | Type | Description |
| --- | --- | --- |
| `id` (Required) | `string` |   |
| `orderTime` (Required) | `string (date-time)` |   |
| `sourceRef` (Required) | `string` |   |
| `sourceName` (Required) | `string` |   |
| `totalPrice` (Required) | `number` |   |
| `totalPriceVat` (Required) | `number` |   |
| `currency` (Required) | `string` |   |
| `items` | `array of CustomOrderItemResponseDto` |   |
| `items[].id` (Required when parent is present) | `string` |   |
| `items[].productId` (Required when parent is present) | `string` |   |
| `items[].productName` (Required when parent is present) | `string` |   |
| `items[].categoryId` (Required when parent is present) | `string` |   |
| `items[].categoryName` (Required when parent is present) | `string` |   |
| `items[].quantity` (Required when parent is present) | `number` |   |
| `items[].price` (Required when parent is present) | `number` |   |
| `items[].priceVat` (Required when parent is present) | `number` |   |

#### 400

Content type: `application/json` · `ErrorResponse`

badRequest

Same fields as [List custom orders for a member (paginated) (400)](https://www.subrite.no/developers/custom-orders?md=true#get-api-v1-custom-orders-member-memberid).

**Example response**

`application/json`

```json
{
  "messageCode": "badRequest",
  "message": "string",
  "errors": [
    {}
  ]
}
```

#### 401

unauthorized

#### 403

Content type: `application/json` · `ErrorResponse`

forbiddenResource

Same fields as [Create or update a custom order (403)](https://www.subrite.no/developers/custom-orders?md=true#post-api-v1-custom-orders).

**Example response**

`application/json`

```json
{
  "messageCode": "string",
  "message": "string",
  "errors": [
    {}
  ]
}
```

#### 404

Content type: `application/json` · `ErrorResponse`

customOrderNotFound

| Name | Type | Description |
| --- | --- | --- |
| `messageCode` (Required) | `string` | Allowed values: `"customOrderNotFound"` |
| `message` | `string` |   |
| `errors` (Required) | `array of FieldError` |   |
| `errors[].field` (Required when parent is present) | `string` |   |
| `errors[].fieldValue` (Required when parent is present) | `string` |   |
| `errors[].identifier` (Required when parent is present) | `string` |   |
| `errors[].identifierValue` (Required when parent is present) | `string` |   |
| `errors[].messageCode` (Required when parent is present) | `string` |   |
| `errors[].message` | `string` |   |
| `errors[].errorType` (Required when parent is present) | `string` |   |

**Example response**

`application/json`

```json
{
  "messageCode": "customOrderNotFound",
  "message": "string",
  "errors": [
    {}
  ]
}
```

#### 500

Content type: `application/json` · `ErrorResponse`

internalServerError

Same fields as [Create or update a custom order (403)](https://www.subrite.no/developers/custom-orders?md=true#post-api-v1-custom-orders).

### Example request

```bash
curl 'https://api.subrite.no/api/v1/custom-orders/member/{memberId}/{orderId}' \
  --header 'Authorization: Bearer <token>'
```

### Example response

200 · `application/json`

```json
{
  "id": "string",
  "orderTime": "2019-08-24T14:15:22Z",
  "sourceRef": "string",
  "sourceName": "string",
  "totalPrice": 0,
  "totalPriceVat": 0,
  "currency": "string",
  "items": [
    {}
  ]
}
```
