ultracart_rest_api_v2_typescript 4.1.94 → 4.1.95
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 -2
- package/dist/apis/OauthApi.d.ts +5 -5
- package/dist/apis/OauthApi.js +5 -3
- package/package.json +1 -1
- package/src/apis/OauthApi.ts +10 -6
package/README.md
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
# UltraCart Typescript SDK
|
|
2
|
-
## ultracart_rest_api_v2_typescript@4.1.
|
|
2
|
+
## ultracart_rest_api_v2_typescript@4.1.95
|
|
3
3
|
|
|
4
4
|
Every API method call has a sample for every language SDK. See https://github.com/UltraCart/sdk_samples
|
|
5
5
|
|
|
6
6
|
Installation
|
|
7
7
|
|
|
8
8
|
```
|
|
9
|
-
npm install ultracart_rest_api_v2_typescript@4.1.
|
|
9
|
+
npm install ultracart_rest_api_v2_typescript@4.1.95 --save
|
|
10
10
|
```
|
|
11
11
|
|
|
12
12
|
```typescript
|
|
@@ -85,6 +85,7 @@ Not every change is committed to every SDK.
|
|
|
85
85
|
|
|
86
86
|
| Version | Date | Comments |
|
|
87
87
|
| --: | :-: | --- |
|
|
88
|
+
| 4.1.95 | 06/02/2026 | fraud api alpha version |
|
|
88
89
|
| 4.1.94 | 06/02/2026 | fraud api alpha version |
|
|
89
90
|
| 4.1.93 | 06/02/2026 | fraud api alpha version for testing |
|
|
90
91
|
| 4.1.92 | 05/26/2026 | AutoOrderApi.getAutoOrderCancelReasons |
|
package/dist/apis/OauthApi.d.ts
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime';
|
|
13
|
-
import { OauthRevokeSuccessResponse, OauthTokenResponse } from '../models';
|
|
13
|
+
import { OauthDeviceAuthorizationResponse, OauthRevokeSuccessResponse, OauthTokenResponse } from '../models';
|
|
14
14
|
export interface OauthAccessTokenRequest {
|
|
15
15
|
clientId: string;
|
|
16
16
|
grantType: string;
|
|
@@ -62,12 +62,12 @@ export interface OauthApiInterface {
|
|
|
62
62
|
* @throws {RequiredError}
|
|
63
63
|
* @memberof OauthApiInterface
|
|
64
64
|
*/
|
|
65
|
-
oauthDeviceAuthorizeRaw(requestParameters: OauthDeviceAuthorizeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<
|
|
65
|
+
oauthDeviceAuthorizeRaw(requestParameters: OauthDeviceAuthorizeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<OauthDeviceAuthorizationResponse>>;
|
|
66
66
|
/**
|
|
67
67
|
* Initiates the device authorization flow by returning a device code and user code. The device displays the user code to the merchant, who visits the verification URI to approve the request. RFC 8628.
|
|
68
68
|
* Initiate a device authorization flow.
|
|
69
69
|
*/
|
|
70
|
-
oauthDeviceAuthorize(requestParameters: OauthDeviceAuthorizeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<
|
|
70
|
+
oauthDeviceAuthorize(requestParameters: OauthDeviceAuthorizeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<OauthDeviceAuthorizationResponse>;
|
|
71
71
|
/**
|
|
72
72
|
* Revokes the OAuth application associated with the specified client_id and token.
|
|
73
73
|
* @summary Revoke this OAuth application.
|
|
@@ -102,12 +102,12 @@ export declare class OauthApi extends runtime.BaseAPI implements OauthApiInterfa
|
|
|
102
102
|
* Initiates the device authorization flow by returning a device code and user code. The device displays the user code to the merchant, who visits the verification URI to approve the request. RFC 8628.
|
|
103
103
|
* Initiate a device authorization flow.
|
|
104
104
|
*/
|
|
105
|
-
oauthDeviceAuthorizeRaw(requestParameters: OauthDeviceAuthorizeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<
|
|
105
|
+
oauthDeviceAuthorizeRaw(requestParameters: OauthDeviceAuthorizeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<OauthDeviceAuthorizationResponse>>;
|
|
106
106
|
/**
|
|
107
107
|
* Initiates the device authorization flow by returning a device code and user code. The device displays the user code to the merchant, who visits the verification URI to approve the request. RFC 8628.
|
|
108
108
|
* Initiate a device authorization flow.
|
|
109
109
|
*/
|
|
110
|
-
oauthDeviceAuthorize(requestParameters: OauthDeviceAuthorizeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<
|
|
110
|
+
oauthDeviceAuthorize(requestParameters: OauthDeviceAuthorizeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<OauthDeviceAuthorizationResponse>;
|
|
111
111
|
/**
|
|
112
112
|
* Revokes the OAuth application associated with the specified client_id and token.
|
|
113
113
|
* Revoke this OAuth application.
|
package/dist/apis/OauthApi.js
CHANGED
|
@@ -230,7 +230,7 @@ var OauthApi = /** @class */ (function (_super) {
|
|
|
230
230
|
}, initOverrides)];
|
|
231
231
|
case 3:
|
|
232
232
|
response = _c.sent();
|
|
233
|
-
return [2 /*return*/, new runtime.
|
|
233
|
+
return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, models_1.OauthDeviceAuthorizationResponseFromJSON)(jsonValue); })];
|
|
234
234
|
}
|
|
235
235
|
});
|
|
236
236
|
});
|
|
@@ -241,12 +241,14 @@ var OauthApi = /** @class */ (function (_super) {
|
|
|
241
241
|
*/
|
|
242
242
|
OauthApi.prototype.oauthDeviceAuthorize = function (requestParameters, initOverrides) {
|
|
243
243
|
return __awaiter(this, void 0, void 0, function () {
|
|
244
|
+
var response;
|
|
244
245
|
return __generator(this, function (_a) {
|
|
245
246
|
switch (_a.label) {
|
|
246
247
|
case 0: return [4 /*yield*/, this.oauthDeviceAuthorizeRaw(requestParameters, initOverrides)];
|
|
247
248
|
case 1:
|
|
248
|
-
_a.sent();
|
|
249
|
-
return [
|
|
249
|
+
response = _a.sent();
|
|
250
|
+
return [4 /*yield*/, response.value()];
|
|
251
|
+
case 2: return [2 /*return*/, _a.sent()];
|
|
250
252
|
}
|
|
251
253
|
});
|
|
252
254
|
});
|
package/package.json
CHANGED
package/src/apis/OauthApi.ts
CHANGED
|
@@ -18,6 +18,9 @@ import {
|
|
|
18
18
|
ErrorResponse,
|
|
19
19
|
ErrorResponseFromJSON,
|
|
20
20
|
ErrorResponseToJSON,
|
|
21
|
+
OauthDeviceAuthorizationResponse,
|
|
22
|
+
OauthDeviceAuthorizationResponseFromJSON,
|
|
23
|
+
OauthDeviceAuthorizationResponseToJSON,
|
|
21
24
|
OauthRevokeSuccessResponse,
|
|
22
25
|
OauthRevokeSuccessResponseFromJSON,
|
|
23
26
|
OauthRevokeSuccessResponseToJSON,
|
|
@@ -82,13 +85,13 @@ export interface OauthApiInterface {
|
|
|
82
85
|
* @throws {RequiredError}
|
|
83
86
|
* @memberof OauthApiInterface
|
|
84
87
|
*/
|
|
85
|
-
oauthDeviceAuthorizeRaw(requestParameters: OauthDeviceAuthorizeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<
|
|
88
|
+
oauthDeviceAuthorizeRaw(requestParameters: OauthDeviceAuthorizeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<OauthDeviceAuthorizationResponse>>;
|
|
86
89
|
|
|
87
90
|
/**
|
|
88
91
|
* Initiates the device authorization flow by returning a device code and user code. The device displays the user code to the merchant, who visits the verification URI to approve the request. RFC 8628.
|
|
89
92
|
* Initiate a device authorization flow.
|
|
90
93
|
*/
|
|
91
|
-
oauthDeviceAuthorize(requestParameters: OauthDeviceAuthorizeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<
|
|
94
|
+
oauthDeviceAuthorize(requestParameters: OauthDeviceAuthorizeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<OauthDeviceAuthorizationResponse>;
|
|
92
95
|
|
|
93
96
|
/**
|
|
94
97
|
* Revokes the OAuth application associated with the specified client_id and token.
|
|
@@ -206,7 +209,7 @@ export class OauthApi extends runtime.BaseAPI implements OauthApiInterface {
|
|
|
206
209
|
* Initiates the device authorization flow by returning a device code and user code. The device displays the user code to the merchant, who visits the verification URI to approve the request. RFC 8628.
|
|
207
210
|
* Initiate a device authorization flow.
|
|
208
211
|
*/
|
|
209
|
-
async oauthDeviceAuthorizeRaw(requestParameters: OauthDeviceAuthorizeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<
|
|
212
|
+
async oauthDeviceAuthorizeRaw(requestParameters: OauthDeviceAuthorizeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<OauthDeviceAuthorizationResponse>> {
|
|
210
213
|
if (requestParameters.clientId === null || requestParameters.clientId === undefined) {
|
|
211
214
|
throw new runtime.RequiredError('clientId','Required parameter requestParameters.clientId was null or undefined when calling oauthDeviceAuthorize.');
|
|
212
215
|
}
|
|
@@ -262,15 +265,16 @@ export class OauthApi extends runtime.BaseAPI implements OauthApiInterface {
|
|
|
262
265
|
body: formParams,
|
|
263
266
|
}, initOverrides);
|
|
264
267
|
|
|
265
|
-
return new runtime.
|
|
268
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => OauthDeviceAuthorizationResponseFromJSON(jsonValue));
|
|
266
269
|
}
|
|
267
270
|
|
|
268
271
|
/**
|
|
269
272
|
* Initiates the device authorization flow by returning a device code and user code. The device displays the user code to the merchant, who visits the verification URI to approve the request. RFC 8628.
|
|
270
273
|
* Initiate a device authorization flow.
|
|
271
274
|
*/
|
|
272
|
-
async oauthDeviceAuthorize(requestParameters: OauthDeviceAuthorizeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<
|
|
273
|
-
await this.oauthDeviceAuthorizeRaw(requestParameters, initOverrides);
|
|
275
|
+
async oauthDeviceAuthorize(requestParameters: OauthDeviceAuthorizeRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<OauthDeviceAuthorizationResponse> {
|
|
276
|
+
const response = await this.oauthDeviceAuthorizeRaw(requestParameters, initOverrides);
|
|
277
|
+
return await response.value();
|
|
274
278
|
}
|
|
275
279
|
|
|
276
280
|
/**
|