@randock/nameshift-api-client 0.0.219 → 0.0.220
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 +3 -3
- package/dist/apis/OrdersPublicApi.d.ts +13 -0
- package/dist/apis/OrdersPublicApi.js +44 -0
- package/package.json +1 -1
- package/src/apis/OrdersPublicApi.ts +38 -0
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
## @randock/nameshift-api-client@0.0.
|
|
1
|
+
## @randock/nameshift-api-client@0.0.220
|
|
2
2
|
|
|
3
3
|
This generator creates TypeScript/JavaScript client that utilizes [Fetch API](https://fetch.spec.whatwg.org/). The generated Node module can be used in the following environments:
|
|
4
4
|
|
|
@@ -36,7 +36,7 @@ navigate to the folder of your consuming project and run one of the following co
|
|
|
36
36
|
_published:_
|
|
37
37
|
|
|
38
38
|
```
|
|
39
|
-
npm install @randock/nameshift-api-client@0.0.
|
|
39
|
+
npm install @randock/nameshift-api-client@0.0.220 --save
|
|
40
40
|
```
|
|
41
41
|
|
|
42
42
|
_unPublished (not recommended):_
|
|
@@ -44,4 +44,4 @@ _unPublished (not recommended):_
|
|
|
44
44
|
```
|
|
45
45
|
npm install PATH_TO_GENERATED_PACKAGE --save
|
|
46
46
|
```
|
|
47
|
-
|
|
47
|
+
3f18e984db15c7a9cc4e2511bed2182e9aaf22f97128649c06fd921a355e2e8d0cb4c54a49301a8ec6750c1fc26b4f28
|
|
@@ -14,6 +14,9 @@ import type { CreateOrderInput, ObjectId, OrderDto, UpdateOrderInput } from '../
|
|
|
14
14
|
export interface OrdersPublicApiCreateOrderRequest {
|
|
15
15
|
createOrderInput: CreateOrderInput;
|
|
16
16
|
}
|
|
17
|
+
export interface OrdersPublicApiCreateOrderManualTransactionRequest {
|
|
18
|
+
orderId: string;
|
|
19
|
+
}
|
|
17
20
|
export interface OrdersPublicApiGetOrderRequest {
|
|
18
21
|
orderId: string;
|
|
19
22
|
}
|
|
@@ -33,6 +36,16 @@ export declare class OrdersPublicApi extends runtime.BaseAPI {
|
|
|
33
36
|
*
|
|
34
37
|
*/
|
|
35
38
|
createOrder(requestParameters: OrdersPublicApiCreateOrderRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ObjectId>;
|
|
39
|
+
/**
|
|
40
|
+
* Creates a new manual transaction for active order with specified open invoice
|
|
41
|
+
* Create a new manual transaction for order invoice
|
|
42
|
+
*/
|
|
43
|
+
createOrderManualTransactionRaw(requestParameters: OrdersPublicApiCreateOrderManualTransactionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
44
|
+
/**
|
|
45
|
+
* Creates a new manual transaction for active order with specified open invoice
|
|
46
|
+
* Create a new manual transaction for order invoice
|
|
47
|
+
*/
|
|
48
|
+
createOrderManualTransaction(requestParameters: OrdersPublicApiCreateOrderManualTransactionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
36
49
|
/**
|
|
37
50
|
*
|
|
38
51
|
*/
|
|
@@ -121,6 +121,50 @@ var OrdersPublicApi = /** @class */ (function (_super) {
|
|
|
121
121
|
});
|
|
122
122
|
});
|
|
123
123
|
};
|
|
124
|
+
/**
|
|
125
|
+
* Creates a new manual transaction for active order with specified open invoice
|
|
126
|
+
* Create a new manual transaction for order invoice
|
|
127
|
+
*/
|
|
128
|
+
OrdersPublicApi.prototype.createOrderManualTransactionRaw = function (requestParameters, initOverrides) {
|
|
129
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
130
|
+
var queryParameters, headerParameters, response;
|
|
131
|
+
return __generator(this, function (_a) {
|
|
132
|
+
switch (_a.label) {
|
|
133
|
+
case 0:
|
|
134
|
+
if (requestParameters['orderId'] == null) {
|
|
135
|
+
throw new runtime.RequiredError('orderId', 'Required parameter "orderId" was null or undefined when calling createOrderManualTransaction().');
|
|
136
|
+
}
|
|
137
|
+
queryParameters = {};
|
|
138
|
+
headerParameters = {};
|
|
139
|
+
return [4 /*yield*/, this.request({
|
|
140
|
+
path: "/orders/{orderId}/invoice/transactions".replace("{".concat("orderId", "}"), encodeURIComponent(String(requestParameters['orderId']))),
|
|
141
|
+
method: 'POST',
|
|
142
|
+
headers: headerParameters,
|
|
143
|
+
query: queryParameters,
|
|
144
|
+
}, initOverrides)];
|
|
145
|
+
case 1:
|
|
146
|
+
response = _a.sent();
|
|
147
|
+
return [2 /*return*/, new runtime.VoidApiResponse(response)];
|
|
148
|
+
}
|
|
149
|
+
});
|
|
150
|
+
});
|
|
151
|
+
};
|
|
152
|
+
/**
|
|
153
|
+
* Creates a new manual transaction for active order with specified open invoice
|
|
154
|
+
* Create a new manual transaction for order invoice
|
|
155
|
+
*/
|
|
156
|
+
OrdersPublicApi.prototype.createOrderManualTransaction = function (requestParameters, initOverrides) {
|
|
157
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
158
|
+
return __generator(this, function (_a) {
|
|
159
|
+
switch (_a.label) {
|
|
160
|
+
case 0: return [4 /*yield*/, this.createOrderManualTransactionRaw(requestParameters, initOverrides)];
|
|
161
|
+
case 1:
|
|
162
|
+
_a.sent();
|
|
163
|
+
return [2 /*return*/];
|
|
164
|
+
}
|
|
165
|
+
});
|
|
166
|
+
});
|
|
167
|
+
};
|
|
124
168
|
/**
|
|
125
169
|
*
|
|
126
170
|
*/
|
package/package.json
CHANGED
|
@@ -47,6 +47,10 @@ export interface OrdersPublicApiCreateOrderRequest {
|
|
|
47
47
|
createOrderInput: CreateOrderInput;
|
|
48
48
|
}
|
|
49
49
|
|
|
50
|
+
export interface OrdersPublicApiCreateOrderManualTransactionRequest {
|
|
51
|
+
orderId: string;
|
|
52
|
+
}
|
|
53
|
+
|
|
50
54
|
export interface OrdersPublicApiGetOrderRequest {
|
|
51
55
|
orderId: string;
|
|
52
56
|
}
|
|
@@ -97,6 +101,40 @@ export class OrdersPublicApi extends runtime.BaseAPI {
|
|
|
97
101
|
return await response.value();
|
|
98
102
|
}
|
|
99
103
|
|
|
104
|
+
/**
|
|
105
|
+
* Creates a new manual transaction for active order with specified open invoice
|
|
106
|
+
* Create a new manual transaction for order invoice
|
|
107
|
+
*/
|
|
108
|
+
async createOrderManualTransactionRaw(requestParameters: OrdersPublicApiCreateOrderManualTransactionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
|
|
109
|
+
if (requestParameters['orderId'] == null) {
|
|
110
|
+
throw new runtime.RequiredError(
|
|
111
|
+
'orderId',
|
|
112
|
+
'Required parameter "orderId" was null or undefined when calling createOrderManualTransaction().'
|
|
113
|
+
);
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
const queryParameters: any = {};
|
|
117
|
+
|
|
118
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
119
|
+
|
|
120
|
+
const response = await this.request({
|
|
121
|
+
path: `/orders/{orderId}/invoice/transactions`.replace(`{${"orderId"}}`, encodeURIComponent(String(requestParameters['orderId']))),
|
|
122
|
+
method: 'POST',
|
|
123
|
+
headers: headerParameters,
|
|
124
|
+
query: queryParameters,
|
|
125
|
+
}, initOverrides);
|
|
126
|
+
|
|
127
|
+
return new runtime.VoidApiResponse(response);
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
/**
|
|
131
|
+
* Creates a new manual transaction for active order with specified open invoice
|
|
132
|
+
* Create a new manual transaction for order invoice
|
|
133
|
+
*/
|
|
134
|
+
async createOrderManualTransaction(requestParameters: OrdersPublicApiCreateOrderManualTransactionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
|
|
135
|
+
await this.createOrderManualTransactionRaw(requestParameters, initOverrides);
|
|
136
|
+
}
|
|
137
|
+
|
|
100
138
|
/**
|
|
101
139
|
*
|
|
102
140
|
*/
|