@authorizerdev/authorizer-js 2.0.0-beta.2 → 2.0.0
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 +6 -2
- package/lib/index.d.mts +3 -1
- package/lib/index.d.ts +3 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -7,9 +7,13 @@ It supports:
|
|
|
7
7
|
- [CommonJS(cjs)](https://flaviocopes.com/commonjs/) build for NodeJS version that don't support ES Modules
|
|
8
8
|
- [ESM (ES Modules)](https://hacks.mozilla.org/2018/03/es-modules-a-cartoon-deep-dive/) build for modern javascript standard, i.e. ES Modules
|
|
9
9
|
|
|
10
|
-
# Migration from 1.x -> 2.x
|
|
10
|
+
# Migration Guide from 1.x -> 2.x
|
|
11
11
|
|
|
12
|
-
`2.x` version of `@authorizerdev/authorizer-js` has a uniform response structure that will help your applications to get right error codes and success response. Methods here have `{data, errors}` as response
|
|
12
|
+
`2.x` version of `@authorizerdev/authorizer-js` has a uniform response structure that will help your applications to get right error codes and success response. Methods here have `{data, errors}` as response objects for methods of this library.
|
|
13
|
+
|
|
14
|
+
For `1.x` version of this library you can get only data in response and error would be thrown so you had to handle that in catch.
|
|
15
|
+
|
|
16
|
+
---
|
|
13
17
|
|
|
14
18
|
All the above versions require `Authorizer` instance to be instantiated and used. Instance constructor requires an object with the following keys
|
|
15
19
|
|
package/lib/index.d.mts
CHANGED
|
@@ -156,7 +156,9 @@ interface ForgotPasswordResponse {
|
|
|
156
156
|
should_show_mobile_otp_screen?: boolean;
|
|
157
157
|
}
|
|
158
158
|
interface ResetPasswordInput {
|
|
159
|
-
token
|
|
159
|
+
token?: string;
|
|
160
|
+
otp?: string;
|
|
161
|
+
phone_number?: string;
|
|
160
162
|
password: string;
|
|
161
163
|
confirm_password: string;
|
|
162
164
|
}
|
package/lib/index.d.ts
CHANGED
|
@@ -156,7 +156,9 @@ interface ForgotPasswordResponse {
|
|
|
156
156
|
should_show_mobile_otp_screen?: boolean;
|
|
157
157
|
}
|
|
158
158
|
interface ResetPasswordInput {
|
|
159
|
-
token
|
|
159
|
+
token?: string;
|
|
160
|
+
otp?: string;
|
|
161
|
+
phone_number?: string;
|
|
160
162
|
password: string;
|
|
161
163
|
confirm_password: string;
|
|
162
164
|
}
|