pipework 0.7.13 → 0.7.17
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/CHANGELOG.md +19 -0
- package/README.md +3 -2
- package/REFERENCE.md +327 -296
- package/dist/REFERENCE.md +396 -431
- package/dist/auth/tenant/scope.d.ts +1 -1
- package/dist/auth/tenant/scope.d.ts.map +1 -1
- package/dist/cli/commands/check.d.ts +2 -1
- package/dist/cli/commands/check.d.ts.map +1 -1
- package/dist/cli/commands/check.js +52 -17
- package/dist/cli/commands/check.js.map +1 -1
- package/dist/cli/commands/migrate.d.ts.map +1 -1
- package/dist/cli/commands/migrate.js +3 -6
- package/dist/cli/commands/migrate.js.map +1 -1
- package/dist/cli/commands/scope.d.ts +12 -0
- package/dist/cli/commands/scope.d.ts.map +1 -0
- package/dist/cli/commands/scope.js +25 -0
- package/dist/cli/commands/scope.js.map +1 -0
- package/dist/cli/commands/test.d.ts +3 -0
- package/dist/cli/commands/test.d.ts.map +1 -1
- package/dist/cli/commands/test.js +65 -1
- package/dist/cli/commands/test.js.map +1 -1
- package/dist/cli/index.d.ts.map +1 -1
- package/dist/cli/index.js +21 -2
- package/dist/cli/index.js.map +1 -1
- package/dist/config/discover.d.ts.map +1 -1
- package/dist/config/discover.js +0 -14
- package/dist/config/discover.js.map +1 -1
- package/dist/core/config/namespace.d.ts +122 -120
- package/dist/core/config/namespace.d.ts.map +1 -1
- package/dist/core/config/schema.d.ts +7 -0
- package/dist/core/config/schema.d.ts.map +1 -1
- package/dist/core/config/schema.js +1 -0
- package/dist/core/config/schema.js.map +1 -1
- package/dist/data/db/col/index.d.ts +1 -1
- package/dist/data/db/col/index.d.ts.map +1 -1
- package/dist/data/db/col/index.js +1 -1
- package/dist/data/db/col/index.js.map +1 -1
- package/dist/data/db/excluded.js +2 -2
- package/dist/data/db/excluded.js.map +1 -1
- package/dist/data/db/filter.d.ts +12 -12
- package/dist/data/db/generated/drizzle-orm/aggregate.d.ts +1 -1
- package/dist/data/db/generated/drizzle-orm/aggregate.d.ts.map +1 -1
- package/dist/data/db/generated/drizzle-orm/aggregate.js +1 -1
- package/dist/data/db/generated/drizzle-orm/aggregate.js.map +1 -1
- package/dist/data/db/generated/drizzle-orm/introspection.d.ts +1 -1
- package/dist/data/db/generated/drizzle-orm/introspection.d.ts.map +1 -1
- package/dist/data/db/generated/drizzle-orm/introspection.js +1 -1
- package/dist/data/db/generated/drizzle-orm/introspection.js.map +1 -1
- package/dist/data/db/generated/drizzle-orm/operator.d.ts +1 -1
- package/dist/data/db/generated/drizzle-orm/operator.d.ts.map +1 -1
- package/dist/data/db/generated/drizzle-orm/operator.js +1 -1
- package/dist/data/db/generated/drizzle-orm/operator.js.map +1 -1
- package/dist/data/db/generated/drizzle-orm/relation.d.ts +1 -1
- package/dist/data/db/generated/drizzle-orm/relation.d.ts.map +1 -1
- package/dist/data/db/generated/drizzle-orm/relation.js +1 -1
- package/dist/data/db/generated/drizzle-orm/relation.js.map +1 -1
- package/dist/data/db/generated/drizzle-orm/type.d.ts +2 -2
- package/dist/data/db/generated/drizzle-orm/type.d.ts.map +1 -1
- package/dist/data/db/generated/drizzle-orm/type.js +1 -1
- package/dist/data/db/generated/drizzle-orm/type.js.map +1 -1
- package/dist/data/db/generated/pg-core/introspection.d.ts +1 -1
- package/dist/data/db/generated/pg-core/introspection.d.ts.map +1 -1
- package/dist/data/db/generated/pg-core/introspection.js +1 -1
- package/dist/data/db/generated/pg-core/introspection.js.map +1 -1
- package/dist/data/db/generated/pg-core/set-operation.d.ts +1 -1
- package/dist/data/db/generated/pg-core/set-operation.d.ts.map +1 -1
- package/dist/data/db/generated/pg-core/set-operation.js +1 -1
- package/dist/data/db/generated/pg-core/set-operation.js.map +1 -1
- package/dist/data/db/generated/pg-core/type.d.ts +2 -2
- package/dist/data/db/generated/pg-core/type.d.ts.map +1 -1
- package/dist/data/db/generated/pg-core/type.js +1 -1
- package/dist/data/db/generated/pg-core/type.js.map +1 -1
- package/dist/data/db/idx/index.d.ts +1 -1
- package/dist/data/db/idx/index.d.ts.map +1 -1
- package/dist/data/db/idx/index.js +1 -1
- package/dist/data/db/idx/index.js.map +1 -1
- package/dist/data/db/namespace.d.ts +43 -43
- package/dist/data/db/pool.d.ts +1 -1
- package/dist/data/db/pool.d.ts.map +1 -1
- package/dist/data/db/pool.js +1 -1
- package/dist/data/db/pool.js.map +1 -1
- package/dist/data/db/schema-features.d.ts +1 -1
- package/dist/data/db/schema-features.d.ts.map +1 -1
- package/dist/data/db/schema-features.js +1 -1
- package/dist/data/db/schema-features.js.map +1 -1
- package/dist/data/db/sql.d.ts +1 -1
- package/dist/data/db/sql.d.ts.map +1 -1
- package/dist/data/db/sql.js +1 -1
- package/dist/data/db/sql.js.map +1 -1
- package/dist/data/db/types.d.ts +3 -3
- package/dist/data/db/types.d.ts.map +1 -1
- package/dist/data/domain/project-table.d.ts +2 -2
- package/dist/data/domain/project-table.js +2 -2
- package/dist/data/domain/project-table.js.map +1 -1
- package/dist/data/domain/types.d.ts +1 -1
- package/dist/data/domain/types.d.ts.map +1 -1
- package/dist/data/migrate/apply.d.ts +8 -0
- package/dist/data/migrate/apply.d.ts.map +1 -0
- package/dist/data/migrate/apply.js +91 -0
- package/dist/data/migrate/apply.js.map +1 -0
- package/dist/data/migrate/diff.d.ts +118 -0
- package/dist/data/migrate/diff.d.ts.map +1 -0
- package/dist/data/migrate/diff.js +215 -0
- package/dist/data/migrate/diff.js.map +1 -0
- package/dist/data/migrate/generate.d.ts.map +1 -1
- package/dist/data/migrate/generate.js +12 -22
- package/dist/data/migrate/generate.js.map +1 -1
- package/dist/data/migrate/run.d.ts.map +1 -1
- package/dist/data/migrate/run.js +5 -16
- package/dist/data/migrate/run.js.map +1 -1
- package/dist/data/migrate/snapshot.d.ts +87 -0
- package/dist/data/migrate/snapshot.d.ts.map +1 -0
- package/dist/data/migrate/snapshot.js +204 -0
- package/dist/data/migrate/snapshot.js.map +1 -0
- package/dist/data/migrate/sql-emit.d.ts +3 -0
- package/dist/data/migrate/sql-emit.d.ts.map +1 -0
- package/dist/data/migrate/sql-emit.js +220 -0
- package/dist/data/migrate/sql-emit.js.map +1 -0
- package/dist/data/query/alias.d.ts +32 -0
- package/dist/data/query/alias.d.ts.map +1 -0
- package/dist/data/query/alias.js +101 -0
- package/dist/data/query/alias.js.map +1 -0
- package/dist/data/query/batch.d.ts +7 -0
- package/dist/data/query/batch.d.ts.map +1 -0
- package/dist/data/query/batch.js +2 -0
- package/dist/data/query/batch.js.map +1 -0
- package/dist/data/query/cache/core/cache.d.ts +37 -0
- package/dist/data/query/cache/core/cache.d.ts.map +1 -0
- package/dist/data/query/cache/core/cache.js +29 -0
- package/dist/data/query/cache/core/cache.js.map +1 -0
- package/dist/data/query/cache/core/index.d.ts +2 -0
- package/dist/data/query/cache/core/index.d.ts.map +1 -0
- package/dist/data/query/cache/core/index.js +2 -0
- package/dist/data/query/cache/core/index.js.map +1 -0
- package/dist/data/query/cache/core/types.d.ts +34 -0
- package/dist/data/query/cache/core/types.d.ts.map +1 -0
- package/dist/data/query/cache/core/types.js +2 -0
- package/dist/data/query/cache/core/types.js.map +1 -0
- package/dist/data/query/casing.d.ts +17 -0
- package/dist/data/query/casing.d.ts.map +1 -0
- package/dist/data/query/casing.js +62 -0
- package/dist/data/query/casing.js.map +1 -0
- package/dist/data/query/column-builder.d.ts +241 -0
- package/dist/data/query/column-builder.d.ts.map +1 -0
- package/dist/data/query/column-builder.js +105 -0
- package/dist/data/query/column-builder.js.map +1 -0
- package/dist/data/query/column.d.ts +70 -0
- package/dist/data/query/column.d.ts.map +1 -0
- package/dist/data/query/column.js +57 -0
- package/dist/data/query/column.js.map +1 -0
- package/dist/data/query/entity.d.ts +8 -0
- package/dist/data/query/entity.d.ts.map +1 -0
- package/dist/data/query/entity.js +25 -0
- package/dist/data/query/entity.js.map +1 -0
- package/dist/data/query/errors.d.ts +19 -0
- package/dist/data/query/errors.d.ts.map +1 -0
- package/dist/data/query/errors.js +31 -0
- package/dist/data/query/errors.js.map +1 -0
- package/dist/data/query/index.d.ts +15 -0
- package/dist/data/query/index.d.ts.map +1 -0
- package/dist/data/query/index.js +15 -0
- package/dist/data/query/index.js.map +1 -0
- package/dist/data/query/logger.d.ts +24 -0
- package/dist/data/query/logger.d.ts.map +1 -0
- package/dist/data/query/logger.js +33 -0
- package/dist/data/query/logger.js.map +1 -0
- package/dist/data/query/operations.d.ts +25 -0
- package/dist/data/query/operations.d.ts.map +1 -0
- package/dist/data/query/operations.js +2 -0
- package/dist/data/query/operations.js.map +1 -0
- package/dist/data/query/pg-core/alias.d.ts +5 -0
- package/dist/data/query/pg-core/alias.d.ts.map +1 -0
- package/dist/data/query/pg-core/alias.js +5 -0
- package/dist/data/query/pg-core/alias.js.map +1 -0
- package/dist/data/query/pg-core/checks.d.ts +21 -0
- package/dist/data/query/pg-core/checks.d.ts.map +1 -0
- package/dist/data/query/pg-core/checks.js +30 -0
- package/dist/data/query/pg-core/checks.js.map +1 -0
- package/dist/data/query/pg-core/columns/all.d.ts +68 -0
- package/dist/data/query/pg-core/columns/all.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/all.js +69 -0
- package/dist/data/query/pg-core/columns/all.js.map +1 -0
- package/dist/data/query/pg-core/columns/bigint.d.ts +54 -0
- package/dist/data/query/pg-core/columns/bigint.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/bigint.js +54 -0
- package/dist/data/query/pg-core/columns/bigint.js.map +1 -0
- package/dist/data/query/pg-core/columns/bigserial.d.ts +53 -0
- package/dist/data/query/pg-core/columns/bigserial.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/bigserial.js +56 -0
- package/dist/data/query/pg-core/columns/bigserial.js.map +1 -0
- package/dist/data/query/pg-core/columns/boolean.d.ts +28 -0
- package/dist/data/query/pg-core/columns/boolean.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/boolean.js +22 -0
- package/dist/data/query/pg-core/columns/boolean.js.map +1 -0
- package/dist/data/query/pg-core/columns/char.d.ts +53 -0
- package/dist/data/query/pg-core/columns/char.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/char.js +28 -0
- package/dist/data/query/pg-core/columns/char.js.map +1 -0
- package/dist/data/query/pg-core/columns/cidr.d.ts +28 -0
- package/dist/data/query/pg-core/columns/cidr.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/cidr.js +22 -0
- package/dist/data/query/pg-core/columns/cidr.js.map +1 -0
- package/dist/data/query/pg-core/columns/common.d.ts +167 -0
- package/dist/data/query/pg-core/columns/common.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/common.js +190 -0
- package/dist/data/query/pg-core/columns/common.js.map +1 -0
- package/dist/data/query/pg-core/columns/custom.d.ts +160 -0
- package/dist/data/query/pg-core/columns/custom.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/custom.js +46 -0
- package/dist/data/query/pg-core/columns/custom.js.map +1 -0
- package/dist/data/query/pg-core/columns/date.common.d.ts +8 -0
- package/dist/data/query/pg-core/columns/date.common.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/date.common.js +10 -0
- package/dist/data/query/pg-core/columns/date.common.js.map +1 -0
- package/dist/data/query/pg-core/columns/date.d.ts +57 -0
- package/dist/data/query/pg-core/columns/date.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/date.js +57 -0
- package/dist/data/query/pg-core/columns/date.js.map +1 -0
- package/dist/data/query/pg-core/columns/double-precision.d.ts +29 -0
- package/dist/data/query/pg-core/columns/double-precision.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/double-precision.js +28 -0
- package/dist/data/query/pg-core/columns/double-precision.js.map +1 -0
- package/dist/data/query/pg-core/columns/enum.d.ts +102 -0
- package/dist/data/query/pg-core/columns/enum.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/enum.js +78 -0
- package/dist/data/query/pg-core/columns/enum.js.map +1 -0
- package/dist/data/query/pg-core/columns/index.d.ts +36 -0
- package/dist/data/query/pg-core/columns/index.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/index.js +36 -0
- package/dist/data/query/pg-core/columns/index.js.map +1 -0
- package/dist/data/query/pg-core/columns/inet.d.ts +28 -0
- package/dist/data/query/pg-core/columns/inet.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/inet.js +22 -0
- package/dist/data/query/pg-core/columns/inet.js.map +1 -0
- package/dist/data/query/pg-core/columns/int.common.d.ts +16 -0
- package/dist/data/query/pg-core/columns/int.common.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/int.common.js +42 -0
- package/dist/data/query/pg-core/columns/int.common.js.map +1 -0
- package/dist/data/query/pg-core/columns/integer.d.ts +30 -0
- package/dist/data/query/pg-core/columns/integer.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/integer.js +29 -0
- package/dist/data/query/pg-core/columns/integer.js.map +1 -0
- package/dist/data/query/pg-core/columns/interval.d.ts +40 -0
- package/dist/data/query/pg-core/columns/interval.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/interval.js +29 -0
- package/dist/data/query/pg-core/columns/interval.js.map +1 -0
- package/dist/data/query/pg-core/columns/json.d.ts +33 -0
- package/dist/data/query/pg-core/columns/json.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/json.js +39 -0
- package/dist/data/query/pg-core/columns/json.js.map +1 -0
- package/dist/data/query/pg-core/columns/jsonb.d.ts +33 -0
- package/dist/data/query/pg-core/columns/jsonb.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/jsonb.js +39 -0
- package/dist/data/query/pg-core/columns/jsonb.js.map +1 -0
- package/dist/data/query/pg-core/columns/line.d.ts +69 -0
- package/dist/data/query/pg-core/columns/line.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/line.js +57 -0
- package/dist/data/query/pg-core/columns/line.js.map +1 -0
- package/dist/data/query/pg-core/columns/macaddr.d.ts +28 -0
- package/dist/data/query/pg-core/columns/macaddr.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/macaddr.js +22 -0
- package/dist/data/query/pg-core/columns/macaddr.js.map +1 -0
- package/dist/data/query/pg-core/columns/macaddr8.d.ts +28 -0
- package/dist/data/query/pg-core/columns/macaddr8.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/macaddr8.js +22 -0
- package/dist/data/query/pg-core/columns/macaddr8.js.map +1 -0
- package/dist/data/query/pg-core/columns/numeric.d.ts +112 -0
- package/dist/data/query/pg-core/columns/numeric.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/numeric.js +126 -0
- package/dist/data/query/pg-core/columns/numeric.js.map +1 -0
- package/dist/data/query/pg-core/columns/point.d.ts +72 -0
- package/dist/data/query/pg-core/columns/point.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/point.js +63 -0
- package/dist/data/query/pg-core/columns/point.js.map +1 -0
- package/dist/data/query/pg-core/columns/postgis_extension/geometry.d.ts +68 -0
- package/dist/data/query/pg-core/columns/postgis_extension/geometry.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/postgis_extension/geometry.js +57 -0
- package/dist/data/query/pg-core/columns/postgis_extension/geometry.js.map +1 -0
- package/dist/data/query/pg-core/columns/postgis_extension/utils.d.ts +2 -0
- package/dist/data/query/pg-core/columns/postgis_extension/utils.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/postgis_extension/utils.js +39 -0
- package/dist/data/query/pg-core/columns/postgis_extension/utils.js.map +1 -0
- package/dist/data/query/pg-core/columns/real.d.ts +34 -0
- package/dist/data/query/pg-core/columns/real.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/real.js +32 -0
- package/dist/data/query/pg-core/columns/real.js.map +1 -0
- package/dist/data/query/pg-core/columns/serial.d.ts +28 -0
- package/dist/data/query/pg-core/columns/serial.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/serial.js +24 -0
- package/dist/data/query/pg-core/columns/serial.js.map +1 -0
- package/dist/data/query/pg-core/columns/smallint.d.ts +30 -0
- package/dist/data/query/pg-core/columns/smallint.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/smallint.js +29 -0
- package/dist/data/query/pg-core/columns/smallint.js.map +1 -0
- package/dist/data/query/pg-core/columns/smallserial.d.ts +28 -0
- package/dist/data/query/pg-core/columns/smallserial.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/smallserial.js +24 -0
- package/dist/data/query/pg-core/columns/smallserial.js.map +1 -0
- package/dist/data/query/pg-core/columns/text.d.ts +38 -0
- package/dist/data/query/pg-core/columns/text.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/text.js +26 -0
- package/dist/data/query/pg-core/columns/text.js.map +1 -0
- package/dist/data/query/pg-core/columns/time.d.ts +45 -0
- package/dist/data/query/pg-core/columns/time.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/time.js +39 -0
- package/dist/data/query/pg-core/columns/time.js.map +1 -0
- package/dist/data/query/pg-core/columns/timestamp.d.ts +76 -0
- package/dist/data/query/pg-core/columns/timestamp.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/timestamp.js +83 -0
- package/dist/data/query/pg-core/columns/timestamp.js.map +1 -0
- package/dist/data/query/pg-core/columns/uuid.d.ts +32 -0
- package/dist/data/query/pg-core/columns/uuid.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/uuid.js +29 -0
- package/dist/data/query/pg-core/columns/uuid.js.map +1 -0
- package/dist/data/query/pg-core/columns/varchar.d.ts +53 -0
- package/dist/data/query/pg-core/columns/varchar.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/varchar.js +28 -0
- package/dist/data/query/pg-core/columns/varchar.js.map +1 -0
- package/dist/data/query/pg-core/columns/vector_extension/bit.d.ts +45 -0
- package/dist/data/query/pg-core/columns/vector_extension/bit.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/vector_extension/bit.js +26 -0
- package/dist/data/query/pg-core/columns/vector_extension/bit.js.map +1 -0
- package/dist/data/query/pg-core/columns/vector_extension/halfvec.d.ts +49 -0
- package/dist/data/query/pg-core/columns/vector_extension/halfvec.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/vector_extension/halfvec.js +35 -0
- package/dist/data/query/pg-core/columns/vector_extension/halfvec.js.map +1 -0
- package/dist/data/query/pg-core/columns/vector_extension/sparsevec.d.ts +36 -0
- package/dist/data/query/pg-core/columns/vector_extension/sparsevec.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/vector_extension/sparsevec.js +26 -0
- package/dist/data/query/pg-core/columns/vector_extension/sparsevec.js.map +1 -0
- package/dist/data/query/pg-core/columns/vector_extension/vector.d.ts +49 -0
- package/dist/data/query/pg-core/columns/vector_extension/vector.d.ts.map +1 -0
- package/dist/data/query/pg-core/columns/vector_extension/vector.js +35 -0
- package/dist/data/query/pg-core/columns/vector_extension/vector.js.map +1 -0
- package/dist/data/query/pg-core/db.d.ts +292 -0
- package/dist/data/query/pg-core/db.d.ts.map +1 -0
- package/dist/data/query/pg-core/db.js +377 -0
- package/dist/data/query/pg-core/db.js.map +1 -0
- package/dist/data/query/pg-core/dialect.d.ts +66 -0
- package/dist/data/query/pg-core/dialect.d.ts.map +1 -0
- package/dist/data/query/pg-core/dialect.js +1099 -0
- package/dist/data/query/pg-core/dialect.js.map +1 -0
- package/dist/data/query/pg-core/expressions.d.ts +9 -0
- package/dist/data/query/pg-core/expressions.d.ts.map +1 -0
- package/dist/data/query/pg-core/expressions.js +18 -0
- package/dist/data/query/pg-core/expressions.js.map +1 -0
- package/dist/data/query/pg-core/foreign-keys.d.ts +57 -0
- package/dist/data/query/pg-core/foreign-keys.d.ts.map +1 -0
- package/dist/data/query/pg-core/foreign-keys.js +70 -0
- package/dist/data/query/pg-core/foreign-keys.js.map +1 -0
- package/dist/data/query/pg-core/index.d.ts +22 -0
- package/dist/data/query/pg-core/index.d.ts.map +1 -0
- package/dist/data/query/pg-core/index.js +22 -0
- package/dist/data/query/pg-core/index.js.map +1 -0
- package/dist/data/query/pg-core/indexes.d.ts +84 -0
- package/dist/data/query/pg-core/indexes.d.ts.map +1 -0
- package/dist/data/query/pg-core/indexes.js +100 -0
- package/dist/data/query/pg-core/indexes.js.map +1 -0
- package/dist/data/query/pg-core/policies.d.ts +27 -0
- package/dist/data/query/pg-core/policies.d.ts.map +1 -0
- package/dist/data/query/pg-core/policies.js +30 -0
- package/dist/data/query/pg-core/policies.js.map +1 -0
- package/dist/data/query/pg-core/primary-keys.d.ts +37 -0
- package/dist/data/query/pg-core/primary-keys.d.ts.map +1 -0
- package/dist/data/query/pg-core/primary-keys.js +38 -0
- package/dist/data/query/pg-core/primary-keys.js.map +1 -0
- package/dist/data/query/pg-core/query-builders/count.d.ts +30 -0
- package/dist/data/query/pg-core/query-builders/count.d.ts.map +1 -0
- package/dist/data/query/pg-core/query-builders/count.js +45 -0
- package/dist/data/query/pg-core/query-builders/count.js.map +1 -0
- package/dist/data/query/pg-core/query-builders/delete.d.ts +115 -0
- package/dist/data/query/pg-core/query-builders/delete.d.ts.map +1 -0
- package/dist/data/query/pg-core/query-builders/delete.js +103 -0
- package/dist/data/query/pg-core/query-builders/delete.js.map +1 -0
- package/dist/data/query/pg-core/query-builders/index.d.ts +8 -0
- package/dist/data/query/pg-core/query-builders/index.d.ts.map +1 -0
- package/dist/data/query/pg-core/query-builders/index.js +8 -0
- package/dist/data/query/pg-core/query-builders/index.js.map +1 -0
- package/dist/data/query/pg-core/query-builders/insert.d.ts +189 -0
- package/dist/data/query/pg-core/query-builders/insert.d.ts.map +1 -0
- package/dist/data/query/pg-core/query-builders/insert.js +201 -0
- package/dist/data/query/pg-core/query-builders/insert.js.map +1 -0
- package/dist/data/query/pg-core/query-builders/query-builder.d.ts +38 -0
- package/dist/data/query/pg-core/query-builders/query-builder.d.ts.map +1 -0
- package/dist/data/query/pg-core/query-builders/query-builder.js +83 -0
- package/dist/data/query/pg-core/query-builders/query-builder.js.map +1 -0
- package/dist/data/query/pg-core/query-builders/query.d.ts +56 -0
- package/dist/data/query/pg-core/query-builders/query.d.ts.map +1 -0
- package/dist/data/query/pg-core/query-builders/query.js +104 -0
- package/dist/data/query/pg-core/query-builders/query.js.map +1 -0
- package/dist/data/query/pg-core/query-builders/raw.d.ts +27 -0
- package/dist/data/query/pg-core/query-builders/raw.d.ts.map +1 -0
- package/dist/data/query/pg-core/query-builders/raw.js +34 -0
- package/dist/data/query/pg-core/query-builders/raw.js.map +1 -0
- package/dist/data/query/pg-core/query-builders/refresh-materialized-view.d.ts +38 -0
- package/dist/data/query/pg-core/query-builders/refresh-materialized-view.d.ts.map +1 -0
- package/dist/data/query/pg-core/query-builders/refresh-materialized-view.js +58 -0
- package/dist/data/query/pg-core/query-builders/refresh-materialized-view.js.map +1 -0
- package/dist/data/query/pg-core/query-builders/select.d.ts +811 -0
- package/dist/data/query/pg-core/query-builders/select.d.ts.map +1 -0
- package/dist/data/query/pg-core/query-builders/select.js +993 -0
- package/dist/data/query/pg-core/query-builders/select.js.map +1 -0
- package/dist/data/query/pg-core/query-builders/select.types.d.ts +141 -0
- package/dist/data/query/pg-core/query-builders/select.types.d.ts.map +1 -0
- package/dist/data/query/pg-core/query-builders/select.types.js +2 -0
- package/dist/data/query/pg-core/query-builders/select.types.js.map +1 -0
- package/dist/data/query/pg-core/query-builders/update.d.ts +183 -0
- package/dist/data/query/pg-core/query-builders/update.d.ts.map +1 -0
- package/dist/data/query/pg-core/query-builders/update.js +210 -0
- package/dist/data/query/pg-core/query-builders/update.js.map +1 -0
- package/dist/data/query/pg-core/roles.d.ts +22 -0
- package/dist/data/query/pg-core/roles.d.ts.map +1 -0
- package/dist/data/query/pg-core/roles.js +29 -0
- package/dist/data/query/pg-core/roles.js.map +1 -0
- package/dist/data/query/pg-core/schema.d.ts +23 -0
- package/dist/data/query/pg-core/schema.d.ts.map +1 -0
- package/dist/data/query/pg-core/schema.js +46 -0
- package/dist/data/query/pg-core/schema.js.map +1 -0
- package/dist/data/query/pg-core/sequence.d.ts +21 -0
- package/dist/data/query/pg-core/sequence.d.ts.map +1 -0
- package/dist/data/query/pg-core/sequence.js +23 -0
- package/dist/data/query/pg-core/sequence.js.map +1 -0
- package/dist/data/query/pg-core/session.d.ts +94 -0
- package/dist/data/query/pg-core/session.d.ts.map +1 -0
- package/dist/data/query/pg-core/session.js +169 -0
- package/dist/data/query/pg-core/session.js.map +1 -0
- package/dist/data/query/pg-core/subquery.d.ts +19 -0
- package/dist/data/query/pg-core/subquery.d.ts.map +1 -0
- package/dist/data/query/pg-core/subquery.js +2 -0
- package/dist/data/query/pg-core/subquery.js.map +1 -0
- package/dist/data/query/pg-core/table.d.ts +129 -0
- package/dist/data/query/pg-core/table.d.ts.map +1 -0
- package/dist/data/query/pg-core/table.js +62 -0
- package/dist/data/query/pg-core/table.js.map +1 -0
- package/dist/data/query/pg-core/unique-constraint.d.ts +34 -0
- package/dist/data/query/pg-core/unique-constraint.d.ts.map +1 -0
- package/dist/data/query/pg-core/unique-constraint.js +56 -0
- package/dist/data/query/pg-core/unique-constraint.js.map +1 -0
- package/dist/data/query/pg-core/utils/array.d.ts +4 -0
- package/dist/data/query/pg-core/utils/array.d.ts.map +1 -0
- package/dist/data/query/pg-core/utils/array.js +75 -0
- package/dist/data/query/pg-core/utils/array.js.map +1 -0
- package/dist/data/query/pg-core/utils/index.d.ts +2 -0
- package/dist/data/query/pg-core/utils/index.d.ts.map +1 -0
- package/dist/data/query/pg-core/utils/index.js +2 -0
- package/dist/data/query/pg-core/utils/index.js.map +1 -0
- package/dist/data/query/pg-core/utils.d.ts +56 -0
- package/dist/data/query/pg-core/utils.d.ts.map +1 -0
- package/dist/data/query/pg-core/utils.js +88 -0
- package/dist/data/query/pg-core/utils.js.map +1 -0
- package/dist/data/query/pg-core/view-base.d.ts +9 -0
- package/dist/data/query/pg-core/view-base.d.ts.map +1 -0
- package/dist/data/query/pg-core/view-base.js +6 -0
- package/dist/data/query/pg-core/view-base.js.map +1 -0
- package/dist/data/query/pg-core/view-common.d.ts +2 -0
- package/dist/data/query/pg-core/view-common.d.ts.map +1 -0
- package/dist/data/query/pg-core/view-common.js +2 -0
- package/dist/data/query/pg-core/view-common.js.map +1 -0
- package/dist/data/query/pg-core/view.d.ts +161 -0
- package/dist/data/query/pg-core/view.d.ts.map +1 -0
- package/dist/data/query/pg-core/view.js +243 -0
- package/dist/data/query/pg-core/view.js.map +1 -0
- package/dist/data/query/postgres-js/driver.d.ts +30 -0
- package/dist/data/query/postgres-js/driver.d.ts.map +1 -0
- package/dist/data/query/postgres-js/driver.js +77 -0
- package/dist/data/query/postgres-js/driver.js.map +1 -0
- package/dist/data/query/postgres-js/index.d.ts +3 -0
- package/dist/data/query/postgres-js/index.d.ts.map +1 -0
- package/dist/data/query/postgres-js/index.js +3 -0
- package/dist/data/query/postgres-js/index.js.map +1 -0
- package/dist/data/query/postgres-js/session.d.ts +67 -0
- package/dist/data/query/postgres-js/session.d.ts.map +1 -0
- package/dist/data/query/postgres-js/session.js +139 -0
- package/dist/data/query/postgres-js/session.js.map +1 -0
- package/dist/data/query/primary-key.d.ts +11 -0
- package/dist/data/query/primary-key.d.ts.map +1 -0
- package/dist/data/query/primary-key.js +11 -0
- package/dist/data/query/primary-key.js.map +1 -0
- package/dist/data/query/query-builders/query-builder.d.ts +14 -0
- package/dist/data/query/query-builders/query-builder.d.ts.map +1 -0
- package/dist/data/query/query-builders/query-builder.js +9 -0
- package/dist/data/query/query-builders/query-builder.js.map +1 -0
- package/dist/data/query/query-builders/select.types.d.ts +59 -0
- package/dist/data/query/query-builders/select.types.d.ts.map +1 -0
- package/dist/data/query/query-builders/select.types.js +2 -0
- package/dist/data/query/query-builders/select.types.js.map +1 -0
- package/dist/data/query/query-promise.d.ts +10 -0
- package/dist/data/query/query-promise.d.ts.map +1 -0
- package/dist/data/query/query-promise.js +21 -0
- package/dist/data/query/query-promise.js.map +1 -0
- package/dist/data/query/relations.d.ts +216 -0
- package/dist/data/query/relations.d.ts.map +1 -0
- package/dist/data/query/relations.js +257 -0
- package/dist/data/query/relations.js.map +1 -0
- package/dist/data/query/runnable-query.d.ts +11 -0
- package/dist/data/query/runnable-query.d.ts.map +1 -0
- package/dist/data/query/runnable-query.js +2 -0
- package/dist/data/query/runnable-query.js.map +1 -0
- package/dist/data/query/selection-proxy.d.ts +10 -0
- package/dist/data/query/selection-proxy.d.ts.map +1 -0
- package/dist/data/query/selection-proxy.js +62 -0
- package/dist/data/query/selection-proxy.js.map +1 -0
- package/dist/data/query/session.d.ts +8 -0
- package/dist/data/query/session.d.ts.map +1 -0
- package/dist/data/query/session.js +2 -0
- package/dist/data/query/session.js.map +1 -0
- package/dist/data/query/sql/expressions/conditions.d.ts +454 -0
- package/dist/data/query/sql/expressions/conditions.d.ts.map +1 -0
- package/dist/data/query/sql/expressions/conditions.js +393 -0
- package/dist/data/query/sql/expressions/conditions.js.map +1 -0
- package/dist/data/query/sql/expressions/index.d.ts +3 -0
- package/dist/data/query/sql/expressions/index.d.ts.map +1 -0
- package/dist/data/query/sql/expressions/index.js +3 -0
- package/dist/data/query/sql/expressions/index.js.map +1 -0
- package/dist/data/query/sql/expressions/select.d.ts +39 -0
- package/dist/data/query/sql/expressions/select.d.ts.map +1 -0
- package/dist/data/query/sql/expressions/select.js +42 -0
- package/dist/data/query/sql/expressions/select.js.map +1 -0
- package/dist/data/query/sql/functions/aggregate.d.ts +105 -0
- package/dist/data/query/sql/functions/aggregate.d.ts.map +1 -0
- package/dist/data/query/sql/functions/aggregate.js +122 -0
- package/dist/data/query/sql/functions/aggregate.js.map +1 -0
- package/dist/data/query/sql/functions/index.d.ts +3 -0
- package/dist/data/query/sql/functions/index.d.ts.map +1 -0
- package/dist/data/query/sql/functions/index.js +3 -0
- package/dist/data/query/sql/functions/index.js.map +1 -0
- package/dist/data/query/sql/functions/vector.d.ts +121 -0
- package/dist/data/query/sql/functions/vector.d.ts.map +1 -0
- package/dist/data/query/sql/functions/vector.js +152 -0
- package/dist/data/query/sql/functions/vector.js.map +1 -0
- package/dist/data/query/sql/index.d.ts +4 -0
- package/dist/data/query/sql/index.d.ts.map +1 -0
- package/dist/data/query/sql/index.js +4 -0
- package/dist/data/query/sql/index.js.map +1 -0
- package/dist/data/query/sql/sql.d.ts +254 -0
- package/dist/data/query/sql/sql.d.ts.map +1 -0
- package/dist/data/query/sql/sql.js +478 -0
- package/dist/data/query/sql/sql.js.map +1 -0
- package/dist/data/query/subquery.d.ts +21 -0
- package/dist/data/query/subquery.d.ts.map +1 -0
- package/dist/data/query/subquery.js +18 -0
- package/dist/data/query/subquery.js.map +1 -0
- package/dist/data/query/table.d.ts +142 -0
- package/dist/data/query/table.d.ts.map +1 -0
- package/dist/data/query/table.js +73 -0
- package/dist/data/query/table.js.map +1 -0
- package/dist/data/query/table.utils.d.ts +3 -0
- package/dist/data/query/table.utils.d.ts.map +1 -0
- package/dist/data/query/table.utils.js +3 -0
- package/dist/data/query/table.utils.js.map +1 -0
- package/dist/data/query/tracing-utils.d.ts +2 -0
- package/dist/data/query/tracing-utils.d.ts.map +1 -0
- package/dist/data/query/tracing-utils.js +4 -0
- package/dist/data/query/tracing-utils.js.map +1 -0
- package/dist/data/query/tracing.d.ts +10 -0
- package/dist/data/query/tracing.d.ts.map +1 -0
- package/dist/data/query/tracing.js +7 -0
- package/dist/data/query/tracing.js.map +1 -0
- package/dist/data/query/utils.d.ts +81 -0
- package/dist/data/query/utils.d.ts.map +1 -0
- package/dist/data/query/utils.js +193 -0
- package/dist/data/query/utils.js.map +1 -0
- package/dist/data/query/version.d.ts +3 -0
- package/dist/data/query/version.d.ts.map +1 -0
- package/dist/data/query/version.js +5 -0
- package/dist/data/query/version.js.map +1 -0
- package/dist/data/query/view-common.d.ts +2 -0
- package/dist/data/query/view-common.d.ts.map +1 -0
- package/dist/data/query/view-common.js +2 -0
- package/dist/data/query/view-common.js.map +1 -0
- package/dist/data/schema/namespace.d.ts +2 -2
- package/dist/data/temporal/columns.d.ts +4 -4
- package/dist/data/vector/types.d.ts +2 -2
- package/dist/db/index.d.ts +0 -1
- package/dist/db/index.d.ts.map +1 -1
- package/dist/db/index.js +0 -1
- package/dist/db/index.js.map +1 -1
- package/dist/db/namespace.d.ts +0 -5
- package/dist/db/namespace.d.ts.map +1 -1
- package/dist/db/namespace.js +0 -5
- package/dist/db/namespace.js.map +1 -1
- package/dist/domain/define.d.ts.map +1 -1
- package/dist/domain/define.js.map +1 -1
- package/dist/domain/field.d.ts +2 -4
- package/dist/domain/field.d.ts.map +1 -1
- package/dist/domain/field.js.map +1 -1
- package/dist/domain/index.d.ts +1 -1
- package/dist/domain/index.d.ts.map +1 -1
- package/dist/domain/types.d.ts +9 -37
- package/dist/domain/types.d.ts.map +1 -1
- package/dist/drizzle/index.d.ts +3 -0
- package/dist/drizzle/index.d.ts.map +1 -0
- package/dist/drizzle/index.js +3 -0
- package/dist/drizzle/index.js.map +1 -0
- package/dist/log/namespace.d.ts +1 -1
- package/dist/logging/index.d.ts +1 -1
- package/dist/logging/index.d.ts.map +1 -1
- package/dist/logging/proxy.d.ts +2 -2
- package/dist/logging/proxy.d.ts.map +1 -1
- package/dist/logging/proxy.js +2 -9
- package/dist/logging/proxy.js.map +1 -1
- package/dist/logging/types.d.ts +0 -7
- package/dist/logging/types.d.ts.map +1 -1
- package/dist/resource/batch.d.ts +17 -0
- package/dist/resource/batch.d.ts.map +1 -0
- package/dist/resource/batch.js +47 -0
- package/dist/resource/batch.js.map +1 -0
- package/dist/resource/builder.d.ts +11 -0
- package/dist/resource/builder.d.ts.map +1 -0
- package/dist/resource/builder.js +12 -0
- package/dist/resource/builder.js.map +1 -0
- package/dist/resource/errors.d.ts +7 -0
- package/dist/resource/errors.d.ts.map +1 -0
- package/dist/resource/errors.js +9 -0
- package/dist/resource/errors.js.map +1 -0
- package/dist/resource/index.d.ts +9 -0
- package/dist/resource/index.d.ts.map +1 -0
- package/dist/resource/index.js +6 -0
- package/dist/resource/index.js.map +1 -0
- package/dist/resource/paginate.d.ts +13 -0
- package/dist/resource/paginate.d.ts.map +1 -0
- package/dist/resource/paginate.js +29 -0
- package/dist/resource/paginate.js.map +1 -0
- package/dist/resource/register.d.ts +16 -0
- package/dist/resource/register.d.ts.map +1 -0
- package/dist/resource/register.js +181 -0
- package/dist/resource/register.js.map +1 -0
- package/dist/resource/types.d.ts +69 -0
- package/dist/resource/types.d.ts.map +1 -0
- package/dist/resource/types.js +2 -0
- package/dist/resource/types.js.map +1 -0
- package/dist/surface/http.d.ts +2 -2
- package/dist/surface/http.d.ts.map +1 -1
- package/dist/surface/http.js +8 -25
- package/dist/surface/http.js.map +1 -1
- package/dist/surface/index.d.ts +1 -1
- package/dist/surface/index.d.ts.map +1 -1
- package/dist/surface/namespace.d.ts +1 -1
- package/dist/surface/namespace.d.ts.map +1 -1
- package/dist/surface/namespace.js +1 -1
- package/dist/surface/namespace.js.map +1 -1
- package/dist/surface/types.d.ts +0 -7
- package/dist/surface/types.d.ts.map +1 -1
- package/dist/temporal/definition-queries.d.ts +5 -5
- package/dist/temporal/definition-queries.d.ts.map +1 -1
- package/dist/temporal/definition-queries.js.map +1 -1
- package/dist/test/plugin.d.ts +2 -1
- package/dist/test/plugin.d.ts.map +1 -1
- package/dist/test/plugin.js +10 -2
- package/dist/test/plugin.js.map +1 -1
- package/dist/test/setup.d.ts.map +1 -1
- package/dist/test/setup.js +6 -4
- package/dist/test/setup.js.map +1 -1
- package/dist/test/vitest.d.ts +2 -2
- package/dist/test/vitest.d.ts.map +1 -1
- package/dist/test/vitest.js +6 -3
- package/dist/test/vitest.js.map +1 -1
- package/dist/trunk.d.ts +35 -0
- package/dist/trunk.d.ts.map +1 -0
- package/dist/trunk.js +102 -0
- package/dist/trunk.js.map +1 -0
- package/dist/validation/surface.d.ts +4 -0
- package/dist/validation/surface.d.ts.map +1 -0
- package/dist/validation/surface.js +55 -0
- package/dist/validation/surface.js.map +1 -0
- package/dist/vector/index.d.ts +1 -2
- package/dist/vector/index.d.ts.map +1 -1
- package/dist/vector/index.js +1 -1
- package/dist/vector/index.js.map +1 -1
- package/dist/vector/namespace.d.ts +4 -10
- package/dist/vector/namespace.d.ts.map +1 -1
- package/dist/vector/namespace.js +4 -10
- package/dist/vector/namespace.js.map +1 -1
- package/dist/vector/query.d.ts +2 -15
- package/dist/vector/query.d.ts.map +1 -1
- package/dist/vector/query.js +1 -39
- package/dist/vector/query.js.map +1 -1
- package/dist/webhook/verify.d.ts +3 -5
- package/dist/webhook/verify.d.ts.map +1 -1
- package/dist/webhook/verify.js +2 -5
- package/dist/webhook/verify.js.map +1 -1
- package/dist/workspace/affected.d.ts +17 -0
- package/dist/workspace/affected.d.ts.map +1 -0
- package/dist/workspace/affected.js +29 -0
- package/dist/workspace/affected.js.map +1 -0
- package/dist/workspace/changed-files.d.ts +7 -0
- package/dist/workspace/changed-files.d.ts.map +1 -0
- package/dist/workspace/changed-files.js +38 -0
- package/dist/workspace/changed-files.js.map +1 -0
- package/dist/workspace/dependency-graph.d.ts +8 -0
- package/dist/workspace/dependency-graph.d.ts.map +1 -0
- package/dist/workspace/dependency-graph.js +54 -0
- package/dist/workspace/dependency-graph.js.map +1 -0
- package/dist/workspace/index.d.ts +3 -0
- package/dist/workspace/index.d.ts.map +1 -1
- package/dist/workspace/index.js +3 -0
- package/dist/workspace/index.js.map +1 -1
- package/package.json +33 -24
- package/dist/config/ts-register.d.ts +0 -2
- package/dist/config/ts-register.d.ts.map +0 -1
- package/dist/config/ts-register.js +0 -3
- package/dist/config/ts-register.js.map +0 -1
- package/dist/config/ts-resolve-hooks.d.ts +0 -10
- package/dist/config/ts-resolve-hooks.d.ts.map +0 -1
- package/dist/config/ts-resolve-hooks.js +0 -14
- package/dist/config/ts-resolve-hooks.js.map +0 -1
- package/dist/db/excluded.d.ts +0 -7
- package/dist/db/excluded.d.ts.map +0 -1
- package/dist/db/excluded.js +0 -11
- package/dist/db/excluded.js.map +0 -1
- package/dist/jsonb/index.d.ts +0 -2
- package/dist/jsonb/index.d.ts.map +0 -1
- package/dist/jsonb/index.js +0 -2
- package/dist/jsonb/index.js.map +0 -1
- package/dist/jsonb/namespace.d.ts +0 -11
- package/dist/jsonb/namespace.d.ts.map +0 -1
- package/dist/jsonb/namespace.js +0 -11
- package/dist/jsonb/namespace.js.map +0 -1
- package/dist/jsonb/query.d.ts +0 -5
- package/dist/jsonb/query.d.ts.map +0 -1
- package/dist/jsonb/query.js +0 -11
- package/dist/jsonb/query.js.map +0 -1
- package/dist/validation/doctrine.d.ts +0 -13
- package/dist/validation/doctrine.d.ts.map +0 -1
- package/dist/validation/doctrine.js +0 -115
- package/dist/validation/doctrine.js.map +0 -1
package/dist/REFERENCE.md
CHANGED
|
@@ -1,53 +1,42 @@
|
|
|
1
1
|
# Pipework API Reference
|
|
2
2
|
|
|
3
3
|
> Auto-generated from source JSDoc. Do not edit manually.
|
|
4
|
-
> Generated: 2026-05-
|
|
4
|
+
> Generated: 2026-05-11
|
|
5
5
|
|
|
6
6
|
## Contents
|
|
7
7
|
|
|
8
|
-
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
- [state](#state)
|
|
35
|
-
- [cache — Caching](#cache-caching)
|
|
36
|
-
- [audit — Audit Logging](#audit-audit-logging)
|
|
37
|
-
- **[Extensions](#extensions)** — Vector search, webhooks, JSON operations, and idempotency.
|
|
38
|
-
- [vector — Vector & Full-Text Search](#vector-vector-full-text-search)
|
|
39
|
-
- [webhook — Inbound & Outbound Webhooks](#webhook-inbound-outbound-webhooks)
|
|
40
|
-
- [jsonb](#jsonb)
|
|
8
|
+
- [Core](#core)
|
|
9
|
+
- [jobs — Background Jobs](#jobs-background-jobs)
|
|
10
|
+
- [pipeline — Multi-Step Pipelines](#pipeline-multi-step-pipelines)
|
|
11
|
+
- [state — State Machines](#state-state-machines)
|
|
12
|
+
- [auth — Authentication](#auth-authentication)
|
|
13
|
+
- [rbac — Access Control](#rbac-access-control)
|
|
14
|
+
- [tenant — Multi-Tenancy](#tenant-multi-tenancy)
|
|
15
|
+
- [config — Configuration](#config-configuration)
|
|
16
|
+
- [errors — Error Classes](#errors-error-classes)
|
|
17
|
+
- [lifecycle — Startup & Shutdown](#lifecycle-startup-shutdown)
|
|
18
|
+
- [log — Structured Logging](#log-structured-logging)
|
|
19
|
+
- [surface — Entry Points](#surface-entry-points)
|
|
20
|
+
- [pipe — Database](#pipe-database)
|
|
21
|
+
- [jsonb — JSONB Column Helpers](#jsonb-jsonb-column-helpers)
|
|
22
|
+
- [schema — Validation & Schema](#schema-validation-schema)
|
|
23
|
+
- [temporal — Bitemporal Data](#temporal-bitemporal-data)
|
|
24
|
+
- [vector — Vector & Full-Text Search](#vector-vector-full-text-search)
|
|
25
|
+
- [audit — Audit Logging](#audit-audit-logging)
|
|
26
|
+
- [cache — Caching](#cache-caching)
|
|
27
|
+
- [webhook — Inbound & Outbound Webhooks](#webhook-inbound-outbound-webhooks)
|
|
28
|
+
- [behavior — Resource Decorators](#behavior-resource-decorators)
|
|
29
|
+
- [fitting — Dependency Injection](#fitting-dependency-injection)
|
|
30
|
+
- [fixture — REST Resources](#fixture-rest-resources)
|
|
31
|
+
- [flow — Context (AsyncLocalStorage)](#flow-context-asynclocalstorage)
|
|
32
|
+
- [http — Server](#http-server)
|
|
33
|
+
- [openapi — API Documentation](#openapi-api-documentation)
|
|
41
34
|
|
|
42
35
|
## Core
|
|
43
36
|
|
|
44
|
-
Application setup, configuration, entry points, and infrastructure.
|
|
45
|
-
|
|
46
|
-
### Core
|
|
47
|
-
|
|
48
37
|
Application instance and foundational types.
|
|
49
38
|
|
|
50
|
-
|
|
39
|
+
### `createManifold`
|
|
51
40
|
|
|
52
41
|
Creates the Pipework application instance. This is the entry point for every Pipework app. Define in `pipework.config.ts` and export as default. /
|
|
53
42
|
|
|
@@ -55,7 +44,7 @@ Creates the Pipework application instance. This is the entry point for every Pip
|
|
|
55
44
|
function createManifold<const TEnv extends EnvDefs = EnvDefs>( raw: Omit<Blueprint, 'env'> &
|
|
56
45
|
```
|
|
57
46
|
|
|
58
|
-
|
|
47
|
+
### Types
|
|
59
48
|
|
|
60
49
|
**`Manifold`** — The application instance — holds config, connection pools, surfaces, and lifecycle.
|
|
61
50
|
|
|
@@ -87,311 +76,91 @@ interface IsolationState
|
|
|
87
76
|
interface ConnectionTracker
|
|
88
77
|
```
|
|
89
78
|
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
Configuration namespace — loads and resolves Blueprint configs, discovers pipework.config.ts.
|
|
93
|
-
|
|
94
|
-
#### `config.load`
|
|
95
|
-
|
|
96
|
-
Parses and resolves a raw Blueprint into a ResolvedConfig with environment detection.
|
|
97
|
-
|
|
98
|
-
#### `config.discover`
|
|
99
|
-
|
|
100
|
-
Walks up from cwd to find pipework.config.ts, imports it, and returns the Manifold.
|
|
101
|
-
|
|
102
|
-
#### `config.configSchema`
|
|
103
|
-
|
|
104
|
-
The zod schema for Blueprint validation — useful for custom config tooling.
|
|
105
|
-
|
|
106
|
-
#### `config.ConfigError`
|
|
107
|
-
|
|
108
|
-
Thrown for configuration problems — includes a suggestion for how to fix.
|
|
109
|
-
|
|
110
|
-
### surface — Entry Points
|
|
111
|
-
|
|
112
|
-
Surface namespace — declarative entry points that define how the app runs (HTTP server, background worker, one-shot script).
|
|
113
|
-
|
|
114
|
-
#### `surface.http`
|
|
115
|
-
|
|
116
|
-
Creates an HTTP surface — a Fastify server with routes, middleware, and production validation. Returns an HttpSurfaceBuilder with a .test() method for inject()-based integration tests.
|
|
117
|
-
|
|
118
|
-
#### `surface.worker`
|
|
119
|
-
|
|
120
|
-
Creates a worker surface — a long-running process that claims and executes jobs from queues.
|
|
121
|
-
|
|
122
|
-
#### `surface.script`
|
|
123
|
-
|
|
124
|
-
Creates a script surface — a one-shot process that runs and exits (migrations, seeds, CLI tools).
|
|
125
|
-
|
|
126
|
-
### lifecycle — Startup & Shutdown
|
|
127
|
-
|
|
128
|
-
Application lifecycle namespace — startup orchestration with hooks and timeouts.
|
|
129
|
-
|
|
130
|
-
#### `lifecycle.orchestrate`
|
|
131
|
-
|
|
132
|
-
Runs pre-start hooks (DB readiness checks, migrations, etc.) with a configurable timeout.
|
|
133
|
-
|
|
134
|
-
### errors — Error Classes
|
|
135
|
-
|
|
136
|
-
Standard error classes — all extend PipeworkError with structured error codes and actionable messages.
|
|
137
|
-
|
|
138
|
-
#### `errors.Base`
|
|
139
|
-
|
|
140
|
-
Base error class with code, statusCode, and suggestion fields.
|
|
141
|
-
|
|
142
|
-
#### `errors.NotFound`
|
|
143
|
-
|
|
144
|
-
404 — resource not found.
|
|
145
|
-
|
|
146
|
-
#### `errors.Unauthorized`
|
|
147
|
-
|
|
148
|
-
401 — missing or invalid authentication.
|
|
149
|
-
|
|
150
|
-
#### `errors.Forbidden`
|
|
151
|
-
|
|
152
|
-
403 — authenticated but insufficient permissions.
|
|
153
|
-
|
|
154
|
-
#### `errors.Validation`
|
|
155
|
-
|
|
156
|
-
422 — input validation failed, carries field-level details.
|
|
157
|
-
|
|
158
|
-
#### `errors.Conflict`
|
|
159
|
-
|
|
160
|
-
409 — resource state conflict (duplicate, version mismatch).
|
|
161
|
-
|
|
162
|
-
### log — Structured Logging
|
|
163
|
-
|
|
164
|
-
Structured logger (Pino) — auto-binds requestId, tenantId, userId, sessionId from ALS context on every log call.
|
|
165
|
-
|
|
166
|
-
#### `log.create`
|
|
167
|
-
|
|
168
|
-
Creates a new PipeworkLogger instance with custom config (level, redaction, transport).
|
|
169
|
-
|
|
170
|
-
#### `log.get`
|
|
171
|
-
|
|
172
|
-
Returns the context-aware logger proxy (same as the log export itself).
|
|
173
|
-
|
|
174
|
-
#### `log.getBase`
|
|
175
|
-
|
|
176
|
-
Returns the raw Pino logger without ALS context binding.
|
|
177
|
-
|
|
178
|
-
#### `log.configure`
|
|
179
|
-
|
|
180
|
-
Sets global logging config (level, redaction paths, custom context fields).
|
|
181
|
-
|
|
182
|
-
#### `log.REDACT_PATHS`
|
|
183
|
-
|
|
184
|
-
Default redaction paths — password, secret, token, authorization, cookie, etc.
|
|
185
|
-
|
|
186
|
-
## Data Layer
|
|
187
|
-
|
|
188
|
-
Database access, domain definitions, schema validation, and queries.
|
|
189
|
-
|
|
190
|
-
### pipe — Database
|
|
191
|
-
|
|
192
|
-
Database accessor — returns a Drizzle DB instance scoped to the current request/job/test context. Requires active AsyncLocalStorage context.
|
|
193
|
-
|
|
194
|
-
#### `pipe.filter`
|
|
195
|
-
|
|
196
|
-
Query operators and aggregates — eq, gt, lt, and, or, count, sum, etc.
|
|
197
|
-
|
|
198
|
-
#### `pipe.migrate`
|
|
199
|
-
|
|
200
|
-
Runs migrations for all configured databases.
|
|
201
|
-
|
|
202
|
-
#### `pipe.migrateOne`
|
|
203
|
-
|
|
204
|
-
Runs migrations for a single named database.
|
|
205
|
-
|
|
206
|
-
#### `pipe.excluded`
|
|
207
|
-
|
|
208
|
-
Returns excluded-column references for onConflictDoUpdate set clauses.
|
|
209
|
-
|
|
210
|
-
#### `pipe.field`
|
|
211
|
-
|
|
212
|
-
Field builders for domain definitions — uuid(), text(), integer(), etc.
|
|
213
|
-
|
|
214
|
-
#### `pipe.define`
|
|
215
|
-
|
|
216
|
-
Registers a domain definition with table, validators, and factory projections.
|
|
217
|
-
|
|
218
|
-
#### `pipe.definitions`
|
|
219
|
-
|
|
220
|
-
Returns the global registry of all domain definitions.
|
|
221
|
-
|
|
222
|
-
### schema — Validation & Schema
|
|
223
|
-
|
|
224
|
-
Schema definition and validation namespace — wraps zod for validation, drizzle for table/column/index definitions.
|
|
225
|
-
|
|
226
|
-
#### `schema.check`
|
|
227
|
-
|
|
228
|
-
Validation sub-namespace — type constructors, combinators, formats, coerce, parse, tryParse, toJsonSchema, branded.
|
|
229
|
-
|
|
230
|
-
#### `schema.col`
|
|
231
|
-
|
|
232
|
-
Column type builders for table definitions — text, uuid, integer, timestamp, jsonb, boolean, varchar, etc.
|
|
233
|
-
|
|
234
|
-
#### `schema.idx`
|
|
235
|
-
|
|
236
|
-
Index and constraint builders — index, uniqueIndex, primaryKey, foreignKey, unique, check.
|
|
237
|
-
|
|
238
|
-
#### Types
|
|
239
|
-
|
|
240
|
-
**`Schema`** — Any validation schema — the base type accepted by .input(), .query(), .params() in the fitting builder.
|
|
241
|
-
|
|
242
|
-
```typescript
|
|
243
|
-
type Schema<T = unknown> = z.ZodType<T>
|
|
244
|
-
```
|
|
245
|
-
|
|
246
|
-
**`Infer`** — Extracts the TypeScript type from a Schema — Infer<typeof mySchema> gives you the validated type.
|
|
247
|
-
|
|
248
|
-
```typescript
|
|
249
|
-
type Infer<T extends Schema> = z.infer<T>
|
|
250
|
-
```
|
|
251
|
-
|
|
252
|
-
## Request Handling
|
|
253
|
-
|
|
254
|
-
HTTP server, route builders, context, and API docs.
|
|
255
|
-
|
|
256
|
-
### fitting — Dependency Injection
|
|
257
|
-
|
|
258
|
-
### http — Server
|
|
259
|
-
|
|
260
|
-
HTTP server namespace — managed by manifold.start(), not directly accessible.
|
|
261
|
-
|
|
262
|
-
#### Types
|
|
263
|
-
|
|
264
|
-
**`CorsConfig`** — CORS configuration — origin, methods, headers, credentials, maxAge.
|
|
265
|
-
|
|
266
|
-
```typescript
|
|
267
|
-
interface CorsConfig
|
|
268
|
-
```
|
|
269
|
-
|
|
270
|
-
**`SecurityConfig`** — Security header configuration — passed to @fastify/helmet.
|
|
271
|
-
|
|
272
|
-
```typescript
|
|
273
|
-
interface SecurityConfig
|
|
274
|
-
```
|
|
275
|
-
|
|
276
|
-
**`RateLimitConfig`** — Rate limiting configuration — max requests, time window, key generator.
|
|
277
|
-
|
|
278
|
-
```typescript
|
|
279
|
-
interface RateLimitConfig
|
|
280
|
-
```
|
|
281
|
-
|
|
282
|
-
**`InjectOptions`** — Options for server.inject() — method, url, headers, payload for testing without HTTP.
|
|
283
|
-
|
|
284
|
-
```typescript
|
|
285
|
-
interface InjectOptions
|
|
286
|
-
```
|
|
287
|
-
|
|
288
|
-
**`InjectResponse`** — Response from server.inject() — statusCode, headers, body, json() helper.
|
|
289
|
-
|
|
290
|
-
```typescript
|
|
291
|
-
interface InjectResponse
|
|
292
|
-
```
|
|
293
|
-
|
|
294
|
-
**`ServerConfig`** — Configuration for http.createServer() — CORS, security headers, rate limiting, transaction timeout.
|
|
295
|
-
|
|
296
|
-
```typescript
|
|
297
|
-
interface ServerConfig
|
|
298
|
-
```
|
|
79
|
+
## jobs — Background Jobs
|
|
299
80
|
|
|
300
|
-
|
|
81
|
+
Background job queue namespace — Postgres-backed with SKIP LOCKED, LISTEN/NOTIFY, cron scheduling.
|
|
301
82
|
|
|
302
|
-
|
|
303
|
-
interface HandlerResponse
|
|
304
|
-
```
|
|
83
|
+
### `jobs.createQueue`
|
|
305
84
|
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
```typescript
|
|
309
|
-
interface ErrorResponse
|
|
310
|
-
```
|
|
85
|
+
Creates a job queue with claim/complete/fail lifecycle, heartbeat, and dead letter requeue.
|
|
311
86
|
|
|
312
|
-
|
|
87
|
+
### `jobs.execute`
|
|
313
88
|
|
|
314
|
-
|
|
315
|
-
interface PipeworkServer
|
|
316
|
-
```
|
|
89
|
+
Executes a fitting handler as a background job with its own Flow context.
|
|
317
90
|
|
|
318
|
-
|
|
91
|
+
### `jobs.parseCron`
|
|
319
92
|
|
|
320
|
-
|
|
321
|
-
interface HttpRequest
|
|
322
|
-
```
|
|
93
|
+
Parses a 5-field cron expression into a CronSchedule (minute, hour, dom, month, dow).
|
|
323
94
|
|
|
324
|
-
|
|
95
|
+
### `jobs.nextTick`
|
|
325
96
|
|
|
326
|
-
|
|
327
|
-
interface HttpResponse
|
|
328
|
-
```
|
|
97
|
+
Computes the next fire time for a CronSchedule after a given date, with optional timezone.
|
|
329
98
|
|
|
330
|
-
|
|
99
|
+
## pipeline — Multi-Step Pipelines
|
|
331
100
|
|
|
332
|
-
|
|
101
|
+
Multi-step pipeline namespace — define, execute, pause, and resume ordered step sequences.
|
|
333
102
|
|
|
334
|
-
|
|
103
|
+
### `pipeline.define`
|
|
335
104
|
|
|
336
|
-
|
|
105
|
+
Defines a pipeline from a config of named steps with handlers. Returns a Pipeline with execute/resume/getStatus.
|
|
337
106
|
|
|
338
|
-
|
|
107
|
+
### `pipeline.PipelineStepError`
|
|
339
108
|
|
|
340
|
-
|
|
109
|
+
Thrown when an individual pipeline step fails.
|
|
341
110
|
|
|
342
|
-
|
|
111
|
+
### `pipeline.PipelineResumeError`
|
|
343
112
|
|
|
344
|
-
|
|
113
|
+
Thrown when resuming a pipeline from an invalid state.
|
|
345
114
|
|
|
346
|
-
|
|
115
|
+
## state — State Machines
|
|
347
116
|
|
|
348
|
-
|
|
117
|
+
State machine namespace — define valid transitions with guards and side effects.
|
|
349
118
|
|
|
350
|
-
###
|
|
119
|
+
### `state.define`
|
|
351
120
|
|
|
352
|
-
|
|
121
|
+
Defines a state machine from states, transitions, guards, and effects. Returns a StateMachine with transition/canTransition.
|
|
353
122
|
|
|
354
|
-
|
|
123
|
+
### `state.InvalidTransitionError`
|
|
355
124
|
|
|
356
|
-
|
|
125
|
+
Thrown when a transition is not allowed from the current state.
|
|
357
126
|
|
|
358
|
-
|
|
127
|
+
### `state.InvalidStateMachineError`
|
|
359
128
|
|
|
360
|
-
|
|
129
|
+
Thrown when the state machine definition is internally inconsistent.
|
|
361
130
|
|
|
362
|
-
|
|
131
|
+
## auth — Authentication
|
|
363
132
|
|
|
364
133
|
Authentication namespace — session management, multi-org support, auth chain resolution.
|
|
365
134
|
|
|
366
|
-
|
|
135
|
+
### `auth.createSessions`
|
|
367
136
|
|
|
368
137
|
Creates a Sessions manager with JWT access/refresh tokens, rotation, and reuse detection.
|
|
369
138
|
|
|
370
|
-
|
|
139
|
+
### `auth.createMultiOrg`
|
|
371
140
|
|
|
372
141
|
Creates multi-org session management — org selection, switching, membership CRUD.
|
|
373
142
|
|
|
374
|
-
|
|
143
|
+
### `auth.runChain`
|
|
375
144
|
|
|
376
145
|
Executes an auth chain (strategy pipeline) to resolve auth + tenant from a request.
|
|
377
146
|
|
|
378
|
-
|
|
147
|
+
### `auth.resolveCookie`
|
|
379
148
|
|
|
380
149
|
Resolves CookieConfig with defaults for secure cookie-based token delivery.
|
|
381
150
|
|
|
382
|
-
|
|
151
|
+
### `auth.parseCookie`
|
|
383
152
|
|
|
384
153
|
Parses a Cookie header string into key-value pairs.
|
|
385
154
|
|
|
386
|
-
|
|
155
|
+
### `auth.buildSetCookie`
|
|
387
156
|
|
|
388
157
|
Builds a Set-Cookie header string from name, value, and CookieConfig.
|
|
389
158
|
|
|
390
|
-
|
|
159
|
+
### `auth.buildClearCookie`
|
|
391
160
|
|
|
392
161
|
Builds a Set-Cookie header that clears (expires) a cookie.
|
|
393
162
|
|
|
394
|
-
|
|
163
|
+
### Types
|
|
395
164
|
|
|
396
165
|
**`AuthContext`** — Runtime auth context passed to strategies — carries the resolved DB and request metadata.
|
|
397
166
|
|
|
@@ -519,326 +288,522 @@ type ResolveLoginResult = AuthenticatedResult | OrgSelectResult
|
|
|
519
288
|
interface MultiOrgSessions
|
|
520
289
|
```
|
|
521
290
|
|
|
522
|
-
|
|
291
|
+
## rbac — Access Control
|
|
292
|
+
|
|
293
|
+
Role-based access control namespace — permission checking, enforcement, scope hierarchy.
|
|
294
|
+
|
|
295
|
+
### `rbac.create`
|
|
296
|
+
|
|
297
|
+
Creates an Rbac instance from config (roles, permissions, hierarchy).
|
|
298
|
+
|
|
299
|
+
### `rbac.check`
|
|
300
|
+
|
|
301
|
+
Checks if a permission set includes the required resource/action/scope. Pure function, no DB.
|
|
302
|
+
|
|
303
|
+
### `rbac.enforce`
|
|
304
|
+
|
|
305
|
+
Checks permission and throws ForbiddenError if denied. Loads permissions from DB with caching.
|
|
306
|
+
|
|
307
|
+
### `rbac.satisfies`
|
|
308
|
+
|
|
309
|
+
Checks if a granted scope satisfies a required scope given a hierarchy (e.g. org > team > self).
|
|
310
|
+
|
|
311
|
+
### `rbac.PermissionCache`
|
|
312
|
+
|
|
313
|
+
LRU cache for resolved permissions — avoids repeated DB lookups within a request.
|
|
314
|
+
|
|
315
|
+
## tenant — Multi-Tenancy
|
|
523
316
|
|
|
524
317
|
Multi-tenant isolation namespace — RLS policies, tenant extraction, Postgres-side verification.
|
|
525
318
|
|
|
526
|
-
|
|
319
|
+
### `tenant.validate`
|
|
527
320
|
|
|
528
321
|
Validates a tenant ID format (non-empty string, safe characters).
|
|
529
322
|
|
|
530
|
-
|
|
323
|
+
### `tenant.rls`
|
|
531
324
|
|
|
532
325
|
Enables RLS on a table and creates the tenant isolation policy in Postgres.
|
|
533
326
|
|
|
534
|
-
|
|
327
|
+
### `tenant.policy`
|
|
535
328
|
|
|
536
329
|
Returns the SQL string for a tenant isolation RLS policy — use in migrations.
|
|
537
330
|
|
|
538
|
-
|
|
331
|
+
### `tenant.verify`
|
|
539
332
|
|
|
540
333
|
Cross-checks ALS tenant against Postgres set_config('pipework.tenant_id') — defense-in-depth.
|
|
541
334
|
|
|
542
|
-
|
|
335
|
+
### `tenant.propagate`
|
|
543
336
|
|
|
544
337
|
Sets pipework.tenant_id on the Postgres connection via set_config().
|
|
545
338
|
|
|
546
|
-
|
|
339
|
+
### `tenant.extract`
|
|
547
340
|
|
|
548
341
|
Extracts tenant ID from auth context using the configured extraction strategy.
|
|
549
342
|
|
|
550
|
-
|
|
343
|
+
### `tenant.isTenantScoped`
|
|
551
344
|
|
|
552
345
|
Returns true if a table has been marked as tenant-scoped (via .tenant() field metadata).
|
|
553
346
|
|
|
554
|
-
|
|
347
|
+
## config — Configuration
|
|
555
348
|
|
|
556
|
-
|
|
349
|
+
Configuration namespace — loads and resolves Blueprint configs, discovers pipework.config.ts.
|
|
557
350
|
|
|
558
|
-
|
|
351
|
+
### `config.load`
|
|
559
352
|
|
|
560
|
-
|
|
353
|
+
Parses and resolves a raw Blueprint into a ResolvedConfig with environment detection.
|
|
561
354
|
|
|
562
|
-
|
|
355
|
+
### `config.discover`
|
|
563
356
|
|
|
564
|
-
|
|
357
|
+
Walks up from cwd to find pipework.config.ts, imports it, and returns the Manifold.
|
|
565
358
|
|
|
566
|
-
|
|
359
|
+
### `config.configSchema`
|
|
567
360
|
|
|
568
|
-
|
|
361
|
+
The zod schema for Blueprint validation — useful for custom config tooling.
|
|
569
362
|
|
|
570
|
-
|
|
363
|
+
### `config.ConfigError`
|
|
571
364
|
|
|
572
|
-
|
|
365
|
+
Thrown for configuration problems — includes a suggestion for how to fix.
|
|
573
366
|
|
|
574
|
-
|
|
367
|
+
## errors — Error Classes
|
|
575
368
|
|
|
576
|
-
|
|
369
|
+
Standard error classes — all extend PipeworkError with structured error codes and actionable messages.
|
|
577
370
|
|
|
578
|
-
|
|
371
|
+
### `errors.Base`
|
|
579
372
|
|
|
580
|
-
|
|
373
|
+
Base error class with code, statusCode, and suggestion fields.
|
|
581
374
|
|
|
582
|
-
###
|
|
375
|
+
### `errors.NotFound`
|
|
583
376
|
|
|
584
|
-
|
|
377
|
+
404 — resource not found.
|
|
585
378
|
|
|
586
|
-
|
|
379
|
+
### `errors.Unauthorized`
|
|
587
380
|
|
|
588
|
-
|
|
381
|
+
401 — missing or invalid authentication.
|
|
589
382
|
|
|
590
|
-
|
|
383
|
+
### `errors.Forbidden`
|
|
591
384
|
|
|
592
|
-
|
|
385
|
+
403 — authenticated but insufficient permissions.
|
|
593
386
|
|
|
594
|
-
|
|
387
|
+
### `errors.Validation`
|
|
595
388
|
|
|
596
|
-
|
|
389
|
+
422 — input validation failed, carries field-level details.
|
|
597
390
|
|
|
598
|
-
|
|
391
|
+
### `errors.Conflict`
|
|
599
392
|
|
|
600
|
-
|
|
393
|
+
409 — resource state conflict (duplicate, version mismatch).
|
|
601
394
|
|
|
602
|
-
|
|
395
|
+
## lifecycle — Startup & Shutdown
|
|
603
396
|
|
|
604
|
-
|
|
397
|
+
Application lifecycle namespace — startup orchestration with hooks and timeouts.
|
|
605
398
|
|
|
606
|
-
|
|
399
|
+
### `lifecycle.orchestrate`
|
|
607
400
|
|
|
608
|
-
|
|
401
|
+
Runs pre-start hooks (DB readiness checks, migrations, etc.) with a configurable timeout.
|
|
609
402
|
|
|
610
|
-
|
|
403
|
+
## log — Structured Logging
|
|
611
404
|
|
|
612
|
-
|
|
405
|
+
Structured logger (Pino) — auto-binds requestId, tenantId, userId, sessionId from ALS context on every log call.
|
|
613
406
|
|
|
614
|
-
|
|
407
|
+
### `log.create`
|
|
615
408
|
|
|
616
|
-
|
|
409
|
+
Creates a new PipeworkLogger instance with custom config (level, redaction, transport).
|
|
617
410
|
|
|
618
|
-
|
|
411
|
+
### `log.get`
|
|
619
412
|
|
|
620
|
-
|
|
413
|
+
Returns the context-aware logger proxy (same as the log export itself).
|
|
621
414
|
|
|
622
|
-
###
|
|
415
|
+
### `log.getBase`
|
|
623
416
|
|
|
624
|
-
|
|
417
|
+
Returns the raw Pino logger without ALS context binding.
|
|
625
418
|
|
|
626
|
-
|
|
419
|
+
### `log.configure`
|
|
627
420
|
|
|
628
|
-
|
|
421
|
+
Sets global logging config (level, redaction paths, custom context fields).
|
|
629
422
|
|
|
630
|
-
|
|
423
|
+
### `log.REDACT_PATHS`
|
|
631
424
|
|
|
632
|
-
|
|
425
|
+
Default redaction paths — password, secret, token, authorization, cookie, etc.
|
|
633
426
|
|
|
634
|
-
|
|
427
|
+
## surface — Entry Points
|
|
635
428
|
|
|
636
|
-
|
|
429
|
+
Surface namespace — declarative entry points that define how the app runs (HTTP server, background worker, one-shot script).
|
|
637
430
|
|
|
638
|
-
|
|
431
|
+
### `surface.http`
|
|
639
432
|
|
|
640
|
-
|
|
433
|
+
Creates an HTTP surface — a Fastify server with routes, middleware, and production validation. Returns an HttpSurfaceBuilder with a .test() method for inject()-based integration tests.
|
|
641
434
|
|
|
642
|
-
|
|
435
|
+
### `surface.worker`
|
|
643
436
|
|
|
644
|
-
|
|
437
|
+
Creates a worker surface — a long-running process that claims and executes jobs from queues.
|
|
645
438
|
|
|
646
|
-
|
|
439
|
+
### `surface.script`
|
|
647
440
|
|
|
648
|
-
|
|
441
|
+
Creates a script surface — a one-shot process that runs and exits (migrations, seeds, CLI tools).
|
|
649
442
|
|
|
650
|
-
|
|
443
|
+
## pipe — Database
|
|
651
444
|
|
|
652
|
-
|
|
445
|
+
Database accessor — returns a Drizzle DB instance scoped to the current request/job/test context. Requires active AsyncLocalStorage context.
|
|
653
446
|
|
|
654
|
-
###
|
|
447
|
+
### `pipe.filter`
|
|
655
448
|
|
|
656
|
-
|
|
449
|
+
Query operators and aggregates — eq, gt, lt, and, or, count, sum, etc.
|
|
657
450
|
|
|
658
|
-
|
|
451
|
+
### `pipe.migrate`
|
|
659
452
|
|
|
660
|
-
|
|
453
|
+
Runs migrations for all configured databases.
|
|
661
454
|
|
|
662
|
-
|
|
455
|
+
### `pipe.migrateOne`
|
|
663
456
|
|
|
664
|
-
|
|
457
|
+
Runs migrations for a single named database.
|
|
665
458
|
|
|
666
|
-
|
|
459
|
+
### `pipe.excluded`
|
|
667
460
|
|
|
668
|
-
|
|
461
|
+
Returns excluded-column references for onConflictDoUpdate set clauses.
|
|
669
462
|
|
|
670
|
-
|
|
463
|
+
### `pipe.field`
|
|
671
464
|
|
|
672
|
-
|
|
465
|
+
Field builders for domain definitions — uuid(), text(), integer(), etc.
|
|
673
466
|
|
|
674
|
-
|
|
467
|
+
### `pipe.define`
|
|
675
468
|
|
|
676
|
-
|
|
469
|
+
Registers a domain definition with table, validators, and factory projections.
|
|
677
470
|
|
|
678
|
-
|
|
471
|
+
### `pipe.definitions`
|
|
679
472
|
|
|
680
|
-
Returns
|
|
473
|
+
Returns the global registry of all domain definitions.
|
|
681
474
|
|
|
682
|
-
|
|
475
|
+
## jsonb — JSONB Column Helpers
|
|
683
476
|
|
|
684
|
-
|
|
477
|
+
JSONB query operators — typed helpers for PostgreSQL JSONB containment and key checks.
|
|
685
478
|
|
|
686
|
-
|
|
479
|
+
### `jsonb.contains`
|
|
687
480
|
|
|
688
|
-
|
|
481
|
+
The @> containment operator — tests whether a JSONB column contains the given value.
|
|
689
482
|
|
|
690
|
-
|
|
483
|
+
### `jsonb.containedBy`
|
|
691
484
|
|
|
692
|
-
|
|
485
|
+
The <@ contained-by operator — tests whether a JSONB column is contained by the given value.
|
|
693
486
|
|
|
694
|
-
|
|
487
|
+
### `jsonb.hasKey`
|
|
695
488
|
|
|
696
|
-
|
|
489
|
+
The ? key-existence operator — tests whether a JSONB column has the given top-level key.
|
|
697
490
|
|
|
698
|
-
|
|
491
|
+
## schema — Validation & Schema
|
|
699
492
|
|
|
700
|
-
|
|
493
|
+
Schema definition and validation namespace — wraps zod for validation, drizzle for table/column/index definitions.
|
|
701
494
|
|
|
702
|
-
|
|
495
|
+
### `schema.check`
|
|
703
496
|
|
|
704
|
-
|
|
497
|
+
Validation sub-namespace — type constructors, combinators, formats, coerce, parse, tryParse, toJsonSchema, branded.
|
|
705
498
|
|
|
706
|
-
|
|
499
|
+
### `schema.col`
|
|
707
500
|
|
|
708
|
-
|
|
501
|
+
Column type builders for table definitions — text, uuid, integer, timestamp, jsonb, boolean, varchar, etc.
|
|
709
502
|
|
|
710
|
-
|
|
503
|
+
### `schema.idx`
|
|
711
504
|
|
|
712
|
-
|
|
505
|
+
Index and constraint builders — index, uniqueIndex, primaryKey, foreignKey, unique, check.
|
|
713
506
|
|
|
714
|
-
|
|
507
|
+
### Types
|
|
715
508
|
|
|
716
|
-
|
|
509
|
+
**`Schema`** — Any validation schema — the base type accepted by .input(), .query(), .params() in the fitting builder.
|
|
717
510
|
|
|
718
|
-
|
|
511
|
+
```typescript
|
|
512
|
+
type Schema<T = unknown> = z.ZodType<T>
|
|
513
|
+
```
|
|
719
514
|
|
|
720
|
-
|
|
515
|
+
**`Infer`** — Extracts the TypeScript type from a Schema — Infer<typeof mySchema> gives you the validated type.
|
|
721
516
|
|
|
722
|
-
|
|
517
|
+
```typescript
|
|
518
|
+
type Infer<T extends Schema> = z.infer<T>
|
|
519
|
+
```
|
|
723
520
|
|
|
724
|
-
|
|
521
|
+
## temporal — Bitemporal Data
|
|
725
522
|
|
|
726
|
-
|
|
523
|
+
Temporal (bitemporal) data namespace — version history with effective date ranges.
|
|
727
524
|
|
|
728
|
-
|
|
525
|
+
### `temporal.columns`
|
|
729
526
|
|
|
730
|
-
|
|
527
|
+
Returns the standard temporal column definitions (effectiveFrom, effectiveTo, version, createdBy) for table schemas.
|
|
731
528
|
|
|
732
|
-
|
|
529
|
+
### `temporal.revise`
|
|
733
530
|
|
|
734
|
-
|
|
531
|
+
Creates a new version of a temporal record, closing the previous version's effectiveTo.
|
|
735
532
|
|
|
736
|
-
|
|
533
|
+
### `temporal.close`
|
|
737
534
|
|
|
738
|
-
|
|
535
|
+
Closes a temporal record by setting effectiveTo to now. Returns number of rows affected.
|
|
739
536
|
|
|
740
|
-
|
|
537
|
+
### `temporal.current`
|
|
741
538
|
|
|
742
|
-
|
|
539
|
+
Fetches the currently-effective version of a temporal record (effectiveTo IS NULL).
|
|
743
540
|
|
|
744
|
-
|
|
541
|
+
### `temporal.atTime`
|
|
745
542
|
|
|
746
|
-
|
|
543
|
+
Returns a SQL condition for records effective at a specific point in time.
|
|
747
544
|
|
|
748
|
-
|
|
545
|
+
### `temporal.between`
|
|
749
546
|
|
|
750
|
-
|
|
547
|
+
Returns a SQL condition for records overlapping a date range.
|
|
751
548
|
|
|
752
|
-
|
|
549
|
+
### `temporal.TemporalIntegrityError`
|
|
550
|
+
|
|
551
|
+
Thrown when a temporal operation would violate version continuity.
|
|
552
|
+
|
|
553
|
+
### `temporal.asOf`
|
|
554
|
+
|
|
555
|
+
Query records effective at a specific date, using a domain definition with .effectiveDated() trait.
|
|
753
556
|
|
|
754
|
-
|
|
557
|
+
### `temporal.allVersions`
|
|
755
558
|
|
|
756
|
-
|
|
559
|
+
Query all versions of temporal records (no date filter).
|
|
560
|
+
|
|
561
|
+
### `temporal.effectiveUpdate`
|
|
562
|
+
|
|
563
|
+
Close the current version and create a new one with updated data.
|
|
757
564
|
|
|
758
|
-
|
|
565
|
+
## vector — Vector & Full-Text Search
|
|
759
566
|
|
|
760
567
|
Vector and full-text search namespace — pgvector column types, similarity queries, and FTS operators.
|
|
761
568
|
|
|
762
|
-
|
|
569
|
+
### `vector.column`
|
|
763
570
|
|
|
764
571
|
Defines a vector(N) column for embeddings.
|
|
765
572
|
|
|
766
|
-
|
|
573
|
+
### `vector.tsvector`
|
|
767
574
|
|
|
768
575
|
Defines a tsvector column for full-text search.
|
|
769
576
|
|
|
770
|
-
|
|
577
|
+
### `vector.cosine`
|
|
771
578
|
|
|
772
579
|
Cosine distance between a column and a query vector (lower = more similar).
|
|
773
580
|
|
|
774
|
-
|
|
581
|
+
### `vector.cosineSimilarity`
|
|
775
582
|
|
|
776
583
|
Cosine similarity (higher = more similar) — 1 - cosineDistance.
|
|
777
584
|
|
|
778
|
-
|
|
585
|
+
### `vector.l2`
|
|
779
586
|
|
|
780
587
|
L2 (Euclidean) distance between a column and a query vector.
|
|
781
588
|
|
|
782
|
-
|
|
589
|
+
### `vector.innerProduct`
|
|
783
590
|
|
|
784
591
|
Inner product between a column and a query vector.
|
|
785
592
|
|
|
786
|
-
|
|
593
|
+
### `vector.toTsvector`
|
|
787
594
|
|
|
788
595
|
Converts text to a tsvector for full-text indexing.
|
|
789
596
|
|
|
790
|
-
|
|
597
|
+
### `vector.toTsquery`
|
|
791
598
|
|
|
792
599
|
Converts a search query string to a tsquery using to_tsquery (supports operators like &, |, !).
|
|
793
600
|
|
|
794
|
-
|
|
601
|
+
### `vector.plainToTsquery`
|
|
795
602
|
|
|
796
603
|
Converts natural language text to a tsquery using plainto_tsquery (no operator syntax required).
|
|
797
604
|
|
|
798
|
-
|
|
605
|
+
### `vector.matches`
|
|
799
606
|
|
|
800
607
|
The @@ match operator — tests whether a tsvector column matches a tsquery.
|
|
801
608
|
|
|
802
|
-
|
|
609
|
+
### `vector.headline`
|
|
803
610
|
|
|
804
611
|
Generates a ts_headline search snippet with highlighted matches.
|
|
805
612
|
|
|
806
|
-
|
|
613
|
+
### `vector.rank`
|
|
807
614
|
|
|
808
615
|
Computes ts_rank for full-text search result ordering. Accepts a pre-built tsquery SQL or a raw query string.
|
|
809
616
|
|
|
810
|
-
|
|
617
|
+
### `vector.validate`
|
|
811
618
|
|
|
812
619
|
Verifies the pgvector extension is installed and accessible.
|
|
813
620
|
|
|
814
|
-
|
|
621
|
+
## audit — Audit Logging
|
|
622
|
+
|
|
623
|
+
Audit logging namespace — structured audit trail for data changes.
|
|
624
|
+
|
|
625
|
+
### `audit.create`
|
|
626
|
+
|
|
627
|
+
Creates an Audit instance that writes audit records to a Postgres table.
|
|
628
|
+
|
|
629
|
+
## cache — Caching
|
|
630
|
+
|
|
631
|
+
In-memory caching namespace — TTL-based with stats, preload, and tenant-aware variants.
|
|
632
|
+
|
|
633
|
+
### `cache.create`
|
|
634
|
+
|
|
635
|
+
Creates a single-key cache with TTL, a loader function, and invalidation.
|
|
636
|
+
|
|
637
|
+
### `cache.createTenant`
|
|
638
|
+
|
|
639
|
+
Creates a per-tenant cache — each tenant gets its own TTL and loader keyed by tenant ID.
|
|
640
|
+
|
|
641
|
+
## webhook — Inbound & Outbound Webhooks
|
|
815
642
|
|
|
816
643
|
Webhook namespace — inbound verification, outbound delivery with retries, HMAC signing.
|
|
817
644
|
|
|
818
|
-
|
|
645
|
+
### `webhook.defineInbound`
|
|
819
646
|
|
|
820
647
|
Defines an inbound webhook handler with signature verification and optional idempotency.
|
|
821
648
|
|
|
822
|
-
|
|
649
|
+
### `webhook.createOutbound`
|
|
823
650
|
|
|
824
651
|
Creates an outbound webhook system — endpoint registration, payload signing, delivery with retries.
|
|
825
652
|
|
|
826
|
-
|
|
653
|
+
### `webhook.sign`
|
|
827
654
|
|
|
828
655
|
Signs a payload with HMAC for outbound delivery — returns body, signature, timestamp, messageId.
|
|
829
656
|
|
|
830
|
-
|
|
657
|
+
## behavior — Resource Decorators
|
|
831
658
|
|
|
832
|
-
|
|
659
|
+
Resource behavior decorators — compose versioning, audit trails, and cache invalidation onto CRUD operations.
|
|
833
660
|
|
|
834
|
-
|
|
661
|
+
### `behavior.compose`
|
|
835
662
|
|
|
836
|
-
|
|
663
|
+
Applies multiple behaviors to a ResourceOperations set in order.
|
|
837
664
|
|
|
838
|
-
|
|
665
|
+
### `behavior.versioned`
|
|
839
666
|
|
|
840
|
-
|
|
667
|
+
Adds optimistic concurrency control via a version column — rejects stale updates.
|
|
841
668
|
|
|
842
|
-
|
|
669
|
+
### `behavior.audited`
|
|
843
670
|
|
|
844
|
-
|
|
671
|
+
Wraps operations to emit audit records on create/update/delete.
|
|
672
|
+
|
|
673
|
+
### `behavior.invalidate`
|
|
674
|
+
|
|
675
|
+
Wraps operations to invalidate a cache on mutations. Returns ops with an attached .cache handle.
|
|
676
|
+
|
|
677
|
+
## fitting — Dependency Injection
|
|
678
|
+
|
|
679
|
+
## fixture — REST Resources
|
|
680
|
+
|
|
681
|
+
REST resource builder namespace — declarative CRUD with cursor pagination and batch operations.
|
|
682
|
+
|
|
683
|
+
### `fixture.toHandlers`
|
|
684
|
+
|
|
685
|
+
Converts a Resource into fitted Handler[] that go through the standard handler pipeline.
|
|
686
|
+
|
|
687
|
+
### `fixture.build`
|
|
688
|
+
|
|
689
|
+
Builds a Resource from a name, operations map, and builder state — used internally by fitting().fixture().
|
|
690
|
+
|
|
691
|
+
### `fixture.encodeCursor`
|
|
692
|
+
|
|
693
|
+
Encodes pagination cursor values into an opaque base64 string.
|
|
694
|
+
|
|
695
|
+
### `fixture.decodeCursor`
|
|
696
|
+
|
|
697
|
+
Decodes an opaque pagination cursor back into its values.
|
|
698
|
+
|
|
699
|
+
### `fixture.buildPage`
|
|
700
|
+
|
|
701
|
+
Builds a PageResult from rows, limit, and cursor extractor — handles hasMore detection.
|
|
702
|
+
|
|
703
|
+
### `fixture.validateBatch`
|
|
704
|
+
|
|
705
|
+
Validates a batch request body (preview/execute mode, targets, actions).
|
|
706
|
+
|
|
707
|
+
### `fixture.MethodNotAllowedError`
|
|
708
|
+
|
|
709
|
+
Thrown when a resource doesn't support the requested HTTP method.
|
|
710
|
+
|
|
711
|
+
## flow — Context (AsyncLocalStorage)
|
|
712
|
+
|
|
713
|
+
AsyncLocalStorage context namespace — manages request/job/test contexts that carry auth, tenant, transactions.
|
|
714
|
+
|
|
715
|
+
### `flow.run`
|
|
716
|
+
|
|
717
|
+
Executes a function within a Flow context (AsyncLocalStorage). All pipe() calls inside will use this context.
|
|
718
|
+
|
|
719
|
+
### `flow.require`
|
|
720
|
+
|
|
721
|
+
Returns the current Flow or throws — use in code that must run inside a managed context.
|
|
722
|
+
|
|
723
|
+
### `flow.get`
|
|
724
|
+
|
|
725
|
+
Returns the current Flow or undefined — use for optional context detection.
|
|
726
|
+
|
|
727
|
+
### `flow.createTest`
|
|
728
|
+
|
|
729
|
+
Creates a Flow for test isolation with optional auth and tenant overrides.
|
|
730
|
+
|
|
731
|
+
## http — Server
|
|
732
|
+
|
|
733
|
+
HTTP server namespace — managed by manifold.start(), not directly accessible.
|
|
734
|
+
|
|
735
|
+
### Types
|
|
736
|
+
|
|
737
|
+
**`CorsConfig`** — CORS configuration — origin, methods, headers, credentials, maxAge.
|
|
738
|
+
|
|
739
|
+
```typescript
|
|
740
|
+
interface CorsConfig
|
|
741
|
+
```
|
|
742
|
+
|
|
743
|
+
**`SecurityConfig`** — Security header configuration — passed to @fastify/helmet.
|
|
744
|
+
|
|
745
|
+
```typescript
|
|
746
|
+
interface SecurityConfig
|
|
747
|
+
```
|
|
748
|
+
|
|
749
|
+
**`RateLimitConfig`** — Rate limiting configuration — max requests, time window, key generator.
|
|
750
|
+
|
|
751
|
+
```typescript
|
|
752
|
+
interface RateLimitConfig
|
|
753
|
+
```
|
|
754
|
+
|
|
755
|
+
**`InjectOptions`** — Options for server.inject() — method, url, headers, payload for testing without HTTP.
|
|
756
|
+
|
|
757
|
+
```typescript
|
|
758
|
+
interface InjectOptions
|
|
759
|
+
```
|
|
760
|
+
|
|
761
|
+
**`InjectResponse`** — Response from server.inject() — statusCode, headers, body, json() helper.
|
|
762
|
+
|
|
763
|
+
```typescript
|
|
764
|
+
interface InjectResponse
|
|
765
|
+
```
|
|
766
|
+
|
|
767
|
+
**`ServerConfig`** — Configuration for http.createServer() — CORS, security headers, rate limiting, transaction timeout.
|
|
768
|
+
|
|
769
|
+
```typescript
|
|
770
|
+
interface ServerConfig
|
|
771
|
+
```
|
|
772
|
+
|
|
773
|
+
**`HandlerResponse`** — Standard handler response shape — statusCode, headers, body.
|
|
774
|
+
|
|
775
|
+
```typescript
|
|
776
|
+
interface HandlerResponse
|
|
777
|
+
```
|
|
778
|
+
|
|
779
|
+
**`ErrorResponse`** — Standard error response shape — { error: { code, message }, statusCode }.
|
|
780
|
+
|
|
781
|
+
```typescript
|
|
782
|
+
interface ErrorResponse
|
|
783
|
+
```
|
|
784
|
+
|
|
785
|
+
**`PipeworkServer`** — Fastify server wrapper with route registration, handler auto-wiring, and inject() for testing.
|
|
786
|
+
|
|
787
|
+
```typescript
|
|
788
|
+
interface PipeworkServer
|
|
789
|
+
```
|
|
790
|
+
|
|
791
|
+
**`HttpRequest`** — Fastify request with pipework extensions — req.id (UUID), typed headers.
|
|
792
|
+
|
|
793
|
+
```typescript
|
|
794
|
+
interface HttpRequest
|
|
795
|
+
```
|
|
796
|
+
|
|
797
|
+
**`HttpResponse`** — Fastify reply with pipework extensions.
|
|
798
|
+
|
|
799
|
+
```typescript
|
|
800
|
+
interface HttpResponse
|
|
801
|
+
```
|
|
802
|
+
|
|
803
|
+
## openapi — API Documentation
|
|
804
|
+
|
|
805
|
+
OpenAPI spec generation namespace.
|
|
806
|
+
|
|
807
|
+
### `openapi.generate`
|
|
808
|
+
|
|
809
|
+
Generates an OpenAPI 3.1 document from route registrations — schemas derived from fitting() input/output.
|