@palmetto/users-sdk 1.8.2 → 1.8.4

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.
@@ -2151,6 +2151,7 @@ export interface operations {
2151
2151
  page?: number;
2152
2152
  limit?: number;
2153
2153
  organizationId?: string;
2154
+ email?: string;
2154
2155
  };
2155
2156
  header?: never;
2156
2157
  path?: never;
package/dist/client.d.ts CHANGED
@@ -29,6 +29,7 @@ export declare class UsersApiClient extends BaseSdkClient<paths> {
29
29
  addUserGrant({ id, ...input }: AddUserGrantInput, opts?: RequestOptions): Promise<AddUserGrantResult>;
30
30
  deleteUserGrant({ id, ...input }: DeleteUserGrantInput, opts?: RequestOptions): Promise<DeleteUserGrantResult>;
31
31
  getAuthToken({ code, skipUserVerification }: GetAuthTokenInput, opts?: RequestOptions): Promise<GetTokenResult>;
32
+ loginWithOtp({ identifier, otp, channel }: LoginWithOtpInput, opts?: RequestOptions): Promise<GetTokenResult>;
32
33
  refreshToken({ refreshToken }: RefreshTokenInput, opts?: RequestOptions): Promise<GetTokenResult>;
33
34
  private getToken;
34
35
  getOtpChannels(input: GetOtpChannelsInput, opts?: RequestOptions): Promise<GetOtpChannelsResult>;
@@ -142,6 +143,11 @@ export interface GetAuthTokenInput {
142
143
  code: string;
143
144
  skipUserVerification?: boolean;
144
145
  }
146
+ export interface LoginWithOtpInput {
147
+ identifier: string;
148
+ otp: string;
149
+ channel: "EMAIL" | "SMS";
150
+ }
145
151
  export interface RefreshTokenInput {
146
152
  refreshToken: string;
147
153
  }
package/dist/client.js CHANGED
@@ -353,6 +353,16 @@ class UsersApiClient extends base_sdk_client_1.BaseSdkClient {
353
353
  }, opts);
354
354
  });
355
355
  }
356
+ loginWithOtp(_a, opts_1) {
357
+ return __awaiter(this, arguments, void 0, function* ({ identifier, otp, channel }, opts) {
358
+ return this.getToken({
359
+ grant_type: "https://users.palmetto.com/oauth/grant-types/otp-challenge",
360
+ identifier,
361
+ otp,
362
+ channel,
363
+ }, opts);
364
+ });
365
+ }
356
366
  refreshToken(_a, opts_1) {
357
367
  return __awaiter(this, arguments, void 0, function* ({ refreshToken }, opts) {
358
368
  return this.getToken({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@palmetto/users-sdk",
3
- "version": "1.8.2",
3
+ "version": "1.8.4",
4
4
  "main": "./dist/main.js",
5
5
  "files": [
6
6
  "dist/**/*",