@pgpm/metaschema-modules 0.21.1 → 0.22.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.
Files changed (48) hide show
  1. package/README.md +7 -8
  2. package/deploy/schemas/metaschema_modules_public/tables/billing_module/table.sql +47 -0
  3. package/deploy/schemas/metaschema_modules_public/tables/billing_provider_module/table.sql +61 -0
  4. package/deploy/schemas/metaschema_modules_public/tables/devices_module/table.sql +36 -0
  5. package/deploy/schemas/metaschema_modules_public/tables/entity_type_provision/table.sql +332 -0
  6. package/deploy/schemas/metaschema_modules_public/tables/identity_providers_module/table.sql +33 -0
  7. package/deploy/schemas/metaschema_modules_public/tables/invites_module/table.sql +8 -0
  8. package/deploy/schemas/metaschema_modules_public/tables/limits_module/table.sql +38 -2
  9. package/deploy/schemas/metaschema_modules_public/tables/memberships_module/table.sql +7 -0
  10. package/deploy/schemas/metaschema_modules_public/tables/notifications_module/table.sql +66 -0
  11. package/deploy/schemas/metaschema_modules_public/tables/permissions_module/table.sql +23 -1
  12. package/deploy/schemas/metaschema_modules_public/tables/plans_module/table.sql +46 -0
  13. package/deploy/schemas/metaschema_modules_public/tables/profiles_module/table.sql +5 -0
  14. package/deploy/schemas/metaschema_modules_public/tables/realtime_module/table.sql +48 -0
  15. package/deploy/schemas/metaschema_modules_public/tables/relation_provision/table.sql +10 -45
  16. package/deploy/schemas/metaschema_modules_public/tables/secure_table_provision/table.sql +8 -39
  17. package/deploy/schemas/metaschema_modules_public/tables/session_secrets_module/table.sql +31 -0
  18. package/deploy/schemas/metaschema_modules_public/tables/storage_module/table.sql +42 -4
  19. package/deploy/schemas/metaschema_modules_public/tables/user_auth_module/table.sql +2 -2
  20. package/deploy/schemas/metaschema_modules_public/tables/webauthn_auth_module/table.sql +63 -0
  21. package/deploy/schemas/metaschema_modules_public/tables/webauthn_credentials_module/table.sql +32 -0
  22. package/package.json +5 -5
  23. package/pgpm.plan +12 -1
  24. package/revert/schemas/metaschema_modules_public/tables/billing_module/table.sql +3 -0
  25. package/revert/schemas/metaschema_modules_public/tables/billing_provider_module/table.sql +3 -0
  26. package/revert/schemas/metaschema_modules_public/tables/devices_module/table.sql +7 -0
  27. package/revert/schemas/metaschema_modules_public/tables/entity_type_provision/table.sql +7 -0
  28. package/revert/schemas/metaschema_modules_public/tables/identity_providers_module/table.sql +7 -0
  29. package/revert/schemas/metaschema_modules_public/tables/notifications_module/table.sql +7 -0
  30. package/revert/schemas/metaschema_modules_public/tables/plans_module/table.sql +7 -0
  31. package/revert/schemas/metaschema_modules_public/tables/realtime_module/table.sql +7 -0
  32. package/revert/schemas/metaschema_modules_public/tables/session_secrets_module/table.sql +7 -0
  33. package/revert/schemas/metaschema_modules_public/tables/webauthn_auth_module/table.sql +7 -0
  34. package/revert/schemas/metaschema_modules_public/tables/webauthn_credentials_module/table.sql +7 -0
  35. package/sql/metaschema-modules--0.15.5.sql +1269 -469
  36. package/verify/schemas/metaschema_modules_public/tables/billing_module/table.sql +23 -0
  37. package/verify/schemas/metaschema_modules_public/tables/billing_provider_module/table.sql +29 -0
  38. package/verify/schemas/metaschema_modules_public/tables/devices_module/table.sql +7 -0
  39. package/verify/schemas/metaschema_modules_public/tables/entity_type_provision/table.sql +7 -0
  40. package/verify/schemas/metaschema_modules_public/tables/identity_providers_module/table.sql +7 -0
  41. package/verify/schemas/metaschema_modules_public/tables/notifications_module/table.sql +7 -0
  42. package/verify/schemas/metaschema_modules_public/tables/plans_module/table.sql +13 -0
  43. package/verify/schemas/metaschema_modules_public/tables/realtime_module/table.sql +7 -0
  44. package/verify/schemas/metaschema_modules_public/tables/relation_provision/table.sql +2 -8
  45. package/verify/schemas/metaschema_modules_public/tables/secure_table_provision/table.sql +2 -8
  46. package/verify/schemas/metaschema_modules_public/tables/session_secrets_module/table.sql +7 -0
  47. package/verify/schemas/metaschema_modules_public/tables/webauthn_auth_module/table.sql +7 -0
  48. package/verify/schemas/metaschema_modules_public/tables/webauthn_credentials_module/table.sql +7 -0
