@teemill/platform 0.27.0 → 0.29.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +12 -2
- package/api.ts +681 -64
- package/base.ts +1 -1
- package/common.ts +1 -1
- package/configuration.ts +1 -1
- package/dist/api.d.ts +478 -42
- package/dist/api.js +289 -49
- package/dist/base.d.ts +1 -1
- package/dist/base.js +1 -1
- package/dist/common.d.ts +1 -1
- package/dist/common.js +1 -1
- package/dist/configuration.d.ts +1 -1
- package/dist/configuration.js +1 -1
- package/dist/esm/api.d.ts +478 -42
- package/dist/esm/api.js +288 -48
- package/dist/esm/base.d.ts +1 -1
- package/dist/esm/base.js +1 -1
- package/dist/esm/common.d.ts +1 -1
- package/dist/esm/common.js +1 -1
- package/dist/esm/configuration.d.ts +1 -1
- package/dist/esm/configuration.js +1 -1
- package/dist/esm/index.d.ts +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/docs/ConfirmOrderFulfillment.md +24 -0
- package/docs/ConfirmOrderFulfillmentShipment.md +21 -0
- package/docs/ConfirmOrderRequest.md +20 -0
- package/docs/CreateOrder.md +33 -0
- package/docs/CreateOrderContactInformation.md +23 -0
- package/docs/CustomersApi.md +59 -23
- package/docs/CustomsInformation.md +27 -0
- package/docs/OrderItem1.md +24 -0
- package/docs/OrderItem1RecipientCost.md +22 -0
- package/docs/OrdersApi.md +128 -0
- package/docs/Statistics.md +2 -0
- package/index.ts +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
# ConfirmOrderFulfillment
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
## Properties
|
|
5
|
+
|
|
6
|
+
Name | Type | Description | Notes
|
|
7
|
+
------------ | ------------- | ------------- | -------------
|
|
8
|
+
**fulfillmentId** | **string** | Unique object identifier | [default to undefined]
|
|
9
|
+
**shippingMethodId** | **string** | Unique object identifier | [optional] [default to undefined]
|
|
10
|
+
**shipment** | [**ConfirmOrderFulfillmentShipment**](ConfirmOrderFulfillmentShipment.md) | | [optional] [default to undefined]
|
|
11
|
+
|
|
12
|
+
## Example
|
|
13
|
+
|
|
14
|
+
```typescript
|
|
15
|
+
import { ConfirmOrderFulfillment } from '@teemill/platform';
|
|
16
|
+
|
|
17
|
+
const instance: ConfirmOrderFulfillment = {
|
|
18
|
+
fulfillmentId,
|
|
19
|
+
shippingMethodId,
|
|
20
|
+
shipment,
|
|
21
|
+
};
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# ConfirmOrderFulfillmentShipment
|
|
2
|
+
|
|
3
|
+
This field is only required if you are using your own shipping label.
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
Name | Type | Description | Notes
|
|
8
|
+
------------ | ------------- | ------------- | -------------
|
|
9
|
+
**image** | **string** | Only required if you are generating shipping labels outside of PodOS | [default to undefined]
|
|
10
|
+
|
|
11
|
+
## Example
|
|
12
|
+
|
|
13
|
+
```typescript
|
|
14
|
+
import { ConfirmOrderFulfillmentShipment } from '@teemill/platform';
|
|
15
|
+
|
|
16
|
+
const instance: ConfirmOrderFulfillmentShipment = {
|
|
17
|
+
image,
|
|
18
|
+
};
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# ConfirmOrderRequest
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
## Properties
|
|
5
|
+
|
|
6
|
+
Name | Type | Description | Notes
|
|
7
|
+
------------ | ------------- | ------------- | -------------
|
|
8
|
+
**fulfillments** | [**Array<ConfirmOrderFulfillment>**](ConfirmOrderFulfillment.md) | | [default to undefined]
|
|
9
|
+
|
|
10
|
+
## Example
|
|
11
|
+
|
|
12
|
+
```typescript
|
|
13
|
+
import { ConfirmOrderRequest } from '@teemill/platform';
|
|
14
|
+
|
|
15
|
+
const instance: ConfirmOrderRequest = {
|
|
16
|
+
fulfillments,
|
|
17
|
+
};
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# CreateOrder
|
|
2
|
+
|
|
3
|
+
Create an order
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
Name | Type | Description | Notes
|
|
8
|
+
------------ | ------------- | ------------- | -------------
|
|
9
|
+
**merchantReference** | **string** | A custom reference to the merchant\'s order. | [optional] [default to undefined]
|
|
10
|
+
**contactInformation** | [**CreateOrderContactInformation**](CreateOrderContactInformation.md) | | [default to undefined]
|
|
11
|
+
**shippingAddress** | [**Address**](Address.md) | | [default to undefined]
|
|
12
|
+
**customsInformation** | [**CustomsInformation**](CustomsInformation.md) | | [optional] [default to undefined]
|
|
13
|
+
**items** | [**Array<OrderItem1>**](OrderItem1.md) | Items to be ordered | [default to undefined]
|
|
14
|
+
**preferredFulfillers** | **Array<string>** | | [optional] [default to undefined]
|
|
15
|
+
**originalOrderRef** | **string** | A reference to the resource location | [optional] [default to undefined]
|
|
16
|
+
|
|
17
|
+
## Example
|
|
18
|
+
|
|
19
|
+
```typescript
|
|
20
|
+
import { CreateOrder } from '@teemill/platform';
|
|
21
|
+
|
|
22
|
+
const instance: CreateOrder = {
|
|
23
|
+
merchantReference,
|
|
24
|
+
contactInformation,
|
|
25
|
+
shippingAddress,
|
|
26
|
+
customsInformation,
|
|
27
|
+
items,
|
|
28
|
+
preferredFulfillers,
|
|
29
|
+
originalOrderRef,
|
|
30
|
+
};
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# CreateOrderContactInformation
|
|
2
|
+
|
|
3
|
+
Contact information for the order
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
Name | Type | Description | Notes
|
|
8
|
+
------------ | ------------- | ------------- | -------------
|
|
9
|
+
**email** | **string** | | [default to undefined]
|
|
10
|
+
**phone** | **string** | | [optional] [default to undefined]
|
|
11
|
+
|
|
12
|
+
## Example
|
|
13
|
+
|
|
14
|
+
```typescript
|
|
15
|
+
import { CreateOrderContactInformation } from '@teemill/platform';
|
|
16
|
+
|
|
17
|
+
const instance: CreateOrderContactInformation = {
|
|
18
|
+
email,
|
|
19
|
+
phone,
|
|
20
|
+
};
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
package/docs/CustomersApi.md
CHANGED
|
@@ -26,24 +26,36 @@ const apiInstance = new CustomersApi(configuration);
|
|
|
26
26
|
|
|
27
27
|
let project: string; //Project unique identifier (default to undefined)
|
|
28
28
|
let platformId: string; //The platform identifier (default to undefined)
|
|
29
|
+
let sortBy: Array<'+lifetimeValue' | '-lifetimeValue' | '+totalOrderCount' | '-totalOrderCount' | '+refundedOrderCount' | '-refundedOrderCount' | '+lastPurchased' | '-lastPurchased' | '+usedDiscount' | '-usedDiscount'>; //An array of fields to sort by, prefixed with a \'-\' for descending order or \'+\' for ascending. Default is ascending. (optional) (default to undefined)
|
|
29
30
|
let countries: Array<string>; //Filter customers by country code (optional) (default to undefined)
|
|
31
|
+
let projects: Array<string>; //Filter customers by project. In the absence of this field, all projects will be included in the export. (optional) (default to undefined)
|
|
30
32
|
let gender: 'male' | 'female'; //Filter customers by gender equal to the value provided (optional) (default to undefined)
|
|
31
|
-
let
|
|
32
|
-
let
|
|
33
|
-
let
|
|
34
|
-
let
|
|
33
|
+
let productTypes: Array<string>; //Filter customers by purchased product types. In the absence of this field, all customers will be included in the export. (optional) (default to undefined)
|
|
34
|
+
let usedDiscount: boolean; //Filter customers by whether they have used a discount (optional) (default to undefined)
|
|
35
|
+
let minimumTotalOrderCount: number; //Filter customers by total order count greater than or equal to the value provided (optional) (default to undefined)
|
|
36
|
+
let maximumTotalOrderCount: number; //Filter customers by total order count less than or equal to the value provided (optional) (default to undefined)
|
|
37
|
+
let minimumRefundedOrderCount: number; //Filter customers by refunded order count greater than or equal to the value provided (optional) (default to undefined)
|
|
38
|
+
let maximumRefundedOrderCount: number; //Filter customers by refunded order count less than or equal to the value provided (optional) (default to undefined)
|
|
39
|
+
let minimumLifetimeValue: number; //Filter customers by lifetime value greater than or equal to the value provided (optional) (default to undefined)
|
|
40
|
+
let maximumLifetimeValue: number; //Filter customers by lifetime value less than or equal to the value provided (optional) (default to undefined)
|
|
35
41
|
let lastPurchasedStart: string; //Start of date range to filter customers by last purchase date (optional) (default to undefined)
|
|
36
42
|
let lastPurchasedEnd: string; //End of date range to filter customers by last purchase date (optional) (default to undefined)
|
|
37
43
|
|
|
38
44
|
const { status, data } = await apiInstance.exportCustomers(
|
|
39
45
|
project,
|
|
40
46
|
platformId,
|
|
47
|
+
sortBy,
|
|
41
48
|
countries,
|
|
49
|
+
projects,
|
|
42
50
|
gender,
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
51
|
+
productTypes,
|
|
52
|
+
usedDiscount,
|
|
53
|
+
minimumTotalOrderCount,
|
|
54
|
+
maximumTotalOrderCount,
|
|
55
|
+
minimumRefundedOrderCount,
|
|
56
|
+
maximumRefundedOrderCount,
|
|
57
|
+
minimumLifetimeValue,
|
|
58
|
+
maximumLifetimeValue,
|
|
47
59
|
lastPurchasedStart,
|
|
48
60
|
lastPurchasedEnd
|
|
49
61
|
);
|
|
@@ -55,12 +67,18 @@ const { status, data } = await apiInstance.exportCustomers(
|
|
|
55
67
|
|------------- | ------------- | ------------- | -------------|
|
|
56
68
|
| **project** | [**string**] | Project unique identifier | defaults to undefined|
|
|
57
69
|
| **platformId** | [**string**] | The platform identifier | defaults to undefined|
|
|
70
|
+
| **sortBy** | **Array<'+lifetimeValue' | '-lifetimeValue' | '+totalOrderCount' | '-totalOrderCount' | '+refundedOrderCount' | '-refundedOrderCount' | '+lastPurchased' | '-lastPurchased' | '+usedDiscount' | '-usedDiscount'>** | An array of fields to sort by, prefixed with a \'-\' for descending order or \'+\' for ascending. Default is ascending. | (optional) defaults to undefined|
|
|
58
71
|
| **countries** | **Array<string>** | Filter customers by country code | (optional) defaults to undefined|
|
|
72
|
+
| **projects** | **Array<string>** | Filter customers by project. In the absence of this field, all projects will be included in the export. | (optional) defaults to undefined|
|
|
59
73
|
| **gender** | [**'male' | 'female'**]**Array<'male' | 'female'>** | Filter customers by gender equal to the value provided | (optional) defaults to undefined|
|
|
60
|
-
| **
|
|
61
|
-
| **
|
|
62
|
-
| **
|
|
63
|
-
| **
|
|
74
|
+
| **productTypes** | **Array<string>** | Filter customers by purchased product types. In the absence of this field, all customers will be included in the export. | (optional) defaults to undefined|
|
|
75
|
+
| **usedDiscount** | [**boolean**] | Filter customers by whether they have used a discount | (optional) defaults to undefined|
|
|
76
|
+
| **minimumTotalOrderCount** | [**number**] | Filter customers by total order count greater than or equal to the value provided | (optional) defaults to undefined|
|
|
77
|
+
| **maximumTotalOrderCount** | [**number**] | Filter customers by total order count less than or equal to the value provided | (optional) defaults to undefined|
|
|
78
|
+
| **minimumRefundedOrderCount** | [**number**] | Filter customers by refunded order count greater than or equal to the value provided | (optional) defaults to undefined|
|
|
79
|
+
| **maximumRefundedOrderCount** | [**number**] | Filter customers by refunded order count less than or equal to the value provided | (optional) defaults to undefined|
|
|
80
|
+
| **minimumLifetimeValue** | [**number**] | Filter customers by lifetime value greater than or equal to the value provided | (optional) defaults to undefined|
|
|
81
|
+
| **maximumLifetimeValue** | [**number**] | Filter customers by lifetime value less than or equal to the value provided | (optional) defaults to undefined|
|
|
64
82
|
| **lastPurchasedStart** | [**string**] | Start of date range to filter customers by last purchase date | (optional) defaults to undefined|
|
|
65
83
|
| **lastPurchasedEnd** | [**string**] | End of date range to filter customers by last purchase date | (optional) defaults to undefined|
|
|
66
84
|
|
|
@@ -174,12 +192,18 @@ let platformId: string; //The platform identifier (default to undefined)
|
|
|
174
192
|
let pageToken: number; //Page reference token (optional) (default to 1)
|
|
175
193
|
let pageSize: number; //Max page size. This is the maximum page size that will be returned, but it might be smaller. (optional) (default to 100)
|
|
176
194
|
let search: string; //Search term to filter results (optional) (default to undefined)
|
|
177
|
-
let sortBy: Array<'+lifetimeValue' | '-lifetimeValue' | '+totalOrderCount' | '-totalOrderCount' | '+refundedOrderCount' | '-refundedOrderCount' | '+lastPurchased' | '-lastPurchased'>; //An array of fields to sort by, prefixed with a \'-\' for descending order or \'+\' for ascending. Default is ascending. (optional) (default to undefined)
|
|
195
|
+
let sortBy: Array<'+lifetimeValue' | '-lifetimeValue' | '+totalOrderCount' | '-totalOrderCount' | '+refundedOrderCount' | '-refundedOrderCount' | '+lastPurchased' | '-lastPurchased' | '+usedDiscount' | '-usedDiscount'>; //An array of fields to sort by, prefixed with a \'-\' for descending order or \'+\' for ascending. Default is ascending. (optional) (default to undefined)
|
|
178
196
|
let countries: Array<string>; //Filter customers by country code (optional) (default to undefined)
|
|
197
|
+
let projects: Array<string>; //Filter customers by project. In the absence of this field, all projects will be included in the export. (optional) (default to undefined)
|
|
179
198
|
let gender: 'male' | 'female'; //Filter customers by gender equal to the value provided (optional) (default to undefined)
|
|
180
|
-
let
|
|
181
|
-
let
|
|
182
|
-
let
|
|
199
|
+
let productTypes: Array<string>; //Filter customers by purchased product types. In the absence of this field, all customers will be included in the export. (optional) (default to undefined)
|
|
200
|
+
let usedDiscount: boolean; //Filter customers by whether they have used a discount (optional) (default to undefined)
|
|
201
|
+
let minimumTotalOrderCount: number; //Filter customers by total order count greater than or equal to the value provided (optional) (default to undefined)
|
|
202
|
+
let maximumTotalOrderCount: number; //Filter customers by total order count less than or equal to the value provided (optional) (default to undefined)
|
|
203
|
+
let minimumRefundedOrderCount: number; //Filter customers by refunded order count greater than or equal to the value provided (optional) (default to undefined)
|
|
204
|
+
let maximumRefundedOrderCount: number; //Filter customers by refunded order count less than or equal to the value provided (optional) (default to undefined)
|
|
205
|
+
let minimumLifetimeValue: number; //Filter customers by lifetime value greater than or equal to the value provided (optional) (default to undefined)
|
|
206
|
+
let maximumLifetimeValue: number; //Filter customers by lifetime value less than or equal to the value provided (optional) (default to undefined)
|
|
183
207
|
let lastPurchasedStart: string; //Start of date range to filter customers by last purchase date (optional) (default to undefined)
|
|
184
208
|
let lastPurchasedEnd: string; //End of date range to filter customers by last purchase date (optional) (default to undefined)
|
|
185
209
|
|
|
@@ -191,10 +215,16 @@ const { status, data } = await apiInstance.listCustomers(
|
|
|
191
215
|
search,
|
|
192
216
|
sortBy,
|
|
193
217
|
countries,
|
|
218
|
+
projects,
|
|
194
219
|
gender,
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
220
|
+
productTypes,
|
|
221
|
+
usedDiscount,
|
|
222
|
+
minimumTotalOrderCount,
|
|
223
|
+
maximumTotalOrderCount,
|
|
224
|
+
minimumRefundedOrderCount,
|
|
225
|
+
maximumRefundedOrderCount,
|
|
226
|
+
minimumLifetimeValue,
|
|
227
|
+
maximumLifetimeValue,
|
|
198
228
|
lastPurchasedStart,
|
|
199
229
|
lastPurchasedEnd
|
|
200
230
|
);
|
|
@@ -209,12 +239,18 @@ const { status, data } = await apiInstance.listCustomers(
|
|
|
209
239
|
| **pageToken** | [**number**] | Page reference token | (optional) defaults to 1|
|
|
210
240
|
| **pageSize** | [**number**] | Max page size. This is the maximum page size that will be returned, but it might be smaller. | (optional) defaults to 100|
|
|
211
241
|
| **search** | [**string**] | Search term to filter results | (optional) defaults to undefined|
|
|
212
|
-
| **sortBy** | **Array<'+lifetimeValue' | '-lifetimeValue' | '+totalOrderCount' | '-totalOrderCount' | '+refundedOrderCount' | '-refundedOrderCount' | '+lastPurchased' | '-lastPurchased'>** | An array of fields to sort by, prefixed with a \'-\' for descending order or \'+\' for ascending. Default is ascending. | (optional) defaults to undefined|
|
|
242
|
+
| **sortBy** | **Array<'+lifetimeValue' | '-lifetimeValue' | '+totalOrderCount' | '-totalOrderCount' | '+refundedOrderCount' | '-refundedOrderCount' | '+lastPurchased' | '-lastPurchased' | '+usedDiscount' | '-usedDiscount'>** | An array of fields to sort by, prefixed with a \'-\' for descending order or \'+\' for ascending. Default is ascending. | (optional) defaults to undefined|
|
|
213
243
|
| **countries** | **Array<string>** | Filter customers by country code | (optional) defaults to undefined|
|
|
244
|
+
| **projects** | **Array<string>** | Filter customers by project. In the absence of this field, all projects will be included in the export. | (optional) defaults to undefined|
|
|
214
245
|
| **gender** | [**'male' | 'female'**]**Array<'male' | 'female'>** | Filter customers by gender equal to the value provided | (optional) defaults to undefined|
|
|
215
|
-
| **
|
|
216
|
-
| **
|
|
217
|
-
| **
|
|
246
|
+
| **productTypes** | **Array<string>** | Filter customers by purchased product types. In the absence of this field, all customers will be included in the export. | (optional) defaults to undefined|
|
|
247
|
+
| **usedDiscount** | [**boolean**] | Filter customers by whether they have used a discount | (optional) defaults to undefined|
|
|
248
|
+
| **minimumTotalOrderCount** | [**number**] | Filter customers by total order count greater than or equal to the value provided | (optional) defaults to undefined|
|
|
249
|
+
| **maximumTotalOrderCount** | [**number**] | Filter customers by total order count less than or equal to the value provided | (optional) defaults to undefined|
|
|
250
|
+
| **minimumRefundedOrderCount** | [**number**] | Filter customers by refunded order count greater than or equal to the value provided | (optional) defaults to undefined|
|
|
251
|
+
| **maximumRefundedOrderCount** | [**number**] | Filter customers by refunded order count less than or equal to the value provided | (optional) defaults to undefined|
|
|
252
|
+
| **minimumLifetimeValue** | [**number**] | Filter customers by lifetime value greater than or equal to the value provided | (optional) defaults to undefined|
|
|
253
|
+
| **maximumLifetimeValue** | [**number**] | Filter customers by lifetime value less than or equal to the value provided | (optional) defaults to undefined|
|
|
218
254
|
| **lastPurchasedStart** | [**string**] | Start of date range to filter customers by last purchase date | (optional) defaults to undefined|
|
|
219
255
|
| **lastPurchasedEnd** | [**string**] | End of date range to filter customers by last purchase date | (optional) defaults to undefined|
|
|
220
256
|
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# CustomsInformation
|
|
2
|
+
|
|
3
|
+
Customs information for the order. **Note:** Adding customs information to an order is only compatible with Shipmate at this time
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
Name | Type | Description | Notes
|
|
8
|
+
------------ | ------------- | ------------- | -------------
|
|
9
|
+
**preRegistrationType** | **string** | Pre-registration type | [optional] [default to undefined]
|
|
10
|
+
**preRegistrationNumber** | **string** | Pre-registration number | [optional] [default to undefined]
|
|
11
|
+
**vatNumber** | **string** | VAT number | [optional] [default to undefined]
|
|
12
|
+
**eoriNumber** | **string** | EORI number | [optional] [default to undefined]
|
|
13
|
+
|
|
14
|
+
## Example
|
|
15
|
+
|
|
16
|
+
```typescript
|
|
17
|
+
import { CustomsInformation } from '@teemill/platform';
|
|
18
|
+
|
|
19
|
+
const instance: CustomsInformation = {
|
|
20
|
+
preRegistrationType,
|
|
21
|
+
preRegistrationNumber,
|
|
22
|
+
vatNumber,
|
|
23
|
+
eoriNumber,
|
|
24
|
+
};
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
# OrderItem1
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
## Properties
|
|
5
|
+
|
|
6
|
+
Name | Type | Description | Notes
|
|
7
|
+
------------ | ------------- | ------------- | -------------
|
|
8
|
+
**variantRef** | **string** | A reference to the variant being ordered | [default to undefined]
|
|
9
|
+
**quantity** | **number** | | [default to undefined]
|
|
10
|
+
**recipientCost** | [**OrderItem1RecipientCost**](OrderItem1RecipientCost.md) | | [optional] [default to undefined]
|
|
11
|
+
|
|
12
|
+
## Example
|
|
13
|
+
|
|
14
|
+
```typescript
|
|
15
|
+
import { OrderItem1 } from '@teemill/platform';
|
|
16
|
+
|
|
17
|
+
const instance: OrderItem1 = {
|
|
18
|
+
variantRef,
|
|
19
|
+
quantity,
|
|
20
|
+
recipientCost,
|
|
21
|
+
};
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# OrderItem1RecipientCost
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
## Properties
|
|
5
|
+
|
|
6
|
+
Name | Type | Description | Notes
|
|
7
|
+
------------ | ------------- | ------------- | -------------
|
|
8
|
+
**amount** | **string** | | [default to undefined]
|
|
9
|
+
**currencyCode** | **string** | | [default to undefined]
|
|
10
|
+
|
|
11
|
+
## Example
|
|
12
|
+
|
|
13
|
+
```typescript
|
|
14
|
+
import { OrderItem1RecipientCost } from '@teemill/platform';
|
|
15
|
+
|
|
16
|
+
const instance: OrderItem1RecipientCost = {
|
|
17
|
+
amount,
|
|
18
|
+
currencyCode,
|
|
19
|
+
};
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
package/docs/OrdersApi.md
CHANGED
|
@@ -4,6 +4,8 @@ All URIs are relative to *https://localhost:8080*
|
|
|
4
4
|
|
|
5
5
|
|Method | HTTP request | Description|
|
|
6
6
|
|------------- | ------------- | -------------|
|
|
7
|
+
|[**confirmOrder**](#confirmorder) | **POST** /v1/platform/{platformId}/orders/{orderId}/confirm | Confirm order|
|
|
8
|
+
|[**createOrder**](#createorder) | **POST** /v1/platform/{platformId}/orders | Create order|
|
|
7
9
|
|[**exportOrders**](#exportorders) | **GET** /v1/platform/{platformId}/orders/export | Export orders|
|
|
8
10
|
|[**getFulfillment**](#getfulfillment) | **GET** /v1/platform/{platformId}/fulfillments/{fulfillmentId} | Get fulfillment|
|
|
9
11
|
|[**getOrder**](#getorder) | **GET** /v1/platform/{platformId}/orders/{orderId} | Get order|
|
|
@@ -14,6 +16,132 @@ All URIs are relative to *https://localhost:8080*
|
|
|
14
16
|
|[**sendOrderReceipt**](#sendorderreceipt) | **POST** /v1/platform/{platformId}/orders/{orderId}/receipt/send | Send order receipt|
|
|
15
17
|
|[**updateFulfillment**](#updatefulfillment) | **PATCH** /v1/platform/{platformId}/fulfillments/{fulfillmentId} | Update fulfillment|
|
|
16
18
|
|
|
19
|
+
# **confirmOrder**
|
|
20
|
+
> Order confirmOrder(confirmOrderRequest)
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
### Example
|
|
24
|
+
|
|
25
|
+
```typescript
|
|
26
|
+
import {
|
|
27
|
+
OrdersApi,
|
|
28
|
+
Configuration,
|
|
29
|
+
ConfirmOrderRequest
|
|
30
|
+
} from '@teemill/platform';
|
|
31
|
+
|
|
32
|
+
const configuration = new Configuration();
|
|
33
|
+
const apiInstance = new OrdersApi(configuration);
|
|
34
|
+
|
|
35
|
+
let project: string; //Project unique identifier (default to undefined)
|
|
36
|
+
let platformId: string; //The platform identifier (default to undefined)
|
|
37
|
+
let orderId: string; //The order identifier (default to undefined)
|
|
38
|
+
let confirmOrderRequest: ConfirmOrderRequest; //ConfirmFulfillment schema
|
|
39
|
+
|
|
40
|
+
const { status, data } = await apiInstance.confirmOrder(
|
|
41
|
+
project,
|
|
42
|
+
platformId,
|
|
43
|
+
orderId,
|
|
44
|
+
confirmOrderRequest
|
|
45
|
+
);
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
### Parameters
|
|
49
|
+
|
|
50
|
+
|Name | Type | Description | Notes|
|
|
51
|
+
|------------- | ------------- | ------------- | -------------|
|
|
52
|
+
| **confirmOrderRequest** | **ConfirmOrderRequest**| ConfirmFulfillment schema | |
|
|
53
|
+
| **project** | [**string**] | Project unique identifier | defaults to undefined|
|
|
54
|
+
| **platformId** | [**string**] | The platform identifier | defaults to undefined|
|
|
55
|
+
| **orderId** | [**string**] | The order identifier | defaults to undefined|
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
### Return type
|
|
59
|
+
|
|
60
|
+
**Order**
|
|
61
|
+
|
|
62
|
+
### Authorization
|
|
63
|
+
|
|
64
|
+
[session-oauth](../README.md#session-oauth), [api-key](../README.md#api-key)
|
|
65
|
+
|
|
66
|
+
### HTTP request headers
|
|
67
|
+
|
|
68
|
+
- **Content-Type**: application/json
|
|
69
|
+
- **Accept**: application/json
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
### HTTP response details
|
|
73
|
+
| Status code | Description | Response headers |
|
|
74
|
+
|-------------|-------------|------------------|
|
|
75
|
+
|**200** | Order schema | - |
|
|
76
|
+
|**400** | Failed validation | - |
|
|
77
|
+
|**401** | Not authorised to access this resource | - |
|
|
78
|
+
|**403** | Refuse to authorize | - |
|
|
79
|
+
|**404** | Resource not found | - |
|
|
80
|
+
|**500** | Unknown server error | - |
|
|
81
|
+
|
|
82
|
+
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
83
|
+
|
|
84
|
+
# **createOrder**
|
|
85
|
+
> Order createOrder(createOrder)
|
|
86
|
+
|
|
87
|
+
|
|
88
|
+
### Example
|
|
89
|
+
|
|
90
|
+
```typescript
|
|
91
|
+
import {
|
|
92
|
+
OrdersApi,
|
|
93
|
+
Configuration,
|
|
94
|
+
CreateOrder
|
|
95
|
+
} from '@teemill/platform';
|
|
96
|
+
|
|
97
|
+
const configuration = new Configuration();
|
|
98
|
+
const apiInstance = new OrdersApi(configuration);
|
|
99
|
+
|
|
100
|
+
let project: string; //Project unique identifier (default to undefined)
|
|
101
|
+
let platformId: string; //The platform identifier (default to undefined)
|
|
102
|
+
let createOrder: CreateOrder; //Create Order schema
|
|
103
|
+
|
|
104
|
+
const { status, data } = await apiInstance.createOrder(
|
|
105
|
+
project,
|
|
106
|
+
platformId,
|
|
107
|
+
createOrder
|
|
108
|
+
);
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
### Parameters
|
|
112
|
+
|
|
113
|
+
|Name | Type | Description | Notes|
|
|
114
|
+
|------------- | ------------- | ------------- | -------------|
|
|
115
|
+
| **createOrder** | **CreateOrder**| Create Order schema | |
|
|
116
|
+
| **project** | [**string**] | Project unique identifier | defaults to undefined|
|
|
117
|
+
| **platformId** | [**string**] | The platform identifier | defaults to undefined|
|
|
118
|
+
|
|
119
|
+
|
|
120
|
+
### Return type
|
|
121
|
+
|
|
122
|
+
**Order**
|
|
123
|
+
|
|
124
|
+
### Authorization
|
|
125
|
+
|
|
126
|
+
[session-oauth](../README.md#session-oauth), [api-key](../README.md#api-key)
|
|
127
|
+
|
|
128
|
+
### HTTP request headers
|
|
129
|
+
|
|
130
|
+
- **Content-Type**: application/json
|
|
131
|
+
- **Accept**: application/json
|
|
132
|
+
|
|
133
|
+
|
|
134
|
+
### HTTP response details
|
|
135
|
+
| Status code | Description | Response headers |
|
|
136
|
+
|-------------|-------------|------------------|
|
|
137
|
+
|**201** | Order schema | - |
|
|
138
|
+
|**400** | Failed validation | - |
|
|
139
|
+
|**401** | Not authorised to access this resource | - |
|
|
140
|
+
|**403** | Refuse to authorize | - |
|
|
141
|
+
|**500** | Unknown server error | - |
|
|
142
|
+
|
|
143
|
+
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
144
|
+
|
|
17
145
|
# **exportOrders**
|
|
18
146
|
> File exportOrders()
|
|
19
147
|
|
package/docs/Statistics.md
CHANGED
|
@@ -9,6 +9,7 @@ Name | Type | Description | Notes
|
|
|
9
9
|
**totalOrderCount** | **number** | | [default to undefined]
|
|
10
10
|
**refundedOrderCount** | **number** | | [default to undefined]
|
|
11
11
|
**lastPurchased** | **string** | | [default to undefined]
|
|
12
|
+
**usedDiscount** | **boolean** | | [default to undefined]
|
|
12
13
|
|
|
13
14
|
## Example
|
|
14
15
|
|
|
@@ -20,6 +21,7 @@ const instance: Statistics = {
|
|
|
20
21
|
totalOrderCount,
|
|
21
22
|
refundedOrderCount,
|
|
22
23
|
lastPurchased,
|
|
24
|
+
usedDiscount,
|
|
23
25
|
};
|
|
24
26
|
```
|
|
25
27
|
|
package/index.ts
CHANGED