@tailor-platform/sdk 2.27.0 → 2.29.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (184) hide show
  1. package/CHANGELOG.md +109 -0
  2. package/README.md +0 -8
  3. package/agent-skills/tailor/SKILL.md +4 -2
  4. package/dist/application-dalGHdrI.mjs +1 -0
  5. package/dist/application-rWYDAfNU.mjs +200 -0
  6. package/dist/application-rWYDAfNU.mjs.map +1 -0
  7. package/dist/cli/cache/bundle-cache.d.mts +1 -0
  8. package/dist/cli/commands/executor/get.d.mts +2 -1
  9. package/dist/cli/commands/executor/jobs.d.mts +2 -1
  10. package/dist/cli/commands/executor/trigger.d.mts +2 -1
  11. package/dist/cli/commands/function/get.d.mts +2 -1
  12. package/dist/cli/commands/function/list.d.mts +2 -1
  13. package/dist/cli/commands/organization/folder/create.d.mts +2 -1
  14. package/dist/cli/commands/organization/folder/delete.d.mts +2 -1
  15. package/dist/cli/commands/organization/folder/get.d.mts +2 -1
  16. package/dist/cli/commands/organization/folder/list.d.mts +2 -1
  17. package/dist/cli/commands/organization/folder/update.d.mts +2 -1
  18. package/dist/cli/commands/organization/get.d.mts +2 -1
  19. package/dist/cli/commands/organization/tree.d.mts +2 -1
  20. package/dist/cli/commands/organization/update.d.mts +2 -1
  21. package/dist/cli/commands/show.d.mts +2 -1
  22. package/dist/cli/commands/tailordb/migrate/diff-calculator.d.mts +2 -1
  23. package/dist/cli/commands/tailordb/migrate/snapshot-types.d.mts +3 -1
  24. package/dist/cli/commands/workflow/executions.d.mts +2 -1
  25. package/dist/cli/commands/workflow/get.d.mts +2 -1
  26. package/dist/cli/commands/workflow/start.d.mts +2 -1
  27. package/dist/cli/commands/workspace/app/health.d.mts +2 -1
  28. package/dist/cli/commands/workspace/app/list.d.mts +2 -1
  29. package/dist/cli/commands/workspace/create.d.mts +5 -2
  30. package/dist/cli/commands/workspace/delete.d.mts +2 -1
  31. package/dist/cli/commands/workspace/get.d.mts +2 -1
  32. package/dist/cli/commands/workspace/restore.d.mts +2 -1
  33. package/dist/cli/commands/workspace/user/invite.d.mts +2 -1
  34. package/dist/cli/commands/workspace/user/list.d.mts +2 -1
  35. package/dist/cli/commands/workspace/user/remove.d.mts +2 -1
  36. package/dist/cli/commands/workspace/user/update.d.mts +2 -1
  37. package/dist/cli/lib.d.mts +1 -1
  38. package/dist/cli/lib.mjs +1 -1
  39. package/dist/cli/lib.mjs.map +1 -1
  40. package/dist/cli/main.d.mts +7 -0
  41. package/dist/cli/main.mjs +55 -42
  42. package/dist/cli/main.mjs.map +1 -1
  43. package/dist/cli/query/index.d.mts +2 -1
  44. package/dist/cli/shared/args.d.mts +4 -2
  45. package/dist/cli/shared/client.d.mts +6 -1
  46. package/dist/cli/shared/context.d.mts +2 -1
  47. package/dist/cli/shared/logger.d.mts +5 -2
  48. package/dist/cli/shared/readonly-guard.d.mts +2 -1
  49. package/dist/cli/shared/seed-context.d.mts +5 -0
  50. package/dist/cli/shared/type-generator.d.mts +2 -1
  51. package/dist/cli/ts-hook.mjs +15 -11
  52. package/dist/completion/zsh-worker.zsh +275 -19
  53. package/dist/configure/config/types.d.mts +80 -1
  54. package/dist/configure/services/aigateway/types.d.mts +2 -1
  55. package/dist/configure/services/auth/types.d.mts +2 -1
  56. package/dist/configure/services/executor/executor.d.mts +2 -1
  57. package/dist/configure/services/executor/operation.d.mts +2 -1
  58. package/dist/configure/services/executor/trigger/event.d.mts +2 -1
  59. package/dist/configure/services/executor/trigger/schedule.d.mts +2 -1
  60. package/dist/configure/services/http-adapter/http-adapter.d.mts +2 -1
  61. package/dist/configure/services/idp/permission.d.mts +2 -1
  62. package/dist/configure/services/idp/types.d.mts +2 -1
  63. package/dist/configure/services/resolver/permission.d.mts +2 -1
  64. package/dist/configure/services/resolver/resolver.d.mts +2 -1
  65. package/dist/configure/services/secrets/types.d.mts +2 -1
  66. package/dist/configure/services/staticwebsite/types.d.mts +2 -1
  67. package/dist/configure/services/tailordb/permission.d.mts +2 -1
  68. package/dist/configure/services/tailordb/schema.d.mts +4 -3
  69. package/dist/configure/services/tailordb/types.d.mts +12 -1
  70. package/dist/configure/services/workflow/execution-policy.types.d.mts +2 -1
  71. package/dist/configure/services/workflow/job.d.mts +2 -1
  72. package/dist/configure/services/workflow/wait-point.d.mts +2 -1
  73. package/dist/configure/types/field.types.d.mts +2 -1
  74. package/dist/configure/types/permission-operand.types.d.mts +2 -1
  75. package/dist/configure/types/type.d.mts +2 -1
  76. package/dist/{crashreport-DFpRn-LS.mjs → crashreport-BAG8c7hB.mjs} +4 -4
  77. package/dist/{crashreport-DFpRn-LS.mjs.map → crashreport-BAG8c7hB.mjs.map} +1 -1
  78. package/dist/crashreport-BcXuocwI.mjs +1 -0
  79. package/dist/{errors-CpvSChyL.mjs → errors-D3qpNHR6.mjs} +2 -2
  80. package/dist/{errors-CpvSChyL.mjs.map → errors-D3qpNHR6.mjs.map} +1 -1
  81. package/dist/kysely-type-BWMfV301.mjs +48 -0
  82. package/dist/kysely-type-BWMfV301.mjs.map +1 -0
  83. package/dist/logger-DuaT2zY3.mjs +9 -0
  84. package/dist/logger-DuaT2zY3.mjs.map +1 -0
  85. package/dist/package-json-D1BRkjtr.mjs +1 -0
  86. package/dist/parser/service/tailordb/types.d.mts +3 -1
  87. package/dist/plugin/builtin/enum-constants/index.d.mts +2 -1
  88. package/dist/plugin/builtin/file-utils/index.d.mts +2 -1
  89. package/dist/plugin/builtin/kysely-type/index.d.mts +2 -1
  90. package/dist/plugin/builtin/kysely-type/index.mjs +1 -1
  91. package/dist/plugin/builtin/seed/index.d.mts +11 -1
  92. package/dist/plugin/builtin/seed/index.mjs +1 -1
  93. package/dist/register-ts-hook-CkfKqhJT.mjs +1014 -0
  94. package/dist/register-ts-hook-CkfKqhJT.mjs.map +1 -0
  95. package/dist/runtime/aigateway.mjs +1 -1
  96. package/dist/runtime/authconnection.mjs +1 -1
  97. package/dist/runtime/context.d.mts +2 -1
  98. package/dist/runtime/context.mjs +1 -1
  99. package/dist/runtime/date.d.mts +2 -1
  100. package/dist/runtime/field-parse.d.mts +2 -1
  101. package/dist/runtime/file.d.mts +2 -1
  102. package/dist/runtime/file.mjs +1 -1
  103. package/dist/runtime/globals.d.mts +2 -1
  104. package/dist/runtime/iconv.mjs +1 -1
  105. package/dist/runtime/idp.mjs +1 -1
  106. package/dist/runtime/logger.mjs +1 -1
  107. package/dist/runtime/secretmanager.mjs +1 -1
  108. package/dist/runtime/types.d.mts +2 -1
  109. package/dist/runtime/workflow.d.mts +2 -1
  110. package/dist/runtime/workflow.mjs +1 -1
  111. package/dist/schema-B6hJQWp6.mjs.map +1 -1
  112. package/dist/seed/index.d.mts +17 -4
  113. package/dist/seed/index.mjs +6 -6
  114. package/dist/seed/index.mjs.map +1 -1
  115. package/dist/seed-C3P_T_Eh.mjs.map +1 -1
  116. package/dist/{service-Cc7OY0Oh.mjs → service-CETr0AKY.mjs} +3 -3
  117. package/dist/service-CETr0AKY.mjs.map +1 -0
  118. package/dist/service-DREWLYxD.mjs +1 -0
  119. package/dist/{service-DFmt9UJP.mjs → service-b1g22NN9.mjs} +2 -2
  120. package/dist/{service-DFmt9UJP.mjs.map → service-b1g22NN9.mjs.map} +1 -1
  121. package/dist/service_pb-Bbu2QSIr.mjs +2 -0
  122. package/dist/service_pb-Bbu2QSIr.mjs.map +1 -0
  123. package/dist/service_pb-urxAIYHT.mjs +1 -0
  124. package/dist/tailor-proto/src/tailor/v1/events_pb.d.mts +53 -1
  125. package/dist/tailor-proto/src/tailor/v1/events_resource_pb.d.mts +33 -0
  126. package/dist/tailor-proto/src/tailor/v1/function_resource_pb.d.mts +0 -8
  127. package/dist/tailor-proto/src/tailor/v1/service_pb.d.mts +18 -1
  128. package/dist/tailor-proto/src/tailor/v1/tailordb_resource_pb.d.mts +4 -0
  129. package/dist/telemetry-DpkFGBmu.mjs +1 -0
  130. package/dist/{telemetry-Bklv9kQY.mjs → telemetry-Xk7J829P.mjs} +2 -2
  131. package/dist/{telemetry-Bklv9kQY.mjs.map → telemetry-Xk7J829P.mjs.map} +1 -1
  132. package/dist/types/tailordb.generated.d.mts +2 -0
  133. package/dist/vitest/index.mjs +1 -1
  134. package/dist/vitest/index.mjs.map +1 -1
  135. package/dist/vitest/mock-kysely.d.mts +2 -1
  136. package/dist/vitest/mocks/aigateway.d.mts +2 -1
  137. package/dist/vitest/mocks/authconnection.d.mts +2 -1
  138. package/dist/vitest/mocks/file.d.mts +2 -1
  139. package/dist/vitest/mocks/iconv.d.mts +2 -1
  140. package/dist/vitest/mocks/idp.d.mts +2 -1
  141. package/dist/vitest/mocks/logger.d.mts +2 -1
  142. package/dist/vitest/mocks/secretmanager.d.mts +2 -1
  143. package/dist/vitest/mocks/tailordb-pglite.d.mts +2 -1
  144. package/dist/vitest/mocks/tailordb.d.mts +2 -1
  145. package/dist/vitest/mocks/workflow.d.mts +3 -1
  146. package/dist/vitest/pglite-kysely.d.mts +2 -1
  147. package/dist/vitest/workflow-local.d.mts +2 -1
  148. package/dist/{workspace_resource_pb-ChWejcj0.mjs → workspace_resource_pb-CaoM2npP.mjs} +2 -2
  149. package/dist/{workspace_resource_pb-ChWejcj0.mjs.map → workspace_resource_pb-CaoM2npP.mjs.map} +1 -1
  150. package/docs/cli/application.md +21 -3
  151. package/docs/cli/data.md +105 -0
  152. package/docs/cli/secret.md +6 -6
  153. package/docs/cli/tailordb.md +52 -16
  154. package/docs/cli/user.md +37 -7
  155. package/docs/cli/workspace.md +9 -1
  156. package/docs/cli-reference.md +36 -3
  157. package/docs/configuration.md +62 -2
  158. package/docs/github-actions.md +179 -13
  159. package/docs/multi-environment.md +24 -0
  160. package/docs/plugin/custom.md +1 -1
  161. package/docs/services/idp.md +1 -1
  162. package/docs/services/resolver.md +1 -58
  163. package/docs/services/tailordb-migration.md +80 -12
  164. package/docs/services/tailordb.md +17 -4
  165. package/docs/services/workflow.md +2 -2
  166. package/docs/testing.md +3 -2
  167. package/package.json +22 -22
  168. package/dist/application-DFeuELRo.mjs +0 -200
  169. package/dist/application-DFeuELRo.mjs.map +0 -1
  170. package/dist/application-nT_4a5HO.mjs +0 -1
  171. package/dist/crashreport-CBaRJl5h.mjs +0 -1
  172. package/dist/kysely-type-RDX59E1j.mjs +0 -48
  173. package/dist/kysely-type-RDX59E1j.mjs.map +0 -1
  174. package/dist/logger-Db-YRTwK.mjs +0 -9
  175. package/dist/logger-Db-YRTwK.mjs.map +0 -1
  176. package/dist/package-json-CmqhDJ__.mjs +0 -1
  177. package/dist/register-ts-hook-D6KXrGrB.mjs +0 -1009
  178. package/dist/register-ts-hook-D6KXrGrB.mjs.map +0 -1
  179. package/dist/service-Cc7OY0Oh.mjs.map +0 -1
  180. package/dist/service-sH2MZ4_W.mjs +0 -1
  181. package/dist/service_pb-Dw2ilc1O.mjs +0 -2
  182. package/dist/service_pb-Dw2ilc1O.mjs.map +0 -1
  183. package/dist/service_pb-GDOqfwb6.mjs +0 -1
  184. package/dist/telemetry-DXHP3VVi.mjs +0 -1