@@ -0,0 +1,32 @@
1
+ -- Deploy schemas/metaschema_modules_public/tables/webauthn_credentials_module/table to pg
2
+
3
+ -- requires: schemas/metaschema_modules_public/schema
4
+
5
+ BEGIN;
6
+
7
+ CREATE TABLE metaschema_modules_public.webauthn_credentials_module (
8
+ id uuid PRIMARY KEY DEFAULT uuidv7(),
9
+ database_id uuid NOT NULL,
10
+
11
+ schema_id uuid NOT NULL DEFAULT uuid_nil(),
12
+ private_schema_id uuid NOT NULL DEFAULT uuid_nil(),
13
+
14
+ table_id uuid NOT NULL DEFAULT uuid_nil(),
15
+ owner_table_id uuid NOT NULL DEFAULT uuid_nil(),
16
+
17
+ table_name text NOT NULL DEFAULT 'webauthn_credentials',
18
+
19
+ --
20
+ CONSTRAINT db_fkey FOREIGN KEY (database_id) REFERENCES metaschema_public.database (id) ON DELETE CASCADE,
21
+ CONSTRAINT table_fkey FOREIGN KEY (table_id) REFERENCES metaschema_public.table (id) ON DELETE CASCADE,
22
+ CONSTRAINT owner_table_fkey FOREIGN KEY (owner_table_id) REFERENCES metaschema_public.table (id) ON DELETE CASCADE,
23
+ CONSTRAINT schema_fkey FOREIGN KEY (schema_id) REFERENCES metaschema_public.schema (id) ON DELETE CASCADE,
24
+ CONSTRAINT private_schema_fkey FOREIGN KEY (private_schema_id) REFERENCES metaschema_public.schema (id) ON DELETE CASCADE
25
+ );
26
+
27
+ CREATE INDEX webauthn_credentials_module_database_id_idx ON metaschema_modules_public.webauthn_credentials_module ( database_id );
28
+
29
+ COMMENT ON TABLE metaschema_modules_public.webauthn_credentials_module IS 'Config row for the webauthn_credentials_module, which provisions the per-user WebAuthn/passkey credentials table (public key, counter, transports, device type, backup state) mirroring crypto_addresses_module. The sibling webauthn_auth_module holds RP config and the registration/sign-in challenge state.';
30
+ COMMENT ON COLUMN metaschema_modules_public.webauthn_credentials_module.private_schema_id IS 'Private schema that hosts SECURITY DEFINER helpers which write to webauthn_credentials (registration / counter-bump / delete).';
31
+
32
+ COMMIT;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pgpm/metaschema-modules",
3
- "version": "0.21.1",
3
+ "version": "0.22.0",
4
4
  "description": "Module metadata handling and dependency tracking",
5
5
  "author": "Dan Lynch <pyramation@gmail.com>",
6
6
  "contributors": [
@@ -21,11 +21,11 @@
21
21
  "test:watch": "jest --watch"
22
22
  },
23
23
  "dependencies": {
24
- "@pgpm/metaschema-schema": "0.21.0",
25
- "@pgpm/verify": "0.21.0"
24
+ "@pgpm/metaschema-schema": "0.22.0",
25
+ "@pgpm/verify": "0.22.0"
26
26
  },
27
27
  "devDependencies": {
28
- "pgpm": "^4.2.3"
28
+ "pgpm": "^4.23.2"
29
29
  },
30
30
  "repository": {
31
31
  "type": "git",
@@ -35,5 +35,5 @@
35
35
  "bugs": {
36
36
  "url": "https://github.com/constructive-io/pgpm-modules/issues"
37
37
  },
38
- "gitHead": "60f39d6306b9f920ddeff0cc267491fdb98b00c7"
38
+ "gitHead": "96ae0195a8b3a3dd056808c344f0e3c31a199e5e"
39
39
  }
