@authsome/client 0.0.1 → 0.0.3
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/CHANGELOG.md +38 -0
- package/README.md +392 -0
- package/RELEASE_CHECKLIST.md +162 -0
- package/RELEASE_v0.0.2.md +126 -0
- package/authsome-client-0.0.2.tgz +0 -0
- package/dist/client.d.ts +65 -3
- package/dist/client.js +52 -8
- package/dist/index.d.ts +25 -25
- package/dist/index.js +78 -26
- package/dist/plugins/oidcprovider.d.ts +1 -1
- package/dist/plugins/webhook.d.ts +1 -1
- package/dist/plugins/webhook.js +4 -4
- package/dist/types.d.ts +2465 -2500
- package/package.json +3 -24
- package/src/client.ts +270 -0
- package/src/errors.ts +92 -0
- package/src/index.ts +33 -0
- package/src/plugin.ts +13 -0
- package/src/plugins/admin.ts +84 -0
- package/src/plugins/anonymous.ts +31 -0
- package/src/plugins/apikey.ts +56 -0
- package/src/plugins/backupauth.ts +208 -0
- package/src/plugins/compliance.ts +204 -0
- package/src/plugins/consent.ts +125 -0
- package/src/plugins/emailotp.ts +33 -0
- package/src/plugins/idverification.ts +80 -0
- package/src/plugins/impersonation.ts +53 -0
- package/src/plugins/jwt.ts +44 -0
- package/src/plugins/magiclink.ts +31 -0
- package/src/plugins/mfa.ts +111 -0
- package/src/plugins/multiapp.ts +116 -0
- package/src/plugins/multisession.ts +36 -0
- package/src/plugins/notification.ts +98 -0
- package/src/plugins/oidcprovider.ts +90 -0
- package/src/plugins/organization.ts +99 -0
- package/src/plugins/passkey.ts +54 -0
- package/src/plugins/phone.ts +40 -0
- package/src/plugins/social.ts +48 -0
- package/src/plugins/sso.ts +55 -0
- package/src/plugins/stepup.ts +97 -0
- package/src/plugins/twofa.ts +61 -0
- package/src/plugins/username.ts +29 -0
- package/src/plugins/webhook.ts +50 -0
- package/src/types.ts +3702 -0
- package/tsconfig.json +16 -0
package/dist/client.d.ts
CHANGED
|
@@ -1,5 +1,30 @@
|
|
|
1
1
|
import { ClientPlugin } from './plugin';
|
|
2
2
|
import * as types from './types';
|
|
3
|
+
import { MagiclinkPlugin } from './plugins/magiclink';
|
|
4
|
+
import { NotificationPlugin } from './plugins/notification';
|
|
5
|
+
import { PasskeyPlugin } from './plugins/passkey';
|
|
6
|
+
import { UsernamePlugin } from './plugins/username';
|
|
7
|
+
import { ApikeyPlugin } from './plugins/apikey';
|
|
8
|
+
import { BackupauthPlugin } from './plugins/backupauth';
|
|
9
|
+
import { ConsentPlugin } from './plugins/consent';
|
|
10
|
+
import { IdverificationPlugin } from './plugins/idverification';
|
|
11
|
+
import { MultiappPlugin } from './plugins/multiapp';
|
|
12
|
+
import { OidcproviderPlugin } from './plugins/oidcprovider';
|
|
13
|
+
import { PhonePlugin } from './plugins/phone';
|
|
14
|
+
import { AdminPlugin } from './plugins/admin';
|
|
15
|
+
import { EmailotpPlugin } from './plugins/emailotp';
|
|
16
|
+
import { MfaPlugin } from './plugins/mfa';
|
|
17
|
+
import { OrganizationPlugin } from './plugins/organization';
|
|
18
|
+
import { SocialPlugin } from './plugins/social';
|
|
19
|
+
import { SsoPlugin } from './plugins/sso';
|
|
20
|
+
import { AnonymousPlugin } from './plugins/anonymous';
|
|
21
|
+
import { StepupPlugin } from './plugins/stepup';
|
|
22
|
+
import { JwtPlugin } from './plugins/jwt';
|
|
23
|
+
import { MultisessionPlugin } from './plugins/multisession';
|
|
24
|
+
import { TwofaPlugin } from './plugins/twofa';
|
|
25
|
+
import { WebhookPlugin } from './plugins/webhook';
|
|
26
|
+
import { CompliancePlugin } from './plugins/compliance';
|
|
27
|
+
import { ImpersonationPlugin } from './plugins/impersonation';
|
|
3
28
|
/**
|
|
4
29
|
* AuthSome client configuration
|
|
5
30
|
* Supports multiple authentication methods that can be used simultaneously:
|
|
@@ -22,9 +47,12 @@ export interface AuthsomeClientConfig {
|
|
|
22
47
|
apiKeyHeader?: string;
|
|
23
48
|
/** Custom headers to include with all requests */
|
|
24
49
|
headers?: Record<string, string>;
|
|
50
|
+
/** Base path prefix for all API routes (default: '') */
|
|
51
|
+
basePath?: string;
|
|
25
52
|
}
|
|
26
53
|
export declare class AuthsomeClient {
|
|
27
54
|
private baseURL;
|
|
55
|
+
private basePath;
|
|
28
56
|
private token?;
|
|
29
57
|
private apiKey?;
|
|
30
58
|
private apiKeyHeader;
|
|
@@ -45,7 +73,41 @@ export declare class AuthsomeClient {
|
|
|
45
73
|
* WARNING: Never expose secret keys in client-side code (browser, mobile apps)
|
|
46
74
|
*/
|
|
47
75
|
setSecretKey(secretKey: string): void;
|
|
76
|
+
setBasePath(basePath: string): void;
|
|
77
|
+
/**
|
|
78
|
+
* Set global headers for all requests
|
|
79
|
+
* @param headers - Headers to set
|
|
80
|
+
* @param replace - If true, replaces all existing headers. If false (default), merges with existing headers
|
|
81
|
+
*/
|
|
82
|
+
setGlobalHeaders(headers: Record<string, string>, replace?: boolean): void;
|
|
48
83
|
getPlugin<T extends ClientPlugin>(id: string): T | undefined;
|
|
84
|
+
readonly $plugins: {
|
|
85
|
+
magiclink: () => MagiclinkPlugin | undefined;
|
|
86
|
+
notification: () => NotificationPlugin | undefined;
|
|
87
|
+
passkey: () => PasskeyPlugin | undefined;
|
|
88
|
+
username: () => UsernamePlugin | undefined;
|
|
89
|
+
apikey: () => ApikeyPlugin | undefined;
|
|
90
|
+
backupauth: () => BackupauthPlugin | undefined;
|
|
91
|
+
consent: () => ConsentPlugin | undefined;
|
|
92
|
+
idverification: () => IdverificationPlugin | undefined;
|
|
93
|
+
multiapp: () => MultiappPlugin | undefined;
|
|
94
|
+
oidcprovider: () => OidcproviderPlugin | undefined;
|
|
95
|
+
phone: () => PhonePlugin | undefined;
|
|
96
|
+
admin: () => AdminPlugin | undefined;
|
|
97
|
+
emailotp: () => EmailotpPlugin | undefined;
|
|
98
|
+
mfa: () => MfaPlugin | undefined;
|
|
99
|
+
organization: () => OrganizationPlugin | undefined;
|
|
100
|
+
social: () => SocialPlugin | undefined;
|
|
101
|
+
sso: () => SsoPlugin | undefined;
|
|
102
|
+
anonymous: () => AnonymousPlugin | undefined;
|
|
103
|
+
stepup: () => StepupPlugin | undefined;
|
|
104
|
+
jwt: () => JwtPlugin | undefined;
|
|
105
|
+
multisession: () => MultisessionPlugin | undefined;
|
|
106
|
+
twofa: () => TwofaPlugin | undefined;
|
|
107
|
+
webhook: () => WebhookPlugin | undefined;
|
|
108
|
+
compliance: () => CompliancePlugin | undefined;
|
|
109
|
+
impersonation: () => ImpersonationPlugin | undefined;
|
|
110
|
+
};
|
|
49
111
|
request<T>(method: string, path: string, options?: {
|
|
50
112
|
body?: any;
|
|
51
113
|
query?: Record<string, string>;
|
|
@@ -63,20 +125,20 @@ export declare class AuthsomeClient {
|
|
|
63
125
|
email: string;
|
|
64
126
|
password: string;
|
|
65
127
|
}): Promise<{
|
|
128
|
+
user: types.User;
|
|
66
129
|
session: types.Session;
|
|
67
130
|
requiresTwoFactor: boolean;
|
|
68
|
-
user: types.User;
|
|
69
131
|
}>;
|
|
70
132
|
signOut(): Promise<{
|
|
71
133
|
success: boolean;
|
|
72
134
|
}>;
|
|
73
135
|
getSession(): Promise<{
|
|
74
|
-
session: types.Session;
|
|
75
136
|
user: types.User;
|
|
137
|
+
session: types.Session;
|
|
76
138
|
}>;
|
|
77
139
|
updateUser(request: {
|
|
78
|
-
name?: string;
|
|
79
140
|
email?: string;
|
|
141
|
+
name?: string;
|
|
80
142
|
}): Promise<{
|
|
81
143
|
user: types.User;
|
|
82
144
|
}>;
|
package/dist/client.js
CHANGED
|
@@ -5,7 +5,35 @@ exports.AuthsomeClient = void 0;
|
|
|
5
5
|
const errors_1 = require("./errors");
|
|
6
6
|
class AuthsomeClient {
|
|
7
7
|
constructor(config) {
|
|
8
|
+
this.$plugins = {
|
|
9
|
+
magiclink: () => this.getPlugin('magiclink'),
|
|
10
|
+
notification: () => this.getPlugin('notification'),
|
|
11
|
+
passkey: () => this.getPlugin('passkey'),
|
|
12
|
+
username: () => this.getPlugin('username'),
|
|
13
|
+
apikey: () => this.getPlugin('apikey'),
|
|
14
|
+
backupauth: () => this.getPlugin('backupauth'),
|
|
15
|
+
consent: () => this.getPlugin('consent'),
|
|
16
|
+
idverification: () => this.getPlugin('idverification'),
|
|
17
|
+
multiapp: () => this.getPlugin('multiapp'),
|
|
18
|
+
oidcprovider: () => this.getPlugin('oidcprovider'),
|
|
19
|
+
phone: () => this.getPlugin('phone'),
|
|
20
|
+
admin: () => this.getPlugin('admin'),
|
|
21
|
+
emailotp: () => this.getPlugin('emailotp'),
|
|
22
|
+
mfa: () => this.getPlugin('mfa'),
|
|
23
|
+
organization: () => this.getPlugin('organization'),
|
|
24
|
+
social: () => this.getPlugin('social'),
|
|
25
|
+
sso: () => this.getPlugin('sso'),
|
|
26
|
+
anonymous: () => this.getPlugin('anonymous'),
|
|
27
|
+
stepup: () => this.getPlugin('stepup'),
|
|
28
|
+
jwt: () => this.getPlugin('jwt'),
|
|
29
|
+
multisession: () => this.getPlugin('multisession'),
|
|
30
|
+
twofa: () => this.getPlugin('twofa'),
|
|
31
|
+
webhook: () => this.getPlugin('webhook'),
|
|
32
|
+
compliance: () => this.getPlugin('compliance'),
|
|
33
|
+
impersonation: () => this.getPlugin('impersonation'),
|
|
34
|
+
};
|
|
8
35
|
this.baseURL = config.baseURL;
|
|
36
|
+
this.basePath = config.basePath || '';
|
|
9
37
|
this.token = config.token;
|
|
10
38
|
this.apiKey = config.apiKey;
|
|
11
39
|
this.apiKeyHeader = config.apiKeyHeader || 'X-API-Key';
|
|
@@ -49,11 +77,27 @@ class AuthsomeClient {
|
|
|
49
77
|
}
|
|
50
78
|
this.setApiKey(secretKey);
|
|
51
79
|
}
|
|
80
|
+
setBasePath(basePath) {
|
|
81
|
+
this.basePath = basePath;
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* Set global headers for all requests
|
|
85
|
+
* @param headers - Headers to set
|
|
86
|
+
* @param replace - If true, replaces all existing headers. If false (default), merges with existing headers
|
|
87
|
+
*/
|
|
88
|
+
setGlobalHeaders(headers, replace = false) {
|
|
89
|
+
if (replace) {
|
|
90
|
+
this.headers = { ...headers };
|
|
91
|
+
}
|
|
92
|
+
else {
|
|
93
|
+
this.headers = { ...this.headers, ...headers };
|
|
94
|
+
}
|
|
95
|
+
}
|
|
52
96
|
getPlugin(id) {
|
|
53
97
|
return this.plugins.get(id);
|
|
54
98
|
}
|
|
55
99
|
async request(method, path, options) {
|
|
56
|
-
const url = new URL(path, this.baseURL);
|
|
100
|
+
const url = new URL(this.basePath + path, this.baseURL);
|
|
57
101
|
if (options?.query) {
|
|
58
102
|
for (const [key, value] of Object.entries(options.query)) {
|
|
59
103
|
url.searchParams.append(key, value);
|
|
@@ -82,44 +126,44 @@ class AuthsomeClient {
|
|
|
82
126
|
return response.json();
|
|
83
127
|
}
|
|
84
128
|
async signUp(request) {
|
|
85
|
-
const path = '/
|
|
129
|
+
const path = '/signup';
|
|
86
130
|
return this.request('POST', path, {
|
|
87
131
|
body: request,
|
|
88
132
|
});
|
|
89
133
|
}
|
|
90
134
|
async signIn(request) {
|
|
91
|
-
const path = '/
|
|
135
|
+
const path = '/signin';
|
|
92
136
|
return this.request('POST', path, {
|
|
93
137
|
body: request,
|
|
94
138
|
});
|
|
95
139
|
}
|
|
96
140
|
async signOut() {
|
|
97
|
-
const path = '/
|
|
141
|
+
const path = '/signout';
|
|
98
142
|
return this.request('POST', path, {
|
|
99
143
|
auth: true,
|
|
100
144
|
});
|
|
101
145
|
}
|
|
102
146
|
async getSession() {
|
|
103
|
-
const path = '/
|
|
147
|
+
const path = '/session';
|
|
104
148
|
return this.request('GET', path, {
|
|
105
149
|
auth: true,
|
|
106
150
|
});
|
|
107
151
|
}
|
|
108
152
|
async updateUser(request) {
|
|
109
|
-
const path = '/
|
|
153
|
+
const path = '/user/update';
|
|
110
154
|
return this.request('POST', path, {
|
|
111
155
|
body: request,
|
|
112
156
|
auth: true,
|
|
113
157
|
});
|
|
114
158
|
}
|
|
115
159
|
async listDevices() {
|
|
116
|
-
const path = '/
|
|
160
|
+
const path = '/devices';
|
|
117
161
|
return this.request('GET', path, {
|
|
118
162
|
auth: true,
|
|
119
163
|
});
|
|
120
164
|
}
|
|
121
165
|
async revokeDevice(request) {
|
|
122
|
-
const path = '/
|
|
166
|
+
const path = '/devices/revoke';
|
|
123
167
|
return this.request('POST', path, {
|
|
124
168
|
body: request,
|
|
125
169
|
auth: true,
|
package/dist/index.d.ts
CHANGED
|
@@ -2,28 +2,28 @@ export { AuthsomeClient, AuthsomeClientConfig } from './client';
|
|
|
2
2
|
export { ClientPlugin } from './plugin';
|
|
3
3
|
export * from './types';
|
|
4
4
|
export * from './errors';
|
|
5
|
-
export
|
|
6
|
-
export
|
|
7
|
-
export
|
|
8
|
-
export
|
|
9
|
-
export
|
|
10
|
-
export
|
|
11
|
-
export
|
|
12
|
-
export
|
|
13
|
-
export
|
|
14
|
-
export
|
|
15
|
-
export
|
|
16
|
-
export
|
|
17
|
-
export
|
|
18
|
-
export
|
|
19
|
-
export
|
|
20
|
-
export
|
|
21
|
-
export
|
|
22
|
-
export
|
|
23
|
-
export
|
|
24
|
-
export
|
|
25
|
-
export
|
|
26
|
-
export
|
|
27
|
-
export
|
|
28
|
-
export
|
|
29
|
-
export
|
|
5
|
+
export { MagiclinkPlugin, magiclinkClient } from './plugins/magiclink';
|
|
6
|
+
export { NotificationPlugin, notificationClient } from './plugins/notification';
|
|
7
|
+
export { PasskeyPlugin, passkeyClient } from './plugins/passkey';
|
|
8
|
+
export { UsernamePlugin, usernameClient } from './plugins/username';
|
|
9
|
+
export { ApikeyPlugin, apikeyClient } from './plugins/apikey';
|
|
10
|
+
export { BackupauthPlugin, backupauthClient } from './plugins/backupauth';
|
|
11
|
+
export { ConsentPlugin, consentClient } from './plugins/consent';
|
|
12
|
+
export { IdverificationPlugin, idverificationClient } from './plugins/idverification';
|
|
13
|
+
export { MultiappPlugin, multiappClient } from './plugins/multiapp';
|
|
14
|
+
export { OidcproviderPlugin, oidcproviderClient } from './plugins/oidcprovider';
|
|
15
|
+
export { PhonePlugin, phoneClient } from './plugins/phone';
|
|
16
|
+
export { AdminPlugin, adminClient } from './plugins/admin';
|
|
17
|
+
export { EmailotpPlugin, emailotpClient } from './plugins/emailotp';
|
|
18
|
+
export { MfaPlugin, mfaClient } from './plugins/mfa';
|
|
19
|
+
export { OrganizationPlugin, organizationClient } from './plugins/organization';
|
|
20
|
+
export { SocialPlugin, socialClient } from './plugins/social';
|
|
21
|
+
export { SsoPlugin, ssoClient } from './plugins/sso';
|
|
22
|
+
export { AnonymousPlugin, anonymousClient } from './plugins/anonymous';
|
|
23
|
+
export { StepupPlugin, stepupClient } from './plugins/stepup';
|
|
24
|
+
export { JwtPlugin, jwtClient } from './plugins/jwt';
|
|
25
|
+
export { MultisessionPlugin, multisessionClient } from './plugins/multisession';
|
|
26
|
+
export { TwofaPlugin, twofaClient } from './plugins/twofa';
|
|
27
|
+
export { WebhookPlugin, webhookClient } from './plugins/webhook';
|
|
28
|
+
export { CompliancePlugin, complianceClient } from './plugins/compliance';
|
|
29
|
+
export { ImpersonationPlugin, impersonationClient } from './plugins/impersonation';
|
package/dist/index.js
CHANGED
|
@@ -15,33 +15,85 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
15
15
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
16
16
|
};
|
|
17
17
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
-
exports.AuthsomeClient = void 0;
|
|
18
|
+
exports.ImpersonationPlugin = exports.complianceClient = exports.CompliancePlugin = exports.webhookClient = exports.WebhookPlugin = exports.twofaClient = exports.TwofaPlugin = exports.multisessionClient = exports.MultisessionPlugin = exports.jwtClient = exports.JwtPlugin = exports.stepupClient = exports.StepupPlugin = exports.anonymousClient = exports.AnonymousPlugin = exports.ssoClient = exports.SsoPlugin = exports.socialClient = exports.SocialPlugin = exports.organizationClient = exports.OrganizationPlugin = exports.mfaClient = exports.MfaPlugin = exports.emailotpClient = exports.EmailotpPlugin = exports.adminClient = exports.AdminPlugin = exports.phoneClient = exports.PhonePlugin = exports.oidcproviderClient = exports.OidcproviderPlugin = exports.multiappClient = exports.MultiappPlugin = exports.idverificationClient = exports.IdverificationPlugin = exports.consentClient = exports.ConsentPlugin = exports.backupauthClient = exports.BackupauthPlugin = exports.apikeyClient = exports.ApikeyPlugin = exports.usernameClient = exports.UsernamePlugin = exports.passkeyClient = exports.PasskeyPlugin = exports.notificationClient = exports.NotificationPlugin = exports.magiclinkClient = exports.MagiclinkPlugin = exports.AuthsomeClient = void 0;
|
|
19
|
+
exports.impersonationClient = void 0;
|
|
19
20
|
var client_1 = require("./client");
|
|
20
21
|
Object.defineProperty(exports, "AuthsomeClient", { enumerable: true, get: function () { return client_1.AuthsomeClient; } });
|
|
21
22
|
__exportStar(require("./types"), exports);
|
|
22
23
|
__exportStar(require("./errors"), exports);
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
24
|
+
// Plugin exports
|
|
25
|
+
var magiclink_1 = require("./plugins/magiclink");
|
|
26
|
+
Object.defineProperty(exports, "MagiclinkPlugin", { enumerable: true, get: function () { return magiclink_1.MagiclinkPlugin; } });
|
|
27
|
+
Object.defineProperty(exports, "magiclinkClient", { enumerable: true, get: function () { return magiclink_1.magiclinkClient; } });
|
|
28
|
+
var notification_1 = require("./plugins/notification");
|
|
29
|
+
Object.defineProperty(exports, "NotificationPlugin", { enumerable: true, get: function () { return notification_1.NotificationPlugin; } });
|
|
30
|
+
Object.defineProperty(exports, "notificationClient", { enumerable: true, get: function () { return notification_1.notificationClient; } });
|
|
31
|
+
var passkey_1 = require("./plugins/passkey");
|
|
32
|
+
Object.defineProperty(exports, "PasskeyPlugin", { enumerable: true, get: function () { return passkey_1.PasskeyPlugin; } });
|
|
33
|
+
Object.defineProperty(exports, "passkeyClient", { enumerable: true, get: function () { return passkey_1.passkeyClient; } });
|
|
34
|
+
var username_1 = require("./plugins/username");
|
|
35
|
+
Object.defineProperty(exports, "UsernamePlugin", { enumerable: true, get: function () { return username_1.UsernamePlugin; } });
|
|
36
|
+
Object.defineProperty(exports, "usernameClient", { enumerable: true, get: function () { return username_1.usernameClient; } });
|
|
37
|
+
var apikey_1 = require("./plugins/apikey");
|
|
38
|
+
Object.defineProperty(exports, "ApikeyPlugin", { enumerable: true, get: function () { return apikey_1.ApikeyPlugin; } });
|
|
39
|
+
Object.defineProperty(exports, "apikeyClient", { enumerable: true, get: function () { return apikey_1.apikeyClient; } });
|
|
40
|
+
var backupauth_1 = require("./plugins/backupauth");
|
|
41
|
+
Object.defineProperty(exports, "BackupauthPlugin", { enumerable: true, get: function () { return backupauth_1.BackupauthPlugin; } });
|
|
42
|
+
Object.defineProperty(exports, "backupauthClient", { enumerable: true, get: function () { return backupauth_1.backupauthClient; } });
|
|
43
|
+
var consent_1 = require("./plugins/consent");
|
|
44
|
+
Object.defineProperty(exports, "ConsentPlugin", { enumerable: true, get: function () { return consent_1.ConsentPlugin; } });
|
|
45
|
+
Object.defineProperty(exports, "consentClient", { enumerable: true, get: function () { return consent_1.consentClient; } });
|
|
46
|
+
var idverification_1 = require("./plugins/idverification");
|
|
47
|
+
Object.defineProperty(exports, "IdverificationPlugin", { enumerable: true, get: function () { return idverification_1.IdverificationPlugin; } });
|
|
48
|
+
Object.defineProperty(exports, "idverificationClient", { enumerable: true, get: function () { return idverification_1.idverificationClient; } });
|
|
49
|
+
var multiapp_1 = require("./plugins/multiapp");
|
|
50
|
+
Object.defineProperty(exports, "MultiappPlugin", { enumerable: true, get: function () { return multiapp_1.MultiappPlugin; } });
|
|
51
|
+
Object.defineProperty(exports, "multiappClient", { enumerable: true, get: function () { return multiapp_1.multiappClient; } });
|
|
52
|
+
var oidcprovider_1 = require("./plugins/oidcprovider");
|
|
53
|
+
Object.defineProperty(exports, "OidcproviderPlugin", { enumerable: true, get: function () { return oidcprovider_1.OidcproviderPlugin; } });
|
|
54
|
+
Object.defineProperty(exports, "oidcproviderClient", { enumerable: true, get: function () { return oidcprovider_1.oidcproviderClient; } });
|
|
55
|
+
var phone_1 = require("./plugins/phone");
|
|
56
|
+
Object.defineProperty(exports, "PhonePlugin", { enumerable: true, get: function () { return phone_1.PhonePlugin; } });
|
|
57
|
+
Object.defineProperty(exports, "phoneClient", { enumerable: true, get: function () { return phone_1.phoneClient; } });
|
|
58
|
+
var admin_1 = require("./plugins/admin");
|
|
59
|
+
Object.defineProperty(exports, "AdminPlugin", { enumerable: true, get: function () { return admin_1.AdminPlugin; } });
|
|
60
|
+
Object.defineProperty(exports, "adminClient", { enumerable: true, get: function () { return admin_1.adminClient; } });
|
|
61
|
+
var emailotp_1 = require("./plugins/emailotp");
|
|
62
|
+
Object.defineProperty(exports, "EmailotpPlugin", { enumerable: true, get: function () { return emailotp_1.EmailotpPlugin; } });
|
|
63
|
+
Object.defineProperty(exports, "emailotpClient", { enumerable: true, get: function () { return emailotp_1.emailotpClient; } });
|
|
64
|
+
var mfa_1 = require("./plugins/mfa");
|
|
65
|
+
Object.defineProperty(exports, "MfaPlugin", { enumerable: true, get: function () { return mfa_1.MfaPlugin; } });
|
|
66
|
+
Object.defineProperty(exports, "mfaClient", { enumerable: true, get: function () { return mfa_1.mfaClient; } });
|
|
67
|
+
var organization_1 = require("./plugins/organization");
|
|
68
|
+
Object.defineProperty(exports, "OrganizationPlugin", { enumerable: true, get: function () { return organization_1.OrganizationPlugin; } });
|
|
69
|
+
Object.defineProperty(exports, "organizationClient", { enumerable: true, get: function () { return organization_1.organizationClient; } });
|
|
70
|
+
var social_1 = require("./plugins/social");
|
|
71
|
+
Object.defineProperty(exports, "SocialPlugin", { enumerable: true, get: function () { return social_1.SocialPlugin; } });
|
|
72
|
+
Object.defineProperty(exports, "socialClient", { enumerable: true, get: function () { return social_1.socialClient; } });
|
|
73
|
+
var sso_1 = require("./plugins/sso");
|
|
74
|
+
Object.defineProperty(exports, "SsoPlugin", { enumerable: true, get: function () { return sso_1.SsoPlugin; } });
|
|
75
|
+
Object.defineProperty(exports, "ssoClient", { enumerable: true, get: function () { return sso_1.ssoClient; } });
|
|
76
|
+
var anonymous_1 = require("./plugins/anonymous");
|
|
77
|
+
Object.defineProperty(exports, "AnonymousPlugin", { enumerable: true, get: function () { return anonymous_1.AnonymousPlugin; } });
|
|
78
|
+
Object.defineProperty(exports, "anonymousClient", { enumerable: true, get: function () { return anonymous_1.anonymousClient; } });
|
|
79
|
+
var stepup_1 = require("./plugins/stepup");
|
|
80
|
+
Object.defineProperty(exports, "StepupPlugin", { enumerable: true, get: function () { return stepup_1.StepupPlugin; } });
|
|
81
|
+
Object.defineProperty(exports, "stepupClient", { enumerable: true, get: function () { return stepup_1.stepupClient; } });
|
|
82
|
+
var jwt_1 = require("./plugins/jwt");
|
|
83
|
+
Object.defineProperty(exports, "JwtPlugin", { enumerable: true, get: function () { return jwt_1.JwtPlugin; } });
|
|
84
|
+
Object.defineProperty(exports, "jwtClient", { enumerable: true, get: function () { return jwt_1.jwtClient; } });
|
|
85
|
+
var multisession_1 = require("./plugins/multisession");
|
|
86
|
+
Object.defineProperty(exports, "MultisessionPlugin", { enumerable: true, get: function () { return multisession_1.MultisessionPlugin; } });
|
|
87
|
+
Object.defineProperty(exports, "multisessionClient", { enumerable: true, get: function () { return multisession_1.multisessionClient; } });
|
|
88
|
+
var twofa_1 = require("./plugins/twofa");
|
|
89
|
+
Object.defineProperty(exports, "TwofaPlugin", { enumerable: true, get: function () { return twofa_1.TwofaPlugin; } });
|
|
90
|
+
Object.defineProperty(exports, "twofaClient", { enumerable: true, get: function () { return twofa_1.twofaClient; } });
|
|
91
|
+
var webhook_1 = require("./plugins/webhook");
|
|
92
|
+
Object.defineProperty(exports, "WebhookPlugin", { enumerable: true, get: function () { return webhook_1.WebhookPlugin; } });
|
|
93
|
+
Object.defineProperty(exports, "webhookClient", { enumerable: true, get: function () { return webhook_1.webhookClient; } });
|
|
94
|
+
var compliance_1 = require("./plugins/compliance");
|
|
95
|
+
Object.defineProperty(exports, "CompliancePlugin", { enumerable: true, get: function () { return compliance_1.CompliancePlugin; } });
|
|
96
|
+
Object.defineProperty(exports, "complianceClient", { enumerable: true, get: function () { return compliance_1.complianceClient; } });
|
|
97
|
+
var impersonation_1 = require("./plugins/impersonation");
|
|
98
|
+
Object.defineProperty(exports, "ImpersonationPlugin", { enumerable: true, get: function () { return impersonation_1.ImpersonationPlugin; } });
|
|
99
|
+
Object.defineProperty(exports, "impersonationClient", { enumerable: true, get: function () { return impersonation_1.impersonationClient; } });
|
|
@@ -17,6 +17,6 @@ export declare class OidcproviderPlugin implements ClientPlugin {
|
|
|
17
17
|
token(request: types.TokenRequest): Promise<void>;
|
|
18
18
|
userInfo(): Promise<void>;
|
|
19
19
|
introspectToken(): Promise<void>;
|
|
20
|
-
revokeToken(): Promise<types.
|
|
20
|
+
revokeToken(): Promise<types.StatusResponse>;
|
|
21
21
|
}
|
|
22
22
|
export declare function oidcproviderClient(): OidcproviderPlugin;
|
package/dist/plugins/webhook.js
CHANGED
|
@@ -11,27 +11,27 @@ class WebhookPlugin {
|
|
|
11
11
|
this.client = client;
|
|
12
12
|
}
|
|
13
13
|
async create(request) {
|
|
14
|
-
const path = '/
|
|
14
|
+
const path = '/webhooks';
|
|
15
15
|
return this.client.request('POST', path, {
|
|
16
16
|
body: request,
|
|
17
17
|
auth: true,
|
|
18
18
|
});
|
|
19
19
|
}
|
|
20
20
|
async list() {
|
|
21
|
-
const path = '/
|
|
21
|
+
const path = '/webhooks';
|
|
22
22
|
return this.client.request('GET', path, {
|
|
23
23
|
auth: true,
|
|
24
24
|
});
|
|
25
25
|
}
|
|
26
26
|
async update(request) {
|
|
27
|
-
const path = '/
|
|
27
|
+
const path = '/webhooks/update';
|
|
28
28
|
return this.client.request('POST', path, {
|
|
29
29
|
body: request,
|
|
30
30
|
auth: true,
|
|
31
31
|
});
|
|
32
32
|
}
|
|
33
33
|
async delete(request) {
|
|
34
|
-
const path = '/
|
|
34
|
+
const path = '/webhooks/delete';
|
|
35
35
|
return this.client.request('POST', path, {
|
|
36
36
|
body: request,
|
|
37
37
|
auth: true,
|