@skyiro/sky-client 0.1.26 → 0.1.28
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/dist/accounts-client.d.ts +4 -1
- package/dist/accounts-client.js +37 -6
- package/dist/accounts-client.js.map +1 -1
- package/dist/types.d.ts +48 -4
- package/dist/types.js.map +1 -1
- package/package.json +1 -1
- package/proto/accounts.proto +59 -5
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { LicenseCheckRequest, LicenseCheckResponse, MfaSessionRequest, MfaSessionResponse, OAuthCodeExchangeRequest, OAuthCodeExchangeResponse, UpdateOrganizationRequest, UpdateOrganizationResponse, OrganizationGetRequest, OrganizationGetResponse, UserCreateRequest, UserCreateResponse, UserDeleteRequest, UserDeleteResponse, UserGetResponse, UserUpdateRequest, UserUpdateResponse, IssueTokenRequest, IssueTokenResponse, SetUserProductAccessRequest, SetUserProductAccessResponse, ResendOnboardingMailRequest, ResendOnboardingMailResponse } from "./types";
|
|
1
|
+
import { LicenseCheckRequest, LicenseCheckResponse, MfaSessionRequest, MfaSessionResponse, OAuthCodeExchangeRequest, OAuthCodeExchangeResponse, UpdateOrganizationRequest, UpdateOrganizationResponse, OrganizationGetRequest, OrganizationGetResponse, UserCreateRequest, UserCreateResponse, UserDeleteRequest, UserDeleteResponse, UserGetResponse, UserUpdateRequest, UserUpdateResponse, IssueTokenRequest, IssueTokenResponse, SetUserProductAccessRequest, SetUserProductAccessResponse, ResendOnboardingMailRequest, ResendOnboardingMailResponse, UserFeaturesRequest, UserFeaturesResponse, UserFeatureVersionRequest, UserFeatureVersionResponse, OrgSubscriptionRequest, OrgSubscriptionResponse } from "./types";
|
|
2
2
|
import { ProductKey } from "./enums";
|
|
3
3
|
export declare class AccountClient {
|
|
4
4
|
private readonly client;
|
|
@@ -17,4 +17,7 @@ export declare class AccountClient {
|
|
|
17
17
|
issueToken(data: IssueTokenRequest): Promise<IssueTokenResponse>;
|
|
18
18
|
setUserProductAccess(data: SetUserProductAccessRequest): Promise<SetUserProductAccessResponse>;
|
|
19
19
|
resendOnboardingMail(data: ResendOnboardingMailRequest): Promise<ResendOnboardingMailResponse>;
|
|
20
|
+
getUserFeatures(data: UserFeaturesRequest): Promise<UserFeaturesResponse>;
|
|
21
|
+
getUserFeatureVersion(data: UserFeatureVersionRequest): Promise<UserFeatureVersionResponse>;
|
|
22
|
+
getOrganizationSubscription(data: OrgSubscriptionRequest): Promise<OrgSubscriptionResponse>;
|
|
20
23
|
}
|
package/dist/accounts-client.js
CHANGED
|
@@ -38,7 +38,7 @@ class AccountClient {
|
|
|
38
38
|
}
|
|
39
39
|
createUser(data) {
|
|
40
40
|
const productKey = data.productKey;
|
|
41
|
-
const { firstName, organizationId, lastName, middleName, countryCode, email, phone, orgRole, personalEmail, designation, location, timezone, language, status,
|
|
41
|
+
const { firstName, organizationId, lastName, middleName, countryCode, email, phone, orgRole, personalEmail, designation, location, timezone, language, status, imagePath, } = data;
|
|
42
42
|
const grpcReq = {
|
|
43
43
|
firstName,
|
|
44
44
|
productKey,
|
|
@@ -55,8 +55,7 @@ class AccountClient {
|
|
|
55
55
|
timezone,
|
|
56
56
|
language,
|
|
57
57
|
status,
|
|
58
|
-
|
|
59
|
-
bannerPhotoUploaderId,
|
|
58
|
+
imagePath,
|
|
60
59
|
};
|
|
61
60
|
return new Promise((resolvePromise, rejectPromise) => {
|
|
62
61
|
this.client.createUser(grpcReq, (error, response) => {
|
|
@@ -70,7 +69,7 @@ class AccountClient {
|
|
|
70
69
|
}
|
|
71
70
|
updateUser(data) {
|
|
72
71
|
const productKey = data.productKey;
|
|
73
|
-
const { id, organizationId, firstName, lastName, middleName, password, orgRole, email, phone, designation, location, timezone, language, status,
|
|
72
|
+
const { id, organizationId, firstName, lastName, middleName, password, orgRole, email, phone, designation, location, timezone, language, status, imagePath, removeProfilePhoto, } = data;
|
|
74
73
|
const grpcReq = {
|
|
75
74
|
id,
|
|
76
75
|
organizationId,
|
|
@@ -87,8 +86,7 @@ class AccountClient {
|
|
|
87
86
|
timezone,
|
|
88
87
|
language,
|
|
89
88
|
status,
|
|
90
|
-
|
|
91
|
-
bannerPhotoUploaderId,
|
|
89
|
+
imagePath,
|
|
92
90
|
removeProfilePhoto,
|
|
93
91
|
};
|
|
94
92
|
return new Promise((resolvePromise, rejectPromise) => {
|
|
@@ -258,6 +256,39 @@ class AccountClient {
|
|
|
258
256
|
});
|
|
259
257
|
});
|
|
260
258
|
}
|
|
259
|
+
getUserFeatures(data) {
|
|
260
|
+
return new Promise((resolvePromise, rejectPromise) => {
|
|
261
|
+
this.client.getUserFeatures(data, (error, response) => {
|
|
262
|
+
if (error) {
|
|
263
|
+
rejectPromise(error);
|
|
264
|
+
return;
|
|
265
|
+
}
|
|
266
|
+
resolvePromise(response);
|
|
267
|
+
});
|
|
268
|
+
});
|
|
269
|
+
}
|
|
270
|
+
getUserFeatureVersion(data) {
|
|
271
|
+
return new Promise((resolvePromise, rejectPromise) => {
|
|
272
|
+
this.client.getUserFeatureVersion(data, (error, response) => {
|
|
273
|
+
if (error) {
|
|
274
|
+
rejectPromise(error);
|
|
275
|
+
return;
|
|
276
|
+
}
|
|
277
|
+
resolvePromise(response);
|
|
278
|
+
});
|
|
279
|
+
});
|
|
280
|
+
}
|
|
281
|
+
getOrganizationSubscription(data) {
|
|
282
|
+
return new Promise((resolvePromise, rejectPromise) => {
|
|
283
|
+
this.client.getOrganizationSubscription(data, (error, response) => {
|
|
284
|
+
if (error) {
|
|
285
|
+
rejectPromise(error);
|
|
286
|
+
return;
|
|
287
|
+
}
|
|
288
|
+
resolvePromise(response);
|
|
289
|
+
});
|
|
290
|
+
});
|
|
291
|
+
}
|
|
261
292
|
}
|
|
262
293
|
exports.AccountClient = AccountClient;
|
|
263
294
|
//# sourceMappingURL=accounts-client.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"accounts-client.js","sourceRoot":"","sources":["../src/accounts-client.ts"],"names":[],"mappings":";;;AAA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AC,qBAAqB,CAAC,IAAI,EAAE,CAAC,KAAK,EAAE,QAAQ,EAAE,EAAE;gBAC1D,IAAI,KAAK,EAAE,CAAC;oBACV,aAAa,CAAC,KAAK,CAAC,CAAC;oBACrB,OAAO;gBACT,CAAC;gBACD,cAAc,CAAC,QAAQ,CAAC,CAAC;YAC3B,CAAC,CAAC,CAAC;QACL,CAAC,CAAC,CAAC;IACL,CAAC;IAED,2BAA2B,CACzB,IAA4B;QAE5B,OAAO,IAAI,OAAO,CAAC,CAAC,cAAc,EAAE,aAAa,EAAE,EAAE;YACnD,IAAI,CAAC,MAAM,CAAC,2BAA2B,CAAC,IAAI,EAAE,CAAC,KAAK,EAAE,QAAQ,EAAE,EAAE;gBAChE,IAAI,KAAK,EAAE,CAAC;oBACV,aAAa,CAAC,KAAK,CAAC,CAAC;oBACrB,OAAO;gBACT,CAAC;gBACD,cAAc,CAAC,QAAQ,CAAC,CAAC;YAC3B,CAAC,CAAC,CAAC;QACL,CAAC,CAAC,CAAC;IACL,CAAC;CACF;AA3WD,sCA2WC"}
|
package/dist/types.d.ts
CHANGED
|
@@ -94,8 +94,7 @@ export type UserCreateRequest = {
|
|
|
94
94
|
timezone?: string;
|
|
95
95
|
language?: string;
|
|
96
96
|
status?: string;
|
|
97
|
-
|
|
98
|
-
bannerPhotoUploaderId?: string;
|
|
97
|
+
imagePath?: string;
|
|
99
98
|
};
|
|
100
99
|
export type UserCreateResponse = {
|
|
101
100
|
id: string;
|
|
@@ -116,8 +115,7 @@ export type UserUpdateRequest = {
|
|
|
116
115
|
timezone?: string;
|
|
117
116
|
language?: string;
|
|
118
117
|
status?: string;
|
|
119
|
-
|
|
120
|
-
bannerPhotoUploaderId?: string;
|
|
118
|
+
imagePath?: string;
|
|
121
119
|
removeProfilePhoto?: boolean;
|
|
122
120
|
};
|
|
123
121
|
export type UserUpdateResponse = {
|
|
@@ -227,3 +225,49 @@ export type ResendOnboardingMailRequest = {
|
|
|
227
225
|
export type ResendOnboardingMailResponse = {
|
|
228
226
|
isSuccess: boolean;
|
|
229
227
|
};
|
|
228
|
+
export type UserFeaturesRequest = {
|
|
229
|
+
organizationId: string;
|
|
230
|
+
userId: string;
|
|
231
|
+
productKey: string;
|
|
232
|
+
knownVersion?: number;
|
|
233
|
+
};
|
|
234
|
+
export type UserFeatureItem = {
|
|
235
|
+
featureKey: string;
|
|
236
|
+
isEnabled: boolean;
|
|
237
|
+
limit: number;
|
|
238
|
+
};
|
|
239
|
+
export type UserFeaturesResponse = {
|
|
240
|
+
organizationId: string;
|
|
241
|
+
userId: string;
|
|
242
|
+
productKey: string;
|
|
243
|
+
featureVersion: number;
|
|
244
|
+
features: UserFeatureItem[];
|
|
245
|
+
notModified: boolean;
|
|
246
|
+
};
|
|
247
|
+
export type UserFeatureVersionRequest = {
|
|
248
|
+
organizationId: string;
|
|
249
|
+
userId: string;
|
|
250
|
+
productKey: string;
|
|
251
|
+
};
|
|
252
|
+
export type UserFeatureVersionResponse = {
|
|
253
|
+
organizationId: string;
|
|
254
|
+
userId: string;
|
|
255
|
+
productKey: string;
|
|
256
|
+
featureVersion: number;
|
|
257
|
+
};
|
|
258
|
+
export type OrgSubscriptionRequest = {
|
|
259
|
+
organizationId: string;
|
|
260
|
+
productKey: string;
|
|
261
|
+
};
|
|
262
|
+
export type OrgSubscriptionResponse = {
|
|
263
|
+
organizationId: string;
|
|
264
|
+
subscriptionId: string;
|
|
265
|
+
planId: string;
|
|
266
|
+
planKey: string;
|
|
267
|
+
planName: string;
|
|
268
|
+
status: string;
|
|
269
|
+
maxSeats: number;
|
|
270
|
+
currentPeriodStart?: string;
|
|
271
|
+
currentPeriodEnd?: string;
|
|
272
|
+
isDefault?: boolean;
|
|
273
|
+
};
|
package/dist/types.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":";;;AAyNA,IAAY,OAKX;AALD,WAAY,OAAO;IACjB,0BAAe,CAAA;IACf,0BAAe,CAAA;IACf,wBAAa,CAAA;IACb,0BAAe,CAAA;AACjB,CAAC,EALW,OAAO,uBAAP,OAAO,QAKlB"}
|
package/package.json
CHANGED
package/proto/accounts.proto
CHANGED
|
@@ -17,6 +17,9 @@ service AccountsGrpcService {
|
|
|
17
17
|
rpc issueToken (IssueTokenRequest) returns (IssueTokenResponse);
|
|
18
18
|
rpc setUserProductAccess (SetUserProductAccessRequest) returns (SetUserProductAccessResponse);
|
|
19
19
|
rpc resendOnboardingMail (ResendOnboardingMailRequest) returns (ResendOnboardingMailResponse);
|
|
20
|
+
rpc getUserFeatures (UserFeaturesRequest) returns (UserFeaturesResponse);
|
|
21
|
+
rpc getUserFeatureVersion (UserFeatureVersionRequest) returns (UserFeatureVersionResponse);
|
|
22
|
+
rpc getOrganizationSubscription (OrgSubscriptionRequest) returns (OrgSubscriptionResponse);
|
|
20
23
|
}
|
|
21
24
|
|
|
22
25
|
enum OrganizationRole {
|
|
@@ -73,8 +76,7 @@ message UserCreateRequest {
|
|
|
73
76
|
optional string phone = 9;
|
|
74
77
|
optional string personalEmail = 10;
|
|
75
78
|
optional string designation = 11;
|
|
76
|
-
optional string
|
|
77
|
-
optional string bannerPhotoUploaderId = 13;
|
|
79
|
+
optional string imagePath = 12;
|
|
78
80
|
}
|
|
79
81
|
|
|
80
82
|
message UserUpdateRequest {
|
|
@@ -90,9 +92,8 @@ message UserUpdateRequest {
|
|
|
90
92
|
optional string phone = 10;
|
|
91
93
|
optional string designation = 11;
|
|
92
94
|
optional string status = 12;
|
|
93
|
-
optional string
|
|
94
|
-
optional
|
|
95
|
-
optional bool removeProfilePhoto = 15;
|
|
95
|
+
optional string imagePath = 13;
|
|
96
|
+
optional bool removeProfilePhoto = 14;
|
|
96
97
|
}
|
|
97
98
|
|
|
98
99
|
message UserCreateResponse {
|
|
@@ -220,3 +221,56 @@ message ResendOnboardingMailResponse {
|
|
|
220
221
|
bool isSuccess = 1;
|
|
221
222
|
}
|
|
222
223
|
|
|
224
|
+
message UserFeaturesRequest {
|
|
225
|
+
string organizationId = 1;
|
|
226
|
+
string userId = 2;
|
|
227
|
+
string productKey = 3;
|
|
228
|
+
int64 knownVersion = 4;
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
message UserFeatureItem {
|
|
232
|
+
string featureKey = 1;
|
|
233
|
+
bool isEnabled = 2;
|
|
234
|
+
int64 limit = 3;
|
|
235
|
+
}
|
|
236
|
+
|
|
237
|
+
message UserFeaturesResponse {
|
|
238
|
+
string organizationId = 1;
|
|
239
|
+
string userId = 2;
|
|
240
|
+
string productKey = 3;
|
|
241
|
+
int64 featureVersion = 4;
|
|
242
|
+
repeated UserFeatureItem features = 5; // repeated --> array of feature obects
|
|
243
|
+
bool notModified = 6;
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
message UserFeatureVersionRequest {
|
|
247
|
+
string organizationId = 1;
|
|
248
|
+
string userId = 2;
|
|
249
|
+
string productKey = 3;
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
message UserFeatureVersionResponse {
|
|
253
|
+
string organizationId = 1;
|
|
254
|
+
string userId = 2;
|
|
255
|
+
string productKey = 3;
|
|
256
|
+
int64 featureVersion = 4;
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
message OrgSubscriptionRequest {
|
|
260
|
+
string organizationId = 1;
|
|
261
|
+
string productKey = 2;
|
|
262
|
+
}
|
|
263
|
+
|
|
264
|
+
message OrgSubscriptionResponse {
|
|
265
|
+
string organizationId = 1;
|
|
266
|
+
string subscriptionId = 2;
|
|
267
|
+
string planId = 3;
|
|
268
|
+
string planKey = 4;
|
|
269
|
+
string planName = 5;
|
|
270
|
+
string status = 6;
|
|
271
|
+
int64 maxSeats = 7;
|
|
272
|
+
optional string currentPeriodStart = 8;
|
|
273
|
+
optional string currentPeriodEnd = 9;
|
|
274
|
+
optional bool isDefault = 10;
|
|
275
|
+
}
|
|
276
|
+
|