package/pgpm.plan CHANGED
@@ -29,11 +29,22 @@ schemas/metaschema_modules_public/tables/user_auth_module/table [schemas/metasch
29
29
  schemas/metaschema_modules_public/tables/users_module/table [schemas/metaschema_modules_public/schema] 2017-08-11T08:11:51Z skitch <skitch@5b0c196eeb62> # add schemas/metaschema_modules_public/tables/users_module/table
30
30
 
31
31
  schemas/metaschema_modules_public/tables/hierarchy_module/table [schemas/metaschema_modules_public/schema] 2024-12-28T00:00:00Z skitch <skitch@5b0c196eeb62> # add schemas/metaschema_modules_public/tables/hierarchy_module/table
32
- schemas/metaschema_modules_public/tables/table_template_module/table [schemas/metaschema_modules_public/schema] 2026-01-14T00:00:00Z devin <devin@cognition.ai> # add schemas/metaschema_modules_public/tables/table_template_module/table
33
32
  schemas/metaschema_modules_public/tables/secure_table_provision/table [schemas/metaschema_modules_public/schema] 2026-02-25T00:00:00Z Constructive <developers@constructive.io> # add schemas/metaschema_modules_public/tables/secure_table_provision/table
34
33
  schemas/metaschema_modules_public/tables/relation_provision/table [schemas/metaschema_modules_public/schema] 2026-02-26T00:00:00Z Constructive <developers@constructive.io> # add schemas/metaschema_modules_public/tables/relation_provision/table
35
34
  schemas/metaschema_modules_public/tables/blueprint_template/table [schemas/metaschema_modules_public/schema] 2026-03-20T00:00:00Z Constructive <developers@constructive.io> # add blueprint_template table for shareable schema recipes
36
35
  schemas/metaschema_modules_public/tables/blueprint/table [schemas/metaschema_modules_public/schema schemas/metaschema_modules_public/tables/blueprint_template/table] 2026-03-20T00:00:01Z Constructive <developers@constructive.io> # add blueprint table for owned executable blueprints
37
36
  schemas/metaschema_modules_public/tables/blueprint_construction/table [schemas/metaschema_modules_public/schema schemas/metaschema_modules_public/tables/blueprint/table] 2026-03-31T00:00:00Z Constructive <developers@constructive.io> # add blueprint_construction table for construction state tracking
38
37
  schemas/metaschema_modules_public/tables/storage_module/table [schemas/metaschema_modules_public/schema] 2026-03-24T00:00:00Z devin <devin@cognition.ai> # add storage_module config table for files and buckets
38
+ schemas/metaschema_modules_public/tables/entity_type_provision/table [schemas/metaschema_modules_public/schema] 2026-04-11T00:00:00Z Constructive <developers@constructive.io> # add entity_type_provision table for dynamic membership type provisioning
39
+
39
40
  schemas/metaschema_modules_public/tables/rate_limits_module/table [schemas/metaschema_modules_public/schema] 2026-04-15T00:00:00Z devin <devin@cognition.ai> # add rate_limits_module for centralized throttle configuration
41
+ schemas/metaschema_modules_public/tables/devices_module/table [schemas/metaschema_modules_public/schema] 2026-04-16T00:00:00Z devin <devin@cognition.ai> # add devices_module for trusted device tracking and recognition
42
+ schemas/metaschema_modules_public/tables/session_secrets_module/table [schemas/metaschema_modules_public/schema] 2026-04-17T00:00:00Z devin <devin@cognition.ai> # add session_secrets_module config table for DB-private session-scoped ephemeral store
43
+ schemas/metaschema_modules_public/tables/webauthn_credentials_module/table [schemas/metaschema_modules_public/schema] 2026-04-18T00:00:00Z devin <devin@cognition.ai> # add webauthn_credentials_module config table for WebAuthn/passkey credentials (phase 11a)
44
+ schemas/metaschema_modules_public/tables/webauthn_auth_module/table [schemas/metaschema_modules_public/schema] 2026-04-18T01:00:00Z devin <devin@cognition.ai> # add webauthn_auth_module config table for WebAuthn/passkey RP config + api_modules publishing (phase 11b)
45
+ schemas/metaschema_modules_public/tables/identity_providers_module/table [schemas/metaschema_modules_public/schema] 2026-04-19T00:00:00Z devin <devin@cognition.ai> # add identity_providers_module config table for OAuth2/OIDC custom identity providers (phase 12a)
46
+ schemas/metaschema_modules_public/tables/notifications_module/table [schemas/metaschema_modules_public/schema] 2026-04-19T10:00:00Z devin <devin@cognition.ai> # add notifications_module config table for v2 notifications (events + scoped inbox)
47
+ schemas/metaschema_modules_public/tables/plans_module/table [schemas/metaschema_modules_public/schema] 2026-05-02T23:30:00Z devin <devin@cognition.ai> # add plans_module config table for plan tiers and plan_limits
48
+ schemas/metaschema_modules_public/tables/billing_module/table [schemas/metaschema_modules_public/schema] 2026-05-02T23:45:00Z devin <devin@cognition.ai> # add billing_module config table for meters, plan_subscriptions, ledger, and balances
49
+ schemas/metaschema_modules_public/tables/billing_provider_module/table [schemas/metaschema_modules_public/schema] 2026-05-03T01:00:00Z devin <devin@cognition.ai> # add billing_provider_module config table for external billing provider integration
50
+ schemas/metaschema_modules_public/tables/realtime_module/table [schemas/metaschema_modules_public/schema] 2026-05-09T10:00:00Z devin <devin@cognition.ai> # add realtime_module config table for real-time subscription infrastructure
@@ -0,0 +1,3 @@
1
+ -- Revert schemas/metaschema_modules_public/tables/billing_module/table from pg
2
+
3
+ DROP TABLE IF EXISTS metaschema_modules_public.billing_module;
@@ -0,0 +1,3 @@
1
+ -- Revert schemas/metaschema_modules_public/tables/billing_provider_module/table from pg
2
+
3
+ DROP TABLE IF EXISTS metaschema_modules_public.billing_provider_module;
@@ -0,0 +1,7 @@
1
+ -- Revert schemas/metaschema_modules_public/tables/devices_module/table from pg
2
+
3
+ BEGIN;
4
+
5
+ DROP TABLE metaschema_modules_public.devices_module;
6
+
7
+ COMMIT;
@@ -0,0 +1,7 @@
1
+ -- Revert schemas/metaschema_modules_public/tables/entity_type_provision/table from pg
2
+
3
+ BEGIN;
4
+
5
+ DROP TABLE metaschema_modules_public.entity_type_provision;
6
+
7
+ COMMIT;
@@ -0,0 +1,7 @@
1
+ -- Revert schemas/metaschema_modules_public/tables/identity_providers_module/table from pg
2
+
3
+ BEGIN;
4
+
5
+ DROP TABLE metaschema_modules_public.identity_providers_module;
6
+
7
+ COMMIT;
@@ -0,0 +1,7 @@
1
+ -- Revert schemas/metaschema_modules_public/tables/notifications_module/table from pg
2
+
3
+ BEGIN;
4
+
5
+ DROP TABLE metaschema_modules_public.notifications_module;
6
+
7
+ COMMIT;
@@ -0,0 +1,7 @@
1
+ -- Revert schemas/metaschema_modules_public/tables/plans_module/table from pg
2
+
3
+ BEGIN;
4
+
5
+ DROP TABLE IF EXISTS metaschema_modules_public.plans_module;
6
+
7
+ COMMIT;
@@ -0,0 +1,7 @@
1
+ -- Revert schemas/metaschema_modules_public/tables/realtime_module/table from pg
2
+
3
+ BEGIN;
4
+
5
+ DROP TABLE metaschema_modules_public.realtime_module;
6
+
7
+ COMMIT;
@@ -0,0 +1,7 @@
1
+ -- Revert schemas/metaschema_modules_public/tables/session_secrets_module/table from pg
2
+
3
+ BEGIN;
4
+
5
+ DROP TABLE metaschema_modules_public.session_secrets_module;
6
+
7
+ COMMIT;
@@ -0,0 +1,7 @@
1
+ -- Revert schemas/metaschema_modules_public/tables/webauthn_auth_module/table from pg
2
+
3
+ BEGIN;
4
+
5
+ DROP TABLE metaschema_modules_public.webauthn_auth_module;
6
+
7
+ COMMIT;
@@ -0,0 +1,7 @@
1
+ -- Revert schemas/metaschema_modules_public/tables/webauthn_credentials_module/table from pg
2
+
3
+ BEGIN;
4
+
5
+ DROP TABLE metaschema_modules_public.webauthn_credentials_module;
6
+
7
+ COMMIT;