Skip to content

chore: update schemas from constructive-db - #2052

Open
Anmol1696 wants to merge 1 commit into
mainfrom
schema-update/20261122-072908
Open

Anmol1696 wants to merge 1 commit into
mainfrom
schema-update/20261122-072908

Conversation

@Anmol1696

@Anmol1696 Anmol1696 commented Nov 22, 2026 •

Copy link
Copy Markdown
Contributor

Automated Schema + SDK Update

This PR was created by the schema-propagation workflow.

What changed

Updated schema files from constructive-db and regenerated ALL SDK clients.

Source: constructive-db@d6537bcc594

Schemas updated

  • sdk/constructive-sdk/schemas/ — all API targets from constructive-db (auto-discovered)
  • sdk/migrate-client/schemas/ — migrate
  • pgpm/export/src/meta-export-tables.json — generated meta export table list

Clients regenerated

  • sdk/constructive-sdk/src/ — ORM client
  • sdk/constructive-cli/src/ — CLI client
  • sdk/constructive-react/src/ — React hooks
  • sdk/migrate-client/src/ — Migrate client

Skill references updated

  • .agents/skills/ — Generated skill documentation

Auto-generated by constructive-hub schema-propagation

Summary by CodeRabbit

  • Documentation
    • Added CLI, ORM, and hooks guidance for working with principals, including examples for querying and managing records.
    • Clarified how principal authorization data relates to credential features, authentication, and session handling.
    • Updated documented table coverage from 88 to 89 and added principals references across module guides.
  • New Features
    • Added principals to the exported table metadata.

Auto-generated by schema-propagation workflow.
Source: constructive-db@d6537bcc594
@luxor-code-review

luxor-code-review Bot commented Nov 22, 2026 •

Copy link
Copy Markdown

Review complete. No blocking issues — approved ✅; 1 nitpick below.

🧹 Nitpicks (1) — 🟢 1 low
  • 🟢 Generated hook examples reference nonexistent name field (useCreatePrincipalsModuleMutation.ts:30) — The new generated JSDoc examples for the PrincipalsModule mutation hooks use a hardcoded name placeholder that does not exist on any PrincipalsModule type.

This PR is a codegen regeneration: the modules GraphQL schema gains a PrincipalsModule table type alongside the existing PrincipalAuthModule, plus bucketKey/isPublic fields on MetaFileField, and every generated package is refreshed to match.

Files Change
sdk/constructive-sdk/schemas/*.graphql Checked-in SDL snapshots updated with PrincipalsModule types/inputs/order-by and MetaFileField.bucketKey/isPublic.
sdk/constructive-cli/src/modules/**, sdk/constructive-sdk/src/modules/** New generated CLI CRUD commands and ORM models/input types for PrincipalsModule.
sdk/constructive-react/src/modules/hooks/** New React Query hooks, query/mutation keys, and invalidation entries for PrincipalsModule.
sdk/constructive-react/src/**/schema-types.ts, sdk/constructive-react/src/modules/types.ts Generated TS schema types refreshed across all API packages.
pgpm/export/src/meta-export-tables.json Export table list updated accordingly.

The changes are almost entirely additive and machine-generated; review focused on cross-package consistency and hook wiring, which checked out. Skill/README markdown files under .agents/skills/ were reviewed at a skim level as documentation only.

Reviewed commit: 16504de

@coderabbitai

coderabbitai Bot commented Nov 22, 2026 •

Copy link
Copy Markdown

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The pull request adds principals-module metadata and documentation for CLI, hooks, and ORM workflows. It updates module counts and reference links, and revises principal-auth descriptions to cover credential provisioning and its prerequisites.

Changes: Principals Module Documentation

