@flashbacktech/flashbackclient 0.2.8 → 0.2.10

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.
@@ -14,6 +14,7 @@ import { UpdateUserRoleResponse, UserRoleResponse } from './types/roles';
14
14
  import { UserProfileResponse } from './types/roles';
15
15
  import { CreateOrgUserRequest, CreateOrgUserResponse, DeleteOrgUserResponse, GetOrganizationResponse, ListOrgUsersResponse, OrgUserResponse, UpdateOrganizationBody, UpdateOrganizationResponse, UpdateOrgUserRequest, UpdateOrgUserResponse } from './types/organization';
16
16
  import { SystemEventQueryRequest, SystemEventQueryResponse } from './types/systemEvent';
17
+ import { UserUpdateRequest, UserUpdateResponse } from './types/user';
17
18
  interface ErrorResponse {
18
19
  message?: string;
19
20
  [key: string]: any;
@@ -91,6 +92,7 @@ export declare class ApiClient implements IApiClient {
91
92
  userActivate: () => Promise<ActivateResponse>;
92
93
  userDeactivate: () => Promise<DeactivateResponse>;
93
94
  getUserQuota: () => Promise<QuotaResponse>;
95
+ updateUser: (userId: string, data: UserUpdateRequest) => Promise<UserUpdateResponse>;
94
96
  requestPasswordReset: (email: string) => Promise<ActionResponse>;
95
97
  resetPassword: (data: ResetPasswordBody) => Promise<ActionResponse>;
96
98
  private validateDateRange;
@@ -231,6 +231,9 @@ class ApiClient {
231
231
  this.getUserQuota = async () => {
232
232
  return this.makeRequest('user/quota', 'GET', null);
233
233
  };
234
+ this.updateUser = async (userId, data) => {
235
+ return this.makeRequest(`user/${userId}`, 'PUT', data);
236
+ };
234
237
  this.requestPasswordReset = async (email) => {
235
238
  return this.makeRequest('user/request-reset-password', 'POST', { email });
236
239
  };
@@ -15,4 +15,5 @@ import * as WorkspaceTypes from './types/workspace';
15
15
  import * as OrganizationTypes from './types/organization';
16
16
  import * as NodeRegistrationTypes from './types/noderegistration';
17
17
  import * as SystemEventTypes from './types/systemEvent';
18
- export { ApiClient, ApiTypes, AuthTypes, StatsTypes, ApiInterfaces, HttpError, BridgeTypes, EmailTypes, QuotaTypes, SubscriptionTypes, DeviceTypes, MFATypes, SettingsTypes, RolesTypes, WorkspaceTypes, OrganizationTypes, NodeRegistrationTypes, SystemEventTypes };
18
+ import * as UserTypes from './types/user';
19
+ export { ApiClient, ApiTypes, AuthTypes, StatsTypes, ApiInterfaces, HttpError, BridgeTypes, EmailTypes, QuotaTypes, SubscriptionTypes, DeviceTypes, MFATypes, SettingsTypes, RolesTypes, WorkspaceTypes, OrganizationTypes, NodeRegistrationTypes, SystemEventTypes, UserTypes };
package/dist/api/index.js CHANGED
@@ -33,7 +33,7 @@ var __importStar = (this && this.__importStar) || (function () {
33
33
  };
34
34
  })();
35
35
  Object.defineProperty(exports, "__esModule", { value: true });
36
- exports.SystemEventTypes = exports.NodeRegistrationTypes = exports.OrganizationTypes = exports.WorkspaceTypes = exports.RolesTypes = exports.SettingsTypes = exports.MFATypes = exports.DeviceTypes = exports.SubscriptionTypes = exports.QuotaTypes = exports.EmailTypes = exports.BridgeTypes = exports.HttpError = exports.ApiInterfaces = exports.StatsTypes = exports.AuthTypes = exports.ApiTypes = exports.ApiClient = void 0;
36
+ exports.UserTypes = exports.SystemEventTypes = exports.NodeRegistrationTypes = exports.OrganizationTypes = exports.WorkspaceTypes = exports.RolesTypes = exports.SettingsTypes = exports.MFATypes = exports.DeviceTypes = exports.SubscriptionTypes = exports.QuotaTypes = exports.EmailTypes = exports.BridgeTypes = exports.HttpError = exports.ApiInterfaces = exports.StatsTypes = exports.AuthTypes = exports.ApiTypes = exports.ApiClient = void 0;
37
37
  const client_1 = require("./client");
38
38
  Object.defineProperty(exports, "ApiClient", { enumerable: true, get: function () { return client_1.ApiClient; } });
39
39
  Object.defineProperty(exports, "HttpError", { enumerable: true, get: function () { return client_1.HttpError; } });
@@ -69,3 +69,5 @@ const NodeRegistrationTypes = __importStar(require("./types/noderegistration"));
69
69
  exports.NodeRegistrationTypes = NodeRegistrationTypes;
70
70
  const SystemEventTypes = __importStar(require("./types/systemEvent"));
71
71
  exports.SystemEventTypes = SystemEventTypes;
72
+ const UserTypes = __importStar(require("./types/user"));
73
+ exports.UserTypes = UserTypes;
@@ -0,0 +1,9 @@
1
+ export interface UserUpdateRequest {
2
+ name?: string;
3
+ lastName?: string;
4
+ password?: string;
5
+ }
6
+ export interface UserUpdateResponse {
7
+ success: boolean;
8
+ message: string;
9
+ }
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@flashbacktech/flashbackclient",
3
- "version": "0.2.8",
3
+ "version": "0.2.10",
4
4
  "type": "commonjs",
5
5
  "publishConfig": {
6
6
  "access": "public"