@schemavaults/auth-common 0.41.3 → 0.42.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/dist/index.d.ts CHANGED
@@ -27,8 +27,8 @@ export { createAudienceSchema, createAudienceListSchema, createResourceUrlAudien
27
27
  export type { AudienceSchemaOverrides } from "./audience-schema";
28
28
  export { inviteCodeFormatSchema, inviteCodeDefinitionSchema, } from "./invite-code";
29
29
  export type { InviteCode, InviteCodeDefinition } from "./invite-code";
30
- export { organizationIdSchema, isValidOrganizationID, RESERVED_ORGANIZATION_IDS, organizationDefinitionSchema, getHardcodedOrgs, getAuthServerOwnerOrganizationId, DEFAULT_AUTH_SERVER_OWNER_ORGANIZATION_ID, getAuthServerOwnerOrganizationName, DEFAULT_AUTH_SERVER_OWNER_ORGANIZATION_NAME, MAXIMUM_USER_ORGANIZATIONS, MINIMUM_ORGANIZATION_ID_LENGTH, MAXIMUM_ORGANIZATION_ID_LENGTH, inviteMemberInputModes, inviteMemberFormSchema, assignableOrganizationMembershipRoles, assignableOrganizationMembershipRoleSchema, assignMemberFormSchema, organizationInvitationStatusTypes, organizationInvitationStatusSchema, organizationInvitationSchema, organizationMembershipRoleTypes, organizationMembershipRoleTypeSchema, isValidOrganizationMembershipRoleType, organizationMembershipRoleDetailsSchema, isValidOrganizationMembershipRoleDetails, } from "./organizations";
31
- export type { OrganizationID, OrganizationDefinition, InviteMemberInputMode, InviteMemberFormValues, InviteMemberSubmitData, AssignableOrganizationMembershipRole, AssignMemberFormValues, AssignMemberSubmitData, OrganizationInvitationStatus, OrganizationInvitation, UserPendingInvitation, OrganizationInvitationWithUserData, OrganizationMembershipRoleType, OrganizationMembershipRoleDetails, } from "./organizations";
30
+ export { organizationIdSchema, isValidOrganizationID, RESERVED_ORGANIZATION_IDS, organizationDefinitionSchema, getHardcodedOrgs, getAuthServerOwnerOrganizationId, DEFAULT_AUTH_SERVER_OWNER_ORGANIZATION_ID, getAuthServerOwnerOrganizationName, DEFAULT_AUTH_SERVER_OWNER_ORGANIZATION_NAME, MAXIMUM_USER_ORGANIZATIONS, MINIMUM_ORGANIZATION_ID_LENGTH, MAXIMUM_ORGANIZATION_ID_LENGTH, inviteMemberInputModes, inviteMemberFormSchema, assignableOrganizationMembershipRoles, assignableOrganizationMembershipRoleSchema, assignMemberFormSchema, serviceAccountOrganizationMembershipRoles, serviceAccountOrganizationMembershipRoleSchema, isServiceAccountOrganizationMembershipRole, organizationInvitationStatusTypes, organizationInvitationStatusSchema, organizationInvitationSchema, organizationMembershipRoleTypes, organizationMembershipRoleTypeSchema, isValidOrganizationMembershipRoleType, organizationMembershipRoleDetailsSchema, isValidOrganizationMembershipRoleDetails, } from "./organizations";
31
+ export type { OrganizationID, OrganizationDefinition, InviteMemberInputMode, InviteMemberFormValues, InviteMemberSubmitData, AssignableOrganizationMembershipRole, AssignMemberFormValues, AssignMemberSubmitData, ServiceAccountOrganizationMembershipRole, OrganizationInvitationStatus, OrganizationInvitation, UserPendingInvitation, OrganizationInvitationWithUserData, OrganizationMembershipRoleType, OrganizationMembershipRoleDetails, } from "./organizations";
32
32
  export { MaximumBrowserCookieSize } from "./MaximumBrowserCookieSize";
33
33
  export { RefreshTokenCookieName, RefreshTokenExpiryCookieName, } from "./RefreshTokenCookieNames";
34
34
  export { AccessTokenCookieName, AccessTokenExpiryCookieName, } from "./AccessTokenCookieNames";
package/dist/index.js CHANGED
@@ -17,7 +17,7 @@ export { getAuthServerUrl } from "@schemavaults/app-definitions";
17
17
  export { appIdSchema } from "@schemavaults/app-definitions";
18
18
  export { createAudienceSchema, createAudienceListSchema, createResourceUrlAudienceSchema, isResourceUrlAudience, RESOURCE_URL_AUDIENCE_MAX_LENGTH, } from "./audience-schema";
19
19
  export { inviteCodeFormatSchema, inviteCodeDefinitionSchema, } from "./invite-code";
20
- export { organizationIdSchema, isValidOrganizationID, RESERVED_ORGANIZATION_IDS, organizationDefinitionSchema, getHardcodedOrgs, getAuthServerOwnerOrganizationId, DEFAULT_AUTH_SERVER_OWNER_ORGANIZATION_ID, getAuthServerOwnerOrganizationName, DEFAULT_AUTH_SERVER_OWNER_ORGANIZATION_NAME, MAXIMUM_USER_ORGANIZATIONS, MINIMUM_ORGANIZATION_ID_LENGTH, MAXIMUM_ORGANIZATION_ID_LENGTH, inviteMemberInputModes, inviteMemberFormSchema, assignableOrganizationMembershipRoles, assignableOrganizationMembershipRoleSchema, assignMemberFormSchema, organizationInvitationStatusTypes, organizationInvitationStatusSchema, organizationInvitationSchema, organizationMembershipRoleTypes, organizationMembershipRoleTypeSchema, isValidOrganizationMembershipRoleType, organizationMembershipRoleDetailsSchema, isValidOrganizationMembershipRoleDetails, } from "./organizations";
20
+ export { organizationIdSchema, isValidOrganizationID, RESERVED_ORGANIZATION_IDS, organizationDefinitionSchema, getHardcodedOrgs, getAuthServerOwnerOrganizationId, DEFAULT_AUTH_SERVER_OWNER_ORGANIZATION_ID, getAuthServerOwnerOrganizationName, DEFAULT_AUTH_SERVER_OWNER_ORGANIZATION_NAME, MAXIMUM_USER_ORGANIZATIONS, MINIMUM_ORGANIZATION_ID_LENGTH, MAXIMUM_ORGANIZATION_ID_LENGTH, inviteMemberInputModes, inviteMemberFormSchema, assignableOrganizationMembershipRoles, assignableOrganizationMembershipRoleSchema, assignMemberFormSchema, serviceAccountOrganizationMembershipRoles, serviceAccountOrganizationMembershipRoleSchema, isServiceAccountOrganizationMembershipRole, organizationInvitationStatusTypes, organizationInvitationStatusSchema, organizationInvitationSchema, organizationMembershipRoleTypes, organizationMembershipRoleTypeSchema, isValidOrganizationMembershipRoleType, organizationMembershipRoleDetailsSchema, isValidOrganizationMembershipRoleDetails, } from "./organizations";
21
21
  export { MaximumBrowserCookieSize } from "./MaximumBrowserCookieSize";
22
22
  export { RefreshTokenCookieName, RefreshTokenExpiryCookieName, } from "./RefreshTokenCookieNames";
23
23
  export { AccessTokenCookieName, AccessTokenExpiryCookieName, } from "./AccessTokenCookieNames";
package/dist/index.js.map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BAA4B,EAC5B,wBAAwB,GACzB,MAAM,cAAc,CAAC;AAGtB,OAAO,EAAE,qBAAqB,EAAE,MAAM,4BAA4B,CAAC;AAEnE,OAAO,EACL,gBAAgB,EAChB,oBAAoB,GACrB,MAAM,sBAAsB,CAAC;AAE9B,OAAO,EAAE,qBAAqB,EAAE,MAAM,QAAQ,CAAC;AAE/C,OAAO,EACL,0BAA0B,EAC1B,uBAAuB,EACvB,qBAAqB,EACrB,sBAAsB,EACtB,wBAAwB,EACxB,uBAAuB,EACvB,qBAAqB,GACtB,MAAM,iBAAiB,CAAC;AAGzB,OAAO,EAAE,gCAAgC,EAAE,MAAM,UAAU,CAAC;AAE5D,OAAO,EACL,iBAAiB,EACjB,yBAAyB,EACzB,gBAAgB,EAChB,0BAA0B,GAC3B,MAAM,uBAAuB,CAAC"}
@@ -11,6 +11,8 @@ export { inviteMemberInputModes, inviteMemberFormSchema, } from "./invite_member
11
11
  export type { InviteMemberInputMode, InviteMemberFormValues, InviteMemberSubmitData, } from "./invite_member_form";
12
12
  export { assignableOrganizationMembershipRoles, assignableOrganizationMembershipRoleSchema, assignMemberFormSchema, } from "./assign_member_form";
13
13
  export type { AssignableOrganizationMembershipRole, AssignMemberFormValues, AssignMemberSubmitData, } from "./assign_member_form";
14
+ export { serviceAccountOrganizationMembershipRoles, serviceAccountOrganizationMembershipRoleSchema, isServiceAccountOrganizationMembershipRole, } from "./service_account_membership_role";
15
+ export type { ServiceAccountOrganizationMembershipRole } from "./service_account_membership_role";
14
16
  export { organizationInvitationStatusTypes, organizationInvitationStatusSchema, organizationInvitationSchema, } from "./organization_invitation";
15
17
  export type { OrganizationInvitationStatus, OrganizationInvitation, UserPendingInvitation, OrganizationInvitationWithUserData, } from "./organization_invitation";
16
18
  export { organizationMembershipRoleTypes, organizationMembershipRoleTypeSchema, isValidOrganizationMembershipRoleType, } from "./organization-membership-role-type";
@@ -6,6 +6,7 @@ export { getHardcodedOrgs } from "./hardcoded_orgs";
6
6
  export { MAXIMUM_USER_ORGANIZATIONS, MINIMUM_ORGANIZATION_ID_LENGTH, MAXIMUM_ORGANIZATION_ID_LENGTH, } from "./organization_constants";
7
7
  export { inviteMemberInputModes, inviteMemberFormSchema, } from "./invite_member_form";
8
8
  export { assignableOrganizationMembershipRoles, assignableOrganizationMembershipRoleSchema, assignMemberFormSchema, } from "./assign_member_form";
9
+ export { serviceAccountOrganizationMembershipRoles, serviceAccountOrganizationMembershipRoleSchema, isServiceAccountOrganizationMembershipRole, } from "./service_account_membership_role";
9
10
  export { organizationInvitationStatusTypes, organizationInvitationStatusSchema, organizationInvitationSchema, } from "./organization_invitation";
10
11
  export { organizationMembershipRoleTypes, organizationMembershipRoleTypeSchema, isValidOrganizationMembershipRoleType, } from "./organization-membership-role-type";
11
12
  export { organizationMembershipRoleDetailsSchema, isValidOrganizationMembershipRoleDetails, } from "./organization_membership_role_details";
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/organizations/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,oBAAoB,EACpB,qBAAqB,EACrB,yBAAyB,GAC1B,MAAM,mBAAmB,CAAC;AAG3B,OAAO,EAAE,4BAA4B,EAAE,MAAM,2BAA2B,CAAC;AAGzE,OAAO,EACL,sBAAsB,EACtB,uBAAuB,GACxB,MAAM,qBAAqB,CAAC;AAG7B,OAAO,EACL,gCAAgC,EAChC,yCAAyC,EACzC,kCAAkC,EAClC,2CAA2C,GAC5C,MAAM,+BAA+B,CAAC;AAEvC,OAAO,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;AAEpD,OAAO,EACL,0BAA0B,EAC1B,8BAA8B,EAC9B,8BAA8B,GAC/B,MAAM,0BAA0B,CAAC;AAElC,OAAO,EACL,sBAAsB,EACtB,sBAAsB,GACvB,MAAM,sBAAsB,CAAC;AAO9B,OAAO,EACL,qCAAqC,EACrC,0CAA0C,EAC1C,sBAAsB,GACvB,MAAM,sBAAsB,CAAC;AAO9B,OAAO,EACL,iCAAiC,EACjC,kCAAkC,EAClC,4BAA4B,GAC7B,MAAM,2BAA2B,CAAC;AAQnC,OAAO,EACL,+BAA+B,EAC/B,oCAAoC,EACpC,qCAAqC,GACtC,MAAM,qCAAqC,CAAC;AAG7C,OAAO,EACL,uCAAuC,EACvC,wCAAwC,GACzC,MAAM,wCAAwC,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/organizations/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,oBAAoB,EACpB,qBAAqB,EACrB,yBAAyB,GAC1B,MAAM,mBAAmB,CAAC;AAG3B,OAAO,EAAE,4BAA4B,EAAE,MAAM,2BAA2B,CAAC;AAGzE,OAAO,EACL,sBAAsB,EACtB,uBAAuB,GACxB,MAAM,qBAAqB,CAAC;AAG7B,OAAO,EACL,gCAAgC,EAChC,yCAAyC,EACzC,kCAAkC,EAClC,2CAA2C,GAC5C,MAAM,+BAA+B,CAAC;AAEvC,OAAO,EAAE,gBAAgB,EAAE,MAAM,kBAAkB,CAAC;AAEpD,OAAO,EACL,0BAA0B,EAC1B,8BAA8B,EAC9B,8BAA8B,GAC/B,MAAM,0BAA0B,CAAC;AAElC,OAAO,EACL,sBAAsB,EACtB,sBAAsB,GACvB,MAAM,sBAAsB,CAAC;AAO9B,OAAO,EACL,qCAAqC,EACrC,0CAA0C,EAC1C,sBAAsB,GACvB,MAAM,sBAAsB,CAAC;AAO9B,OAAO,EACL,yCAAyC,EACzC,8CAA8C,EAC9C,0CAA0C,GAC3C,MAAM,mCAAmC,CAAC;AAG3C,OAAO,EACL,iCAAiC,EACjC,kCAAkC,EAClC,4BAA4B,GAC7B,MAAM,2BAA2B,CAAC;AAQnC,OAAO,EACL,+BAA+B,EAC/B,oCAAoC,EACpC,qCAAqC,GACtC,MAAM,qCAAqC,CAAC;AAG7C,OAAO,EACL,uCAAuC,EACvC,wCAAwC,GACzC,MAAM,wCAAwC,CAAC"}
@@ -0,0 +1,20 @@
1
+ import { z } from "zod";
2
+ /**
3
+ * The roles the service account of an organization-owned client application
4
+ * may hold in the organization that owns the app (its virtual membership,
5
+ * `PUT /api/apps/{app_id}/service-account/organization-membership`): only
6
+ * `member`.
7
+ *
8
+ * Organization roles govern people. A service account is a machine
9
+ * credential: whoever holds the app's client secret acts as it, it cannot
10
+ * meet an organization's MFA requirement, and it is not listed among the
11
+ * organization's members. So it joins as a member only, and gets any further
12
+ * permission at a resource server from API scopes (the app's service-account
13
+ * scope allowance), which that API server's owner grants.
14
+ */
15
+ export declare const serviceAccountOrganizationMembershipRoles: readonly ["member"];
16
+ export type ServiceAccountOrganizationMembershipRole = (typeof serviceAccountOrganizationMembershipRoles)[number];
17
+ export declare const serviceAccountOrganizationMembershipRoleSchema: z.ZodEnum<{
18
+ member: "member";
19
+ }>;
20
+ export declare function isServiceAccountOrganizationMembershipRole(role: unknown): role is ServiceAccountOrganizationMembershipRole;
@@ -0,0 +1,21 @@
1
+ import { z } from "zod";
2
+ /**
3
+ * The roles the service account of an organization-owned client application
4
+ * may hold in the organization that owns the app (its virtual membership,
5
+ * `PUT /api/apps/{app_id}/service-account/organization-membership`): only
6
+ * `member`.
7
+ *
8
+ * Organization roles govern people. A service account is a machine
9
+ * credential: whoever holds the app's client secret acts as it, it cannot
10
+ * meet an organization's MFA requirement, and it is not listed among the
11
+ * organization's members. So it joins as a member only, and gets any further
12
+ * permission at a resource server from API scopes (the app's service-account
13
+ * scope allowance), which that API server's owner grants.
14
+ */
15
+ export const serviceAccountOrganizationMembershipRoles = ["member"];
16
+ export const serviceAccountOrganizationMembershipRoleSchema = z.enum(serviceAccountOrganizationMembershipRoles);
17
+ export function isServiceAccountOrganizationMembershipRole(role) {
18
+ return (typeof role === "string" &&
19
+ serviceAccountOrganizationMembershipRoles.includes(role));
20
+ }
21
+ //# sourceMappingURL=service_account_membership_role.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"service_account_membership_role.js","sourceRoot":"","sources":["../../src/organizations/service_account_membership_role.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;;;;;;;;;GAYG;AACH,MAAM,CAAC,MAAM,yCAAyC,GAAG,CAAC,QAAQ,CAAU,CAAC;AAK7E,MAAM,CAAC,MAAM,8CAA8C,GAAG,CAAC,CAAC,IAAI,CAClE,yCAAyC,CAC1C,CAAC;AAEF,MAAM,UAAU,0CAA0C,CACxD,IAAa;IAEb,OAAO,CACL,OAAO,IAAI,KAAK,QAAQ;QACvB,yCAA+D,CAAC,QAAQ,CACvE,IAAI,CACL,CACF,CAAC;AACJ,CAAC"}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@schemavaults/auth-common",
3
3
  "description": "Types and utility functions for authentication and authorization",
4
- "version": "0.41.3",
4
+ "version": "0.42.0",
5
5
  "license": "UNLICENSED",
6
6
  "private": false,
7
7
  "repository": {