@teemill/platform 0.26.0 → 0.28.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 +483 -6
- package/base.ts +1 -1
- package/common.ts +1 -1
- package/configuration.ts +1 -1
- package/dist/api.d.ts +349 -3
- package/dist/api.js +193 -7
- 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 +349 -3
- package/dist/esm/api.js +192 -6
- 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/CustomsInformation.md +27 -0
- package/docs/OrderItem1.md +24 -0
- package/docs/OrderItem1RecipientCost.md +22 -0
- package/docs/OrdersApi.md +135 -1
- package/index.ts +1 -1
- package/package.json +1 -1
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
|
|
|
@@ -354,6 +482,8 @@ let search: string; //Search term to filter based on order reference, customer n
|
|
|
354
482
|
let start: string; //Start of date range to filter when orders were placed (optional) (default to undefined)
|
|
355
483
|
let end: string; //End of date range to filter when orders were placed (optional) (default to undefined)
|
|
356
484
|
let dateFilterType: 'createdAt' | 'updatedAt' | 'statusChangedAt'; //Specifies the type of date range filter to apply. Determines which date field the `start` and `end` fields should query. (optional) (default to 'createdAt')
|
|
485
|
+
let maxOrderTotal: number; //The maximum value of the order (optional) (default to undefined)
|
|
486
|
+
let minOrderTotal: number; //The minimum value of the order (optional) (default to undefined)
|
|
357
487
|
|
|
358
488
|
const { status, data } = await apiInstance.listOrders(
|
|
359
489
|
project,
|
|
@@ -363,7 +493,9 @@ const { status, data } = await apiInstance.listOrders(
|
|
|
363
493
|
search,
|
|
364
494
|
start,
|
|
365
495
|
end,
|
|
366
|
-
dateFilterType
|
|
496
|
+
dateFilterType,
|
|
497
|
+
maxOrderTotal,
|
|
498
|
+
minOrderTotal
|
|
367
499
|
);
|
|
368
500
|
```
|
|
369
501
|
|
|
@@ -379,6 +511,8 @@ const { status, data } = await apiInstance.listOrders(
|
|
|
379
511
|
| **start** | [**string**] | Start of date range to filter when orders were placed | (optional) defaults to undefined|
|
|
380
512
|
| **end** | [**string**] | End of date range to filter when orders were placed | (optional) defaults to undefined|
|
|
381
513
|
| **dateFilterType** | [**'createdAt' | 'updatedAt' | 'statusChangedAt'**]**Array<'createdAt' | 'updatedAt' | 'statusChangedAt'>** | Specifies the type of date range filter to apply. Determines which date field the `start` and `end` fields should query. | (optional) defaults to 'createdAt'|
|
|
514
|
+
| **maxOrderTotal** | [**number**] | The maximum value of the order | (optional) defaults to undefined|
|
|
515
|
+
| **minOrderTotal** | [**number**] | The minimum value of the order | (optional) defaults to undefined|
|
|
382
516
|
|
|
383
517
|
|
|
384
518
|
### Return type
|
package/index.ts
CHANGED