@c1m-public/platform-auth 0.18.0 → 0.20.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.
@@ -1 +1 @@
1
- export { a as AccessEntry, b as AccessErrorCode, c as AccessScopeType, A as AccessSnapshot, d as AccessSnapshotError, D as DASH_PERMISSIONS, e as DASH_ROLES, f as DEFAULT_ACCESS_ENDPOINT_PATH, g as DashPermissionKey, h as DashRole, F as FetchAccessSnapshotOptions, L as LEADBROKER_PERMISSIONS, i as LeadBrokerPermissionKey, j as PIPELINE_STAGES, k as PLATFORM_PERMISSIONS, P as PermissionCheckOptions, l as PermissionKey, m as PipelineStage, n as PlatformPermissionKey, W as WORKSPACE_PERMISSIONS, o as WORKSPACE_ROLES, p as WorkspacePermissionKey, q as WorkspaceRole, r as appScopes, s as dashRole, t as emptySnapshot, u as entryCoversApp, v as fetchAccessSnapshot, w as hasAllPermissions, x as hasAnyPermission, y as hasPermission, z as hasWorkspacePermission, B as isAccessSnapshotError, C as isPipelineStage, E as isPlatformOwner, G as managedDashes, H as parseAccessSnapshot, I as permissionsFor } from '../index-DieAxYYh.js';
1
+ export { a as AccessEntry, b as AccessErrorCode, c as AccessScopeType, A as AccessSnapshot, d as AccessSnapshotError, D as DASH_PERMISSIONS, e as DASH_ROLES, f as DEFAULT_ACCESS_ENDPOINT_PATH, g as DashPermissionKey, h as DashRole, F as FetchAccessSnapshotOptions, L as LEADBROKER_PERMISSIONS, i as LeadBrokerPermissionKey, j as PIPELINE_STAGES, k as PLATFORM_PERMISSIONS, P as PermissionCheckOptions, l as PermissionKey, m as PipelineStage, n as PlatformPermissionKey, W as WORKSPACE_PERMISSIONS, o as WORKSPACE_ROLES, p as WorkspacePermissionKey, q as WorkspaceRole, r as appScopes, s as dashRole, t as emptySnapshot, u as entryCoversApp, v as fetchAccessSnapshot, w as hasAllPermissions, x as hasAnyPermission, y as hasPermission, z as hasWorkspacePermission, B as isAccessSnapshotError, C as isPipelineStage, E as isPlatformOwner, G as managedDashes, H as parseAccessSnapshot, I as permissionsFor } from '../index-DeCYIw0L.js';
@@ -16,6 +16,10 @@ var PLATFORM_PERMISSIONS = [
16
16
  "platform.billing.view",
17
17
  "platform.channels.manage",
18
18
  "platform.channels.view",
19
+ "platform.communications.content.view",
20
+ "platform.communications.manage",
21
+ "platform.communications.send",
22
+ "platform.communications.view",
19
23
  "platform.config.manage",
20
24
  "platform.dashes.archive",
21
25
  "platform.dashes.manage",
@@ -24,6 +28,8 @@ var PLATFORM_PERMISSIONS = [
24
28
  "platform.dashes.view",
25
29
  "platform.docs.manage",
26
30
  "platform.docs.view",
31
+ "platform.leads.manage",
32
+ "platform.leads.view",
27
33
  "platform.mcp.access",
28
34
  "platform.observability.manage",
29
35
  "platform.observability.view",
@@ -33,6 +39,7 @@ var PLATFORM_PERMISSIONS = [
33
39
  "platform.ownership.transfer",
34
40
  "platform.service_accounts.manage",
35
41
  "platform.service_accounts.view",
42
+ "platform.site_mode.manage",
36
43
  "platform.support.impersonate",
37
44
  "platform.support.impersonation.delegate",
38
45
  "platform.support.sessions",
@@ -100,6 +107,7 @@ var WORKSPACE_PERMISSIONS = [
100
107
  "workspace.orders.manage",
101
108
  "workspace.orders.view",
102
109
  "workspace.payments.record",
110
+ "workspace.payments.refund",
103
111
  "workspace.site.edit",
104
112
  "workspace.site.view",
105
113
  "workspace.staff.manage"
@@ -1,5 +1,5 @@
1
- import { A as AccessSnapshot, P as PermissionCheckOptions, R as Resolvable } from '../index-DieAxYYh.js';
2
- export { a as AccessEntry, b as AccessErrorCode, c as AccessScopeType, d as AccessSnapshotError, D as DASH_PERMISSIONS, e as DASH_ROLES, f as DEFAULT_ACCESS_ENDPOINT_PATH, g as DashPermissionKey, h as DashRole, F as FetchAccessSnapshotOptions, L as LEADBROKER_PERMISSIONS, i as LeadBrokerPermissionKey, j as PIPELINE_STAGES, k as PLATFORM_PERMISSIONS, l as PermissionKey, m as PipelineStage, n as PlatformPermissionKey, W as WORKSPACE_PERMISSIONS, o as WORKSPACE_ROLES, p as WorkspacePermissionKey, q as WorkspaceRole, r as appScopes, s as dashRole, t as emptySnapshot, u as entryCoversApp, v as fetchAccessSnapshot, w as hasAllPermissions, x as hasAnyPermission, y as hasPermission, z as hasWorkspacePermission, B as isAccessSnapshotError, C as isPipelineStage, E as isPlatformOwner, G as managedDashes, H as parseAccessSnapshot, I as permissionsFor } from '../index-DieAxYYh.js';
1
+ import { A as AccessSnapshot, P as PermissionCheckOptions, R as Resolvable } from '../index-DeCYIw0L.js';
2
+ export { a as AccessEntry, b as AccessErrorCode, c as AccessScopeType, d as AccessSnapshotError, D as DASH_PERMISSIONS, e as DASH_ROLES, f as DEFAULT_ACCESS_ENDPOINT_PATH, g as DashPermissionKey, h as DashRole, F as FetchAccessSnapshotOptions, L as LEADBROKER_PERMISSIONS, i as LeadBrokerPermissionKey, j as PIPELINE_STAGES, k as PLATFORM_PERMISSIONS, l as PermissionKey, m as PipelineStage, n as PlatformPermissionKey, W as WORKSPACE_PERMISSIONS, o as WORKSPACE_ROLES, p as WorkspacePermissionKey, q as WorkspaceRole, r as appScopes, s as dashRole, t as emptySnapshot, u as entryCoversApp, v as fetchAccessSnapshot, w as hasAllPermissions, x as hasAnyPermission, y as hasPermission, z as hasWorkspacePermission, B as isAccessSnapshotError, C as isPipelineStage, E as isPlatformOwner, G as managedDashes, H as parseAccessSnapshot, I as permissionsFor } from '../index-DeCYIw0L.js';
3
3
 
4
4
  /** Default cache tag for one subject's snapshot: `access:<subjectId>`. */
5
5
  declare function accessCacheTag(subjectId: string): string;
@@ -274,6 +274,10 @@ var PLATFORM_PERMISSIONS = [
274
274
  "platform.billing.view",
275
275
  "platform.channels.manage",
276
276
  "platform.channels.view",
277
+ "platform.communications.content.view",
278
+ "platform.communications.manage",
279
+ "platform.communications.send",
280
+ "platform.communications.view",
277
281
  "platform.config.manage",
278
282
  "platform.dashes.archive",
279
283
  "platform.dashes.manage",
@@ -282,6 +286,8 @@ var PLATFORM_PERMISSIONS = [
282
286
  "platform.dashes.view",
283
287
  "platform.docs.manage",
284
288
  "platform.docs.view",
289
+ "platform.leads.manage",
290
+ "platform.leads.view",
285
291
  "platform.mcp.access",
286
292
  "platform.observability.manage",
287
293
  "platform.observability.view",
@@ -291,6 +297,7 @@ var PLATFORM_PERMISSIONS = [
291
297
  "platform.ownership.transfer",
292
298
  "platform.service_accounts.manage",
293
299
  "platform.service_accounts.view",
300
+ "platform.site_mode.manage",
294
301
  "platform.support.impersonate",
295
302
  "platform.support.impersonation.delegate",
296
303
  "platform.support.sessions",
@@ -358,6 +365,7 @@ var WORKSPACE_PERMISSIONS = [
358
365
  "workspace.orders.manage",
359
366
  "workspace.orders.view",
360
367
  "workspace.payments.record",
368
+ "workspace.payments.refund",
361
369
  "workspace.site.edit",
362
370
  "workspace.site.view",
363
371
  "workspace.staff.manage"
@@ -1,5 +1,5 @@
1
1
  /** Platform-operator permission keys. */
2
- declare const PLATFORM_PERMISSIONS: readonly ["affiliates.enrollments.manage", "affiliates.finance.manage", "affiliates.partners.manage", "affiliates.programmes.manage", "affiliates.view", "linkservice.domains.manage", "linkservice.links.manage", "linkservice.qr.manage", "linkservice.view", "platform.admin.view", "platform.audit.view", "platform.auth.manage", "platform.billing.manage", "platform.billing.view", "platform.channels.manage", "platform.channels.view", "platform.config.manage", "platform.dashes.archive", "platform.dashes.manage", "platform.dashes.purge", "platform.dashes.restore", "platform.dashes.view", "platform.docs.manage", "platform.docs.view", "platform.mcp.access", "platform.observability.manage", "platform.observability.view", "platform.offboarding.view", "platform.ops.manage", "platform.ops.view", "platform.ownership.transfer", "platform.service_accounts.manage", "platform.service_accounts.view", "platform.support.impersonate", "platform.support.impersonation.delegate", "platform.support.sessions", "platform.users.deactivate", "platform.users.delete", "platform.users.invite", "platform.users.manage_access", "platform.users.manage_profile", "platform.users.reactivate", "platform.users.view"];
2
+ declare const PLATFORM_PERMISSIONS: readonly ["affiliates.enrollments.manage", "affiliates.finance.manage", "affiliates.partners.manage", "affiliates.programmes.manage", "affiliates.view", "linkservice.domains.manage", "linkservice.links.manage", "linkservice.qr.manage", "linkservice.view", "platform.admin.view", "platform.audit.view", "platform.auth.manage", "platform.billing.manage", "platform.billing.view", "platform.channels.manage", "platform.channels.view", "platform.communications.content.view", "platform.communications.manage", "platform.communications.send", "platform.communications.view", "platform.config.manage", "platform.dashes.archive", "platform.dashes.manage", "platform.dashes.purge", "platform.dashes.restore", "platform.dashes.view", "platform.docs.manage", "platform.docs.view", "platform.leads.manage", "platform.leads.view", "platform.mcp.access", "platform.observability.manage", "platform.observability.view", "platform.offboarding.view", "platform.ops.manage", "platform.ops.view", "platform.ownership.transfer", "platform.service_accounts.manage", "platform.service_accounts.view", "platform.site_mode.manage", "platform.support.impersonate", "platform.support.impersonation.delegate", "platform.support.sessions", "platform.users.deactivate", "platform.users.delete", "platform.users.invite", "platform.users.manage_access", "platform.users.manage_profile", "platform.users.reactivate", "platform.users.view"];
3
3
  type PlatformPermissionKey = (typeof PLATFORM_PERMISSIONS)[number];
4
4
  /** Dash-owner permission keys (granted at dash scope, mirrored from the membership role). */
5
5
  declare const DASH_PERMISSIONS: readonly ["dash.activity.view", "dash.apps.manage", "dash.apps.view", "dash.billing.manage", "dash.billing.view", "dash.channels.manage", "dash.customers.manage", "dash.customers.view", "dash.domains.manage", "dash.domains.view", "dash.leads.export", "dash.leads.view", "dash.learning.records.view", "dash.learning.view", "dash.marketing.view", "dash.mcp.access", "dash.members.manage", "dash.members.view", "dash.ops_library.view", "dash.overview.view", "dash.ownership.transfer", "dash.plans.manage", "dash.plans.view", "dash.publish", "dash.settings.manage", "dash.settings.view", "dash.shop.view", "dash.workspaces.admin", "dash.workspaces.manage", "dash.workspaces.view"];
@@ -11,7 +11,7 @@ type DashRole = (typeof DASH_ROLES)[number];
11
11
  declare const LEADBROKER_PERMISSIONS: readonly ["leadbroker.finance.manage", "leadbroker.leads.dispatch", "leadbroker.leads.review", "leadbroker.leads.view", "leadbroker.policy.manage"];
12
12
  type LeadBrokerPermissionKey = (typeof LEADBROKER_PERMISSIONS)[number];
13
13
  /** Workspace-staff permission keys. */
14
- declare const WORKSPACE_PERMISSIONS: readonly ["workspace.channels.manage", "workspace.channels.secrets", "workspace.channels.view", "workspace.crm.manage", "workspace.crm.view", "workspace.customers.manage", "workspace.customers.view", "workspace.drafts.delete", "workspace.lifecycle.manage", "workspace.orders.manage", "workspace.orders.view", "workspace.payments.record", "workspace.site.edit", "workspace.site.view", "workspace.staff.manage"];
14
+ declare const WORKSPACE_PERMISSIONS: readonly ["workspace.channels.manage", "workspace.channels.secrets", "workspace.channels.view", "workspace.crm.manage", "workspace.crm.view", "workspace.customers.manage", "workspace.customers.view", "workspace.drafts.delete", "workspace.lifecycle.manage", "workspace.orders.manage", "workspace.orders.view", "workspace.payments.record", "workspace.payments.refund", "workspace.site.edit", "workspace.site.view", "workspace.staff.manage"];
15
15
  type WorkspacePermissionKey = (typeof WORKSPACE_PERMISSIONS)[number];
16
16
  /** Assignable workspace-staff role bundles (grant keys at workspace scope). */
17
17
  declare const WORKSPACE_ROLES: readonly ["workspace.editor", "workspace.frontdesk", "workspace.manager"];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@c1m-public/platform-auth",
3
- "version": "0.18.0",
3
+ "version": "0.20.0",
4
4
  "type": "module",
5
5
  "license": "MIT",
6
6
  "description": "Session and authorization helpers for C1M platform surfaces. The root is runtime-neutral (Web Request/Response): token/session reads, the first-party handoff (PKCE target + source), proxy session gate and coalesced refresh; ./next adds the server-only guard; ./access carries the resolved access snapshot, typed permission keys, predicates, a Next loader and React bindings",