@workos-inc/node 7.66.1 → 7.68.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
CHANGED
|
@@ -238,14 +238,30 @@ export interface EmailVerificationCreatedEventResponse extends EventResponseBase
|
|
|
238
238
|
event: 'email_verification.created';
|
|
239
239
|
data: EmailVerificationEventResponse;
|
|
240
240
|
}
|
|
241
|
+
export interface InvitationAcceptedEvent extends EventBase {
|
|
242
|
+
event: 'invitation.accepted';
|
|
243
|
+
data: InvitationEvent;
|
|
244
|
+
}
|
|
241
245
|
export interface InvitationCreatedEvent extends EventBase {
|
|
242
246
|
event: 'invitation.created';
|
|
243
247
|
data: InvitationEvent;
|
|
244
248
|
}
|
|
249
|
+
export interface InvitationRevokedEvent extends EventBase {
|
|
250
|
+
event: 'invitation.revoked';
|
|
251
|
+
data: InvitationEvent;
|
|
252
|
+
}
|
|
253
|
+
export interface InvitationAcceptedEventResponse extends EventResponseBase {
|
|
254
|
+
event: 'invitation.accepted';
|
|
255
|
+
data: InvitationEventResponse;
|
|
256
|
+
}
|
|
245
257
|
export interface InvitationCreatedEventResponse extends EventResponseBase {
|
|
246
258
|
event: 'invitation.created';
|
|
247
259
|
data: InvitationEventResponse;
|
|
248
260
|
}
|
|
261
|
+
export interface InvitationRevokedEventResponse extends EventResponseBase {
|
|
262
|
+
event: 'invitation.revoked';
|
|
263
|
+
data: InvitationEventResponse;
|
|
264
|
+
}
|
|
249
265
|
export interface MagicAuthCreatedEvent extends EventBase {
|
|
250
266
|
event: 'magic_auth.created';
|
|
251
267
|
data: MagicAuthEvent;
|
|
@@ -450,7 +466,7 @@ export interface OrganizationDomainDeletedEventResponse extends EventResponseBas
|
|
|
450
466
|
event: 'organization_domain.deleted';
|
|
451
467
|
data: OrganizationDomainResponse;
|
|
452
468
|
}
|
|
453
|
-
export type Event = AuthenticationEmailVerificationSucceededEvent | AuthenticationMfaSucceededEvent | AuthenticationOAuthFailedEvent | AuthenticationOAuthSucceededEvent | AuthenticationSSOFailedEvent | AuthenticationSSOSucceededEvent | AuthenticationPasswordFailedEvent | AuthenticationPasswordSucceededEvent | AuthenticationMagicAuthFailedEvent | AuthenticationMagicAuthSucceededEvent | AuthenticationRadarRiskDetectedEvent | ConnectionActivatedEvent | ConnectionDeactivatedEvent | ConnectionDeletedEvent | DsyncActivatedEvent | DsyncDeactivatedEvent | DsyncDeletedEvent | DsyncGroupCreatedEvent | DsyncGroupUpdatedEvent | DsyncGroupDeletedEvent | DsyncGroupUserAddedEvent | DsyncGroupUserRemovedEvent | DsyncUserCreatedEvent | DsyncUserUpdatedEvent | DsyncUserDeletedEvent | EmailVerificationCreatedEvent | InvitationCreatedEvent | MagicAuthCreatedEvent | PasswordResetCreatedEvent | PasswordResetSucceededEvent | UserCreatedEvent | UserUpdatedEvent | UserDeletedEvent | OrganizationMembershipAdded | OrganizationMembershipCreated | OrganizationMembershipDeleted | OrganizationMembershipUpdated | OrganizationMembershipRemoved | RoleCreatedEvent | RoleDeletedEvent | RoleUpdatedEvent | SessionCreatedEvent | SessionRevokedEvent | OrganizationCreatedEvent | OrganizationUpdatedEvent | OrganizationDeletedEvent | OrganizationDomainVerifiedEvent | OrganizationDomainVerificationFailedEvent | OrganizationDomainCreatedEvent | OrganizationDomainUpdatedEvent | OrganizationDomainDeletedEvent;
|
|
454
|
-
export type EventResponse = AuthenticationEmailVerificationSucceededEventResponse | AuthenticationMagicAuthFailedEventResponse | AuthenticationMagicAuthSucceededEventResponse | AuthenticationMfaSucceededEventResponse | AuthenticationOAuthFailedEventResponse | AuthenticationOAuthSucceededEventResponse | AuthenticationPasswordFailedEventResponse | AuthenticationPasswordSucceededEventResponse | AuthenticationSSOFailedEventResponse | AuthenticationSSOSucceededEventResponse | AuthenticationRadarRiskDetectedEventResponse | ConnectionActivatedEventResponse | ConnectionDeactivatedEventResponse | ConnectionDeletedEventResponse | DsyncActivatedEventResponse | DsyncDeactivatedEventResponse | DsyncDeletedEventResponse | DsyncGroupCreatedEventResponse | DsyncGroupUpdatedEventResponse | DsyncGroupDeletedEventResponse | DsyncGroupUserAddedEventResponse | DsyncGroupUserRemovedEventResponse | DsyncUserCreatedEventResponse | DsyncUserUpdatedEventResponse | DsyncUserDeletedEventResponse | EmailVerificationCreatedEventResponse | InvitationCreatedEventResponse | MagicAuthCreatedEventResponse | PasswordResetCreatedEventResponse | PasswordResetSucceededEventResponse | UserCreatedEventResponse | UserUpdatedEventResponse | UserDeletedEventResponse | OrganizationMembershipAddedResponse | OrganizationMembershipCreatedResponse | OrganizationMembershipDeletedResponse | OrganizationMembershipUpdatedResponse | OrganizationMembershipRemovedResponse | RoleCreatedEventResponse | RoleDeletedEventResponse | RoleUpdatedEventResponse | SessionCreatedEventResponse | SessionRevokedEventResponse | OrganizationCreatedResponse | OrganizationUpdatedResponse | OrganizationDeletedResponse | OrganizationDomainVerifiedEventResponse | OrganizationDomainVerificationFailedEventResponse | OrganizationDomainCreatedEventResponse | OrganizationDomainUpdatedEventResponse | OrganizationDomainDeletedEventResponse;
|
|
469
|
+
export type Event = AuthenticationEmailVerificationSucceededEvent | AuthenticationMfaSucceededEvent | AuthenticationOAuthFailedEvent | AuthenticationOAuthSucceededEvent | AuthenticationSSOFailedEvent | AuthenticationSSOSucceededEvent | AuthenticationPasswordFailedEvent | AuthenticationPasswordSucceededEvent | AuthenticationMagicAuthFailedEvent | AuthenticationMagicAuthSucceededEvent | AuthenticationRadarRiskDetectedEvent | ConnectionActivatedEvent | ConnectionDeactivatedEvent | ConnectionDeletedEvent | DsyncActivatedEvent | DsyncDeactivatedEvent | DsyncDeletedEvent | DsyncGroupCreatedEvent | DsyncGroupUpdatedEvent | DsyncGroupDeletedEvent | DsyncGroupUserAddedEvent | DsyncGroupUserRemovedEvent | DsyncUserCreatedEvent | DsyncUserUpdatedEvent | DsyncUserDeletedEvent | EmailVerificationCreatedEvent | InvitationAcceptedEvent | InvitationCreatedEvent | InvitationRevokedEvent | MagicAuthCreatedEvent | PasswordResetCreatedEvent | PasswordResetSucceededEvent | UserCreatedEvent | UserUpdatedEvent | UserDeletedEvent | OrganizationMembershipAdded | OrganizationMembershipCreated | OrganizationMembershipDeleted | OrganizationMembershipUpdated | OrganizationMembershipRemoved | RoleCreatedEvent | RoleDeletedEvent | RoleUpdatedEvent | SessionCreatedEvent | SessionRevokedEvent | OrganizationCreatedEvent | OrganizationUpdatedEvent | OrganizationDeletedEvent | OrganizationDomainVerifiedEvent | OrganizationDomainVerificationFailedEvent | OrganizationDomainCreatedEvent | OrganizationDomainUpdatedEvent | OrganizationDomainDeletedEvent;
|
|
470
|
+
export type EventResponse = AuthenticationEmailVerificationSucceededEventResponse | AuthenticationMagicAuthFailedEventResponse | AuthenticationMagicAuthSucceededEventResponse | AuthenticationMfaSucceededEventResponse | AuthenticationOAuthFailedEventResponse | AuthenticationOAuthSucceededEventResponse | AuthenticationPasswordFailedEventResponse | AuthenticationPasswordSucceededEventResponse | AuthenticationSSOFailedEventResponse | AuthenticationSSOSucceededEventResponse | AuthenticationRadarRiskDetectedEventResponse | ConnectionActivatedEventResponse | ConnectionDeactivatedEventResponse | ConnectionDeletedEventResponse | DsyncActivatedEventResponse | DsyncDeactivatedEventResponse | DsyncDeletedEventResponse | DsyncGroupCreatedEventResponse | DsyncGroupUpdatedEventResponse | DsyncGroupDeletedEventResponse | DsyncGroupUserAddedEventResponse | DsyncGroupUserRemovedEventResponse | DsyncUserCreatedEventResponse | DsyncUserUpdatedEventResponse | DsyncUserDeletedEventResponse | EmailVerificationCreatedEventResponse | InvitationAcceptedEventResponse | InvitationCreatedEventResponse | InvitationRevokedEventResponse | MagicAuthCreatedEventResponse | PasswordResetCreatedEventResponse | PasswordResetSucceededEventResponse | UserCreatedEventResponse | UserUpdatedEventResponse | UserDeletedEventResponse | OrganizationMembershipAddedResponse | OrganizationMembershipCreatedResponse | OrganizationMembershipDeletedResponse | OrganizationMembershipUpdatedResponse | OrganizationMembershipRemovedResponse | RoleCreatedEventResponse | RoleDeletedEventResponse | RoleUpdatedEventResponse | SessionCreatedEventResponse | SessionRevokedEventResponse | OrganizationCreatedResponse | OrganizationUpdatedResponse | OrganizationDeletedResponse | OrganizationDomainVerifiedEventResponse | OrganizationDomainVerificationFailedEventResponse | OrganizationDomainCreatedEventResponse | OrganizationDomainUpdatedEventResponse | OrganizationDomainDeletedEventResponse;
|
|
455
471
|
export type EventName = Event['event'];
|
|
456
472
|
export {};
|
|
@@ -57,7 +57,9 @@ const deserializeEvent = (event) => {
|
|
|
57
57
|
return Object.assign(Object.assign({}, eventBase), { event: event.event, data: (0, serializers_1.deserializeUpdatedEventDirectoryUser)(event.data) });
|
|
58
58
|
case 'email_verification.created':
|
|
59
59
|
return Object.assign(Object.assign({}, eventBase), { event: event.event, data: (0, serializers_4.deserializeEmailVerificationEvent)(event.data) });
|
|
60
|
+
case 'invitation.accepted':
|
|
60
61
|
case 'invitation.created':
|
|
62
|
+
case 'invitation.revoked':
|
|
61
63
|
return Object.assign(Object.assign({}, eventBase), { event: event.event, data: (0, serializers_4.deserializeInvitationEvent)(event.data) });
|
|
62
64
|
case 'magic_auth.created':
|
|
63
65
|
return Object.assign(Object.assign({}, eventBase), { event: event.event, data: (0, serializers_4.deserializeMagicAuthEvent)(event.data) });
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
export type WidgetScope = 'widgets:users-table:manage';
|
|
1
|
+
export type WidgetScope = 'widgets:users-table:manage' | 'widgets:sso:manage' | 'widgets:domain-verification:manage';
|
|
2
2
|
export interface GetTokenOptions {
|
|
3
3
|
organizationId: string;
|
|
4
|
-
userId
|
|
4
|
+
userId?: string;
|
|
5
5
|
scopes?: [WidgetScope];
|
|
6
6
|
}
|
|
7
7
|
export interface SerializedGetTokenOptions {
|
|
8
8
|
organization_id: string;
|
|
9
|
-
user_id
|
|
9
|
+
user_id?: string;
|
|
10
10
|
scopes?: [WidgetScope];
|
|
11
11
|
}
|
|
12
12
|
export declare const serializeGetTokenOptions: (options: GetTokenOptions) => SerializedGetTokenOptions;
|
package/lib/workos.js
CHANGED
|
@@ -32,7 +32,7 @@ const actions_1 = require("./actions/actions");
|
|
|
32
32
|
const vault_1 = require("./vault/vault");
|
|
33
33
|
const conflict_exception_1 = require("./common/exceptions/conflict.exception");
|
|
34
34
|
const parse_error_1 = require("./common/exceptions/parse-error");
|
|
35
|
-
const VERSION = '7.
|
|
35
|
+
const VERSION = '7.68.0';
|
|
36
36
|
const DEFAULT_HOSTNAME = 'api.workos.com';
|
|
37
37
|
const HEADER_AUTHORIZATION = 'Authorization';
|
|
38
38
|
const HEADER_IDEMPOTENCY_KEY = 'Idempotency-Key';
|
package/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "7.
|
|
2
|
+
"version": "7.68.0",
|
|
3
3
|
"name": "@workos-inc/node",
|
|
4
4
|
"author": "WorkOS",
|
|
5
5
|
"description": "A Node wrapper for the WorkOS API",
|
|
@@ -8,9 +8,6 @@
|
|
|
8
8
|
"keywords": [
|
|
9
9
|
"workos"
|
|
10
10
|
],
|
|
11
|
-
"volta": {
|
|
12
|
-
"yarn": "1.22.19"
|
|
13
|
-
},
|
|
14
11
|
"engines": {
|
|
15
12
|
"node": ">=16"
|
|
16
13
|
},
|
|
@@ -34,7 +31,7 @@
|
|
|
34
31
|
"test:worker": "jest src/worker.spec.ts",
|
|
35
32
|
"prettier": "prettier \"src/**/*.{js,ts,tsx}\" --check",
|
|
36
33
|
"format": "prettier \"src/**/*.{js,ts,tsx}\" --write",
|
|
37
|
-
"prepublishOnly": "
|
|
34
|
+
"prepublishOnly": "npm run build"
|
|
38
35
|
},
|
|
39
36
|
"dependencies": {
|
|
40
37
|
"iron-session": "~6.3.1",
|