@randock/nameshift-api-client 0.0.40 → 0.0.41
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/.openapi-generator/FILES +2 -2
- package/README.md +3 -3
- package/dist/apis/AccountsPublicApi.d.ts +1 -46
- package/dist/apis/AccountsPublicApi.js +0 -181
- package/dist/apis/UsersPublicApi.d.ts +63 -0
- package/dist/apis/UsersPublicApi.js +261 -0
- package/dist/apis/index.d.ts +1 -0
- package/dist/apis/index.js +1 -0
- package/dist/models/LoginDto.d.ts +37 -0
- package/dist/models/LoginDto.js +51 -0
- package/dist/models/index.d.ts +1 -2
- package/dist/models/index.js +1 -2
- package/package.json +1 -1
- package/src/apis/AccountsApi.ts +0 -3
- package/src/apis/AccountsPublicApi.ts +0 -184
- package/src/apis/DomainsApi.ts +0 -3
- package/src/apis/UsersPublicApi.ts +214 -0
- package/src/apis/index.ts +1 -0
- package/src/models/{TokenDto.ts → LoginDto.ts} +18 -9
- package/src/models/index.ts +1 -2
- package/dist/models/TokenDto.d.ts +0 -31
- package/dist/models/TokenDto.js +0 -47
- package/dist/models/UnauthorizedException.d.ts +0 -43
- package/dist/models/UnauthorizedException.js +0 -55
- package/src/models/UnauthorizedException.ts +0 -79
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Nameshift
|
|
6
|
+
* Nameshift API
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.LoginDtoToJSON = exports.LoginDtoFromJSONTyped = exports.LoginDtoFromJSON = exports.instanceOfLoginDto = void 0;
|
|
17
|
+
/**
|
|
18
|
+
* Check if a given object implements the LoginDto interface.
|
|
19
|
+
*/
|
|
20
|
+
function instanceOfLoginDto(value) {
|
|
21
|
+
if (!('token' in value))
|
|
22
|
+
return false;
|
|
23
|
+
if (!('locale' in value))
|
|
24
|
+
return false;
|
|
25
|
+
return true;
|
|
26
|
+
}
|
|
27
|
+
exports.instanceOfLoginDto = instanceOfLoginDto;
|
|
28
|
+
function LoginDtoFromJSON(json) {
|
|
29
|
+
return LoginDtoFromJSONTyped(json, false);
|
|
30
|
+
}
|
|
31
|
+
exports.LoginDtoFromJSON = LoginDtoFromJSON;
|
|
32
|
+
function LoginDtoFromJSONTyped(json, ignoreDiscriminator) {
|
|
33
|
+
if (json == null) {
|
|
34
|
+
return json;
|
|
35
|
+
}
|
|
36
|
+
return {
|
|
37
|
+
'token': json['token'],
|
|
38
|
+
'locale': json['locale'],
|
|
39
|
+
};
|
|
40
|
+
}
|
|
41
|
+
exports.LoginDtoFromJSONTyped = LoginDtoFromJSONTyped;
|
|
42
|
+
function LoginDtoToJSON(value) {
|
|
43
|
+
if (value == null) {
|
|
44
|
+
return value;
|
|
45
|
+
}
|
|
46
|
+
return {
|
|
47
|
+
'token': value['token'],
|
|
48
|
+
'locale': value['locale'],
|
|
49
|
+
};
|
|
50
|
+
}
|
|
51
|
+
exports.LoginDtoToJSON = LoginDtoToJSON;
|
package/dist/models/index.d.ts
CHANGED
|
@@ -39,6 +39,7 @@ export * from './List200Response';
|
|
|
39
39
|
export * from './ListAccountDto';
|
|
40
40
|
export * from './ListAccounts200Response';
|
|
41
41
|
export * from './ListLeadMessagesDto';
|
|
42
|
+
export * from './LoginDto';
|
|
42
43
|
export * from './LoginInput';
|
|
43
44
|
export * from './MoneyDto';
|
|
44
45
|
export * from './MoneyInput';
|
|
@@ -55,8 +56,6 @@ export * from './SellerDomainTransferDomainDto';
|
|
|
55
56
|
export * from './SellerDomainTransferDto';
|
|
56
57
|
export * from './SetNewPasswordInput';
|
|
57
58
|
export * from './ThrottlerException';
|
|
58
|
-
export * from './TokenDto';
|
|
59
|
-
export * from './UnauthorizedException';
|
|
60
59
|
export * from './UpdateDomainInput';
|
|
61
60
|
export * from './UpdateDomainTransferAuthCodeInput';
|
|
62
61
|
export * from './UserPasswordResetDto';
|
package/dist/models/index.js
CHANGED
|
@@ -57,6 +57,7 @@ __exportStar(require("./List200Response"), exports);
|
|
|
57
57
|
__exportStar(require("./ListAccountDto"), exports);
|
|
58
58
|
__exportStar(require("./ListAccounts200Response"), exports);
|
|
59
59
|
__exportStar(require("./ListLeadMessagesDto"), exports);
|
|
60
|
+
__exportStar(require("./LoginDto"), exports);
|
|
60
61
|
__exportStar(require("./LoginInput"), exports);
|
|
61
62
|
__exportStar(require("./MoneyDto"), exports);
|
|
62
63
|
__exportStar(require("./MoneyInput"), exports);
|
|
@@ -73,8 +74,6 @@ __exportStar(require("./SellerDomainTransferDomainDto"), exports);
|
|
|
73
74
|
__exportStar(require("./SellerDomainTransferDto"), exports);
|
|
74
75
|
__exportStar(require("./SetNewPasswordInput"), exports);
|
|
75
76
|
__exportStar(require("./ThrottlerException"), exports);
|
|
76
|
-
__exportStar(require("./TokenDto"), exports);
|
|
77
|
-
__exportStar(require("./UnauthorizedException"), exports);
|
|
78
77
|
__exportStar(require("./UpdateDomainInput"), exports);
|
|
79
78
|
__exportStar(require("./UpdateDomainTransferAuthCodeInput"), exports);
|
|
80
79
|
__exportStar(require("./UserPasswordResetDto"), exports);
|
package/package.json
CHANGED
package/src/apis/AccountsApi.ts
CHANGED
|
@@ -20,7 +20,6 @@ import type {
|
|
|
20
20
|
AccountSettingsInput,
|
|
21
21
|
IntersectionAccountDtoWithFinancialDtoWithSettingsDtoWithAddressDto,
|
|
22
22
|
ThrottlerException,
|
|
23
|
-
UnauthorizedException,
|
|
24
23
|
ValidationException,
|
|
25
24
|
} from '../models/index';
|
|
26
25
|
import {
|
|
@@ -34,8 +33,6 @@ import {
|
|
|
34
33
|
IntersectionAccountDtoWithFinancialDtoWithSettingsDtoWithAddressDtoToJSON,
|
|
35
34
|
ThrottlerExceptionFromJSON,
|
|
36
35
|
ThrottlerExceptionToJSON,
|
|
37
|
-
UnauthorizedExceptionFromJSON,
|
|
38
|
-
UnauthorizedExceptionToJSON,
|
|
39
36
|
ValidationExceptionFromJSON,
|
|
40
37
|
ValidationExceptionToJSON,
|
|
41
38
|
} from '../models/index';
|
|
@@ -16,59 +16,21 @@
|
|
|
16
16
|
import * as runtime from '../runtime';
|
|
17
17
|
import type {
|
|
18
18
|
ConflictException,
|
|
19
|
-
ForgotPasswordRequestInput,
|
|
20
|
-
LoginInput,
|
|
21
|
-
NotFoundException,
|
|
22
19
|
RegisterAccountInput,
|
|
23
|
-
SetNewPasswordInput,
|
|
24
20
|
ThrottlerException,
|
|
25
|
-
TokenDto,
|
|
26
|
-
UnauthorizedException,
|
|
27
|
-
UserPasswordResetDto,
|
|
28
21
|
ValidationException,
|
|
29
22
|
} from '../models/index';
|
|
30
23
|
import {
|
|
31
24
|
ConflictExceptionFromJSON,
|
|
32
25
|
ConflictExceptionToJSON,
|
|
33
|
-
ForgotPasswordRequestInputFromJSON,
|
|
34
|
-
ForgotPasswordRequestInputToJSON,
|
|
35
|
-
LoginInputFromJSON,
|
|
36
|
-
LoginInputToJSON,
|
|
37
|
-
NotFoundExceptionFromJSON,
|
|
38
|
-
NotFoundExceptionToJSON,
|
|
39
26
|
RegisterAccountInputFromJSON,
|
|
40
27
|
RegisterAccountInputToJSON,
|
|
41
|
-
SetNewPasswordInputFromJSON,
|
|
42
|
-
SetNewPasswordInputToJSON,
|
|
43
28
|
ThrottlerExceptionFromJSON,
|
|
44
29
|
ThrottlerExceptionToJSON,
|
|
45
|
-
TokenDtoFromJSON,
|
|
46
|
-
TokenDtoToJSON,
|
|
47
|
-
UnauthorizedExceptionFromJSON,
|
|
48
|
-
UnauthorizedExceptionToJSON,
|
|
49
|
-
UserPasswordResetDtoFromJSON,
|
|
50
|
-
UserPasswordResetDtoToJSON,
|
|
51
30
|
ValidationExceptionFromJSON,
|
|
52
31
|
ValidationExceptionToJSON,
|
|
53
32
|
} from '../models/index';
|
|
54
33
|
|
|
55
|
-
export interface AccountsPublicApiForgotPasswordRequestRequest {
|
|
56
|
-
forgotPasswordRequestInput: ForgotPasswordRequestInput;
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
export interface AccountsPublicApiGetForgotPasswordRequestRequest {
|
|
60
|
-
passwordRequestId: string;
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
export interface AccountsPublicApiLoginRequest {
|
|
64
|
-
loginInput: LoginInput;
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
export interface AccountsPublicApiPostNewPasswordRequest {
|
|
68
|
-
passwordRequestId: string;
|
|
69
|
-
setNewPasswordInput: SetNewPasswordInput;
|
|
70
|
-
}
|
|
71
|
-
|
|
72
34
|
export interface AccountsPublicApiRegisterRequest {
|
|
73
35
|
registerAccountInput: RegisterAccountInput;
|
|
74
36
|
}
|
|
@@ -78,152 +40,6 @@ export interface AccountsPublicApiRegisterRequest {
|
|
|
78
40
|
*/
|
|
79
41
|
export class AccountsPublicApi extends runtime.BaseAPI {
|
|
80
42
|
|
|
81
|
-
/**
|
|
82
|
-
*
|
|
83
|
-
*/
|
|
84
|
-
async forgotPasswordRequestRaw(requestParameters: AccountsPublicApiForgotPasswordRequestRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
|
|
85
|
-
if (requestParameters['forgotPasswordRequestInput'] == null) {
|
|
86
|
-
throw new runtime.RequiredError(
|
|
87
|
-
'forgotPasswordRequestInput',
|
|
88
|
-
'Required parameter "forgotPasswordRequestInput" was null or undefined when calling forgotPasswordRequest().'
|
|
89
|
-
);
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
const queryParameters: any = {};
|
|
93
|
-
|
|
94
|
-
const headerParameters: runtime.HTTPHeaders = {};
|
|
95
|
-
|
|
96
|
-
headerParameters['Content-Type'] = 'application/json';
|
|
97
|
-
|
|
98
|
-
const response = await this.request({
|
|
99
|
-
path: `/accounts/forgot-password-request`,
|
|
100
|
-
method: 'POST',
|
|
101
|
-
headers: headerParameters,
|
|
102
|
-
query: queryParameters,
|
|
103
|
-
body: ForgotPasswordRequestInputToJSON(requestParameters['forgotPasswordRequestInput']),
|
|
104
|
-
}, initOverrides);
|
|
105
|
-
|
|
106
|
-
return new runtime.VoidApiResponse(response);
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
/**
|
|
110
|
-
*
|
|
111
|
-
*/
|
|
112
|
-
async forgotPasswordRequest(requestParameters: AccountsPublicApiForgotPasswordRequestRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
|
|
113
|
-
await this.forgotPasswordRequestRaw(requestParameters, initOverrides);
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
/**
|
|
117
|
-
*
|
|
118
|
-
*/
|
|
119
|
-
async getForgotPasswordRequestRaw(requestParameters: AccountsPublicApiGetForgotPasswordRequestRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<UserPasswordResetDto>> {
|
|
120
|
-
if (requestParameters['passwordRequestId'] == null) {
|
|
121
|
-
throw new runtime.RequiredError(
|
|
122
|
-
'passwordRequestId',
|
|
123
|
-
'Required parameter "passwordRequestId" was null or undefined when calling getForgotPasswordRequest().'
|
|
124
|
-
);
|
|
125
|
-
}
|
|
126
|
-
|
|
127
|
-
const queryParameters: any = {};
|
|
128
|
-
|
|
129
|
-
const headerParameters: runtime.HTTPHeaders = {};
|
|
130
|
-
|
|
131
|
-
const response = await this.request({
|
|
132
|
-
path: `/accounts/forgot-password-request/{passwordRequestId}`.replace(`{${"passwordRequestId"}}`, encodeURIComponent(String(requestParameters['passwordRequestId']))),
|
|
133
|
-
method: 'GET',
|
|
134
|
-
headers: headerParameters,
|
|
135
|
-
query: queryParameters,
|
|
136
|
-
}, initOverrides);
|
|
137
|
-
|
|
138
|
-
return new runtime.JSONApiResponse(response, (jsonValue) => UserPasswordResetDtoFromJSON(jsonValue));
|
|
139
|
-
}
|
|
140
|
-
|
|
141
|
-
/**
|
|
142
|
-
*
|
|
143
|
-
*/
|
|
144
|
-
async getForgotPasswordRequest(requestParameters: AccountsPublicApiGetForgotPasswordRequestRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<UserPasswordResetDto> {
|
|
145
|
-
const response = await this.getForgotPasswordRequestRaw(requestParameters, initOverrides);
|
|
146
|
-
return await response.value();
|
|
147
|
-
}
|
|
148
|
-
|
|
149
|
-
/**
|
|
150
|
-
*
|
|
151
|
-
*/
|
|
152
|
-
async loginRaw(requestParameters: AccountsPublicApiLoginRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<TokenDto>> {
|
|
153
|
-
if (requestParameters['loginInput'] == null) {
|
|
154
|
-
throw new runtime.RequiredError(
|
|
155
|
-
'loginInput',
|
|
156
|
-
'Required parameter "loginInput" was null or undefined when calling login().'
|
|
157
|
-
);
|
|
158
|
-
}
|
|
159
|
-
|
|
160
|
-
const queryParameters: any = {};
|
|
161
|
-
|
|
162
|
-
const headerParameters: runtime.HTTPHeaders = {};
|
|
163
|
-
|
|
164
|
-
headerParameters['Content-Type'] = 'application/json';
|
|
165
|
-
|
|
166
|
-
const response = await this.request({
|
|
167
|
-
path: `/accounts/login`,
|
|
168
|
-
method: 'POST',
|
|
169
|
-
headers: headerParameters,
|
|
170
|
-
query: queryParameters,
|
|
171
|
-
body: LoginInputToJSON(requestParameters['loginInput']),
|
|
172
|
-
}, initOverrides);
|
|
173
|
-
|
|
174
|
-
return new runtime.JSONApiResponse(response, (jsonValue) => TokenDtoFromJSON(jsonValue));
|
|
175
|
-
}
|
|
176
|
-
|
|
177
|
-
/**
|
|
178
|
-
*
|
|
179
|
-
*/
|
|
180
|
-
async login(requestParameters: AccountsPublicApiLoginRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<TokenDto> {
|
|
181
|
-
const response = await this.loginRaw(requestParameters, initOverrides);
|
|
182
|
-
return await response.value();
|
|
183
|
-
}
|
|
184
|
-
|
|
185
|
-
/**
|
|
186
|
-
*
|
|
187
|
-
*/
|
|
188
|
-
async postNewPasswordRaw(requestParameters: AccountsPublicApiPostNewPasswordRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
|
|
189
|
-
if (requestParameters['passwordRequestId'] == null) {
|
|
190
|
-
throw new runtime.RequiredError(
|
|
191
|
-
'passwordRequestId',
|
|
192
|
-
'Required parameter "passwordRequestId" was null or undefined when calling postNewPassword().'
|
|
193
|
-
);
|
|
194
|
-
}
|
|
195
|
-
|
|
196
|
-
if (requestParameters['setNewPasswordInput'] == null) {
|
|
197
|
-
throw new runtime.RequiredError(
|
|
198
|
-
'setNewPasswordInput',
|
|
199
|
-
'Required parameter "setNewPasswordInput" was null or undefined when calling postNewPassword().'
|
|
200
|
-
);
|
|
201
|
-
}
|
|
202
|
-
|
|
203
|
-
const queryParameters: any = {};
|
|
204
|
-
|
|
205
|
-
const headerParameters: runtime.HTTPHeaders = {};
|
|
206
|
-
|
|
207
|
-
headerParameters['Content-Type'] = 'application/json';
|
|
208
|
-
|
|
209
|
-
const response = await this.request({
|
|
210
|
-
path: `/accounts/forgot-password-request/{passwordRequestId}`.replace(`{${"passwordRequestId"}}`, encodeURIComponent(String(requestParameters['passwordRequestId']))),
|
|
211
|
-
method: 'POST',
|
|
212
|
-
headers: headerParameters,
|
|
213
|
-
query: queryParameters,
|
|
214
|
-
body: SetNewPasswordInputToJSON(requestParameters['setNewPasswordInput']),
|
|
215
|
-
}, initOverrides);
|
|
216
|
-
|
|
217
|
-
return new runtime.VoidApiResponse(response);
|
|
218
|
-
}
|
|
219
|
-
|
|
220
|
-
/**
|
|
221
|
-
*
|
|
222
|
-
*/
|
|
223
|
-
async postNewPassword(requestParameters: AccountsPublicApiPostNewPasswordRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
|
|
224
|
-
await this.postNewPasswordRaw(requestParameters, initOverrides);
|
|
225
|
-
}
|
|
226
|
-
|
|
227
43
|
/**
|
|
228
44
|
*
|
|
229
45
|
*/
|
package/src/apis/DomainsApi.ts
CHANGED
|
@@ -23,7 +23,6 @@ import type {
|
|
|
23
23
|
List200Response,
|
|
24
24
|
NotFoundException,
|
|
25
25
|
ThrottlerException,
|
|
26
|
-
UnauthorizedException,
|
|
27
26
|
UpdateDomainInput,
|
|
28
27
|
ValidationException,
|
|
29
28
|
} from '../models/index';
|
|
@@ -44,8 +43,6 @@ import {
|
|
|
44
43
|
NotFoundExceptionToJSON,
|
|
45
44
|
ThrottlerExceptionFromJSON,
|
|
46
45
|
ThrottlerExceptionToJSON,
|
|
47
|
-
UnauthorizedExceptionFromJSON,
|
|
48
|
-
UnauthorizedExceptionToJSON,
|
|
49
46
|
UpdateDomainInputFromJSON,
|
|
50
47
|
UpdateDomainInputToJSON,
|
|
51
48
|
ValidationExceptionFromJSON,
|
|
@@ -0,0 +1,214 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Nameshift
|
|
5
|
+
* Nameshift API
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
import * as runtime from '../runtime';
|
|
17
|
+
import type {
|
|
18
|
+
ForgotPasswordRequestInput,
|
|
19
|
+
LoginDto,
|
|
20
|
+
LoginInput,
|
|
21
|
+
NotFoundException,
|
|
22
|
+
SetNewPasswordInput,
|
|
23
|
+
ThrottlerException,
|
|
24
|
+
UserPasswordResetDto,
|
|
25
|
+
ValidationException,
|
|
26
|
+
} from '../models/index';
|
|
27
|
+
import {
|
|
28
|
+
ForgotPasswordRequestInputFromJSON,
|
|
29
|
+
ForgotPasswordRequestInputToJSON,
|
|
30
|
+
LoginDtoFromJSON,
|
|
31
|
+
LoginDtoToJSON,
|
|
32
|
+
LoginInputFromJSON,
|
|
33
|
+
LoginInputToJSON,
|
|
34
|
+
NotFoundExceptionFromJSON,
|
|
35
|
+
NotFoundExceptionToJSON,
|
|
36
|
+
SetNewPasswordInputFromJSON,
|
|
37
|
+
SetNewPasswordInputToJSON,
|
|
38
|
+
ThrottlerExceptionFromJSON,
|
|
39
|
+
ThrottlerExceptionToJSON,
|
|
40
|
+
UserPasswordResetDtoFromJSON,
|
|
41
|
+
UserPasswordResetDtoToJSON,
|
|
42
|
+
ValidationExceptionFromJSON,
|
|
43
|
+
ValidationExceptionToJSON,
|
|
44
|
+
} from '../models/index';
|
|
45
|
+
|
|
46
|
+
export interface UsersPublicApiForgotPasswordRequestRequest {
|
|
47
|
+
forgotPasswordRequestInput: ForgotPasswordRequestInput;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
export interface UsersPublicApiGetForgotPasswordRequestRequest {
|
|
51
|
+
passwordRequestId: string;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
export interface UsersPublicApiLoginRequest {
|
|
55
|
+
loginInput: LoginInput;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export interface UsersPublicApiPostNewPasswordRequest {
|
|
59
|
+
passwordRequestId: string;
|
|
60
|
+
setNewPasswordInput: SetNewPasswordInput;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
/**
|
|
64
|
+
*
|
|
65
|
+
*/
|
|
66
|
+
export class UsersPublicApi extends runtime.BaseAPI {
|
|
67
|
+
|
|
68
|
+
/**
|
|
69
|
+
*
|
|
70
|
+
*/
|
|
71
|
+
async forgotPasswordRequestRaw(requestParameters: UsersPublicApiForgotPasswordRequestRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
|
|
72
|
+
if (requestParameters['forgotPasswordRequestInput'] == null) {
|
|
73
|
+
throw new runtime.RequiredError(
|
|
74
|
+
'forgotPasswordRequestInput',
|
|
75
|
+
'Required parameter "forgotPasswordRequestInput" was null or undefined when calling forgotPasswordRequest().'
|
|
76
|
+
);
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
const queryParameters: any = {};
|
|
80
|
+
|
|
81
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
82
|
+
|
|
83
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
84
|
+
|
|
85
|
+
const response = await this.request({
|
|
86
|
+
path: `/users/forgot-password-request`,
|
|
87
|
+
method: 'POST',
|
|
88
|
+
headers: headerParameters,
|
|
89
|
+
query: queryParameters,
|
|
90
|
+
body: ForgotPasswordRequestInputToJSON(requestParameters['forgotPasswordRequestInput']),
|
|
91
|
+
}, initOverrides);
|
|
92
|
+
|
|
93
|
+
return new runtime.VoidApiResponse(response);
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
/**
|
|
97
|
+
*
|
|
98
|
+
*/
|
|
99
|
+
async forgotPasswordRequest(requestParameters: UsersPublicApiForgotPasswordRequestRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
|
|
100
|
+
await this.forgotPasswordRequestRaw(requestParameters, initOverrides);
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
/**
|
|
104
|
+
*
|
|
105
|
+
*/
|
|
106
|
+
async getForgotPasswordRequestRaw(requestParameters: UsersPublicApiGetForgotPasswordRequestRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<UserPasswordResetDto>> {
|
|
107
|
+
if (requestParameters['passwordRequestId'] == null) {
|
|
108
|
+
throw new runtime.RequiredError(
|
|
109
|
+
'passwordRequestId',
|
|
110
|
+
'Required parameter "passwordRequestId" was null or undefined when calling getForgotPasswordRequest().'
|
|
111
|
+
);
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
const queryParameters: any = {};
|
|
115
|
+
|
|
116
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
117
|
+
|
|
118
|
+
const response = await this.request({
|
|
119
|
+
path: `/users/forgot-password-request/{passwordRequestId}`.replace(`{${"passwordRequestId"}}`, encodeURIComponent(String(requestParameters['passwordRequestId']))),
|
|
120
|
+
method: 'GET',
|
|
121
|
+
headers: headerParameters,
|
|
122
|
+
query: queryParameters,
|
|
123
|
+
}, initOverrides);
|
|
124
|
+
|
|
125
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => UserPasswordResetDtoFromJSON(jsonValue));
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
/**
|
|
129
|
+
*
|
|
130
|
+
*/
|
|
131
|
+
async getForgotPasswordRequest(requestParameters: UsersPublicApiGetForgotPasswordRequestRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<UserPasswordResetDto> {
|
|
132
|
+
const response = await this.getForgotPasswordRequestRaw(requestParameters, initOverrides);
|
|
133
|
+
return await response.value();
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
/**
|
|
137
|
+
*
|
|
138
|
+
*/
|
|
139
|
+
async loginRaw(requestParameters: UsersPublicApiLoginRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<LoginDto>> {
|
|
140
|
+
if (requestParameters['loginInput'] == null) {
|
|
141
|
+
throw new runtime.RequiredError(
|
|
142
|
+
'loginInput',
|
|
143
|
+
'Required parameter "loginInput" was null or undefined when calling login().'
|
|
144
|
+
);
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
const queryParameters: any = {};
|
|
148
|
+
|
|
149
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
150
|
+
|
|
151
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
152
|
+
|
|
153
|
+
const response = await this.request({
|
|
154
|
+
path: `/users/login`,
|
|
155
|
+
method: 'POST',
|
|
156
|
+
headers: headerParameters,
|
|
157
|
+
query: queryParameters,
|
|
158
|
+
body: LoginInputToJSON(requestParameters['loginInput']),
|
|
159
|
+
}, initOverrides);
|
|
160
|
+
|
|
161
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => LoginDtoFromJSON(jsonValue));
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
/**
|
|
165
|
+
*
|
|
166
|
+
*/
|
|
167
|
+
async login(requestParameters: UsersPublicApiLoginRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<LoginDto> {
|
|
168
|
+
const response = await this.loginRaw(requestParameters, initOverrides);
|
|
169
|
+
return await response.value();
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
/**
|
|
173
|
+
*
|
|
174
|
+
*/
|
|
175
|
+
async postNewPasswordRaw(requestParameters: UsersPublicApiPostNewPasswordRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
|
|
176
|
+
if (requestParameters['passwordRequestId'] == null) {
|
|
177
|
+
throw new runtime.RequiredError(
|
|
178
|
+
'passwordRequestId',
|
|
179
|
+
'Required parameter "passwordRequestId" was null or undefined when calling postNewPassword().'
|
|
180
|
+
);
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
if (requestParameters['setNewPasswordInput'] == null) {
|
|
184
|
+
throw new runtime.RequiredError(
|
|
185
|
+
'setNewPasswordInput',
|
|
186
|
+
'Required parameter "setNewPasswordInput" was null or undefined when calling postNewPassword().'
|
|
187
|
+
);
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
const queryParameters: any = {};
|
|
191
|
+
|
|
192
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
193
|
+
|
|
194
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
195
|
+
|
|
196
|
+
const response = await this.request({
|
|
197
|
+
path: `/users/forgot-password-request/{passwordRequestId}`.replace(`{${"passwordRequestId"}}`, encodeURIComponent(String(requestParameters['passwordRequestId']))),
|
|
198
|
+
method: 'POST',
|
|
199
|
+
headers: headerParameters,
|
|
200
|
+
query: queryParameters,
|
|
201
|
+
body: SetNewPasswordInputToJSON(requestParameters['setNewPasswordInput']),
|
|
202
|
+
}, initOverrides);
|
|
203
|
+
|
|
204
|
+
return new runtime.VoidApiResponse(response);
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
/**
|
|
208
|
+
*
|
|
209
|
+
*/
|
|
210
|
+
async postNewPassword(requestParameters: UsersPublicApiPostNewPasswordRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
|
|
211
|
+
await this.postNewPasswordRaw(requestParameters, initOverrides);
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
}
|
package/src/apis/index.ts
CHANGED
|
@@ -16,46 +16,55 @@ import { mapValues } from '../runtime';
|
|
|
16
16
|
/**
|
|
17
17
|
*
|
|
18
18
|
* @export
|
|
19
|
-
* @interface
|
|
19
|
+
* @interface LoginDto
|
|
20
20
|
*/
|
|
21
|
-
export interface
|
|
21
|
+
export interface LoginDto {
|
|
22
22
|
/**
|
|
23
23
|
*
|
|
24
24
|
* @type {string}
|
|
25
|
-
* @memberof
|
|
25
|
+
* @memberof LoginDto
|
|
26
26
|
*/
|
|
27
27
|
token: string;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {string}
|
|
31
|
+
* @memberof LoginDto
|
|
32
|
+
*/
|
|
33
|
+
locale: string;
|
|
28
34
|
}
|
|
29
35
|
|
|
30
36
|
/**
|
|
31
|
-
* Check if a given object implements the
|
|
37
|
+
* Check if a given object implements the LoginDto interface.
|
|
32
38
|
*/
|
|
33
|
-
export function
|
|
39
|
+
export function instanceOfLoginDto(value: object): boolean {
|
|
34
40
|
if (!('token' in value)) return false;
|
|
41
|
+
if (!('locale' in value)) return false;
|
|
35
42
|
return true;
|
|
36
43
|
}
|
|
37
44
|
|
|
38
|
-
export function
|
|
39
|
-
return
|
|
45
|
+
export function LoginDtoFromJSON(json: any): LoginDto {
|
|
46
|
+
return LoginDtoFromJSONTyped(json, false);
|
|
40
47
|
}
|
|
41
48
|
|
|
42
|
-
export function
|
|
49
|
+
export function LoginDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): LoginDto {
|
|
43
50
|
if (json == null) {
|
|
44
51
|
return json;
|
|
45
52
|
}
|
|
46
53
|
return {
|
|
47
54
|
|
|
48
55
|
'token': json['token'],
|
|
56
|
+
'locale': json['locale'],
|
|
49
57
|
};
|
|
50
58
|
}
|
|
51
59
|
|
|
52
|
-
export function
|
|
60
|
+
export function LoginDtoToJSON(value?: LoginDto | null): any {
|
|
53
61
|
if (value == null) {
|
|
54
62
|
return value;
|
|
55
63
|
}
|
|
56
64
|
return {
|
|
57
65
|
|
|
58
66
|
'token': value['token'],
|
|
67
|
+
'locale': value['locale'],
|
|
59
68
|
};
|
|
60
69
|
}
|
|
61
70
|
|
package/src/models/index.ts
CHANGED
|
@@ -41,6 +41,7 @@ export * from './List200Response';
|
|
|
41
41
|
export * from './ListAccountDto';
|
|
42
42
|
export * from './ListAccounts200Response';
|
|
43
43
|
export * from './ListLeadMessagesDto';
|
|
44
|
+
export * from './LoginDto';
|
|
44
45
|
export * from './LoginInput';
|
|
45
46
|
export * from './MoneyDto';
|
|
46
47
|
export * from './MoneyInput';
|
|
@@ -57,8 +58,6 @@ export * from './SellerDomainTransferDomainDto';
|
|
|
57
58
|
export * from './SellerDomainTransferDto';
|
|
58
59
|
export * from './SetNewPasswordInput';
|
|
59
60
|
export * from './ThrottlerException';
|
|
60
|
-
export * from './TokenDto';
|
|
61
|
-
export * from './UnauthorizedException';
|
|
62
61
|
export * from './UpdateDomainInput';
|
|
63
62
|
export * from './UpdateDomainTransferAuthCodeInput';
|
|
64
63
|
export * from './UserPasswordResetDto';
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Nameshift
|
|
3
|
-
* Nameshift API
|
|
4
|
-
*
|
|
5
|
-
* The version of the OpenAPI document: 1.0
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
-
* https://openapi-generator.tech
|
|
10
|
-
* Do not edit the class manually.
|
|
11
|
-
*/
|
|
12
|
-
/**
|
|
13
|
-
*
|
|
14
|
-
* @export
|
|
15
|
-
* @interface TokenDto
|
|
16
|
-
*/
|
|
17
|
-
export interface TokenDto {
|
|
18
|
-
/**
|
|
19
|
-
*
|
|
20
|
-
* @type {string}
|
|
21
|
-
* @memberof TokenDto
|
|
22
|
-
*/
|
|
23
|
-
token: string;
|
|
24
|
-
}
|
|
25
|
-
/**
|
|
26
|
-
* Check if a given object implements the TokenDto interface.
|
|
27
|
-
*/
|
|
28
|
-
export declare function instanceOfTokenDto(value: object): boolean;
|
|
29
|
-
export declare function TokenDtoFromJSON(json: any): TokenDto;
|
|
30
|
-
export declare function TokenDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): TokenDto;
|
|
31
|
-
export declare function TokenDtoToJSON(value?: TokenDto | null): any;
|