Layer / File(s) Summary
Register the principals module
pgpm/export/src/meta-export-tables.json, .agents/skills/cli-modules/SKILL.md, .agents/skills/hooks-modules/SKILL.md, .agents/skills/orm-modules/SKILL.md
The exported table metadata adds principals_module. The three skill overviews update the documented table count from 88 to 89 and link to the new reference.
Document module behavior and ORM usage
.agents/skills/hooks-modules/references/principals-module.md, .agents/skills/orm-modules/references/principals-module.md, .agents/skills/hooks-modules/references/principal-auth-module.md, .agents/skills/orm-modules/references/principal-auth-module.md
The principals-module references describe its authorization-data scope, tables, mutations, transaction claim requirement, and usage examples. The principal-auth descriptions cover credential provisioning, auth-stack prerequisites, and conditions for org API key functions.
Document CLI commands
.agents/skills/cli-modules/references/principals-module.md
The new reference documents CLI syntax and examples for listing, filtering, pagination, field selection, and CRUD commands.

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Other

Possibly related PRs

Suggested reviewers: luxor-code-review, pyramation

Merge Risk: Minimal · up to 16504

This PR updates exported module metadata and generated documentation for the principals module. It has no runtime effect, and the risk of merging is minimal.

Architecture risk: Low · up to 16504

The change affects 1 system.

Changed systems: pgpm

Architecture concerns
No architecture-level concerns identified.

Review details

Systems and components

  • observed — pgpm (service) was modified; 1 changed file maps to changed impact.

Before / after behavior

  • observed — Modified behavior in pgpm/export/src/meta-export-tables.json: Adds the principals_module table entry in the metaschema_modules_public schema.
  • observed — Modified behavior in .agents/skills/cli-modules/SKILL.md: The description and generated CLI overview now state that the modules API provides CRUD commands for 89 tables instead of 88.
  • observed — Modified behavior in .agents/skills/cli-modules/SKILL.md: Adds the principals-module reference to the API documentation index.
  • observed — Modified behavior in .agents/skills/cli-modules/references/principals-module.md: Adds CLI usage syntax and examples for principals-module CRUD commands, including list filters and ordering, offset and cursor pagination, field selection, find-first, get, create, update, and delete.
Pre-merge checks: Passed 4

Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed The title "chore: update schemas from constructive-db" matches the main change. The PR copies schemas from constructive-db into the SDK schema directories and regenerates the ORM, CLI, React hooks, an…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title "chore: update schemas from constructive-db" matches the main change. The PR copies schemas from constructive-db into the SDK schema directories and regenerates the ORM, CLI, React hooks, and Migrate clients. It also updates the generated skill documentation and the meta export table list. The title names the source and the type of change, but it does not name the new principals module, which is the main functional addition. This is acceptable for an automated sync PR.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 34f95e8 and 16504de.

