Skip to content

ApplyFunctionRenderOptions

Defined in: packages/server/src/mutations/plpgsql-apply.ts:457

How the generated apply function is rendered. Both fields are part of the artifact’s IDENTITY: they change the fingerprinted body, so a change to either forces the regenerate-and-commit flow, and the SERVER must be configured with the same values (it recomputes the expected fingerprint at runtime).

optional functionSchema?: string

Defined in: packages/server/src/mutations/plpgsql-apply.ts:459

Schema to qualify the function with. Default: unqualified (resolved through search_path).


optional grantExecuteTo?: readonly string[]

Defined in: packages/server/src/mutations/plpgsql-apply.ts:466

Roles that receive GRANT EXECUTE on the apply function (ADR-0054 decision 2). Default []owner-only, which is right whenever the server connects as the function’s owner or a superuser. Name ONLY server roles: the function trusts the p_user_claims it is handed, so a granted role can pass any claims it likes. The grant list IS the write path’s trust boundary.