@tailor-platform/sdk 1.76.0 → 1.76.2

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 (273) hide show
  1. package/CHANGELOG.md +52 -0
  2. package/dist/application-6zsDLGKv.mjs +3 -0
  3. package/dist/{application-BUfYmf0O.mjs → application-CqjCcZ2n.mjs} +372 -1673
  4. package/dist/application-CqjCcZ2n.mjs.map +1 -0
  5. package/dist/cli/cache/bundle-cache.d.mts +2 -1
  6. package/dist/cli/cache/store.d.mts +1 -1
  7. package/dist/cli/commands/api/index.d.mts +1 -0
  8. package/dist/cli/commands/deploy/aigateway.d.mts +5 -1
  9. package/dist/cli/commands/deploy/application.d.mts +7 -1
  10. package/dist/cli/commands/deploy/apply-phases.d.mts +14 -1
  11. package/dist/cli/commands/deploy/auth.d.mts +5 -1
  12. package/dist/cli/commands/deploy/deploy.d.mts +5 -0
  13. package/dist/cli/commands/deploy/executor.d.mts +7 -1
  14. package/dist/cli/commands/deploy/function-registry.d.mts +5 -0
  15. package/dist/cli/commands/deploy/idp.d.mts +5 -1
  16. package/dist/cli/commands/deploy/resolver.d.mts +5 -1
  17. package/dist/cli/commands/deploy/secret-manager.d.mts +5 -1
  18. package/dist/cli/commands/deploy/staticwebsite.d.mts +5 -1
  19. package/dist/cli/commands/deploy/tailordb/index.d.mts +8 -1
  20. package/dist/cli/commands/deploy/types.d.mts +3 -1
  21. package/dist/cli/commands/deploy/workflow-execution-policy.d.mts +3 -1
  22. package/dist/cli/commands/deploy/workflow.d.mts +4 -1
  23. package/dist/cli/commands/executor/get.d.mts +0 -1
  24. package/dist/cli/commands/executor/jobs.d.mts +0 -1
  25. package/dist/cli/commands/executor/list.d.mts +0 -1
  26. package/dist/cli/commands/executor/transform.d.mts +1 -0
  27. package/dist/cli/commands/executor/trigger.d.mts +0 -1
  28. package/dist/cli/commands/executor/webhook.d.mts +0 -1
  29. package/dist/cli/commands/function/get.d.mts +0 -1
  30. package/dist/cli/commands/function/list.d.mts +0 -1
  31. package/dist/cli/commands/function/transform.d.mts +1 -0
  32. package/dist/cli/commands/generate/service.d.mts +5 -1
  33. package/dist/cli/commands/generate/types.d.mts +3 -1
  34. package/dist/cli/commands/machineuser/list.d.mts +0 -1
  35. package/dist/cli/commands/machineuser/token.d.mts +0 -1
  36. package/dist/cli/commands/oauth2client/get.d.mts +0 -1
  37. package/dist/cli/commands/oauth2client/list.d.mts +0 -1
  38. package/dist/cli/commands/oauth2client/transform.d.mts +1 -0
  39. package/dist/cli/commands/organization/folder/create.d.mts +0 -1
  40. package/dist/cli/commands/organization/folder/delete.d.mts +0 -1
  41. package/dist/cli/commands/organization/folder/get.d.mts +0 -1
  42. package/dist/cli/commands/organization/folder/list.d.mts +0 -1
  43. package/dist/cli/commands/organization/folder/update.d.mts +0 -1
  44. package/dist/cli/commands/organization/get.d.mts +0 -1
  45. package/dist/cli/commands/organization/list.d.mts +0 -1
  46. package/dist/cli/commands/organization/transform.d.mts +2 -0
  47. package/dist/cli/commands/organization/tree.d.mts +0 -1
  48. package/dist/cli/commands/organization/update.d.mts +0 -1
  49. package/dist/cli/commands/remove.d.mts +0 -1
  50. package/dist/cli/commands/show.d.mts +0 -1
  51. package/dist/cli/commands/tailordb/migrate/config.d.mts +0 -1
  52. package/dist/cli/commands/tailordb/migrate/diff-calculator.d.mts +0 -1
  53. package/dist/cli/commands/tailordb/migrate/generate.d.mts +0 -1
  54. package/dist/cli/commands/tailordb/migrate/snapshot.d.mts +1 -1
  55. package/dist/cli/commands/tailordb/truncate.d.mts +0 -1
  56. package/dist/cli/commands/workflow/executions.d.mts +0 -1
  57. package/dist/cli/commands/workflow/get.d.mts +2 -1
  58. package/dist/cli/commands/workflow/list.d.mts +0 -1
  59. package/dist/cli/commands/workflow/resume.d.mts +0 -1
  60. package/dist/cli/commands/workflow/start.d.mts +0 -1
  61. package/dist/cli/commands/workflow/status.d.mts +1 -0
  62. package/dist/cli/commands/workflow/transform.d.mts +1 -0
  63. package/dist/cli/commands/workflow/wait.d.mts +0 -1
  64. package/dist/cli/commands/workflow/waiter.d.mts +1 -1
  65. package/dist/cli/commands/workspace/app/health.d.mts +0 -1
  66. package/dist/cli/commands/workspace/app/list.d.mts +0 -1
  67. package/dist/cli/commands/workspace/app/transform.d.mts +2 -0
  68. package/dist/cli/commands/workspace/create.d.mts +0 -1
  69. package/dist/cli/commands/workspace/delete.d.mts +0 -1
  70. package/dist/cli/commands/workspace/get.d.mts +0 -1
  71. package/dist/cli/commands/workspace/list.d.mts +0 -1
  72. package/dist/cli/commands/workspace/restore.d.mts +0 -1
  73. package/dist/cli/commands/workspace/transform.d.mts +2 -0
  74. package/dist/cli/commands/workspace/user/invite.d.mts +0 -1
  75. package/dist/cli/commands/workspace/user/list.d.mts +0 -1
  76. package/dist/cli/commands/workspace/user/remove.d.mts +0 -1
  77. package/dist/cli/commands/workspace/user/transform.d.mts +1 -0
  78. package/dist/cli/commands/workspace/user/update.d.mts +0 -1
  79. package/dist/cli/index.d.mts +3 -1
  80. package/dist/cli/index.mjs +599 -42
  81. package/dist/cli/index.mjs.map +1 -1
  82. package/dist/cli/lib.d.mts +2 -0
  83. package/dist/cli/lib.mjs +3 -3
  84. package/dist/cli/query/index.d.mts +0 -1
  85. package/dist/cli/services/application.d.mts +12 -1
  86. package/dist/cli/services/auth/service.d.mts +2 -0
  87. package/dist/cli/services/executor/service.d.mts +1 -1
  88. package/dist/cli/services/http-adapter/bundler.d.mts +3 -1
  89. package/dist/cli/services/http-adapter/service.d.mts +2 -1
  90. package/dist/cli/services/resolver/service.d.mts +1 -1
  91. package/dist/cli/services/tailordb/service.d.mts +3 -1
  92. package/dist/cli/services/workflow/bundler.d.mts +2 -1
  93. package/dist/cli/services/workflow/service.d.mts +1 -1
  94. package/dist/cli/shared/args.d.mts +1 -1
  95. package/dist/cli/shared/client.d.mts +1 -1
  96. package/dist/cli/shared/config-loader.d.mts +0 -1
  97. package/dist/cli/shared/context.d.mts +2 -1
  98. package/dist/cli/shared/script-executor.d.mts +0 -1
  99. package/dist/cli/shared/seed-chunker.d.mts +7 -3
  100. package/dist/cli/shared/type-generator.d.mts +0 -1
  101. package/dist/completion/zsh-worker.zsh +1 -1
  102. package/dist/configure/config/index.d.mts +0 -1
  103. package/dist/configure/config/types.d.mts +2 -2
  104. package/dist/configure/index.d.mts +2 -1
  105. package/dist/configure/index.mjs +54 -4
  106. package/dist/configure/index.mjs.map +1 -1
  107. package/dist/configure/services/aigateway/index.d.mts +0 -1
  108. package/dist/configure/services/aigateway/types.d.mts +0 -1
  109. package/dist/configure/services/auth/index.d.mts +0 -1
  110. package/dist/configure/services/auth/types.d.mts +14 -13
  111. package/dist/configure/services/executor/executor.d.mts +0 -1
  112. package/dist/configure/services/executor/index.d.mts +1 -0
  113. package/dist/configure/services/executor/operation.d.mts +1 -2
  114. package/dist/configure/services/executor/trigger/event.d.mts +0 -1
  115. package/dist/configure/services/executor/trigger/index.d.mts +0 -1
  116. package/dist/configure/services/executor/trigger/schedule.d.mts +0 -1
  117. package/dist/configure/services/executor/trigger/webhook.d.mts +0 -1
  118. package/dist/configure/services/http-adapter/http-adapter.d.mts +1 -2
  119. package/dist/configure/services/idp/index.d.mts +0 -1
  120. package/dist/configure/services/idp/permission.d.mts +4 -5
  121. package/dist/configure/services/idp/types.d.mts +0 -1
  122. package/dist/configure/services/index.d.mts +5 -0
  123. package/dist/configure/services/resolver/resolver.d.mts +0 -1
  124. package/dist/configure/services/resolver/types.d.mts +0 -1
  125. package/dist/configure/services/secrets/index.d.mts +0 -1
  126. package/dist/configure/services/secrets/types.d.mts +0 -1
  127. package/dist/configure/services/staticwebsite/index.d.mts +0 -1
  128. package/dist/configure/services/staticwebsite/types.d.mts +0 -1
  129. package/dist/configure/services/tailordb/permission.d.mts +4 -5
  130. package/dist/configure/services/tailordb/schema.d.mts +24 -14
  131. package/dist/configure/services/tailordb/types.d.mts +4 -5
  132. package/dist/configure/services/workflow/execution-policy.d.mts +0 -1
  133. package/dist/configure/services/workflow/execution-policy.types.d.mts +0 -1
  134. package/dist/configure/services/workflow/index.d.mts +1 -0
  135. package/dist/configure/services/workflow/job.d.mts +0 -1
  136. package/dist/configure/services/workflow/wait-point.d.mts +0 -1
  137. package/dist/configure/services/workflow/workflow.d.mts +0 -1
  138. package/dist/configure/types/field-runtime.d.mts +1 -1
  139. package/dist/configure/types/field.d.mts +1 -2
  140. package/dist/configure/types/field.types.d.mts +1 -2
  141. package/dist/configure/types/type.d.mts +1 -1
  142. package/dist/configure/user.d.mts +0 -1
  143. package/dist/{crashreport-ayWANEZ6.mjs → crashreport-DZDr-TvH.mjs} +3 -2
  144. package/dist/{crashreport-ayWANEZ6.mjs.map → crashreport-DZDr-TvH.mjs.map} +1 -1
  145. package/dist/{crashreport-Dy4ZzSkd.mjs → crashreport-np4-_DX2.mjs} +1 -1
  146. package/dist/{field-runtime-9bfXBAOK.mjs → field-runtime-D4QWRiB1.mjs} +66 -46
  147. package/dist/field-runtime-D4QWRiB1.mjs.map +1 -0
  148. package/dist/{globals-CcU1ONiK.mjs → globals-z6zYMjlr.mjs} +2 -2
  149. package/dist/{globals-CcU1ONiK.mjs.map → globals-z6zYMjlr.mjs.map} +1 -1
  150. package/dist/kysely/index.d.mts +3 -4
  151. package/dist/parser/service/auth/index.d.mts +1 -1
  152. package/dist/parser/service/auth/schema.d.mts +1 -0
  153. package/dist/parser/service/http-adapter/index.d.mts +1 -1
  154. package/dist/parser/service/idp/types.d.mts +1 -0
  155. package/dist/parser/service/tailordb/types.d.mts +0 -1
  156. package/dist/plugin/builtin/enum-constants/index.d.mts +0 -1
  157. package/dist/plugin/builtin/file-utils/index.d.mts +0 -1
  158. package/dist/plugin/builtin/kysely-type/index.d.mts +0 -1
  159. package/dist/plugin/builtin/seed/index.d.mts +0 -1
  160. package/dist/plugin/builtin/seed/index.mjs +1 -1
  161. package/dist/plugin/get-generated-type.d.mts +0 -1
  162. package/dist/plugin/manager.d.mts +3 -1
  163. package/dist/plugin/types.d.mts +0 -1
  164. package/dist/plugin/with-context.d.mts +0 -1
  165. package/dist/{registry-NfSW0BRo.mjs → registry-CTgoVWc_.mjs} +4 -49
  166. package/dist/registry-CTgoVWc_.mjs.map +1 -0
  167. package/dist/runtime/aigateway.d.mts +0 -2
  168. package/dist/runtime/authconnection.d.mts +0 -2
  169. package/dist/runtime/globals.d.mts +0 -1
  170. package/dist/runtime/index.d.mts +0 -1
  171. package/dist/runtime/types.d.mts +16 -7
  172. package/dist/{runtime-_vUgjiqT.mjs → runtime-DlklyuHN.mjs} +1301 -716
  173. package/dist/runtime-DlklyuHN.mjs.map +1 -0
  174. package/dist/{schema-DrVyN-LP.mjs → schema-DbTR1c6M.mjs} +3 -2
  175. package/dist/schema-DbTR1c6M.mjs.map +1 -0
  176. package/dist/{secret-file-VSVGy1V0.mjs → secret-file-DBqZhjFQ.mjs} +2 -27
  177. package/dist/{secret-file-VSVGy1V0.mjs.map → secret-file-DBqZhjFQ.mjs.map} +1 -1
  178. package/dist/seed/index.d.mts +3 -2
  179. package/dist/{seed-fm0LeYP2.mjs → seed-DFFigL8V.mjs} +3 -13
  180. package/dist/seed-DFFigL8V.mjs.map +1 -0
  181. package/dist/service_pb-BoLM0X4K.mjs +167 -0
  182. package/dist/service_pb-BoLM0X4K.mjs.map +1 -0
  183. package/dist/{service_pb-B2FF59sP.mjs → service_pb-r1T7kpJc.mjs} +1 -1
  184. package/dist/tailor-proto/src/tailor/v1/aigateway_pb.d.mts +0 -1
  185. package/dist/tailor-proto/src/tailor/v1/aigateway_resource_pb.d.mts +0 -1
  186. package/dist/tailor-proto/src/tailor/v1/application_pb.d.mts +0 -1
  187. package/dist/tailor-proto/src/tailor/v1/application_resource_pb.d.mts +0 -1
  188. package/dist/tailor-proto/src/tailor/v1/auth_pb.d.mts +0 -1
  189. package/dist/tailor-proto/src/tailor/v1/auth_resource_pb.d.mts +0 -1
  190. package/dist/tailor-proto/src/tailor/v1/events_pb.d.mts +0 -1
  191. package/dist/tailor-proto/src/tailor/v1/events_resource_pb.d.mts +0 -1
  192. package/dist/tailor-proto/src/tailor/v1/executor_pb.d.mts +0 -1
  193. package/dist/tailor-proto/src/tailor/v1/executor_resource_pb.d.mts +0 -1
  194. package/dist/tailor-proto/src/tailor/v1/function_pb.d.mts +0 -1
  195. package/dist/tailor-proto/src/tailor/v1/function_registry_pb.d.mts +0 -1
  196. package/dist/tailor-proto/src/tailor/v1/function_resource_pb.d.mts +0 -1
  197. package/dist/tailor-proto/src/tailor/v1/http_adapter_resource_pb.d.mts +0 -1
  198. package/dist/tailor-proto/src/tailor/v1/idp_pb.d.mts +0 -1
  199. package/dist/tailor-proto/src/tailor/v1/idp_resource_pb.d.mts +0 -1
  200. package/dist/tailor-proto/src/tailor/v1/metadata_pb.d.mts +0 -1
  201. package/dist/tailor-proto/src/tailor/v1/metadata_resource_pb.d.mts +0 -1
  202. package/dist/tailor-proto/src/tailor/v1/meter_pb.d.mts +0 -1
  203. package/dist/tailor-proto/src/tailor/v1/pipeline_pb.d.mts +0 -1
  204. package/dist/tailor-proto/src/tailor/v1/pipeline_resource_pb.d.mts +0 -1
  205. package/dist/tailor-proto/src/tailor/v1/resource_pb.d.mts +0 -1
  206. package/dist/tailor-proto/src/tailor/v1/secret_manager_pb.d.mts +0 -1
  207. package/dist/tailor-proto/src/tailor/v1/secret_manager_resource_pb.d.mts +0 -1
  208. package/dist/tailor-proto/src/tailor/v1/service_pb.d.mts +0 -1
  209. package/dist/tailor-proto/src/tailor/v1/stateflow_pb.d.mts +0 -1
  210. package/dist/tailor-proto/src/tailor/v1/stateflow_resource_pb.d.mts +0 -1
  211. package/dist/tailor-proto/src/tailor/v1/staticwebsite_pb.d.mts +0 -1
  212. package/dist/tailor-proto/src/tailor/v1/staticwebsite_resource_pb.d.mts +0 -1
  213. package/dist/tailor-proto/src/tailor/v1/tailordb_pb.d.mts +0 -1
  214. package/dist/tailor-proto/src/tailor/v1/tailordb_resource_pb.d.mts +0 -1
  215. package/dist/tailor-proto/src/tailor/v1/telemetryrouter_pb.d.mts +0 -1
  216. package/dist/tailor-proto/src/tailor/v1/telemetryrouter_resource_pb.d.mts +0 -1
  217. package/dist/tailor-proto/src/tailor/v1/workflow_pb.d.mts +0 -1
  218. package/dist/tailor-proto/src/tailor/v1/workflow_resource_pb.d.mts +0 -1
  219. package/dist/tailor-proto/src/tailor/v1/workspace_pb.d.mts +0 -1
  220. package/dist/tailor-proto/src/tailor/v1/workspace_resource_pb.d.mts +0 -1
  221. package/dist/test-env-key-IPapa1KJ.mjs +49 -0
  222. package/dist/test-env-key-IPapa1KJ.mjs.map +1 -0
  223. package/dist/type-source-DH_LH20p.mjs +13 -0
  224. package/dist/type-source-DH_LH20p.mjs.map +1 -0
  225. package/dist/types/aigateway.generated.d.mts +5 -2
  226. package/dist/types/auth-connection.generated.d.mts +11 -5
  227. package/dist/types/auth.generated.d.mts +111 -51
  228. package/dist/types/executor.generated.d.mts +59 -27
  229. package/dist/types/helpers.d.mts +5 -5
  230. package/dist/types/http-adapter.generated.d.mts +11 -5
  231. package/dist/types/idp.generated.d.mts +20 -9
  232. package/dist/types/resolver.generated.d.mts +19 -9
  233. package/dist/types/staticwebsite.generated.d.mts +7 -3
  234. package/dist/types/tailordb.generated.d.mts +47 -22
  235. package/dist/types/workflow.generated.d.mts +9 -4
  236. package/dist/{types-BwzB2okW.mjs → types-BzJ7A_fn.mjs} +2 -2
  237. package/dist/{types-BwzB2okW.mjs.map → types-BzJ7A_fn.mjs.map} +1 -1
  238. package/dist/types-CG9H7HuE.mjs +4 -0
  239. package/dist/user-agent-DX2Jnw0-.mjs +28 -0
  240. package/dist/user-agent-DX2Jnw0-.mjs.map +1 -0
  241. package/dist/utils/test/index.d.mts +0 -1
  242. package/dist/utils/test/index.mjs +1 -1
  243. package/dist/utils/test/mock.d.mts +0 -1
  244. package/dist/vitest/environment.mjs +1 -1
  245. package/dist/vitest/index.d.mts +1 -1
  246. package/dist/vitest/index.mjs +2 -1
  247. package/dist/vitest/index.mjs.map +1 -1
  248. package/dist/vitest/mock-kysely.d.mts +0 -1
  249. package/dist/vitest/mocks/aigateway.d.mts +2 -2
  250. package/dist/vitest/mocks/authconnection.d.mts +2 -2
  251. package/dist/vitest/mocks/idp.d.mts +2 -2
  252. package/dist/vitest/mocks/secretmanager.d.mts +3 -1
  253. package/dist/vitest/mocks/tailordb.d.mts +6 -3
  254. package/dist/vitest/mocks/workflow.d.mts +11 -6
  255. package/dist/vitest/setup.mjs +1 -1
  256. package/dist/{service_pb-B5w9rjPY.mjs → workspace_resource_pb-Db3fv68L.mjs} +57 -165
  257. package/dist/workspace_resource_pb-Db3fv68L.mjs.map +1 -0
  258. package/docs/services/tailordb.md +10 -1
  259. package/package.json +18 -18
  260. package/dist/application-BUfYmf0O.mjs.map +0 -1
  261. package/dist/application-DbvD5UUz.mjs +0 -3
  262. package/dist/cli/shared/trigger-context.d.mts +0 -1
  263. package/dist/field-runtime-9bfXBAOK.mjs.map +0 -1
  264. package/dist/job-D-PbD1P3.mjs +0 -55
  265. package/dist/job-D-PbD1P3.mjs.map +0 -1
  266. package/dist/registry-NfSW0BRo.mjs.map +0 -1
  267. package/dist/resource_pb-BRv7AMXK.mjs +0 -49
  268. package/dist/resource_pb-BRv7AMXK.mjs.map +0 -1
  269. package/dist/runtime-_vUgjiqT.mjs.map +0 -1
  270. package/dist/schema-DrVyN-LP.mjs.map +0 -1
  271. package/dist/seed-fm0LeYP2.mjs.map +0 -1
  272. package/dist/service_pb-B5w9rjPY.mjs.map +0 -1
  273. package/dist/types-KlawuVKa.mjs +0 -4
@@ -6,6 +6,7 @@ import { Resolver } from "../types/resolver.generated.mjs";
6
6
  import { LoadedConfig, loadConfig } from "./shared/config-loader.mjs";
7
7
  import { AuthInvoker } from "../tailor-proto/src/tailor/v1/auth_resource_pb.mjs";
8
8
  import { OperatorClient, initOperatorClient } from "./shared/client.mjs";
9
+ import "./commands/deploy/function-registry.mjs";
9
10
  import { NormalizedSchemaSnapshot, SchemaSnapshot, SnapshotFieldConfig, TailorDBSnapshotType } from "./commands/tailordb/migrate/snapshot-types.mjs";
10
11
  import { BreakingChangeInfo, MigrationDiff, formatDiffSummary, formatMigrationDiff, hasChanges } from "./commands/tailordb/migrate/diff-calculator.mjs";
11
12
  import { MIGRATION_LABEL_KEY } from "./commands/tailordb/migrate/types.mjs";
@@ -69,6 +70,7 @@ import { UpdateFolderOptions, updateFolder } from "./commands/organization/folde
69
70
  import { DeleteFolderOptions, deleteFolder } from "./commands/organization/folder/delete.mjs";
70
71
  import { loadAccessToken, loadWorkspaceId } from "./shared/context.mjs";
71
72
  import { ApiCallOptions, ApiCallResult, apiCall } from "./commands/api/api-call.mjs";
73
+ import "./commands/api/index.mjs";
72
74
  import { query } from "./query/index.mjs";
73
75
  import { TruncateOptions, truncate } from "./commands/tailordb/truncate.mjs";
74
76
  import { GenerateOptions as GenerateOptions$1, generate as generate$1 } from "./commands/tailordb/migrate/generate.mjs";
package/dist/cli/lib.mjs CHANGED
@@ -1,11 +1,11 @@
1
1
  import { t as assertDefined } from "../assert-DBxo8jPo.mjs";
2
- import { D as loadConfig, M as loadAccessToken, R as loadWorkspaceId, _ as platformBundleDefinePlugin, rt as initOperatorClient, w as getDistDir } from "../application-BUfYmf0O.mjs";
3
- import { $ as getOrganization, At as getExecutorWaitFailureMessage, B as show, Bt as listWorkflowExecutions, Cn as hasChanges, Ct as listWebhookExecutors, D as waitWorkflowExecution, Et as triggerExecutor, Ft as startWorkflow, Gt as deploy, J as organizationTree, Jt as waitForExecution, Lt as getWorkflow, M as truncate, Mt as listExecutorJobs, Nt as watchExecutorJob, On as generateUserTypes, Ot as listExecutors, P as generate$1, S as listApps, Sn as formatMigrationDiff, St as getFunctionRegistry, W as remove, Wt as getExecutor, Xt as MIGRATION_LABEL_KEY, Yt as bundleMigrationScript, Z as listOrganizations, _ as getWorkspace, _t as listMachineUsers, a as updateUser, an as MIGRATE_FILE_NAME, at as getFolder, bt as listFunctionRegistries, cn as compareLocalTypesWithSnapshot, d as inviteUser, dn as getLatestMigrationNumber, dt as listOAuth2Clients, fn as getMigrationDirPath, h as listWorkspaces, hn as getNextMigrationNumber, in as INITIAL_SCHEMA_NUMBER, j as listWorkflows, jn as apiCall, k as resumeWorkflow, kt as getExecutorJob, l as listUsers, ln as compareSnapshots, lt as createFolder, mn as getMigrationFiles, mt as getMachineUserToken, n as query, nn as DB_TYPES_FILE_NAME, on as SCHEMA_FILE_NAME, p as restoreWorkspace, pn as getMigrationFilePath, pt as getOAuth2Client, q as updateOrganization, qt as executeScript, rn as DIFF_FILE_NAME, rt as listFolders, s as removeUser, st as deleteFolder, t as isNativeTypeScriptRuntime, tt as updateFolder, un as createSnapshotFromLocalTypes, vn as reconstructSnapshotFromMigrations, vt as generate, w as getAppHealth, wn as getNamespacesWithMigrations, x as createWorkspace, xn as formatDiffSummary, y as deleteWorkspace, zt as getWorkflowExecution } from "../runtime-_vUgjiqT.mjs";
2
+ import { $ as getOrganization, An as apiCall, At as getExecutorWaitFailureMessage, B as show, Bt as listWorkflowExecutions, Cn as hasChanges, Ct as listWebhookExecutors, D as waitWorkflowExecution, Et as triggerExecutor, Ft as startWorkflow, Gt as deploy, J as organizationTree, Jt as waitForExecution, Ln as loadAccessToken, Lt as getWorkflow, M as truncate, Mn as loadConfig, Mt as listExecutorJobs, Nt as watchExecutorJob, On as generateUserTypes, Ot as listExecutors, P as generate$1, S as listApps, Sn as formatMigrationDiff, St as getFunctionRegistry, Vn as loadWorkspaceId, W as remove, Wt as getExecutor, Xt as MIGRATION_LABEL_KEY, Yt as bundleMigrationScript, Z as listOrganizations, _ as getWorkspace, _t as listMachineUsers, a as updateUser, an as MIGRATE_FILE_NAME, at as getFolder, bt as listFunctionRegistries, cn as compareLocalTypesWithSnapshot, d as inviteUser, dn as getLatestMigrationNumber, dt as listOAuth2Clients, fn as getMigrationDirPath, h as listWorkspaces, hn as getNextMigrationNumber, in as INITIAL_SCHEMA_NUMBER, j as listWorkflows, k as resumeWorkflow, kt as getExecutorJob, l as listUsers, ln as compareSnapshots, lt as createFolder, mn as getMigrationFiles, mt as getMachineUserToken, n as query, nn as DB_TYPES_FILE_NAME, on as SCHEMA_FILE_NAME, p as restoreWorkspace, pn as getMigrationFilePath, pt as getOAuth2Client, q as updateOrganization, qt as executeScript, rn as DIFF_FILE_NAME, rt as listFolders, s as removeUser, st as deleteFolder, t as isNativeTypeScriptRuntime, tt as updateFolder, un as createSnapshotFromLocalTypes, vn as reconstructSnapshotFromMigrations, vt as generate, w as getAppHealth, wn as getNamespacesWithMigrations, x as createWorkspace, xn as formatDiffSummary, y as deleteWorkspace, zt as getWorkflowExecution } from "../runtime-DlklyuHN.mjs";
3
+ import { B as initOperatorClient, _ as platformBundleDefinePlugin, w as getDistDir } from "../application-CqjCcZ2n.mjs";
4
4
  import { n as enumConstantsPlugin } from "../enum-constants-j9QBF0cB.mjs";
5
5
  import { t as multiline } from "../multiline-sfHpTZZK.mjs";
6
6
  import { n as fileUtilsPlugin } from "../file-utils-DcyIPFQh.mjs";
7
7
  import { n as kyselyTypePlugin } from "../kysely-type-D-zflMGf.mjs";
8
- import { n as seedPlugin } from "../seed-fm0LeYP2.mjs";
8
+ import { n as seedPlugin } from "../seed-DFFigL8V.mjs";
9
9
  import * as fs from "node:fs";
10
10
  import * as path from "pathe";
11
11
  import { resolveTSConfig } from "pkg-types";
@@ -1,5 +1,4 @@
1
1
  import { z } from "zod";
2
-
3
2
  //#region src/cli/query/index.d.ts
4
3
  declare const queryOptionsSchema: z.ZodObject<{
5
4
  workspaceId: z.ZodOptional<z.ZodString>;
@@ -1 +1,12 @@
1
- export { };
1
+ import "../../plugin/manager.mjs";
2
+ import "./tailordb/service.mjs";
3
+ import "./auth/service.mjs";
4
+ import "../../configure/config/types.mjs";
5
+ import "./executor/service.mjs";
6
+ import "../cache/bundle-cache.mjs";
7
+ import "./http-adapter/bundler.mjs";
8
+ import "./http-adapter/service.mjs";
9
+ import "./resolver/service.mjs";
10
+ import "./workflow/bundler.mjs";
11
+ import "./workflow/service.mjs";
12
+ import "../shared/config-loader.mjs";
@@ -1 +1,3 @@
1
+ import "../tailordb/service.mjs";
2
+ import "../../../parser/service/auth/index.mjs";
1
3
  import { z } from "zod";
@@ -1 +1 @@
1
- export { };
1
+ import "../../../configure/config/types.mjs";
@@ -1 +1,3 @@
1
- export { };
1
+ import "../../../configure/config/types.mjs";
2
+ import "../../cache/bundle-cache.mjs";
3
+ import "../../../parser/service/http-adapter/index.mjs";
@@ -1 +1,2 @@
1
- export { };
1
+ import "../../../configure/config/types.mjs";
2
+ import "../../../parser/service/http-adapter/index.mjs";
@@ -1 +1 @@
1
- export { };
1
+ import "../../../configure/config/types.mjs";
@@ -1 +1,3 @@
1
- export { };
1
+ import "../../../parser/service/tailordb/types.mjs";
2
+ import "../../../plugin/types.mjs";
3
+ import "../../../plugin/manager.mjs";
@@ -1 +1,2 @@
1
- export { };
1
+ import "../../../configure/config/types.mjs";
2
+ import "../../cache/bundle-cache.mjs";
@@ -1 +1 @@
1
- export { };
1
+ import "../../../configure/config/types.mjs";
@@ -1,5 +1,5 @@
1
+ import "../../tailor-proto/src/tailor/v1/resource_pb.mjs";
1
2
  import { z } from "zod";
2
-
3
3
  //#region src/cli/shared/args.d.ts
4
4
  /**
5
5
  * Schema for sort order (`asc` or `desc`).
@@ -17,8 +17,8 @@ import { CreateWorkflowJobFunctionExecutionPolicyRequestSchema, CreateWorkflowJo
17
17
  import { GetMetadataRequestSchema, GetMetadataResponseSchema, SetMetadataRequestSchema, SetMetadataResponseSchema } from "../../tailor-proto/src/tailor/v1/metadata_pb.mjs";
18
18
  import { CreateOTLPExporterRequestSchema, CreateOTLPExporterResponseSchema, CreateResourceAttributesConfigRequestSchema, CreateResourceAttributesConfigResponseSchema, DeleteOTLPExporterRequestSchema, DeleteOTLPExporterResponseSchema, DeleteResourceAttributesConfigRequestSchema, DeleteResourceAttributesConfigResponseSchema, GetOTLPExporterRequestSchema, GetOTLPExporterResponseSchema, GetResourceAttributesConfigRequestSchema, GetResourceAttributesConfigResponseSchema, ListOTLPExportersRequestSchema, ListOTLPExportersResponseSchema, TestOTLPExporterRequestSchema, TestOTLPExporterResponseSchema, UpdateOTLPExporterRequestSchema, UpdateOTLPExporterResponseSchema, UpdateResourceAttributesConfigRequestSchema, UpdateResourceAttributesConfigResponseSchema } from "../../tailor-proto/src/tailor/v1/telemetryrouter_pb.mjs";
19
19
  import { OperatorService, PingRequestSchema, PingResponseSchema } from "../../tailor-proto/src/tailor/v1/service_pb.mjs";
20
+ import "@badgateway/oauth2-client";
20
21
  import { Client } from "@connectrpc/connect";
21
-
22
22
  //#region src/cli/shared/client.d.ts
23
23
  type PlatformClientConfig = {
24
24
  platformUrl?: string;
@@ -1,7 +1,6 @@
1
1
  import { Plugin } from "../../plugin/types.mjs";
2
2
  import { AppConfig } from "../../configure/config/types.mjs";
3
3
  import { z } from "zod";
4
-
5
4
  //#region src/cli/shared/config-loader.d.ts
6
5
  /**
7
6
  * Loaded configuration with resolved path
@@ -1,5 +1,6 @@
1
+ import "./client.mjs";
2
+ import "./args.mjs";
1
3
  import { z } from "zod";
2
-
3
4
  //#region src/cli/shared/context.d.ts
4
5
  type LoadWorkspaceIdOptions = {
5
6
  workspaceId?: string;
@@ -1,7 +1,6 @@
1
1
  import { AuthInvoker } from "../../tailor-proto/src/tailor/v1/auth_resource_pb.mjs";
2
2
  import { FunctionExecution_Status } from "../../tailor-proto/src/tailor/v1/function_resource_pb.mjs";
3
3
  import { OperatorClient } from "./client.mjs";
4
-
5
4
  //#region src/cli/shared/script-executor.d.ts
6
5
  /**
7
6
  * Options for script execution
@@ -22,9 +22,13 @@ type SeedChunk = {
22
22
  * Options for chunking seed data.
23
23
  */
24
24
  type ChunkSeedDataOptions = {
25
- /** Seed data keyed by type name */data: SeedData; /** Ordered list of type names (dependency order) */
26
- order: string[]; /** Byte size of the bundled seed script code */
27
- codeByteSize: number; /** Maximum gRPC message size in bytes (default: 3.5MB) */
25
+ /** Seed data keyed by type name */
26
+ data: SeedData;
27
+ /** Ordered list of type names (dependency order) */
28
+ order: string[];
29
+ /** Byte size of the bundled seed script code */
30
+ codeByteSize: number;
31
+ /** Maximum gRPC message size in bytes (default: 3.5MB) */
28
32
  maxMessageSize?: number;
29
33
  };
30
34
  /**
@@ -1,5 +1,4 @@
1
1
  import { AppConfig } from "../../configure/config/types.mjs";
2
-
3
2
  //#region src/cli/shared/type-generator.d.ts
4
3
  /**
5
4
  * Options for generating user type definitions
@@ -1,5 +1,5 @@
1
1
  # politty-completion-version: 1
2
- # politty-bin-sig: 1783647457
2
+ # politty-bin-sig: 1783991997
3
3
  # politty-bin-path: /home/runner/work/sdk/sdk/node_modules/.bin/tailor-sdk
4
4
  # program: tailor-sdk
5
5
  # shell: zsh
@@ -1,7 +1,6 @@
1
1
  import { BaseGeneratorConfig } from "../../types/generator-config.generated.mjs";
2
2
  import { GeneratorConfig, Plugin } from "../../plugin/types.mjs";
3
3
  import { AppConfig } from "./types.mjs";
4
-
5
4
  //#region src/configure/config/index.d.ts
6
5
  /**
7
6
  * Define a Tailor SDK application configuration with shallow exactness.
@@ -6,7 +6,6 @@ import { SecretsConfig } from "../services/secrets/types.mjs";
6
6
  import { StaticWebsiteConfig } from "../services/staticwebsite/types.mjs";
7
7
  import { ExecutionPolicyInstance } from "../services/workflow/execution-policy.types.mjs";
8
8
  import { LogLevelEnum } from "../../types/app-config.generated.mjs";
9
-
10
9
  //#region src/configure/config/types.d.ts
11
10
  type LogLevel = LogLevelEnum;
12
11
  type LogLevelInput = LogLevel | (string & {});
@@ -33,7 +32,8 @@ type WorkflowServiceConfig = {
33
32
  files: string[];
34
33
  job_files?: string[];
35
34
  ignores?: string[];
36
- job_ignores?: string[]; /** Workspace-level execution policies for workflow job functions. */
35
+ job_ignores?: string[];
36
+ /** Workspace-level execution policies for workflow job functions. */
37
37
  executionPolicies?: Record<string, ExecutionPolicyInstance>;
38
38
  };
39
39
  type WorkflowServiceInput = WorkflowServiceConfig;
@@ -21,6 +21,7 @@ import { ExecutorServiceConfig, ExecutorServiceInput, ResolverExternalConfig, Re
21
21
  import { ConcurrencyPolicy, RetryPolicy } from "../types/workflow.generated.mjs";
22
22
  import { TailorAnyField, TailorField } from "./types/type.mjs";
23
23
  import { MachineUserName, MachineUserNameRegistry } from "./types/machine-user.mjs";
24
+ import "./types/index.mjs";
24
25
  import { unauthenticatedTailorUser } from "./user.mjs";
25
26
  import { IdpName, IdpNameRegistry } from "./types/idp-name.mjs";
26
27
  import { ConnectionName, ConnectionNameRegistry } from "./types/connection-name.mjs";
@@ -45,8 +46,8 @@ import { IdPPermission, IdPPermissionCondition, unsafeAllowAllIdPPermission } fr
45
46
  import { defineIdp } from "./services/idp/index.mjs";
46
47
  import { defineSecretManager } from "./services/secrets/index.mjs";
47
48
  import { HttpAdapter, HttpAdapterGraphQLQuery, HttpAdapterGraphQLRequest, HttpAdapterGraphQLResponse, HttpAdapterInput, HttpAdapterInputFn, HttpAdapterOutputFn, HttpAdapterRequest, HttpAdapterResponse, HttpAdapterTypedDocumentNode, createHttpAdapter } from "./services/http-adapter/http-adapter.mjs";
49
+ import "./services/index.mjs";
48
50
  import { defineConfig, defineGenerators, definePlugins } from "./config/index.mjs";
49
-
50
51
  //#region src/configure/index.d.ts
51
52
  type TailorOutput<T> = output$1<T>;
52
53
  type infer<T> = TailorOutput<T>;
@@ -1,8 +1,8 @@
1
- import { t as t$1 } from "../types-BwzB2okW.mjs";
1
+ import { t as t$1 } from "../types-BzJ7A_fn.mjs";
2
2
  import { t as brandValue } from "../brand-Eo4pLXPJ.mjs";
3
- import { t as db } from "../schema-DrVyN-LP.mjs";
4
- import { r as dispatchTriggerWorkflow, s as registerWorkflow, u as WORKFLOW_TEST_ENV_KEY } from "../registry-NfSW0BRo.mjs";
5
- import { t as createWorkflowJob } from "../job-D-PbD1P3.mjs";
3
+ import { t as db } from "../schema-DbTR1c6M.mjs";
4
+ import { n as dispatchTriggerJob, o as registerJob, r as dispatchTriggerWorkflow, s as registerWorkflow } from "../registry-CTgoVWc_.mjs";
5
+ import { t as WORKFLOW_TEST_ENV_KEY } from "../test-env-key-IPapa1KJ.mjs";
6
6
 
7
7
  //#region src/configure/user.ts
8
8
  /** Represents an unauthenticated user in the Tailor platform. */
@@ -477,6 +477,56 @@ function defineWorkflowExecutionPolicies(builder, options) {
477
477
  return result;
478
478
  }
479
479
 
480
+ //#endregion
481
+ //#region src/configure/services/workflow/job.ts
482
+ /**
483
+ * Create a workflow job definition.
484
+ *
485
+ * All jobs must be named exports from the workflow file.
486
+ * Job names must be unique across the entire project.
487
+ *
488
+ * Input and output must be JsonValue-compatible (primitives, plain objects, arrays).
489
+ * Functions and objects with a `toJSON` method are rejected at the type level;
490
+ * class instances exposing methods are rejected via the property walk.
491
+ * @param config - Job configuration with name and body function.
492
+ * @param config.name - Unique job name across the project.
493
+ * @param config.body - Async function that processes the job input.
494
+ * @returns A WorkflowJob that can be triggered from other jobs.
495
+ * @example
496
+ * // Simple job with async body:
497
+ * export const fetchData = createWorkflowJob({
498
+ * name: "fetch-data",
499
+ * body: async (input: { id: string }) => {
500
+ * const db = getDB("tailordb");
501
+ * return await db.selectFrom("Table").selectAll().where("id", "=", input.id).executeTakeFirst();
502
+ * },
503
+ * });
504
+ * @example
505
+ * // Orchestrator job that fans out to other jobs.
506
+ * export const orchestrate = createWorkflowJob({
507
+ * name: "orchestrate",
508
+ * body: async (input: { orderId: string }) => {
509
+ * const inventory = await checkInventory.trigger({ orderId: input.orderId });
510
+ * const payment = await processPayment.trigger({ orderId: input.orderId });
511
+ * return { inventory, payment };
512
+ * },
513
+ * });
514
+ */
515
+ function createWorkflowJob(config) {
516
+ const body = config.body;
517
+ if (!process.env.TAILOR_PLATFORM_BUNDLE) registerJob(config.name, body);
518
+ const trigger = process.env.TAILOR_PLATFORM_BUNDLE ? async () => {
519
+ throw new Error("This workflow job's .trigger() is rewritten at build time and is unavailable in the bundle");
520
+ } : async function trigger(args, options) {
521
+ return arguments.length >= 2 ? await dispatchTriggerJob(config.name, args, options) : await dispatchTriggerJob(config.name, args);
522
+ };
523
+ return brandValue({
524
+ name: config.name,
525
+ trigger,
526
+ body
527
+ }, "workflow-job");
528
+ }
529
+
480
530
  //#endregion
481
531
  //#region src/configure/services/workflow/wait-point.ts
482
532
  function getPlatformWorkflow() {