package/CHANGELOG.md CHANGED
@@ -1,5 +1,114 @@
1
1
  # @tailor-platform/sdk
2
2
 
3
+ ## 2.29.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#2631](https://github.com/tailor-platform/sdk/pull/2631) [`9f617fa`](https://github.com/tailor-platform/sdk/commit/9f617fa247d62dfffe94862775d998ca2a914004) Thanks [@toiroakr](https://github.com/toiroakr)! - Add `buildOptions.treeshake` to `defineConfig` to control how unused code is removed from bundled functions. Set `propertyReadSideEffects: false` to drop calls whose arguments only read properties, which keeps modules a function never reaches out of its bundle. `moduleSideEffects`, `annotations`, and `unknownGlobalSideEffects` override the SDK's defaults. Nothing changes unless you set it.
8
+
9
+ - [#2584](https://github.com/tailor-platform/sdk/pull/2584) [`78acf8d`](https://github.com/tailor-platform/sdk/commit/78acf8d04a93dbd19ec7c26c91b9986751964350) Thanks [@toiroakr](https://github.com/toiroakr)! - Add `tailor tailordb migration resolve` to settle a migration that a failed deploy left in progress. `--rollback` returns the namespace to the schema before the failed migration and leaves the checkpoint where it was, so the next deploy runs that migration again from its first step. `--complete` applies the schema of the failed migration, moves the checkpoint to it without running its `migrate.ts` again, and is meant for use after you repaired the data by hand. Both options clear the in-progress record, take the namespace's tables out of maintenance mode, and remove the temporary resources of the failed run, so `deploy` and the other migration commands work again.
10
+
11
+ - [#2635](https://github.com/tailor-platform/sdk/pull/2635) [`9fb24be`](https://github.com/tailor-platform/sdk/commit/9fb24be283e7820e9c7816c513f37140b8b3914f) Thanks [@toiroakr](https://github.com/toiroakr)! - Leave the source text of installed packages (everything under `node_modules`) out of the inline sourcemap in bundled resolvers, executors, workflow jobs, and auth hooks. The sourcemap makes up most of a bundled function's size, so this makes the bundles much smaller: in one project's resolver bundles the median dropped from 5.7 MB to 3.1 MB. Error positions in stack traces still resolve to the original files and lines, and your own source text is still embedded. `tailor function run` and `tailor function logs` show the code snippet for a frame inside an installed package from the package's file in your local `node_modules`. `tailor function logs` also no longer prints the paths of a deployed function's files one folder too high (`../src/handler.ts` instead of `./src/handler.ts`). Set `buildOptions.inlineSourcemapDependencySources: true` to embed the source text of installed packages as before, or list package names (for example `["kysely"]`) to embed only those.
12
+
13
+ - [#2660](https://github.com/tailor-platform/sdk/pull/2660) [`df71b44`](https://github.com/tailor-platform/sdk/commit/df71b44d2c03d8f767bea5448ee64bb1f114dcfb) Thanks [@dqn](https://github.com/dqn)! - The `tailor` CLI, the setup, seed, and TailorDB ERD plugins, `create-sdk`, and the codemod CLI now exit with code 2 when they reject the command line itself, such as an unknown option or subcommand, an unexpected argument, or an option value that fails validation, so scripts and agents can tell a mistyped command from one that failed while running, which still exits with 1. A command that only warns about an unknown option or an extra argument, such as `create-sdk`, keeps running as before. A script that checks for exactly 1 after a mistyped command needs to accept 2. `runMain` and `runCommand` from `@tailor-platform/sdk/cli` follow the same rule, so a CLI plugin built on them exits with 2 for these errors, and `runCommand` reports them with `exitCode` 2.
14
+
15
+ ### Patch Changes
16
+
17
+ - [#2649](https://github.com/tailor-platform/sdk/pull/2649) [`e0fb7c0`](https://github.com/tailor-platform/sdk/commit/e0fb7c0ad86391c899fec8daa06a1f2d033414c5) Thanks [@dqn](https://github.com/dqn)! - Fix `tailor deploy --dry-run --json` reporting `resourceType` in `warnings` and `conflicts` as the display name from the human-readable plan, such as `Executor` or `TailorDB service`. It now reports a stable identifier such as `executor` or `tailordb.service`, and the human-readable plan is unchanged. The values change as follows:
18
+
19
+ | Before | After |
20
+ | --------------------------- | ---------------------------------------- |
21
+ | `Application` | `application` |
22
+ | `AIGateway` | `aigateway` |
23
+ | `Auth connection` | `auth.connection` |
24
+ | `Auth service` | `auth.service` |
25
+ | `Executor` | `executor` |
26
+ | `Function registry` | `function_registry` |
27
+ | `IdP service` | `idp.service` |
28
+ | `Pipeline service` | `pipeline.service` |
29
+ | `Secret Manager vault` | `secret.vault` |
30
+ | `StaticWebsite` | `staticwebsite` |
31
+ | `TailorDB service` | `tailordb.service` |
32
+ | `Workflow` | `workflow` |
33
+ | `Workflow execution policy` | `workflow_job_function_execution_policy` |
34
+ | `secret` (skipped secrets) | `secret.secret` |
35
+
36
+ - [#2652](https://github.com/tailor-platform/sdk/pull/2652) [`ac872f3`](https://github.com/tailor-platform/sdk/commit/ac872f3b1f3e68e066c5518b6201c430d7a2c5b3) Thanks [@dqn](https://github.com/dqn)! - Guard the `resourceType` values in `tailor deploy --dry-run --json` output against accidental changes. No observable behavior change.
37
+
38
+ - [#2640](https://github.com/tailor-platform/sdk/pull/2640) [`4b626ce`](https://github.com/tailor-platform/sdk/commit/4b626cec93b8e2771084927bbb54a64a35256e64) Thanks [@dqn](https://github.com/dqn)! - When `tailor deploy` is given multiple configs that define the same resource name, the `DEPLOY_DUPLICATE_RESOURCE_NAME` error now lists every duplicate in one run, each with its resource type, name, and the config files that define it, instead of stopping at the first one. With `--json`, the duplicates are also available in `error.context.duplicates`.
39
+
40
+ - [#2659](https://github.com/tailor-platform/sdk/pull/2659) [`3accb07`](https://github.com/tailor-platform/sdk/commit/3accb0734ea6e9f2dd3d1ef671b03ec7a8820393) Thanks [@dqn](https://github.com/dqn)! - Hide secrets in the GitHub Actions `::error::` annotation a failed command writes. Values the CLI already masks as `<redacted>` in its log output, such as client secrets and access tokens, appeared unmasked in the annotation when they were part of the error.
41
+
42
+ - [#2646](https://github.com/tailor-platform/sdk/pull/2646) [`76d4f9c`](https://github.com/tailor-platform/sdk/commit/76d4f9c8675ac118a008c67bd8f95d1ad823e2c4) Thanks [@toiroakr](https://github.com/toiroakr)! - fix(deps): migrate from @toiroakr/lines-db to lines-db
43
+
44
+ - [#2626](https://github.com/tailor-platform/sdk/pull/2626) [`c97c8f3`](https://github.com/tailor-platform/sdk/commit/c97c8f3cd17518c4f58e69d555bfb060d8b2ca6d) Thanks [@dqn](https://github.com/dqn)! - Keep `tailor deploy` migrations within their own TailorDB namespace when a table name exists in more than one, such as after moving a table between namespaces. A migration in one namespace could write its own schema over another namespace's table of the same name, fail the deploy by creating that table a second time, delete that table before the other namespace's migration script read it, or skip writing that table's metadata.
45
+
46
+ - [#2627](https://github.com/tailor-platform/sdk/pull/2627) [`9cc6efb`](https://github.com/tailor-platform/sdk/commit/9cc6efb69cf2dc16e7468c9a215973283b5d27a6) Thanks [@dqn](https://github.com/dqn)! - Find tables in TailorDB namespaces with more than 50 tables in `tailor tailordb truncate <tables...>`, and in `tailor query --engine sql` for apps with more than one TailorDB namespace. Tables created after the first 50 in a namespace were reported as `The following tables were not found in any namespace` or `Could not find namespace for tables in query`. When listing a namespace's tables fails, both commands now stop with that error instead of skipping that namespace and continuing with the others.
47
+
48
+ - [#2621](https://github.com/tailor-platform/sdk/pull/2621) [`1108cb3`](https://github.com/tailor-platform/sdk/commit/1108cb3519f748714907d14fc69d8cccafacf538) Thanks [@renovate](https://github.com/apps/renovate)! - fix(deps): update @​opentelemetry
49
+
50
+ - [#2638](https://github.com/tailor-platform/sdk/pull/2638) [`55c8466`](https://github.com/tailor-platform/sdk/commit/55c8466e5830cf9aad029ef65df3049704789f22) Thanks [@renovate](https://github.com/apps/renovate)! - fix(deps): update dependency zod to v4.6.7
51
+
52
+ - [#2641](https://github.com/tailor-platform/sdk/pull/2641) [`5dd5e9c`](https://github.com/tailor-platform/sdk/commit/5dd5e9cddce99c40dc02985a9c73b4acd581ac54) Thanks [@renovate](https://github.com/apps/renovate)! - fix(deps): update oxc
53
+
54
+ - [#2601](https://github.com/tailor-platform/sdk/pull/2601) [`00c5613`](https://github.com/tailor-platform/sdk/commit/00c56132166f4fec563d82b686afc3bad82f8ef2) Thanks [@dqn](https://github.com/dqn)! - The workflows `tailor setup ci` generates now run on GitHub Enterprise Server: the plan comment, change detection, preview deployment, and ERD preview comment call the GitHub API of the server the workflow runs on instead of github.com. Run `tailor setup update` to regenerate existing workflows.
55
+
56
+ GitHub Enterprise Server does not support the artifact upload the ERD preview uses, so pass `--ghes` with `--erd-preview` to `tailor setup ci branch` there: each ERD viewer is then uploaded as a zip file, and the pull request comment links to the workflow run. The GitHub Actions guide lists the runner and action setup GitHub Enterprise Server needs.
57
+
58
+ - [#2643](https://github.com/tailor-platform/sdk/pull/2643) [`f5c304f`](https://github.com/tailor-platform/sdk/commit/f5c304f8867d6416ccfa315694163d2e77a69e73) Thanks [@dqn](https://github.com/dqn)! - Add `tailor setup ci env --check`, which reads GitHub with `gh` and reports which secrets and variables each GitHub Environment used by the generated workflows still lacks. It fails when a required entry is missing, only reports missing optional ones, and prints the `gh` commands that set the missing entries together with where each value comes from. Entries set on the repository or organization count as registered, and an entry registered as the wrong kind (a secret where the workflow reads a variable) is pointed out. When `gh` is not installed, not logged in, or cannot read the repository's secrets and variables, the check says so instead of reporting entries as missing. The next steps printed after `tailor setup ci branch`, `tag`, and `preview` now suggest running it.
59
+
60
+ When the `origin` remote is not on github.com, `tailor setup ci env` now names the repository that `gh repo view` reports, with its host on GitHub Enterprise Server, instead of leaving it to `gh` at run time: the printed `gh` commands pass that host, and the Terraform output sets `GITHUB_BASE_URL` to it. `--check` prints its commands for the host it checked. When `gh` cannot tell the repository, the output says how to point `gh` and Terraform at a GitHub Enterprise Server host.
61
+
62
+ - [#2645](https://github.com/tailor-platform/sdk/pull/2645) [`c12410d`](https://github.com/tailor-platform/sdk/commit/c12410d573e9b43b2b84bf5a7d459edb36c83533) Thanks [@toiroakr](https://github.com/toiroakr)! - Fix `Cannot find package '@/...'` from commands that load `tailor.config.ts` (for example `tailor generate`) when the project uses tsconfig `paths` aliases together with pnpm 11.23.0 or later and `enableGlobalVirtualStore: true`. pnpm's `NODE_PATH` resolve hook retries a failed import with a different `parentURL` and leaves it on the hook's context, so the TypeScript loader looked for `tsconfig.json` from `node_modules` instead of from the importing file. The loader now reads the importer before resolving and uses that value afterwards.
63
+
64
+ ## 2.28.0
65
+
66
+ ### Minor Changes
67
+
68
+ - [#2589](https://github.com/tailor-platform/sdk/pull/2589) [`4bf9fd5`](https://github.com/tailor-platform/sdk/commit/4bf9fd5cae3b240f39647002adfdb55b93afb15b) Thanks [@dqn](https://github.com/dqn)! - Default to JSON output when an AI coding agent such as Claude Code, Codex, Cursor, or Gemini CLI runs `tailor`, so the agent reads parseable output even without the bundled agent skill, and start `--help` with guidance for the agent. Pass `--json=false` or set `TAILOR_JSON_OUTPUT=false` to keep table output under an agent, or set `POLITTY_NO_AGENT=1` to turn agent detection off. CLI plugins keep their current output.
69
+
70
+ - [#2595](https://github.com/tailor-platform/sdk/pull/2595) [`928a0cf`](https://github.com/tailor-platform/sdk/commit/928a0cf2d12deeb680f1319ae5cfc90d3c52873d) Thanks [@toiroakr](https://github.com/toiroakr)! - Add `tailor data clone` to copy the data of an application from one workspace to another, and `tailor data operation get` to check on a started clone or wait for it with `--wait`. It copies the TailorDB namespaces registered in the application's subgraph; `--copy-files` and `--copy-idp-users` also copy TailorDB file content and IdP users. `--name` defaults to the application name in the config file. `data clone` waits for the clone to finish; pass `--no-wait` to start it and exit.
71
+
72
+ - [#2595](https://github.com/tailor-platform/sdk/pull/2595) [`a99be0b`](https://github.com/tailor-platform/sdk/commit/a99be0b905bf95a5057e52e19d146b53a78475cc) Thanks [@toiroakr](https://github.com/toiroakr)! - Add `--clone-timeout` to `tailor tailordb migration test` to set how long `--data clone` waits for the data clone to finish, for example `30s` or `10m`. The default is now 30 minutes, up from 5, and the option is rejected with `--data seed`. If your CI job time limit is shorter than 30 minutes, pass a shorter `--clone-timeout` so the command can time out and delete its temporary workspace before the job is stopped.
73
+
74
+ - [#2595](https://github.com/tailor-platform/sdk/pull/2595) [`a99be0b`](https://github.com/tailor-platform/sdk/commit/a99be0b905bf95a5057e52e19d146b53a78475cc) Thanks [@toiroakr](https://github.com/toiroakr)! - Add `--keep-ttl` to `tailor tailordb migration test` to record an expiry, for example `24h` or `7d`, on the temporary workspace that `--keep` retains, so `tailor workspace prune --expired` can delete it later. It requires `--keep`.
75
+
76
+ - [#2586](https://github.com/tailor-platform/sdk/pull/2586) [`65b793b`](https://github.com/tailor-platform/sdk/commit/65b793b86896b939946851a49cbf65f6465fbee7) Thanks [@dqn](https://github.com/dqn)! - Keep scenario and per-environment seed data side by side as datasets: directories under `<distPath>/data/` holding JSONL rows for some of the tables. `tailor seed apply`, `validate`, and `fill` take `--dataset <name>` (repeatable) to use datasets on top of the base seed data, and `tailor seed dump --dataset <name>` writes into one. `--all-datasets` selects every dataset directory in name order for `apply`, `validate`, and `fill`, including gitignored local datasets and directories added later; it cannot be combined with `--dataset`, and fails if no dataset directories exist. `apply --truncate --all-datasets` keeps the existing truncate scope and confirmation. `validate` checks foreign keys across the base data and the selected datasets and reports an id defined in more than one of them at its own file and line; `apply` rejects such an id before it changes anything. `--no-base` applies or validates the selected datasets alone, so a dump written with `--dataset` restores on its own. Name the combinations you use in the new `datasets` option of `seedPlugin` (for example `datasets: { preview: ["cogs", "shipments"] }`) to select them with one `--dataset`. Projects without datasets work as before, except that `tailor seed apply` now reads all seed rows before truncating or seeding anything, so a malformed file stops the run with the workspace untouched. Naming a dataset directory, or a file in one, as the path of `tailor seed validate` or `fill` points you at `--dataset`.
77
+
78
+ - [#2600](https://github.com/tailor-platform/sdk/pull/2600) [`ea634ba`](https://github.com/tailor-platform/sdk/commit/ea634ba08df767730a1e8f415c87e60dfc4c0300) Thanks [@ikawaha](https://github.com/ikawaha)! - Add the `gapless` option to `.serial()` (preview), which numbers records without gaps: a number is used only by a create that commits.
79
+
80
+ - [#2583](https://github.com/tailor-platform/sdk/pull/2583) [`23b3b36`](https://github.com/tailor-platform/sdk/commit/23b3b363cc09bbf6c48e7d84d8b32068898062dd) Thanks [@dqn](https://github.com/dqn)! - Add `maintenanceMode` to `defineConfig()` to choose whether `tailor deploy` restricts the TailorDB namespaces it migrates while pending migrations run. `"migration"` restricts them (no generated GraphQL create, update, delete, or bulk upsert, and no record events) until the migrations complete, as every deploy did before; `"deploy"` keeps them restricted until the deploy has also applied resolvers, executors, and workflows, so executors from the previous deploy do not receive events from the migrated tables while the deploy replaces them; `false` does not restrict them.
81
+
82
+ Tables that a deploy left restricted after its migrations completed, for example because the deploy was interrupted, no longer make the next deploy stop with remote schema drift; that deploy releases them when it applies its TailorDB changes.
83
+
84
+ Restoring table settings after a failed migration no longer fails for a table whose checkpoint sets `publishEvents: false` while an executor in the same deploy subscribes to it, which left that table restricted.
85
+
86
+ - [#2577](https://github.com/tailor-platform/sdk/pull/2577) [`eab2d88`](https://github.com/tailor-platform/sdk/commit/eab2d8867b4e74c79a31a7f47eaeb958c6381370) Thanks [@dqn](https://github.com/dqn)! - Show how long `tailor deploy` keeps tables in maintenance mode while it applies TailorDB migrations. Deploy now tells waiting for a migration job to start apart from the script running: it reports when the script starts running, how long it waited and ran, and a summary of the whole maintenance window by phase. `tailor deploy --json` returns the same breakdown under `tailordbMaintenance`. Each migration job now logs `[tailor-sdk] migration script started` before the script runs.
87
+
88
+ - [#2579](https://github.com/tailor-platform/sdk/pull/2579) [`a139e89`](https://github.com/tailor-platform/sdk/commit/a139e899b087858677aa9e4cc03bf54e49dba95b) Thanks [@dqn](https://github.com/dqn)! - Add `tailor user update --default-organization-id <id> [--default-folder-id <id>]` to store where `tailor workspace create`, workspace creation during `deploy`, and the programmatic `createWorkspace()` put new workspaces when neither organization nor folder is given. The defaults are kept per user and platform, and any explicit organization or folder, including through `TAILOR_PLATFORM_ORGANIZATION_ID` / `TAILOR_PLATFORM_FOLDER_ID` for CLI commands, replaces both. `deploy --create-workspace` also uses the resolved default location when checking whether an existing workspace matches. `workspace create`, `deploy --create-workspace`, and the programmatic `createWorkspace()` now reject a folder ID without an organization ID with a clear error instead of failing with an internal error.
89
+
90
+ `workspace create` and `deploy` now use organization and folder IDs from `--env-file`, even when no user defaults are stored. Previously these values were ignored; a folder-only env file now fails unless an organization is also given. Command-line options take precedence, and empty env-file values are treated as not given.
91
+
92
+ ### Patch Changes
93
+
94
+ - [#2609](https://github.com/tailor-platform/sdk/pull/2609) [`1c36c61`](https://github.com/tailor-platform/sdk/commit/1c36c618e9c4ad2ee4373a5962c8ea278e9aac07) Thanks [@toiroakr](https://github.com/toiroakr)! - `tailor deploy` now warns when an IdP `permission` rule allows every authenticated user (a condition on `_loggedIn`, such as `[{ user: "_loggedIn" }, "=", true]`, as its only condition). Such a rule lets any signed-in user run that operation against any IdP user, for example reading and changing login information such as email addresses or sending password reset emails to anyone. The deploy still succeeds; restrict the rule to an administrator role unless every user who can sign in is trusted.
95
+
96
+ - [#2588](https://github.com/tailor-platform/sdk/pull/2588) [`3de270f`](https://github.com/tailor-platform/sdk/commit/3de270f6bb1d75b74ed4d277593f0e70ecc2b59b) Thanks [@dqn](https://github.com/dqn)! - Update `@politty/zod` to 0.4.3. A positional argument is no longer accepted under its own name as an option, so pass the value positionally: `tailor profile create dev`, not `tailor profile create --name dev`. Most commands report such an option as unknown; a few, such as `tailor completion` and `npm create @tailor-platform/sdk`, only warn and ignore it. `tailor secret vault create --name`, `tailor secret vault delete --name`, and `tailor tailordb truncate --tables`, which the documentation and earlier release notes use, still accept both forms. Mixing the two forms, as in `tailor tailordb truncate --tables User Order`, is rejected; repeat the option for each table, as in `--tables User --tables Order`.
97
+
98
+ - [#2578](https://github.com/tailor-platform/sdk/pull/2578) [`b57a21f`](https://github.com/tailor-platform/sdk/commit/b57a21f9b6e16d6e3a87e19f7504429a41988a9c) Thanks [@dqn](https://github.com/dqn)! - Keep settings that a newer SDK version wrote to the CLI config file (`~/.config/tailor-platform/config.yaml`) when this version rewrites the file, for example after logging in or refreshing a token, instead of silently dropping them.
99
+
100
+ - [#2580](https://github.com/tailor-platform/sdk/pull/2580) [`9c54e51`](https://github.com/tailor-platform/sdk/commit/9c54e516264276dd453d6ad3b546452c830b4006) Thanks [@dqn](https://github.com/dqn)! - Clarify in `tailor workspace prune --help` and error suggestions that location options must be given on the command line and that the defaults from `tailor user update` are not used. Warn before an unscoped sweep that every visible workspace is a candidate for the name and age filters, including with `--yes` or `--dry-run`.
101
+
102
+ - [#2612](https://github.com/tailor-platform/sdk/pull/2612) [`34a67e3`](https://github.com/tailor-platform/sdk/commit/34a67e33a34533bd62f34b7e5bc358c2448eb038) Thanks [@toiroakr](https://github.com/toiroakr)! - Reject `.serial()` on fields inside `db.object()`. TailorDB cannot number a serial field nested in an object, so a create that omitted the value failed with an internal error. It is now a type error, and a build that still defines one fails; remove `.serial()` from the nested field (or move the field out of the object) to upgrade.
103
+
104
+ - [#2556](https://github.com/tailor-platform/sdk/pull/2556) [`56abcc9`](https://github.com/tailor-platform/sdk/commit/56abcc9a063ca90c4561d908c1975296227a3480) Thanks [@renovate](https://github.com/apps/renovate)! - fix(deps): update @​inquirer
105
+
106
+ - [#2604](https://github.com/tailor-platform/sdk/pull/2604) [`4dde6ea`](https://github.com/tailor-platform/sdk/commit/4dde6ea565c97b1bfbdc8606bd0c565d25af6623) Thanks [@renovate](https://github.com/apps/renovate)! - chore(deps): update dependency @​types/node to v24.19.2
107
+
108
+ - [#2607](https://github.com/tailor-platform/sdk/pull/2607) [`b517e0a`](https://github.com/tailor-platform/sdk/commit/b517e0aeede87d34eb518b79c5cfdd8378eb0e50) Thanks [@renovate](https://github.com/apps/renovate)! - fix(deps): update dependency @​napi-rs/keyring to v2.1.1
109
+
110
+ - [#2611](https://github.com/tailor-platform/sdk/pull/2611) [`938f418`](https://github.com/tailor-platform/sdk/commit/938f418c4d847402e579f458f1e3ef3941906288) Thanks [@renovate](https://github.com/apps/renovate)! - fix(deps): update rolldown
111
+
3
112
  ## 2.27.0
4
113
 
5
114
  ### Minor Changes
package/README.md CHANGED
@@ -14,14 +14,6 @@ Tailor Platform is a headless business platform that provides backend services f
14
14
 
15
15
  All configurations are written in TypeScript, providing full type safety.
16
16
 
17
- ### Important Notes
18
-
19
- Some SDK concepts differ from the native Tailor Platform. Be aware of these differences when referring to the official Tailor Platform documentation.
20
-
21
- #### Resolver
22
-
23
- The SDK's Resolver corresponds to Tailor Platform's [Pipeline Resolver](https://docs.tailor.tech/guides/pipeline). The key difference is that Pipeline steps are replaced with a single `body` function. See [Resolver](./docs/services/resolver.md) for details.
24
-
25
17
  ## Installation
26
18
 
27
19
  ```bash
@@ -26,8 +26,10 @@ Use these files as the single source of truth:
26
26
  1. Prefer SDK docs above assumptions. If behavior is unclear, cite the exact doc path used.
27
27
  2. Keep examples compatible with Node.js 22+.
28
28
  3. For CLI questions, verify command and option names from `docs/cli-reference.md` and `docs/cli/*.md`.
29
- 4. When running CLI commands, set `TAILOR_JSON_OUTPUT=true` (or pass `--json`) and parse the JSON
30
- instead of the table output, which is formatted for humans and may change.
29
+ 4. When running CLI commands, parse the JSON instead of the table output, which is formatted for
30
+ humans and may change. The CLI defaults to JSON when it detects an AI coding agent; if a command
31
+ still prints a table (an undetected agent, or a CLI plugin command), set `TAILOR_JSON_OUTPUT=true`
32
+ or pass `--json`. Use `--help-json` for machine-readable help.
31
33
  5. For configuration questions, validate examples against `docs/configuration.md` and related service docs.
32
34
 
33
35
  ## Quick Navigation
@@ -0,0 +1 @@
1
+ export{t as defineApplication,n as generatePluginFilesIfNeeded}from"./application-rWYDAfNU.mjs";