Files ignored due to path filters: 68

  • sdk/constructive-cli/src/api/orm/input-types.ts is excluded by !sdk/**
  • sdk/constructive-cli/src/modules/README.md is excluded by !sdk/**
  • sdk/constructive-cli/src/modules/cli/README.md is excluded by !sdk/**
  • sdk/constructive-cli/src/modules/cli/commands.ts is excluded by !sdk/**
  • sdk/constructive-cli/src/modules/cli/commands/principals-module.ts is excluded by !sdk/**
  • sdk/constructive-cli/src/modules/orm/README.md is excluded by !sdk/**
  • sdk/constructive-cli/src/modules/orm/index.ts is excluded by !sdk/**
  • sdk/constructive-cli/src/modules/orm/input-types.ts is excluded by !sdk/**
  • sdk/constructive-cli/src/modules/orm/models/index.ts is excluded by !sdk/**
  • sdk/constructive-cli/src/modules/orm/models/principalsModule.ts is excluded by !sdk/**
  • sdk/constructive-react/src/admin/schema-types.ts is excluded by !sdk/**
  • sdk/constructive-react/src/agent/schema-types.ts is excluded by !sdk/**
  • sdk/constructive-react/src/api/orm/input-types.ts is excluded by !sdk/**
  • sdk/constructive-react/src/api/schema-types.ts is excluded by !sdk/**
  • sdk/constructive-react/src/auth/schema-types.ts is excluded by !sdk/**
  • sdk/constructive-react/src/compute/schema-types.ts is excluded by !sdk/**
  • sdk/constructive-react/src/config/schema-types.ts is excluded by !sdk/**
  • sdk/constructive-react/src/infra/schema-types.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/README.md is excluded by !sdk/**
  • sdk/constructive-react/src/modules/hooks/README.md is excluded by !sdk/**
  • sdk/constructive-react/src/modules/hooks/index.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/hooks/invalidation.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/hooks/mutation-keys.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/hooks/mutations/index.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/hooks/mutations/useCreatePrincipalAuthModuleMutation.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/hooks/mutations/useCreatePrincipalsModuleMutation.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/hooks/mutations/useDeletePrincipalAuthModuleMutation.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/hooks/mutations/useDeletePrincipalsModuleMutation.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/hooks/mutations/useUpdatePrincipalAuthModuleMutation.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/hooks/mutations/useUpdatePrincipalsModuleMutation.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/hooks/queries/index.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/hooks/queries/usePrincipalAuthModuleQuery.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/hooks/queries/usePrincipalAuthModulesQuery.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/hooks/queries/usePrincipalsModuleQuery.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/hooks/queries/usePrincipalsModulesQuery.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/hooks/query-keys.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/orm/README.md is excluded by !sdk/**
  • sdk/constructive-react/src/modules/orm/index.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/orm/input-types.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/orm/models/index.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/orm/models/principalsModule.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/schema-types.ts is excluded by !sdk/**
  • sdk/constructive-react/src/modules/types.ts is excluded by !sdk/**
  • sdk/constructive-react/src/objects/schema-types.ts is excluded by !sdk/**
  • sdk/constructive-react/src/remote/schema-types.ts is excluded by !sdk/**
  • sdk/constructive-react/src/storage/schema-types.ts is excluded by !sdk/**
  • sdk/constructive-react/src/usage/schema-types.ts is excluded by !sdk/**
  • sdk/constructive-sdk/schemas/admin.graphql is excluded by !sdk/**
  • sdk/constructive-sdk/schemas/agent.graphql is excluded by !sdk/**
  • sdk/constructive-sdk/schemas/api.graphql is excluded by !sdk/**
  • sdk/constructive-sdk/schemas/auth.graphql is excluded by !sdk/**
  • sdk/constructive-sdk/schemas/cluster.graphql is excluded by !sdk/**
  • sdk/constructive-sdk/schemas/compute.graphql is excluded by !sdk/**
  • sdk/constructive-sdk/schemas/config.graphql is excluded by !sdk/**
  • sdk/constructive-sdk/schemas/infra.graphql is excluded by !sdk/**
  • sdk/constructive-sdk/schemas/modules.graphql is excluded by !sdk/**
  • sdk/constructive-sdk/schemas/objects.graphql is excluded by !sdk/**
  • sdk/constructive-sdk/schemas/remote.graphql is excluded by !sdk/**
  • sdk/constructive-sdk/schemas/storage.graphql is excluded by !sdk/**
  • sdk/constructive-sdk/schemas/usage.graphql is excluded by !sdk/**
  • sdk/constructive-sdk/src/api/orm/input-types.ts is excluded by !sdk/**
  • sdk/constructive-sdk/src/modules/README.md is excluded by !sdk/**
  • sdk/constructive-sdk/src/modules/orm/README.md is excluded by !sdk/**
  • sdk/constructive-sdk/src/modules/orm/index.ts is excluded by !sdk/**
  • sdk/constructive-sdk/src/modules/orm/input-types.ts is excluded by !sdk/**
  • sdk/constructive-sdk/src/modules/orm/models/index.ts is excluded by !sdk/**
  • sdk/constructive-sdk/src/modules/orm/models/principalsModule.ts is excluded by !sdk/**
  • sdk/migrate-client/schemas/migrate.graphql is excluded by !sdk/**
Files selected for processing: 9

  • .agents/skills/cli-modules/SKILL.md
  • .agents/skills/cli-modules/references/principals-module.md
  • .agents/skills/hooks-modules/SKILL.md
  • .agents/skills/hooks-modules/references/principal-auth-module.md
  • .agents/skills/hooks-modules/references/principals-module.md
  • .agents/skills/orm-modules/SKILL.md
  • .agents/skills/orm-modules/references/principal-auth-module.md
  • .agents/skills/orm-modules/references/principals-module.md
  • pgpm/export/src/meta-export-tables.json

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 7 remain after this review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant