@tailor-platform/sdk 2.0.0-next.2 → 2.0.0-next.3

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 (410) hide show
  1. package/CHANGELOG.md +466 -10
  2. package/README.md +9 -9
  3. package/agent-skills/{tailor-sdk → tailor}/SKILL.md +3 -1
  4. package/dist/aigateway-B3oZZE6v.mjs +15 -0
  5. package/dist/aigateway-B3oZZE6v.mjs.map +1 -0
  6. package/dist/application-D2hSK1ZL.mjs +3 -0
  7. package/dist/application-eHp9jXld.mjs +6393 -0
  8. package/dist/application-eHp9jXld.mjs.map +1 -0
  9. package/dist/{authconnection-D2MhtTN5.mjs → authconnection-BGQM8FZI.mjs} +2 -2
  10. package/dist/authconnection-BGQM8FZI.mjs.map +1 -0
  11. package/dist/cli/cache/bundle-cache.d.mts +1 -0
  12. package/dist/cli/cache/store.d.mts +1 -0
  13. package/dist/cli/cache/types.d.mts +1 -0
  14. package/dist/cli/commands/api/api-call.d.mts +19 -0
  15. package/dist/cli/commands/api/index.d.mts +3 -0
  16. package/dist/cli/commands/deploy/aigateway.d.mts +1 -0
  17. package/dist/cli/commands/deploy/application.d.mts +1 -0
  18. package/dist/cli/commands/deploy/apply-phases.d.mts +1 -0
  19. package/dist/cli/commands/deploy/auth.d.mts +1 -0
  20. package/dist/cli/commands/deploy/deploy.d.mts +24 -0
  21. package/dist/cli/commands/deploy/executor.d.mts +1 -0
  22. package/dist/cli/commands/deploy/function-registry-types.d.mts +12 -0
  23. package/dist/cli/commands/deploy/function-registry.d.mts +2 -0
  24. package/dist/cli/commands/deploy/idp.d.mts +1 -0
  25. package/dist/cli/commands/deploy/resolver.d.mts +1 -0
  26. package/dist/cli/commands/deploy/secret-manager.d.mts +1 -0
  27. package/dist/cli/commands/deploy/staticwebsite.d.mts +1 -0
  28. package/dist/cli/commands/deploy/tailordb/index.d.mts +1 -0
  29. package/dist/cli/commands/deploy/types.d.mts +1 -0
  30. package/dist/cli/commands/deploy/workflow.d.mts +1 -0
  31. package/dist/cli/commands/executor/get.d.mts +29 -0
  32. package/dist/cli/commands/executor/jobs.d.mts +123 -0
  33. package/dist/cli/commands/executor/list.d.mts +19 -0
  34. package/dist/cli/commands/executor/transform.d.mts +41 -0
  35. package/dist/cli/commands/executor/trigger.d.mts +41 -0
  36. package/dist/cli/commands/executor/webhook.d.mts +22 -0
  37. package/dist/cli/commands/function/get.d.mts +18 -0
  38. package/dist/cli/commands/function/list.d.mts +22 -0
  39. package/dist/cli/commands/function/transform.d.mts +11 -0
  40. package/dist/cli/commands/generate/options.d.mts +7 -0
  41. package/dist/cli/commands/generate/seed/bundler.d.mts +26 -0
  42. package/dist/cli/commands/generate/service.d.mts +11 -0
  43. package/dist/cli/commands/machineuser/list.d.mts +27 -0
  44. package/dist/cli/commands/machineuser/token.d.mts +22 -0
  45. package/dist/cli/commands/oauth2client/get.d.mts +18 -0
  46. package/dist/cli/commands/oauth2client/list.d.mts +20 -0
  47. package/dist/cli/commands/oauth2client/transform.d.mts +20 -0
  48. package/dist/cli/commands/organization/folder/create.d.mts +18 -0
  49. package/dist/cli/commands/organization/folder/delete.d.mts +16 -0
  50. package/dist/cli/commands/organization/folder/get.d.mts +17 -0
  51. package/dist/cli/commands/organization/folder/list.d.mts +22 -0
  52. package/dist/cli/commands/organization/folder/update.d.mts +18 -0
  53. package/dist/cli/commands/organization/get.d.mts +16 -0
  54. package/dist/cli/commands/organization/list.d.mts +15 -0
  55. package/dist/cli/commands/organization/transform.d.mts +27 -0
  56. package/dist/cli/commands/organization/tree.d.mts +25 -0
  57. package/dist/cli/commands/organization/update.d.mts +17 -0
  58. package/dist/cli/commands/remove.d.mts +16 -0
  59. package/dist/cli/commands/show.d.mts +34 -0
  60. package/dist/cli/commands/tailordb/migrate/bundler.d.mts +28 -0
  61. package/dist/cli/commands/tailordb/migrate/config.d.mts +19 -0
  62. package/dist/cli/commands/tailordb/migrate/diff-calculator.d.mts +223 -0
  63. package/dist/cli/commands/tailordb/migrate/generate.d.mts +17 -0
  64. package/dist/cli/commands/tailordb/migrate/snapshot-types.d.mts +202 -0
  65. package/dist/cli/commands/tailordb/migrate/snapshot.d.mts +98 -0
  66. package/dist/cli/commands/tailordb/migrate/types.d.mts +7 -0
  67. package/dist/cli/commands/tailordb/truncate.d.mts +19 -0
  68. package/dist/cli/commands/workflow/executions.d.mts +75 -0
  69. package/dist/cli/commands/workflow/get.d.mts +29 -0
  70. package/dist/cli/commands/workflow/list.d.mts +19 -0
  71. package/dist/cli/commands/workflow/resume.d.mts +23 -0
  72. package/dist/cli/commands/workflow/start.d.mts +61 -0
  73. package/dist/cli/commands/workflow/status.d.mts +5 -0
  74. package/dist/cli/commands/workflow/transform.d.mts +33 -0
  75. package/dist/cli/commands/workflow/wait.d.mts +16 -0
  76. package/dist/cli/commands/workflow/waiter.d.mts +23 -0
  77. package/dist/cli/commands/workspace/app/health.d.mts +18 -0
  78. package/dist/cli/commands/workspace/app/list.d.mts +22 -0
  79. package/dist/cli/commands/workspace/app/transform.d.mts +18 -0
  80. package/dist/cli/commands/workspace/create.d.mts +25 -0
  81. package/dist/cli/commands/workspace/delete.d.mts +15 -0
  82. package/dist/cli/commands/workspace/get.d.mts +17 -0
  83. package/dist/cli/commands/workspace/list.d.mts +17 -0
  84. package/dist/cli/commands/workspace/restore.d.mts +15 -0
  85. package/dist/cli/commands/workspace/transform.d.mts +16 -0
  86. package/dist/cli/commands/workspace/user/invite.d.mts +22 -0
  87. package/dist/cli/commands/workspace/user/list.d.mts +22 -0
  88. package/dist/cli/commands/workspace/user/remove.d.mts +17 -0
  89. package/dist/cli/commands/workspace/user/transform.d.mts +8 -0
  90. package/dist/cli/commands/workspace/user/update.d.mts +22 -0
  91. package/dist/cli/erd-viewer-assets/app.js +279 -36
  92. package/dist/cli/erd-viewer-assets/index.html +4 -0
  93. package/dist/cli/erd-viewer-assets/styles.css +252 -5
  94. package/dist/cli/index.d.mts +18 -3
  95. package/dist/cli/index.mjs +2136 -519
  96. package/dist/cli/index.mjs.map +1 -1
  97. package/dist/cli/lib.d.mts +81 -21107
  98. package/dist/cli/lib.mjs +6 -9
  99. package/dist/cli/lib.mjs.map +1 -1
  100. package/dist/cli/query/index.d.mts +35 -0
  101. package/dist/cli/services/application.d.mts +1 -0
  102. package/dist/cli/services/auth/service.d.mts +1 -0
  103. package/dist/cli/services/executor/service.d.mts +1 -0
  104. package/dist/cli/services/http-adapter/bundler.d.mts +1 -0
  105. package/dist/cli/services/http-adapter/service.d.mts +1 -0
  106. package/dist/cli/services/resolver/service.d.mts +1 -0
  107. package/dist/cli/services/tailordb/service.d.mts +1 -0
  108. package/dist/cli/services/workflow/bundler.d.mts +1 -0
  109. package/dist/cli/services/workflow/service.d.mts +1 -0
  110. package/dist/cli/shared/args.d.mts +13 -0
  111. package/dist/cli/shared/client.d.mts +1273 -0
  112. package/dist/cli/shared/config-loader.d.mts +26 -0
  113. package/dist/cli/shared/context.d.mts +28 -0
  114. package/dist/cli/shared/script-executor.d.mts +75 -0
  115. package/dist/cli/shared/seed-chunker.d.mts +46 -0
  116. package/dist/cli/shared/trigger-context.d.mts +1 -0
  117. package/dist/cli/shared/type-generator.d.mts +20 -0
  118. package/dist/cli/ts-hook.d.mts +4 -0
  119. package/dist/cli/ts-hook.mjs +303 -0
  120. package/dist/completion/zsh-worker.zsh +1523 -1123
  121. package/dist/configure/config/index.d.mts +21 -0
  122. package/dist/configure/config/types.d.mts +103 -0
  123. package/dist/configure/index.d.mts +122 -9
  124. package/dist/configure/index.mjs +24 -21
  125. package/dist/configure/index.mjs.map +1 -1
  126. package/dist/configure/services/aigateway/index.d.mts +17 -0
  127. package/dist/configure/services/aigateway/types.d.mts +11 -0
  128. package/dist/configure/services/auth/index.d.mts +34 -0
  129. package/dist/configure/services/auth/types.d.mts +172 -0
  130. package/dist/configure/services/executor/executor.d.mts +81 -0
  131. package/dist/configure/services/executor/index.d.mts +8 -0
  132. package/dist/configure/services/executor/operation.d.mts +45 -0
  133. package/dist/configure/services/executor/trigger/event.d.mts +272 -0
  134. package/dist/configure/services/executor/trigger/index.d.mts +8 -0
  135. package/dist/configure/services/executor/trigger/schedule.d.mts +25 -0
  136. package/dist/configure/services/executor/trigger/webhook.d.mts +44 -0
  137. package/dist/configure/services/executor/types.d.mts +2 -0
  138. package/dist/configure/services/http-adapter/http-adapter.d.mts +125 -0
  139. package/dist/configure/services/http-adapter/index.d.mts +2 -0
  140. package/dist/configure/services/idp/index.d.mts +64 -0
  141. package/dist/configure/services/idp/permission.d.mts +80 -0
  142. package/dist/configure/services/idp/types.d.mts +20 -0
  143. package/dist/configure/services/index.d.mts +32 -0
  144. package/dist/configure/services/resolver/index.d.mts +5 -0
  145. package/dist/configure/services/resolver/resolver.d.mts +75 -0
  146. package/dist/configure/services/resolver/types.d.mts +6 -0
  147. package/dist/configure/services/secrets/index.d.mts +38 -0
  148. package/dist/configure/services/secrets/types.d.mts +11 -0
  149. package/dist/configure/services/staticwebsite/index.d.mts +19 -0
  150. package/dist/configure/services/staticwebsite/types.d.mts +11 -0
  151. package/dist/configure/services/tailordb/index.d.mts +4 -0
  152. package/dist/configure/services/tailordb/permission.d.mts +119 -0
  153. package/dist/configure/services/tailordb/schema.d.mts +456 -0
  154. package/dist/configure/services/tailordb/types.d.mts +149 -0
  155. package/dist/configure/services/workflow/index.d.mts +6 -0
  156. package/dist/configure/services/workflow/job.d.mts +79 -0
  157. package/dist/configure/services/workflow/types.d.mts +2 -0
  158. package/dist/configure/services/workflow/wait-point.d.mts +73 -0
  159. package/dist/configure/services/workflow/workflow.d.mts +54 -0
  160. package/dist/configure/types/aigateway-name.d.mts +12 -0
  161. package/dist/configure/types/connection-name.d.mts +12 -0
  162. package/dist/configure/types/field-runtime.d.mts +17 -0
  163. package/dist/configure/types/field.d.mts +9 -0
  164. package/dist/configure/types/field.types.d.mts +109 -0
  165. package/dist/configure/types/idp-name.d.mts +12 -0
  166. package/dist/configure/types/index.d.mts +4 -0
  167. package/dist/configure/types/machine-user.d.mts +2 -0
  168. package/dist/configure/types/type.d.mts +82 -0
  169. package/dist/context-Bd266-ru.mjs.map +1 -1
  170. package/dist/{crashreport-DFq-vsU0.mjs → crashreport-Cg-pqRJV.mjs} +6 -6
  171. package/dist/{crashreport-DFq-vsU0.mjs.map → crashreport-Cg-pqRJV.mjs.map} +1 -1
  172. package/dist/{crashreport-BMWcxeSE.mjs → crashreport-D3RjuSYb.mjs} +1 -1
  173. package/dist/enum-constants-j9QBF0cB.mjs.map +1 -1
  174. package/dist/{errors-Dtf2WPaW.mjs → errors-118wUDRr.mjs} +2 -2
  175. package/dist/errors-118wUDRr.mjs.map +1 -0
  176. package/dist/field-runtime-CAnh_oow.mjs +183 -0
  177. package/dist/field-runtime-CAnh_oow.mjs.map +1 -0
  178. package/dist/file-utils-CYZnO1pX.mjs.map +1 -1
  179. package/dist/{globals-Cf0sxIt8.mjs → globals-DhwZj0RB.mjs} +4 -46
  180. package/dist/globals-DhwZj0RB.mjs.map +1 -0
  181. package/dist/{idp-BDbK5gjm.mjs → idp-Bx25ZBdN.mjs} +9 -1
  182. package/dist/idp-Bx25ZBdN.mjs.map +1 -0
  183. package/dist/{interceptor-D-q1rvRl.mjs → interceptor-e33JtsC-.mjs} +2 -2
  184. package/dist/interceptor-e33JtsC-.mjs.map +1 -0
  185. package/dist/kysely/index.d.mts +2 -3
  186. package/dist/{kysely-type-DR8uzZTA.mjs → kysely-type-5eAChaHO.mjs} +4 -2
  187. package/dist/kysely-type-5eAChaHO.mjs.map +1 -0
  188. package/dist/{logger-CxF-Ex5d.mjs → logger-BEiZZ3qT.mjs} +3 -3
  189. package/dist/{logger-CxF-Ex5d.mjs.map → logger-BEiZZ3qT.mjs.map} +1 -1
  190. package/dist/parser/service/auth/index.d.mts +1 -0
  191. package/dist/parser/service/auth/schema.d.mts +1 -0
  192. package/dist/parser/service/http-adapter/index.d.mts +1 -0
  193. package/dist/parser/service/http-adapter/schema.d.mts +1 -0
  194. package/dist/parser/service/idp/types.d.mts +4 -0
  195. package/dist/parser/service/tailordb/types.d.mts +126 -0
  196. package/dist/platform-serialize-RoRtBS0v.mjs +46 -0
  197. package/dist/platform-serialize-RoRtBS0v.mjs.map +1 -0
  198. package/dist/plugin/builtin/enum-constants/index.d.mts +16 -1
  199. package/dist/plugin/builtin/file-utils/index.d.mts +16 -1
  200. package/dist/plugin/builtin/kysely-type/index.d.mts +16 -1
  201. package/dist/plugin/builtin/kysely-type/index.mjs +1 -1
  202. package/dist/plugin/builtin/seed/index.d.mts +45 -1
  203. package/dist/plugin/builtin/seed/index.mjs +1 -1
  204. package/dist/plugin/get-generated-type.d.mts +17 -0
  205. package/dist/plugin/index.d.mts +3 -118
  206. package/dist/plugin/index.mjs +1 -1
  207. package/dist/plugin/index.mjs.map +1 -1
  208. package/dist/plugin/manager.d.mts +1 -0
  209. package/dist/plugin/types.d.mts +243 -0
  210. package/dist/plugin/with-context.d.mts +102 -0
  211. package/dist/{runtime-CY4JvrDj.mjs → register-ts-hook-ZpBacA07.mjs} +3426 -2041
  212. package/dist/register-ts-hook-ZpBacA07.mjs.map +1 -0
  213. package/dist/registry-DH4m7eYo.mjs.map +1 -1
  214. package/dist/{repl-editor-DmGr9zMw.mjs → repl-editor-BCozyiNq.mjs} +6 -5
  215. package/dist/{repl-editor-DmGr9zMw.mjs.map → repl-editor-BCozyiNq.mjs.map} +1 -1
  216. package/dist/runtime/aigateway.d.mts +35 -0
  217. package/dist/runtime/aigateway.mjs +3 -0
  218. package/dist/runtime/authconnection.d.mts +31 -2
  219. package/dist/runtime/authconnection.mjs +1 -1
  220. package/dist/runtime/context.d.mts +46 -2
  221. package/dist/runtime/file.d.mts +210 -2
  222. package/dist/runtime/globals.d.mts +31 -19
  223. package/dist/runtime/iconv.d.mts +121 -2
  224. package/dist/runtime/idp.d.mts +186 -2
  225. package/dist/runtime/idp.mjs +1 -1
  226. package/dist/runtime/index.d.mts +47 -9
  227. package/dist/runtime/index.mjs +5 -4
  228. package/dist/runtime/secretmanager.d.mts +54 -2
  229. package/dist/{types-BZ7QKVE8.d.mts → runtime/types.d.mts} +4 -5
  230. package/dist/runtime/workflow.d.mts +112 -2
  231. package/dist/runtime/workflow.mjs +2 -2
  232. package/dist/{schema-Dtw9Orye.mjs → schema-89dYxNC2.mjs} +17 -182
  233. package/dist/schema-89dYxNC2.mjs.map +1 -0
  234. package/dist/{secret-file-VSVGy1V0.mjs → secret-file-aoNXJmKa.mjs} +3 -3
  235. package/dist/secret-file-aoNXJmKa.mjs.map +1 -0
  236. package/dist/secretmanager-Bd45j7an.mjs +98 -0
  237. package/dist/secretmanager-Bd45j7an.mjs.map +1 -0
  238. package/dist/seed/index.d.mts +1 -2
  239. package/dist/{seed-izIEyP3z.mjs → seed-CRSQJI_z.mjs} +14 -3
  240. package/dist/seed-CRSQJI_z.mjs.map +1 -0
  241. package/dist/service-CkIwEctX.mjs +3 -0
  242. package/dist/{service-DU1mVzri2.mjs → service-DeZeYa06.mjs} +3 -3
  243. package/dist/service-DeZeYa06.mjs.map +1 -0
  244. package/dist/{service-DjyqbCaJ.mjs → service-ufH7sS8o.mjs} +396 -58
  245. package/dist/service-ufH7sS8o.mjs.map +1 -0
  246. package/dist/service_pb-CIrhGwHk.mjs +988 -0
  247. package/dist/service_pb-CIrhGwHk.mjs.map +1 -0
  248. package/dist/service_pb-DjwIn4jO.mjs +3 -0
  249. package/dist/tailor-proto/src/tailor/v1/aigateway_pb.d.mts +204 -0
  250. package/dist/tailor-proto/src/tailor/v1/aigateway_resource_pb.d.mts +58 -0
  251. package/dist/tailor-proto/src/tailor/v1/application_pb.d.mts +316 -0
  252. package/dist/tailor-proto/src/tailor/v1/application_resource_pb.d.mts +161 -0
  253. package/dist/tailor-proto/src/tailor/v1/auth_pb.d.mts +2070 -0
  254. package/dist/tailor-proto/src/tailor/v1/auth_resource_pb.d.mts +861 -0
  255. package/dist/tailor-proto/src/tailor/v1/events_pb.d.mts +112 -0
  256. package/dist/tailor-proto/src/tailor/v1/events_resource_pb.d.mts +69 -0
  257. package/dist/tailor-proto/src/tailor/v1/executor_pb.d.mts +439 -0
  258. package/dist/tailor-proto/src/tailor/v1/executor_resource_pb.d.mts +564 -0
  259. package/dist/tailor-proto/src/tailor/v1/function_pb.d.mts +145 -0
  260. package/dist/tailor-proto/src/tailor/v1/function_registry_pb.d.mts +451 -0
  261. package/dist/tailor-proto/src/tailor/v1/function_resource_pb.d.mts +192 -0
  262. package/dist/tailor-proto/src/tailor/v1/http_adapter_resource_pb.d.mts +50 -0
  263. package/dist/tailor-proto/src/tailor/v1/idp_pb.d.mts +407 -0
  264. package/dist/tailor-proto/src/tailor/v1/idp_resource_pb.d.mts +430 -0
  265. package/dist/tailor-proto/src/tailor/v1/metadata_pb.d.mts +73 -0
  266. package/dist/tailor-proto/src/tailor/v1/metadata_resource_pb.d.mts +17 -0
  267. package/dist/tailor-proto/src/tailor/v1/meter_pb.d.mts +309 -0
  268. package/dist/tailor-proto/src/tailor/v1/pipeline_pb.d.mts +591 -0
  269. package/dist/tailor-proto/src/tailor/v1/pipeline_resource_pb.d.mts +330 -0
  270. package/dist/tailor-proto/src/tailor/v1/resource_pb.d.mts +113 -0
  271. package/dist/tailor-proto/src/tailor/v1/secret_manager_pb.d.mts +346 -0
  272. package/dist/tailor-proto/src/tailor/v1/secret_manager_resource_pb.d.mts +54 -0
  273. package/dist/tailor-proto/src/tailor/v1/service_pb.d.mts +3576 -0
  274. package/dist/tailor-proto/src/tailor/v1/stateflow_pb.d.mts +187 -0
  275. package/dist/tailor-proto/src/tailor/v1/stateflow_resource_pb.d.mts +29 -0
  276. package/dist/tailor-proto/src/tailor/v1/staticwebsite_pb.d.mts +429 -0
  277. package/dist/tailor-proto/src/tailor/v1/staticwebsite_resource_pb.d.mts +90 -0
  278. package/dist/tailor-proto/src/tailor/v1/tailordb_pb.d.mts +684 -0
  279. package/dist/tailor-proto/src/tailor/v1/tailordb_resource_pb.d.mts +797 -0
  280. package/dist/tailor-proto/src/tailor/v1/telemetryrouter_pb.d.mts +330 -0
  281. package/dist/tailor-proto/src/tailor/v1/telemetryrouter_resource_pb.d.mts +183 -0
  282. package/dist/tailor-proto/src/tailor/v1/workflow_pb.d.mts +842 -0
  283. package/dist/tailor-proto/src/tailor/v1/workflow_resource_pb.d.mts +276 -0
  284. package/dist/tailor-proto/src/tailor/v1/workspace_pb.d.mts +2015 -0
  285. package/dist/tailor-proto/src/tailor/v1/workspace_resource_pb.d.mts +483 -0
  286. package/dist/{telemetry-CdqJEzkj.mjs → telemetry-BRVdwh14.mjs} +3 -3
  287. package/dist/telemetry-BRVdwh14.mjs.map +1 -0
  288. package/dist/telemetry-CkbkeJxl.mjs +3 -0
  289. package/dist/types/aigateway.generated.d.mts +9 -0
  290. package/dist/types/app-config.generated.d.mts +4 -0
  291. package/dist/types/auth-connection.generated.d.mts +20 -0
  292. package/dist/types/auth.generated.d.mts +145 -0
  293. package/dist/types/executor.generated.d.mts +177 -0
  294. package/dist/types/helpers.d.mts +39 -0
  295. package/dist/types/http-adapter.generated.d.mts +17 -0
  296. package/dist/{workflow.generated-ClEjBYhm.d.mts → types/idp.generated.d.mts} +98 -185
  297. package/dist/types/resolver.generated.d.mts +39 -0
  298. package/dist/types/secrets.generated.d.mts +14 -0
  299. package/dist/types/staticwebsite.generated.d.mts +10 -0
  300. package/dist/{types-CdcQh4Z2.d.mts → types/tailordb.generated.d.mts} +2 -287
  301. package/dist/types/workflow.generated.d.mts +12 -0
  302. package/dist/types-C-lQ4se3.mjs +4 -0
  303. package/dist/types-CXF2OYdR.mjs +199 -0
  304. package/dist/types-CXF2OYdR.mjs.map +1 -0
  305. package/dist/utils/test/index.d.mts +5 -89
  306. package/dist/utils/test/index.mjs.map +1 -1
  307. package/dist/utils/test/mock.d.mts +87 -0
  308. package/dist/vitest/environment.d.mts +1 -2
  309. package/dist/vitest/environment.mjs +2 -2
  310. package/dist/vitest/environment.mjs.map +1 -1
  311. package/dist/vitest/index.d.mts +12 -428
  312. package/dist/vitest/index.mjs +739 -8
  313. package/dist/vitest/index.mjs.map +1 -1
  314. package/dist/vitest/mock-kysely.d.mts +62 -0
  315. package/dist/vitest/mock.d.mts +9 -0
  316. package/dist/vitest/mocks/aigateway.d.mts +30 -0
  317. package/dist/vitest/mocks/authconnection.d.mts +28 -0
  318. package/dist/vitest/mocks/file.d.mts +41 -0
  319. package/dist/vitest/mocks/iconv.d.mts +27 -0
  320. package/dist/vitest/mocks/idp.d.mts +44 -0
  321. package/dist/vitest/mocks/secretmanager.d.mts +33 -0
  322. package/dist/vitest/mocks/tailordb.d.mts +71 -0
  323. package/dist/vitest/mocks/workflow.d.mts +115 -0
  324. package/dist/vitest/setup.d.mts +1 -2
  325. package/dist/vitest/setup.mjs +2 -2
  326. package/dist/vitest/workflow-local.d.mts +40 -0
  327. package/dist/{workflow-BOmaZwwG.mjs → workflow-Bo59B75H.mjs} +9 -2
  328. package/dist/workflow-Bo59B75H.mjs.map +1 -0
  329. package/docs/cli/application.md +98 -250
  330. package/docs/cli/auth.md +48 -292
  331. package/docs/cli/completion.md +1 -25
  332. package/docs/cli/crashreport.md +3 -61
  333. package/docs/cli/executor.md +23 -187
  334. package/docs/cli/function.md +14 -130
  335. package/docs/cli/organization.md +11 -221
  336. package/docs/cli/plugin.md +29 -0
  337. package/docs/cli/query.md +2 -22
  338. package/docs/cli/secret.md +71 -251
  339. package/docs/cli/setup.md +137 -41
  340. package/docs/cli/skills.md +50 -39
  341. package/docs/cli/staticwebsite.md +32 -180
  342. package/docs/cli/tailordb.md +97 -323
  343. package/docs/cli/upgrade.md +2 -22
  344. package/docs/cli/user.md +78 -247
  345. package/docs/cli/workflow.md +44 -203
  346. package/docs/cli/workspace.md +165 -538
  347. package/docs/cli-reference.md +167 -67
  348. package/docs/configuration.md +10 -4
  349. package/docs/github-actions.md +46 -19
  350. package/docs/migration/v2.md +286 -26
  351. package/docs/multi-environment.md +29 -7
  352. package/docs/plugin/index.md +6 -6
  353. package/docs/quickstart.md +8 -7
  354. package/docs/runtime.md +5 -1
  355. package/docs/services/aigateway.md +18 -2
  356. package/docs/services/auth.md +32 -40
  357. package/docs/services/http-adapter.md +16 -1
  358. package/docs/services/idp.md +55 -2
  359. package/docs/services/resolver.md +1 -1
  360. package/docs/services/secret.md +11 -11
  361. package/docs/services/staticwebsite.md +8 -2
  362. package/docs/services/tailordb-migration.md +24 -22
  363. package/docs/services/tailordb.md +25 -2
  364. package/docs/services/workflow.md +14 -14
  365. package/docs/testing.md +49 -3
  366. package/package.json +42 -31
  367. package/postinstall.mjs +4 -6
  368. package/dist/application-Dtqap5jM.mjs +0 -3
  369. package/dist/application-XuMWK4eq.mjs +0 -7257
  370. package/dist/application-XuMWK4eq.mjs.map +0 -1
  371. package/dist/authconnection-D2MhtTN5.mjs.map +0 -1
  372. package/dist/authconnection-DvUQAjQS.d.mts +0 -39
  373. package/dist/context-C2lEi9uw.d.mts +0 -47
  374. package/dist/errors-Dtf2WPaW.mjs.map +0 -1
  375. package/dist/field-DOsJCPFa.mjs +0 -22
  376. package/dist/field-DOsJCPFa.mjs.map +0 -1
  377. package/dist/file-Dq3NIt_F.d.mts +0 -211
  378. package/dist/globals-Cf0sxIt8.mjs.map +0 -1
  379. package/dist/http-adapter.generated-DFsXDdm5.d.mts +0 -581
  380. package/dist/iconv-Co-TOPuH.d.mts +0 -122
  381. package/dist/idp-BDbK5gjm.mjs.map +0 -1
  382. package/dist/idp-DrhVrLmV.d.mts +0 -160
  383. package/dist/index-BI-_j9Z3.d.mts +0 -1013
  384. package/dist/index-C4JirJH8.d.mts +0 -18
  385. package/dist/index-CZfWhr0a.d.mts +0 -18
  386. package/dist/index-Cg8VKAdN.d.mts +0 -46
  387. package/dist/index-DYRjoLXD.d.mts +0 -47
  388. package/dist/index-lFpcjHPU.d.mts +0 -201
  389. package/dist/index-nW7hE6oE.d.mts +0 -18
  390. package/dist/interceptor-D-q1rvRl.mjs.map +0 -1
  391. package/dist/kysely-type-DR8uzZTA.mjs.map +0 -1
  392. package/dist/mock-FPxmnt-y.mjs +0 -759
  393. package/dist/mock-FPxmnt-y.mjs.map +0 -1
  394. package/dist/runtime-CY4JvrDj.mjs.map +0 -1
  395. package/dist/schema-Dtw9Orye.mjs.map +0 -1
  396. package/dist/secret-file-VSVGy1V0.mjs.map +0 -1
  397. package/dist/secretmanager-B3n4KHfm.d.mts +0 -55
  398. package/dist/seed-izIEyP3z.mjs.map +0 -1
  399. package/dist/service-DCqIWibD.mjs +0 -3
  400. package/dist/service-DU1mVzri2.mjs.map +0 -1
  401. package/dist/service-DjyqbCaJ.mjs.map +0 -1
  402. package/dist/telemetry-CdqJEzkj.mjs.map +0 -1
  403. package/dist/telemetry-ClwW5ohF.mjs +0 -3
  404. package/dist/types-74etvaxy.mjs +0 -4
  405. package/dist/types-BDRml5C3.d.mts +0 -574
  406. package/dist/types-BQijbo4m.mjs +0 -371
  407. package/dist/types-BQijbo4m.mjs.map +0 -1
  408. package/dist/types-BX4q6Mo6.d.mts +0 -339
  409. package/dist/workflow-BOmaZwwG.mjs.map +0 -1
  410. package/dist/workflow-BVy4XWjS.d.mts +0 -101
@@ -1,1013 +0,0 @@
1
- import { a as TailorEnv, i as InferredAttributeMap, o as TailorPrincipal } from "./types-BZ7QKVE8.mjs";
2
- import { C as FieldMetadata, D as TailorField$1, E as FieldValidateInput, F as output$1, N as JsonValue, O as TailorFieldType, P as Prettify, T as FieldOutput, b as ArrayFieldOutput, j as InferFieldsOutput, w as FieldOptions, x as DefinedFieldMetadata } from "./types-CdcQh4Z2.mjs";
3
- import { _ as UserAttributeListKey, a as AuthServiceInput, c as DefinedAuth, f as MachineUserName, v as UserAttributeMap } from "./types-BX4q6Mo6.mjs";
4
- import { A as ResolverExecutedTrigger$1, C as AuthAccessTokenTrigger$1, D as GqlOperation$1, E as FunctionOperation$1, M as TailorDBTrigger$1, N as WebhookOperation$1, O as IdpUserTrigger$1, P as WorkflowOperation$1, S as ResolverInput, T as ExecutorInput, i as Plugin, j as ScheduleTriggerInput, k as IncomingWebhookTrigger$1, x as Resolver } from "./types-BDRml5C3.mjs";
5
- import { a as TailorDBInstance, m as AllowedValuesOutput, o as TailorDBType, p as AllowedValues, t as HttpAdapterConfigInput } from "./http-adapter.generated-DFsXDdm5.mjs";
6
- import { S as IdPInput, T as AIGatewayInput, f as StaticWebsiteDefinitionBrand, h as SecretsDefinitionBrand, p as StaticWebsiteInput, r as AppConfig, v as IdpDefinitionBrand, w as AIGatewayDefinitionBrand } from "./workflow.generated-ClEjBYhm.mjs";
7
- import { i as Workflow } from "./index-lFpcjHPU.mjs";
8
- import { StandardSchemaV1 } from "@standard-schema/spec";
9
- import { Client } from "@urql/core";
10
- import { StandardCRON } from "ts-cron-validator";
11
-
12
- //#region src/configure/types/type.d.ts
13
- type TailorAnyField = TailorField<any>;
14
- /**
15
- * Full TailorField interface with builder methods.
16
- * Extends the minimal structural interface from types/ with fluent API methods.
17
- */
18
- interface TailorField<Defined extends DefinedFieldMetadata = DefinedFieldMetadata, Output = any, M extends FieldMetadata = FieldMetadata, T extends TailorFieldType = TailorFieldType> extends TailorField$1<Defined, Output, M, T> {
19
- readonly fields: Record<string, TailorAnyField>;
20
- _metadata: M;
21
- /**
22
- * Set a description for the field
23
- * @param description - The description text
24
- * @returns The field with updated metadata
25
- */
26
- description<CurrentDefined extends Defined>(this: CurrentDefined extends {
27
- description: unknown;
28
- } ? never : TailorField<CurrentDefined, Output>, description: string): TailorField<Prettify<CurrentDefined & {
29
- description: true;
30
- }>, Output>;
31
- /**
32
- * Set a custom type name for enum or nested types
33
- * @param typeName - The custom type name
34
- * @returns The field with updated metadata
35
- */
36
- typeName<CurrentDefined extends Defined>(this: CurrentDefined extends {
37
- typeName: unknown;
38
- } ? never : CurrentDefined extends {
39
- type: "enum" | "nested";
40
- } ? TailorField<CurrentDefined, Output> : never, typeName: string): TailorField<Prettify<CurrentDefined & {
41
- typeName: true;
42
- }>, Output>;
43
- /**
44
- * Add validation functions to the field
45
- * @param validate - One or more validation functions
46
- * @returns The field with updated metadata
47
- */
48
- validate<CurrentDefined extends Defined>(this: CurrentDefined extends {
49
- validate: unknown;
50
- } ? never : TailorField<CurrentDefined, Output>, ...validate: FieldValidateInput<Output>[]): TailorField<Prettify<CurrentDefined & {
51
- validate: true;
52
- }>, Output>;
53
- /**
54
- * Parse and validate a value against this field's validation rules
55
- * Returns StandardSchema Result type with success or failure
56
- * @param args - Value, context data, and invoker
57
- * @returns Validation result
58
- */
59
- parse(args: FieldParseArgs): StandardSchemaV1.Result<Output>;
60
- /**
61
- * Internal parse method that tracks field path for nested validation
62
- * @private
63
- * @param args - Parse arguments
64
- * @returns Validation result
65
- */
66
- _parseInternal(args: FieldParseInternalArgs): StandardSchemaV1.Result<Output>;
67
- }
68
- type FieldParseArgs = {
69
- value: unknown;
70
- data: unknown;
71
- invoker: TailorPrincipal | null;
72
- };
73
- type FieldParseInternalArgs = {
74
- value: any;
75
- data: unknown;
76
- invoker: TailorPrincipal | null;
77
- pathArray: string[];
78
- };
79
- /**
80
- * Create a UUID field for resolver input/output.
81
- * @param options - Field configuration options
82
- * @returns A UUID field
83
- * @example t.uuid()
84
- */
85
- //#endregion
86
- //#region src/configure/types/idp-name.d.ts
87
- interface IdpNameRegistry {}
88
- /**
89
- * IdP namespace name.
90
- *
91
- * When `tailor.d.ts` is generated (via `tailor-sdk deploy`/`generate`), this is narrowed
92
- * to the union of defined IdP names. When no IdPs are registered yet, falls back to
93
- * `string` to avoid blocking editing before the first generate run.
94
- */
95
- type IdpName = keyof IdpNameRegistry extends never ? string : keyof IdpNameRegistry & string;
96
- //#endregion
97
- //#region src/configure/services/auth/index.d.ts
98
- type MachineUserAttributeFields = Record<string, TailorField$1<DefinedFieldMetadata, unknown, FieldMetadata, TailorFieldType>>;
99
- type PlaceholderUser = TailorDBInstance<Record<string, never>, Record<string, never>>;
100
- type PlaceholderAttributeMap = UserAttributeMap<PlaceholderUser>;
101
- type PlaceholderAttributeList = UserAttributeListKey<PlaceholderUser>[];
102
- type UserProfileAuthInput<User extends TailorDBInstance, AttributeMap extends UserAttributeMap<User>, AttributeList extends UserAttributeListKey<User>[], MachineUserNames extends string, ConnectionNames extends string = string> = Omit<AuthServiceInput<User, AttributeMap, AttributeList, MachineUserNames, undefined, ConnectionNames>, "userProfile" | "machineUserAttributes"> & {
103
- userProfile: NonNullable<AuthServiceInput<User, AttributeMap, AttributeList, MachineUserNames, undefined>["userProfile"]>;
104
- machineUserAttributes?: never;
105
- };
106
- type MachineUserOnlyAuthInput<MachineUserNames extends string, MachineUserAttributes extends MachineUserAttributeFields, ConnectionNames extends string = string> = Omit<AuthServiceInput<PlaceholderUser, PlaceholderAttributeMap, PlaceholderAttributeList, MachineUserNames, MachineUserAttributes, ConnectionNames>, "userProfile" | "machineUserAttributes"> & {
107
- userProfile?: never;
108
- machineUserAttributes: MachineUserAttributes;
109
- };
110
- /**
111
- * Define an auth service for the Tailor SDK.
112
- * @template Name
113
- * @template User
114
- * @template AttributeMap
115
- * @template AttributeList
116
- * @template MachineUserNames
117
- * @param name - Auth service name
118
- * @param config - Auth service configuration
119
- * @returns Defined auth service
120
- */
121
- declare function defineAuth<const Name extends string, const User extends TailorDBInstance, const AttributeMap extends UserAttributeMap<User>, const AttributeList extends UserAttributeListKey<User>[], const MachineUserNames extends string, const ConnectionNames extends string = string>(name: Name, config: UserProfileAuthInput<User, AttributeMap, AttributeList, MachineUserNames, ConnectionNames>): DefinedAuth<Name, UserProfileAuthInput<User, AttributeMap, AttributeList, MachineUserNames, ConnectionNames>>;
122
- declare function defineAuth<const Name extends string, const MachineUserAttributes extends MachineUserAttributeFields, const MachineUserNames extends string, const ConnectionNames extends string = string>(name: Name, config: MachineUserOnlyAuthInput<MachineUserNames, MachineUserAttributes, ConnectionNames>): DefinedAuth<Name, MachineUserOnlyAuthInput<MachineUserNames, MachineUserAttributes, ConnectionNames>>;
123
- //#endregion
124
- //#region src/configure/services/resolver/resolver.d.ts
125
- type Context<Input extends Record<string, TailorAnyField> | undefined> = {
126
- input: Input extends Record<string, TailorAnyField> ? InferFieldsOutput<Input> : never;
127
- caller: TailorPrincipal | null;
128
- invoker: TailorPrincipal | null;
129
- env: TailorEnv;
130
- };
131
- type OutputType<O> = O extends TailorAnyField ? output$1<O> : O extends Record<string, TailorAnyField> ? InferFieldsOutput<O> : never;
132
- /**
133
- * Normalized output type that preserves generic type information.
134
- * - If Output is already a TailorField, use it as-is
135
- * - If Output is a Record of fields, wrap it as a nested TailorField
136
- */
137
- type NormalizedOutput<Output extends TailorAnyField | Record<string, TailorAnyField>> = Output extends TailorAnyField ? Output : TailorField<{
138
- type: "nested";
139
- array: false;
140
- }, InferFieldsOutput<Extract<Output, Record<string, TailorAnyField>>>>;
141
- type ResolverReturn<Input extends Record<string, TailorAnyField> | undefined, Output extends TailorAnyField | Record<string, TailorAnyField>> = Omit<ResolverInput, "input" | "output" | "body" | "invoker"> & Readonly<{
142
- input?: Input;
143
- output: NormalizedOutput<Output>;
144
- body: (context: Context<Input>) => OutputType<Output> | Promise<OutputType<Output>>;
145
- invoker?: MachineUserName;
146
- }>;
147
- /**
148
- * Create a resolver definition for the Tailor SDK.
149
- *
150
- * The `body` function receives a context with `input` (typed from `config.input`),
151
- * `caller`, `invoker` (reflects configured machine-user delegation), and `env`.
152
- * The return value of `body` must match the `output` type.
153
- *
154
- * `output` accepts either a single TailorField (e.g. `t.string()`) or a
155
- * Record of fields (e.g. `{ name: t.string(), age: t.int() }`).
156
- *
157
- * `publishEvents` enables publishing execution events for this resolver.
158
- * If not specified, this is automatically set to true when an executor uses this resolver
159
- * with `resolverExecutedTrigger`. If explicitly set to false while an executor uses this
160
- * resolver, an error will be thrown during apply.
161
- * @template Input
162
- * @template Output
163
- * @param config - Resolver configuration
164
- * @returns Normalized resolver configuration
165
- * @example
166
- * import { createResolver, t } from "@tailor-platform/sdk";
167
- *
168
- * export default createResolver({
169
- * name: "getUser",
170
- * operation: "query",
171
- * input: {
172
- * id: t.string(),
173
- * },
174
- * body: async ({ input, caller }) => {
175
- * const db = getDB("tailordb");
176
- * const result = await db.selectFrom("User").selectAll().where("id", "=", input.id).executeTakeFirst();
177
- * return { name: result?.name ?? "", email: result?.email ?? "" };
178
- * },
179
- * output: t.object({
180
- * name: t.string(),
181
- * email: t.string(),
182
- * }),
183
- * });
184
- */
185
- declare function createResolver<Input extends Record<string, TailorAnyField> | undefined = undefined, Output extends TailorAnyField | Record<string, TailorAnyField> = TailorAnyField>(config: Omit<ResolverInput, "input" | "output" | "body" | "invoker"> & Readonly<{
186
- input?: Input;
187
- output: Output;
188
- body: (context: Context<Input>) => OutputType<Output> | Promise<OutputType<Output>>;
189
- invoker?: MachineUserName;
190
- }>): ResolverReturn<Input, Output>;
191
- type ResolverConfig = ReturnType<typeof createResolver<any, any>>;
192
- //#endregion
193
- //#region src/configure/services/resolver/types.d.ts
194
- type QueryType = Resolver["operation"];
195
- //#endregion
196
- //#region src/configure/services/executor/operation.d.ts
197
- /** Function-based executor operation. The body receives the trigger args and the `invoker`. */
198
- type FunctionOperation<Args> = Omit<FunctionOperation$1, "body" | "invoker"> & {
199
- body: (args: Args & {
200
- invoker: TailorPrincipal | null;
201
- }) => void | Promise<void>;
202
- invoker?: MachineUserName;
203
- };
204
- type UrqlOperationArgs = Parameters<Client["query"] | Client["mutation"]>;
205
- /** GraphQL-based executor operation. Executes a GraphQL query or mutation. */
206
- type GqlOperation<Args> = Omit<GqlOperation$1, "query" | "variables" | "invoker"> & {
207
- query: UrqlOperationArgs[0];
208
- variables?: (args: Args) => UrqlOperationArgs[1];
209
- invoker?: MachineUserName;
210
- };
211
- type RequestHeader = "A-IM" | "Accept" | "Accept-Additions" | "Accept-CH" | "Accept-Charset" | "Accept-Datetime" | "Accept-Encoding" | "Accept-Features" | "Accept-Language" | "Accept-Patch" | "Accept-Post" | "Accept-Ranges" | "Accept-Signature" | "Access-Control" | "Access-Control-Allow-Credentials" | "Access-Control-Allow-Headers" | "Access-Control-Allow-Methods" | "Access-Control-Allow-Origin" | "Access-Control-Expose-Headers" | "Access-Control-Max-Age" | "Access-Control-Request-Headers" | "Access-Control-Request-Method" | "Age" | "Allow" | "ALPN" | "Alt-Svc" | "Alt-Used" | "Alternates" | "AMP-Cache-Transform" | "Apply-To-Redirect-Ref" | "Authentication-Control" | "Authentication-Info" | "Authorization" | "Available-Dictionary" | "C-Ext" | "C-Man" | "C-Opt" | "C-PEP" | "C-PEP-Info" | "Cache-Control" | "Cache-Status" | "Cal-Managed-ID" | "CalDAV-Timezones" | "Capsule-Protocol" | "CDN-Cache-Control" | "CDN-Loop" | "Cert-Not-After" | "Cert-Not-Before" | "Clear-Site-Data" | "Client-Cert" | "Client-Cert-Chain" | "Close" | "CMCD-Object" | "CMCD-Request" | "CMCD-Session" | "CMCD-Status" | "CMSD-Dynamic" | "CMSD-Static" | "Concealed-Auth-Export" | "Configuration-Context" | "Connection" | "Content-Base" | "Content-Digest" | "Content-Disposition" | "Content-Encoding" | "Content-ID" | "Content-Language" | "Content-Length" | "Content-Location" | "Content-MD5" | "Content-Range" | "Content-Script-Type" | "Content-Security-Policy" | "Content-Security-Policy-Report-Only" | "Content-Style-Type" | "Content-Type" | "Content-Version" | "Cookie" | "Cookie2" | "Cross-Origin-Embedder-Policy" | "Cross-Origin-Embedder-Policy-Report-Only" | "Cross-Origin-Opener-Policy" | "Cross-Origin-Opener-Policy-Report-Only" | "Cross-Origin-Resource-Policy" | "CTA-Common-Access-Token" | "DASL" | "Date" | "DAV" | "Default-Style" | "Delta-Base" | "Deprecation" | "Depth" | "Derived-From" | "Destination" | "Differential-ID" | "Dictionary-ID" | "Digest" | "DPoP" | "DPoP-Nonce" | "Early-Data" | "EDIINT-Features" | "ETag" | "Expect" | "Expect-CT" | "Expires" | "Ext" | "Forwarded" | "From" | "GetProfile" | "Hobareg" | "Host" | "HTTP2-Settings" | "If" | "If-Match" | "If-Modified-Since" | "If-None-Match" | "If-Range" | "If-Schedule-Tag-Match" | "If-Unmodified-Since" | "IM" | "Include-Referred-Token-Binding-ID" | "Isolation" | "Keep-Alive" | "Label" | "Last-Event-ID" | "Last-Modified" | "Link" | "Link-Template" | "Location" | "Lock-Token" | "Man" | "Max-Forwards" | "Memento-Datetime" | "Meter" | "Method-Check" | "Method-Check-Expires" | "MIME-Version" | "Negotiate" | "NEL" | "OData-EntityId" | "OData-Isolation" | "OData-MaxVersion" | "OData-Version" | "Opt" | "Optional-WWW-Authenticate" | "Ordering-Type" | "Origin" | "Origin-Agent-Cluster" | "OSCORE" | "OSLC-Core-Version" | "Overwrite" | "P3P" | "PEP" | "PEP-Info" | "Permissions-Policy" | "PICS-Label" | "Ping-From" | "Ping-To" | "Position" | "Pragma" | "Prefer" | "Preference-Applied" | "Priority" | "ProfileObject" | "Protocol" | "Protocol-Info" | "Protocol-Query" | "Protocol-Request" | "Proxy-Authenticate" | "Proxy-Authentication-Info" | "Proxy-Authorization" | "Proxy-Features" | "Proxy-Instruction" | "Proxy-Status" | "Public" | "Public-Key-Pins" | "Public-Key-Pins-Report-Only" | "Range" | "Redirect-Ref" | "Referer" | "Referer-Root" | "Referrer-Policy" | "Refresh" | "Repeatability-Client-ID" | "Repeatability-First-Sent" | "Repeatability-Request-ID" | "Repeatability-Result" | "Replay-Nonce" | "Reporting-Endpoints" | "Repr-Digest" | "Retry-After" | "Safe" | "Schedule-Reply" | "Schedule-Tag" | "Sec-GPC" | "Sec-Purpose" | "Sec-Token-Binding" | "Sec-WebSocket-Accept" | "Sec-WebSocket-Extensions" | "Sec-WebSocket-Key" | "Sec-WebSocket-Protocol" | "Sec-WebSocket-Version" | "Security-Scheme" | "Server" | "Server-Timing" | "Set-Cookie" | "Set-Cookie2" | "SetProfile" | "Signature" | "Signature-Input" | "SLUG" | "SoapAction" | "Status-URI" | "Strict-Transport-Security" | "Sunset" | "Surrogate-Capability" | "Surrogate-Control" | "TCN" | "TE" | "Timeout" | "Timing-Allow-Origin" | "Topic" | "Traceparent" | "Tracestate" | "Trailer" | "Transfer-Encoding" | "TTL" | "Upgrade" | "Urgency" | "URI" | "Use-As-Dictionary" | "User-Agent" | "Variant-Vary" | "Vary" | "Via" | "Want-Content-Digest" | "Want-Digest" | "Want-Repr-Digest" | "Warning" | "WWW-Authenticate" | "X-Content-Type-Options" | "X-Frame-Options" | (string & {});
212
- /** Outbound webhook executor operation. Sends HTTP requests to external URLs. */
213
- type WebhookOperation<Args> = Omit<WebhookOperation$1, "url" | "requestBody" | "headers"> & {
214
- url: (args: Args) => string;
215
- requestBody?: (args: Args) => Record<string, unknown>;
216
- headers?: { [key in RequestHeader]?: string | {
217
- vault: string;
218
- key: string;
219
- } };
220
- };
221
- /**
222
- * Extract mainJob's Input type from Workflow.
223
- * Workflow<Job> -> Job is WorkflowJob<Name, Input, Output> -> Input
224
- */
225
- type WorkflowInput$1<W extends Workflow> = Parameters<W["trigger"]>[0];
226
- /** Workflow-triggering executor operation. Triggers a workflow in response to an event. */
227
- type WorkflowOperation<Args, W extends Workflow = Workflow> = Omit<WorkflowOperation$1, "workflowName" | "args" | "invoker"> & {
228
- workflow: W;
229
- args?: WorkflowInput$1<W> | ((args: Args) => WorkflowInput$1<W>);
230
- invoker?: MachineUserName;
231
- };
232
- type Operation<Args> = FunctionOperation<Args> | GqlOperation<Args> | WebhookOperation<Args> | WorkflowOperation<Args>;
233
- //#endregion
234
- //#region src/configure/services/executor/trigger/event.d.ts
235
- interface EventArgs {
236
- workspaceId: string;
237
- appNamespace: string;
238
- env: TailorEnv;
239
- actor: TailorPrincipal | null;
240
- }
241
- interface RecordArgs extends EventArgs {
242
- typeName: string;
243
- }
244
- interface RecordCreatedArgs<T extends TailorDBType> extends RecordArgs {
245
- event: "created";
246
- rawEvent: "tailordb.type_record.created";
247
- newRecord: output$1<T>;
248
- }
249
- interface RecordUpdatedArgs<T extends TailorDBType> extends RecordArgs {
250
- event: "updated";
251
- rawEvent: "tailordb.type_record.updated";
252
- newRecord: output$1<T>;
253
- oldRecord: output$1<T>;
254
- }
255
- interface RecordDeletedArgs<T extends TailorDBType> extends RecordArgs {
256
- event: "deleted";
257
- rawEvent: "tailordb.type_record.deleted";
258
- oldRecord: output$1<T>;
259
- }
260
- /**
261
- * Args for resolverExecutedTrigger. This is a discriminated union on `success`.
262
- *
263
- * When `success` is true, `result` contains the resolver output and `error` is never.
264
- * When `success` is false, `error` contains the error message and `result` is never.
265
- *
266
- * Narrow on `success` to safely access either `result` or `error`.
267
- * @example
268
- * body: async (args) => {
269
- * if (args.success) {
270
- * console.log(args.result);
271
- * } else {
272
- * console.error(args.error);
273
- * }
274
- * }
275
- */
276
- type ResolverExecutedArgs<R extends ResolverConfig> = EventArgs & {
277
- resolverName: string;
278
- } & ({
279
- success: true;
280
- result: output$1<R["output"]>;
281
- error?: never;
282
- } | {
283
- success: false;
284
- result?: never;
285
- error: string;
286
- });
287
- interface IdpUserCreatedArgs extends EventArgs {
288
- event: "created";
289
- rawEvent: "idp.user.created";
290
- namespaceName: string;
291
- userId: string;
292
- }
293
- interface IdpUserUpdatedArgs extends EventArgs {
294
- event: "updated";
295
- rawEvent: "idp.user.updated";
296
- namespaceName: string;
297
- userId: string;
298
- }
299
- interface IdpUserDeletedArgs extends EventArgs {
300
- event: "deleted";
301
- rawEvent: "idp.user.deleted";
302
- namespaceName: string;
303
- userId: string;
304
- }
305
- type IdpUserArgs = IdpUserCreatedArgs | IdpUserUpdatedArgs | IdpUserDeletedArgs;
306
- interface AuthAccessTokenIssuedArgs extends EventArgs {
307
- event: "issued";
308
- rawEvent: "auth.access_token.issued";
309
- namespaceName: string;
310
- userId: string;
311
- }
312
- interface AuthAccessTokenRefreshedArgs extends EventArgs {
313
- event: "refreshed";
314
- rawEvent: "auth.access_token.refreshed";
315
- namespaceName: string;
316
- userId: string;
317
- }
318
- interface AuthAccessTokenRevokedArgs extends EventArgs {
319
- event: "revoked";
320
- rawEvent: "auth.access_token.revoked";
321
- namespaceName: string;
322
- userId: string;
323
- }
324
- type AuthAccessTokenArgs = AuthAccessTokenIssuedArgs | AuthAccessTokenRefreshedArgs | AuthAccessTokenRevokedArgs;
325
- declare const recordEventMap: {
326
- readonly created: "tailordb.type_record.created";
327
- readonly updated: "tailordb.type_record.updated";
328
- readonly deleted: "tailordb.type_record.deleted";
329
- };
330
- type RecordEventMap = typeof recordEventMap;
331
- type RecordEventKind = keyof RecordEventMap;
332
- type RecordArgsMap<T extends TailorDBType> = {
333
- created: RecordCreatedArgs<T>;
334
- updated: RecordUpdatedArgs<T>;
335
- deleted: RecordDeletedArgs<T>;
336
- };
337
- type RecordMultiArgs<T extends TailorDBType, K extends RecordEventKind[]> = RecordArgsMap<T>[K[number]];
338
- type TailorDBTrigger<Args> = TailorDBTrigger$1 & {
339
- __args: Args;
340
- };
341
- type RecordTriggerOptions<T extends TailorDBType, Args> = {
342
- type: T;
343
- condition?: (args: Args) => boolean;
344
- };
345
- /**
346
- * Create a trigger that fires when a TailorDB record is created.
347
- * @template T
348
- * @param options - Trigger options
349
- * @returns Record created trigger
350
- */
351
- declare function recordCreatedTrigger<T extends TailorDBType>(options: RecordTriggerOptions<T, RecordCreatedArgs<T>>): TailorDBTrigger<RecordCreatedArgs<T>>;
352
- /**
353
- * Create a trigger that fires when a TailorDB record is updated.
354
- * @template T
355
- * @param options - Trigger options
356
- * @returns Record updated trigger
357
- */
358
- declare function recordUpdatedTrigger<T extends TailorDBType>(options: RecordTriggerOptions<T, RecordUpdatedArgs<T>>): TailorDBTrigger<RecordUpdatedArgs<T>>;
359
- /**
360
- * Create a trigger that fires when a TailorDB record is deleted.
361
- * @template T
362
- * @param options - Trigger options
363
- * @returns Record deleted trigger
364
- */
365
- declare function recordDeletedTrigger<T extends TailorDBType>(options: RecordTriggerOptions<T, RecordDeletedArgs<T>>): TailorDBTrigger<RecordDeletedArgs<T>>;
366
- type RecordTriggerMultiOptions<T extends TailorDBType, K extends RecordEventKind[]> = {
367
- type: T;
368
- events: K;
369
- condition?: (args: RecordMultiArgs<T, K>) => boolean;
370
- };
371
- /**
372
- * Create a trigger that fires on multiple TailorDB record event types.
373
- * @template T
374
- * @template K
375
- * @param options - Trigger options with events array
376
- * @returns TailorDB record trigger
377
- */
378
- declare function recordTrigger<T extends TailorDBType, const K extends [RecordEventKind, ...RecordEventKind[]]>(options: RecordTriggerMultiOptions<T, K>): TailorDBTrigger<RecordMultiArgs<T, K>>;
379
- type ResolverExecutedTrigger<Args> = ResolverExecutedTrigger$1 & {
380
- __args: Args;
381
- };
382
- type ResolverExecutedTriggerOptions<R extends ResolverConfig> = {
383
- resolver: R;
384
- condition?: (args: ResolverExecutedArgs<R>) => boolean;
385
- };
386
- /**
387
- * Create a trigger that fires when a resolver is executed.
388
- * @template R
389
- * @param options - Trigger options
390
- * @returns Resolver executed trigger
391
- */
392
- declare function resolverExecutedTrigger<R extends ResolverConfig>(options: ResolverExecutedTriggerOptions<R>): ResolverExecutedTrigger<ResolverExecutedArgs<R>>;
393
- declare const idpUserEventMap: {
394
- readonly created: "idp.user.created";
395
- readonly updated: "idp.user.updated";
396
- readonly deleted: "idp.user.deleted";
397
- };
398
- type IdpUserEventMap = typeof idpUserEventMap;
399
- type IdpUserEventKind = keyof IdpUserEventMap;
400
- type IdpUserArgsMap = {
401
- created: IdpUserCreatedArgs;
402
- updated: IdpUserUpdatedArgs;
403
- deleted: IdpUserDeletedArgs;
404
- };
405
- type IdpUserMultiArgs<K extends IdpUserEventKind[]> = IdpUserArgsMap[K[number]];
406
- type IdpUserTrigger<Args> = IdpUserTrigger$1 & {
407
- __args: Args;
408
- };
409
- type IdpUserSingleTriggerOptions = {
410
- /**
411
- * IdP namespace name to subscribe to. Required when the project defines
412
- * multiple IdPs; optional when a single IdP exists. Must match an IdP name
413
- * declared in `defineConfig({ idp: [...] })`.
414
- */
415
- idp?: IdpName;
416
- };
417
- /**
418
- * Create a trigger that fires when an IdP user is created.
419
- * @param options - Trigger options
420
- * @param options.idp - IdP namespace name to subscribe to
421
- * @returns IdP user created trigger
422
- */
423
- declare function idpUserCreatedTrigger(options?: IdpUserSingleTriggerOptions): IdpUserTrigger<IdpUserCreatedArgs>;
424
- /**
425
- * Create a trigger that fires when an IdP user is updated.
426
- * @param options - Trigger options
427
- * @param options.idp - IdP namespace name to subscribe to
428
- * @returns IdP user updated trigger
429
- */
430
- declare function idpUserUpdatedTrigger(options?: IdpUserSingleTriggerOptions): IdpUserTrigger<IdpUserUpdatedArgs>;
431
- /**
432
- * Create a trigger that fires when an IdP user is deleted.
433
- * @param options - Trigger options
434
- * @param options.idp - IdP namespace name to subscribe to
435
- * @returns IdP user deleted trigger
436
- */
437
- declare function idpUserDeletedTrigger(options?: IdpUserSingleTriggerOptions): IdpUserTrigger<IdpUserDeletedArgs>;
438
- type IdpUserTriggerOptions<K extends IdpUserEventKind[]> = {
439
- events: K;
440
- /**
441
- * IdP namespace name to subscribe to. Required when the project defines
442
- * multiple IdPs; optional when a single IdP exists. Must match an IdP name
443
- * declared in `defineConfig({ idp: [...] })`.
444
- */
445
- idp?: IdpName;
446
- };
447
- /**
448
- * Create a trigger that fires on multiple IdP user event types.
449
- * @template K
450
- * @param options - Trigger options with events array
451
- * @param options.events - IdP user event kinds to subscribe to
452
- * @param options.idp - IdP namespace name to subscribe to
453
- * @returns IdP user trigger
454
- */
455
- declare function idpUserTrigger<const K extends [IdpUserEventKind, ...IdpUserEventKind[]]>(options: IdpUserTriggerOptions<K>): IdpUserTrigger<IdpUserMultiArgs<K>>;
456
- declare const authAccessTokenEventMap: {
457
- readonly issued: "auth.access_token.issued";
458
- readonly refreshed: "auth.access_token.refreshed";
459
- readonly revoked: "auth.access_token.revoked";
460
- };
461
- type AuthAccessTokenEventMap = typeof authAccessTokenEventMap;
462
- type AuthAccessTokenEventKind = keyof AuthAccessTokenEventMap;
463
- type AuthAccessTokenArgsMap = {
464
- issued: AuthAccessTokenIssuedArgs;
465
- refreshed: AuthAccessTokenRefreshedArgs;
466
- revoked: AuthAccessTokenRevokedArgs;
467
- };
468
- type AuthAccessTokenMultiArgs<K extends AuthAccessTokenEventKind[]> = AuthAccessTokenArgsMap[K[number]];
469
- type AuthAccessTokenTrigger<Args> = AuthAccessTokenTrigger$1 & {
470
- __args: Args;
471
- };
472
- /**
473
- * Create a trigger that fires when an access token is issued.
474
- * @returns Auth access token issued trigger
475
- */
476
- declare function authAccessTokenIssuedTrigger(): AuthAccessTokenTrigger<AuthAccessTokenIssuedArgs>;
477
- /**
478
- * Create a trigger that fires when an access token is refreshed.
479
- * @returns Auth access token refreshed trigger
480
- */
481
- declare function authAccessTokenRefreshedTrigger(): AuthAccessTokenTrigger<AuthAccessTokenRefreshedArgs>;
482
- /**
483
- * Create a trigger that fires when an access token is revoked.
484
- * @returns Auth access token revoked trigger
485
- */
486
- declare function authAccessTokenRevokedTrigger(): AuthAccessTokenTrigger<AuthAccessTokenRevokedArgs>;
487
- type AuthAccessTokenTriggerOptions<K extends AuthAccessTokenEventKind[]> = {
488
- events: K;
489
- };
490
- /**
491
- * Create a trigger that fires on multiple auth access token event types.
492
- * @template K
493
- * @param options - Trigger options with events array
494
- * @returns Auth access token trigger
495
- */
496
- declare function authAccessTokenTrigger<const K extends [AuthAccessTokenEventKind, ...AuthAccessTokenEventKind[]]>(options: AuthAccessTokenTriggerOptions<K>): AuthAccessTokenTrigger<AuthAccessTokenMultiArgs<K>>;
497
- //#endregion
498
- //#region src/configure/services/executor/trigger/schedule.d.ts
499
- type Timezone = "UTC" | "Pacific/Midway" | "Pacific/Niue" | "Pacific/Pago_Pago" | "America/Adak" | "Pacific/Honolulu" | "Pacific/Rarotonga" | "Pacific/Tahiti" | "Pacific/Marquesas" | "America/Anchorage" | "America/Juneau" | "America/Metlakatla" | "America/Nome" | "America/Sitka" | "America/Yakutat" | "Pacific/Gambier" | "America/Los_Angeles" | "America/Tijuana" | "America/Vancouver" | "Pacific/Pitcairn" | "America/Boise" | "America/Cambridge_Bay" | "America/Chihuahua" | "America/Creston" | "America/Dawson" | "America/Dawson_Creek" | "America/Denver" | "America/Edmonton" | "America/Fort_Nelson" | "America/Hermosillo" | "America/Inuvik" | "America/Mazatlan" | "America/Ojinaga" | "America/Phoenix" | "America/Whitehorse" | "America/Yellowknife" | "America/Bahia_Banderas" | "America/Belize" | "America/Chicago" | "America/Costa_Rica" | "America/El_Salvador" | "America/Guatemala" | "America/Indiana/Knox" | "America/Indiana/Tell_City" | "America/Managua" | "America/Matamoros" | "America/Menominee" | "America/Merida" | "America/Mexico_City" | "America/Monterrey" | "America/North_Dakota/Beulah" | "America/North_Dakota/Center" | "America/North_Dakota/New_Salem" | "America/Rainy_River" | "America/Rankin_Inlet" | "America/Regina" | "America/Resolute" | "America/Swift_Current" | "America/Tegucigalpa" | "America/Winnipeg" | "Pacific/Easter" | "Pacific/Galapagos" | "America/Atikokan" | "America/Bogota" | "America/Cancun" | "America/Cayman" | "America/Detroit" | "America/Eirunepe" | "America/Grand_Turk" | "America/Guayaquil" | "America/Havana" | "America/Indiana/Indianapolis" | "America/Indiana/Marengo" | "America/Indiana/Petersburg" | "America/Indiana/Vevay" | "America/Indiana/Vincennes" | "America/Indiana/Winamac" | "America/Iqaluit" | "America/Jamaica" | "America/Kentucky/Louisville" | "America/Kentucky/Monticello" | "America/Lima" | "America/Nassau" | "America/New_York" | "America/Nipigon" | "America/Panama" | "America/Pangnirtung" | "America/Port-au-Prince" | "America/Rio_Branco" | "America/Thunder_Bay" | "America/Toronto" | "America/Anguilla" | "America/Antigua" | "America/Aruba" | "America/Asuncion" | "America/Barbados" | "America/Blanc-Sablon" | "America/Boa_Vista" | "America/Campo_Grande" | "America/Caracas" | "America/Cuiaba" | "America/Curacao" | "America/Dominica" | "America/Glace_Bay" | "America/Goose_Bay" | "America/Grenada" | "America/Guadeloupe" | "America/Guyana" | "America/Halifax" | "America/Kralendijk" | "America/La_Paz" | "America/Lower_Princes" | "America/Manaus" | "America/Marigot" | "America/Martinique" | "America/Moncton" | "America/Montserrat" | "America/Porto_Velho" | "America/Port_of_Spain" | "America/Puerto_Rico" | "America/Santiago" | "America/Santo_Domingo" | "America/St_Barthelemy" | "America/St_Kitts" | "America/St_Lucia" | "America/St_Thomas" | "America/St_Vincent" | "America/Thule" | "America/Tortola" | "Atlantic/Bermuda" | "America/St_Johns" | "America/Araguaina" | "America/Argentina/Buenos_Aires" | "America/Argentina/Catamarca" | "America/Argentina/Cordoba" | "America/Argentina/Jujuy" | "America/Argentina/La_Rioja" | "America/Argentina/Mendoza" | "America/Argentina/Rio_Gallegos" | "America/Argentina/Salta" | "America/Argentina/San_Juan" | "America/Argentina/San_Luis" | "America/Argentina/Tucuman" | "America/Argentina/Ushuaia" | "America/Bahia" | "America/Belem" | "America/Cayenne" | "America/Fortaleza" | "America/Godthab" | "America/Maceio" | "America/Miquelon" | "America/Montevideo" | "America/Paramaribo" | "America/Punta_Arenas" | "America/Recife" | "America/Santarem" | "America/Sao_Paulo" | "Antarctica/Palmer" | "Antarctica/Rothera" | "Atlantic/Stanley" | "America/Noronha" | "Atlantic/South_Georgia" | "America/Scoresbysund" | "Atlantic/Azores" | "Atlantic/Cape_Verde" | "Africa/Abidjan" | "Africa/Accra" | "Africa/Bamako" | "Africa/Banjul" | "Africa/Bissau" | "Africa/Casablanca" | "Africa/Conakry" | "Africa/Dakar" | "Africa/El_Aaiun" | "Africa/Freetown" | "Africa/Lome" | "Africa/Monrovia" | "Africa/Nouakchott" | "Africa/Ouagadougou" | "Africa/Sao_Tome" | "America/Danmarkshavn" | "Antarctica/Troll" | "Atlantic/Canary" | "Atlantic/Faroe" | "Atlantic/Madeira" | "Atlantic/Reykjavik" | "Atlantic/St_Helena" | "Europe/Dublin" | "Europe/Guernsey" | "Europe/Isle_of_Man" | "Europe/Jersey" | "Europe/Lisbon" | "Europe/London" | "Africa/Algiers" | "Africa/Bangui" | "Africa/Brazzaville" | "Africa/Ceuta" | "Africa/Douala" | "Africa/Kinshasa" | "Africa/Lagos" | "Africa/Libreville" | "Africa/Luanda" | "Africa/Malabo" | "Africa/Ndjamena" | "Africa/Niamey" | "Africa/Porto-Novo" | "Africa/Tunis" | "Africa/Windhoek" | "Arctic/Longyearbyen" | "Europe/Amsterdam" | "Europe/Andorra" | "Europe/Belgrade" | "Europe/Berlin" | "Europe/Bratislava" | "Europe/Brussels" | "Europe/Budapest" | "Europe/Copenhagen" | "Europe/Gibraltar" | "Europe/Ljubljana" | "Europe/Luxembourg" | "Europe/Madrid" | "Europe/Malta" | "Europe/Monaco" | "Europe/Oslo" | "Europe/Paris" | "Europe/Podgorica" | "Europe/Prague" | "Europe/Rome" | "Europe/San_Marino" | "Europe/Sarajevo" | "Europe/Skopje" | "Europe/Stockholm" | "Europe/Tirane" | "Europe/Vaduz" | "Europe/Vatican" | "Europe/Vienna" | "Europe/Warsaw" | "Europe/Zagreb" | "Europe/Zurich" | "Africa/Blantyre" | "Africa/Bujumbura" | "Africa/Cairo" | "Africa/Gaborone" | "Africa/Harare" | "Africa/Johannesburg" | "Africa/Juba" | "Africa/Khartoum" | "Africa/Kigali" | "Africa/Lubumbashi" | "Africa/Lusaka" | "Africa/Maputo" | "Africa/Maseru" | "Africa/Mbabane" | "Africa/Tripoli" | "Asia/Amman" | "Asia/Beirut" | "Asia/Damascus" | "Asia/Famagusta" | "Asia/Gaza" | "Asia/Hebron" | "Asia/Jerusalem" | "Asia/Nicosia" | "Europe/Athens" | "Europe/Bucharest" | "Europe/Chisinau" | "Europe/Helsinki" | "Europe/Kaliningrad" | "Europe/Kyiv" | "Europe/Mariehamn" | "Europe/Riga" | "Europe/Sofia" | "Europe/Tallinn" | "Europe/Uzhgorod" | "Europe/Vilnius" | "Europe/Zaporizhzhia" | "Africa/Addis_Ababa" | "Africa/Asmara" | "Africa/Dar_es_Salaam" | "Africa/Djibouti" | "Africa/Kampala" | "Africa/Mogadishu" | "Africa/Nairobi" | "Antarctica/Syowa" | "Asia/Aden" | "Asia/Baghdad" | "Asia/Bahrain" | "Asia/Kuwait" | "Asia/Qatar" | "Asia/Riyadh" | "Europe/Istanbul" | "Europe/Kirov" | "Europe/Minsk" | "Europe/Moscow" | "Europe/Simferopol" | "Europe/Volgograd" | "Indian/Antananarivo" | "Indian/Comoro" | "Indian/Mayotte" | "Asia/Tehran" | "Asia/Baku" | "Asia/Dubai" | "Asia/Muscat" | "Asia/Tbilisi" | "Asia/Yerevan" | "Europe/Astrakhan" | "Europe/Samara" | "Europe/Saratov" | "Europe/Ulyanovsk" | "Indian/Mahe" | "Indian/Mauritius" | "Indian/Reunion" | "Asia/Kabul" | "Antarctica/Mawson" | "Asia/Aqtau" | "Asia/Aqtobe" | "Asia/Ashgabat" | "Asia/Atyrau" | "Asia/Dushanbe" | "Asia/Karachi" | "Asia/Oral" | "Asia/Qyzylorda" | "Asia/Samarkand" | "Asia/Tashkent" | "Asia/Yekaterinburg" | "Indian/Kerguelen" | "Indian/Maldives" | "Asia/Colombo" | "Asia/Kolkata" | "Asia/Kathmandu" | "Antarctica/Vostok" | "Asia/Almaty" | "Asia/Bishkek" | "Asia/Dhaka" | "Asia/Omsk" | "Asia/Qostanay" | "Asia/Thimphu" | "Asia/Urumqi" | "Indian/Chagos" | "Asia/Yangon" | "Indian/Cocos" | "Antarctica/Davis" | "Asia/Bangkok" | "Asia/Barnaul" | "Asia/Hovd" | "Asia/Ho_Chi_Minh" | "Asia/Jakarta" | "Asia/Krasnoyarsk" | "Asia/Novokuznetsk" | "Asia/Novosibirsk" | "Asia/Phnom_Penh" | "Asia/Pontianak" | "Asia/Tomsk" | "Asia/Vientiane" | "Indian/Christmas" | "Asia/Brunei" | "Asia/Choibalsan" | "Asia/Hong_Kong" | "Asia/Irkutsk" | "Asia/Kuala_Lumpur" | "Asia/Kuching" | "Asia/Macau" | "Asia/Makassar" | "Asia/Manila" | "Asia/Shanghai" | "Asia/Singapore" | "Asia/Taipei" | "Asia/Ulaanbaatar" | "Australia/Perth" | "Australia/Eucla" | "Asia/Chita" | "Asia/Dili" | "Asia/Jayapura" | "Asia/Khandyga" | "Asia/Pyongyang" | "Asia/Seoul" | "Asia/Tokyo" | "Asia/Yakutsk" | "Pacific/Palau" | "Australia/Adelaide" | "Australia/Broken_Hill" | "Australia/Darwin" | "Antarctica/DumontDUrville" | "Antarctica/Macquarie" | "Asia/Ust-Nera" | "Asia/Vladivostok" | "Australia/Brisbane" | "Australia/Currie" | "Australia/Hobart" | "Australia/Lindeman" | "Australia/Melbourne" | "Australia/Sydney" | "Pacific/Chuuk" | "Pacific/Guam" | "Pacific/Port_Moresby" | "Pacific/Saipan" | "Australia/Lord_Howe" | "Antarctica/Casey" | "Asia/Magadan" | "Asia/Sakhalin" | "Asia/Srednekolymsk" | "Pacific/Bougainville" | "Pacific/Efate" | "Pacific/Guadalcanal" | "Pacific/Kosrae" | "Pacific/Norfolk" | "Pacific/Noumea" | "Pacific/Pohnpei" | "Antarctica/McMurdo" | "Asia/Anadyr" | "Asia/Kamchatka" | "Pacific/Auckland" | "Pacific/Fiji" | "Pacific/Funafuti" | "Pacific/Kwajalein" | "Pacific/Majuro" | "Pacific/Nauru" | "Pacific/Tarawa" | "Pacific/Wake" | "Pacific/Wallis" | "Pacific/Chatham" | "Pacific/Apia" | "Pacific/Enderbury" | "Pacific/Fakaofo" | "Pacific/Tongatapu" | "Pacific/Kiritimati";
500
- type ScheduleTrigger<Args> = ScheduleTriggerInput & {
501
- __args: Args;
502
- };
503
- interface ScheduleArgs {
504
- env: TailorEnv;
505
- }
506
- interface ScheduleTriggerOptions<T extends string> {
507
- cron: StandardCRON<T> extends never ? never : T;
508
- timezone?: Timezone;
509
- }
510
- /**
511
- * Create a schedule-based trigger using a CRON expression and optional timezone.
512
- * @template T
513
- * @param options - Schedule options
514
- * @returns Schedule trigger
515
- */
516
- declare function scheduleTrigger<T extends string>(options: ScheduleTriggerOptions<T>): ScheduleTrigger<ScheduleArgs>;
517
- //#endregion
518
- //#region src/configure/services/executor/trigger/webhook.d.ts
519
- interface IncomingWebhookArgs<T extends IncomingWebhookRequest> {
520
- body: T["body"];
521
- headers: T["headers"];
522
- method: "POST" | "GET" | "PUT" | "DELETE";
523
- rawBody: string;
524
- env: TailorEnv;
525
- }
526
- interface IncomingWebhookRequest {
527
- body: Record<string, unknown>;
528
- headers: Record<string, string>;
529
- }
530
- interface IncomingWebhookResponseConfig<Args> {
531
- /**
532
- * Expression that returns the webhook HTTP response body.
533
- * Receives the same args as the executor operation.
534
- */
535
- body?: (args: Args) => JsonValue;
536
- /**
537
- * HTTP status code for the response.
538
- * If omitted and `body` is set, the platform uses 200.
539
- */
540
- statusCode?: number;
541
- }
542
- type IncomingWebhookResponse<Args> = ((args: Args) => JsonValue) | IncomingWebhookResponseConfig<Args>;
543
- interface IncomingWebhookTriggerOptions<Args> {
544
- response?: IncomingWebhookResponse<Args>;
545
- }
546
- type IncomingWebhookTrigger<Args> = IncomingWebhookTrigger$1 & {
547
- __args: Args;
548
- };
549
- /**
550
- * Create a trigger for incoming webhook requests.
551
- * @template T
552
- * @param options - Optional trigger options including response configuration
553
- * @returns Incoming webhook trigger
554
- */
555
- declare function incomingWebhookTrigger<T extends IncomingWebhookRequest>(options?: IncomingWebhookTriggerOptions<IncomingWebhookArgs<T>>): IncomingWebhookTrigger<IncomingWebhookArgs<T>>;
556
- //#endregion
557
- //#region src/configure/services/executor/trigger/index.d.ts
558
- type Trigger<Args> = TailorDBTrigger<Args> | ResolverExecutedTrigger<Args> | ScheduleTrigger<Args> | IncomingWebhookTrigger<Args> | IdpUserTrigger<Args> | AuthAccessTokenTrigger<Args>;
559
- //#endregion
560
- //#region src/configure/services/executor/executor.d.ts
561
- /**
562
- * Extract mainJob's Input type from Workflow.
563
- */
564
- type WorkflowInput<W extends Workflow> = Parameters<W["trigger"]>[0];
565
- type TriggerArgs<T extends Trigger<unknown>> = T extends {
566
- __args: infer Args;
567
- } ? Args : never;
568
- type ExecutorBase<T extends Trigger<unknown>> = Omit<ExecutorInput, "trigger" | "operation"> & {
569
- trigger: T;
570
- };
571
- /**
572
- * Executor type with conditional inference for workflow operations.
573
- * When operation.kind is "workflow", infers W from the workflow property
574
- * to ensure args type matches the workflow's mainJob input type.
575
- */
576
- type Executor<T extends Trigger<unknown>, O> = O extends {
577
- kind: "workflow";
578
- workflow: infer W extends Workflow;
579
- } ? ExecutorBase<T> & {
580
- operation: {
581
- kind: "workflow";
582
- workflow: W;
583
- args?: WorkflowInput<W> | ((args: TriggerArgs<T>) => WorkflowInput<W>);
584
- invoker?: MachineUserName;
585
- };
586
- } : ExecutorBase<T> & {
587
- operation: O;
588
- };
589
- /**
590
- * Create an executor configuration for the Tailor SDK.
591
- *
592
- * Executors are event-driven handlers that respond to record changes,
593
- * resolver executions, or other events.
594
- *
595
- * Operation kinds: "function", "graphql", "webhook", "workflow".
596
- * @template T
597
- * @template O
598
- * @param config - Executor configuration
599
- * @returns The same executor configuration
600
- * @example
601
- * import { createExecutor, recordCreatedTrigger } from "@tailor-platform/sdk";
602
- * import { order } from "../tailordb/order";
603
- *
604
- * export default createExecutor({
605
- * name: "order-created",
606
- * description: "Handles new order creation",
607
- * trigger: recordCreatedTrigger({ type: order }),
608
- * operation: {
609
- * kind: "function",
610
- * body: async ({ newRecord }) => {
611
- * console.log("New order:", newRecord.id);
612
- * },
613
- * },
614
- * });
615
- */
616
- declare function createExecutor<T extends Trigger<unknown>, O extends Operation<TriggerArgs<T>> | {
617
- kind: "workflow";
618
- workflow: Workflow;
619
- }>(config: Executor<T, O>): Executor<T, O>;
620
- /**
621
- * Create an executor configuration for the Tailor SDK.
622
- * This overload preserves source compatibility for legacy explicit generic calls,
623
- * where the first generic argument represents trigger args.
624
- * @template Args
625
- * @template O
626
- * @param config - Executor configuration
627
- * @returns The same executor configuration
628
- */
629
- declare function createExecutor<Args, O extends Operation<Args> | {
630
- kind: "workflow";
631
- workflow: Workflow;
632
- }>(config: Executor<Trigger<Args>, O>): Executor<Trigger<Args>, O>;
633
- //#endregion
634
- //#region src/configure/services/staticwebsite/index.d.ts
635
- /**
636
- * Define a static website configuration for the Tailor SDK.
637
- * @param name - Static website name
638
- * @param config - Static website configuration
639
- * @returns Defined static website
640
- */
641
- declare function defineStaticWebSite(name: string, config: Omit<StaticWebsiteInput, "name">): {
642
- readonly name: string;
643
- readonly url: `${string}:url`;
644
- readonly description?: string | undefined;
645
- readonly allowedIpAddresses?: string[] | undefined;
646
- readonly customDomains?: string[] | undefined;
647
- } & StaticWebsiteDefinitionBrand;
648
- //#endregion
649
- //#region src/configure/services/aigateway/index.d.ts
650
- /**
651
- * Define an AI Gateway configuration for the Tailor SDK.
652
- * @param name - AI Gateway name
653
- * @param config - AI Gateway configuration
654
- * @returns Defined AI Gateway
655
- */
656
- declare function defineAIGateway(name: string, config: Omit<AIGatewayInput, "name">): {
657
- readonly name: string;
658
- readonly cors?: string[] | undefined;
659
- readonly authNamespace: string;
660
- } & AIGatewayDefinitionBrand;
661
- //#endregion
662
- //#region src/parser/service/idp/types.d.ts
663
- type IdPUserField = "id" | "name" | "disabled";
664
- //#endregion
665
- //#region src/configure/services/idp/permission.d.ts
666
- type EqualityOperator = "=" | "!=";
667
- type ContainsOperator = "in" | "not in";
668
- type StringFieldKeys<User extends object> = { [K in keyof User]: User[K] extends string ? K : never }[keyof User];
669
- type StringArrayFieldKeys<User extends object> = { [K in keyof User]: User[K] extends string[] ? K : never }[keyof User];
670
- type BooleanFieldKeys<User extends object> = { [K in keyof User]: User[K] extends boolean ? K : never }[keyof User];
671
- type BooleanArrayFieldKeys<User extends object> = { [K in keyof User]: User[K] extends boolean[] ? K : never }[keyof User];
672
- type UserStringOperand<User extends object = InferredAttributeMap> = {
673
- user: StringFieldKeys<User> | "id";
674
- };
675
- type UserStringArrayOperand<User extends object = InferredAttributeMap> = {
676
- user: StringArrayFieldKeys<User>;
677
- };
678
- type UserBooleanOperand<User extends object = InferredAttributeMap> = {
679
- user: BooleanFieldKeys<User> | "_loggedIn";
680
- };
681
- type UserBooleanArrayOperand<User extends object = InferredAttributeMap> = {
682
- user: BooleanArrayFieldKeys<User>;
683
- };
684
- type IdPUserOperand<Update extends boolean = false> = Update extends true ? {
685
- oldIdpUser: IdPUserField;
686
- } | {
687
- newIdpUser: IdPUserField;
688
- } : {
689
- idpUser: IdPUserField;
690
- };
691
- type StringEqualityCondition<User extends object, Update extends boolean> = readonly [string, EqualityOperator, string] | readonly [UserStringOperand<User>, EqualityOperator, string] | readonly [string, EqualityOperator, UserStringOperand<User>] | readonly [IdPUserOperand<Update>, EqualityOperator, string | UserStringOperand<User> | IdPUserOperand<Update>] | readonly [string | UserStringOperand<User>, EqualityOperator, IdPUserOperand<Update>];
692
- type BooleanEqualityCondition<User extends object, Update extends boolean> = readonly [boolean, EqualityOperator, boolean] | readonly [UserBooleanOperand<User>, EqualityOperator, boolean] | readonly [boolean, EqualityOperator, UserBooleanOperand<User>] | readonly [IdPUserOperand<Update>, EqualityOperator, boolean | UserBooleanOperand<User> | IdPUserOperand<Update>] | readonly [boolean | UserBooleanOperand<User>, EqualityOperator, IdPUserOperand<Update>];
693
- type EqualityCondition<User extends object = InferredAttributeMap, Update extends boolean = boolean> = StringEqualityCondition<User, Update> | BooleanEqualityCondition<User, Update>;
694
- type StringContainsCondition<User extends object, Update extends boolean> = readonly [string, ContainsOperator, string[]] | readonly [UserStringOperand<User>, ContainsOperator, string[]] | readonly [string, ContainsOperator, UserStringArrayOperand<User>] | readonly [IdPUserOperand<Update>, ContainsOperator, string[] | UserStringArrayOperand<User>];
695
- type BooleanContainsCondition<User extends object, Update extends boolean> = readonly [boolean, ContainsOperator, boolean[]] | readonly [UserBooleanOperand<User>, ContainsOperator, boolean[]] | readonly [boolean, ContainsOperator, UserBooleanArrayOperand<User>] | readonly [IdPUserOperand<Update>, ContainsOperator, boolean[] | UserBooleanArrayOperand<User>];
696
- type ContainsCondition<User extends object = InferredAttributeMap, Update extends boolean = boolean> = StringContainsCondition<User, Update> | BooleanContainsCondition<User, Update>;
697
- type IdPPermissionCondition<User extends object = InferredAttributeMap, Update extends boolean = boolean> = EqualityCondition<User, Update> | ContainsCondition<User, Update>;
698
- type IdPActionPermission<User extends object = InferredAttributeMap, Update extends boolean = boolean> = {
699
- conditions: IdPPermissionCondition<User, Update> | readonly IdPPermissionCondition<User, Update>[];
700
- description?: string | undefined;
701
- /**
702
- * Whether matching users are granted (`true`) or denied (`false`).
703
- * Omitting `permit` in this object form defaults to `deny` and emits a
704
- * warning; set it explicitly. (The array shorthand defaults to `allow`.)
705
- */
706
- permit?: boolean;
707
- } | readonly [...IdPPermissionCondition<User, Update>, ...([] | [boolean])] | readonly [...IdPPermissionCondition<User, Update>[], ...([] | [boolean])];
708
- /**
709
- * Per-operation permission policies for an IdP service.
710
- * Defines create, read, update, delete, and sendPasswordResetEmail permissions.
711
- *
712
- * For update operations, use `newIdpUser`/`oldIdpUser` operands instead of `idpUser`.
713
- * @example
714
- * const permission: IdPPermission = {
715
- * create: [{ conditions: [[{ user: "role" }, "=", "ADMIN"]], permit: true }],
716
- * read: [{ conditions: [[{ user: "_loggedIn" }, "=", true]], permit: true }],
717
- * update: [{ conditions: [[{ newIdpUser: "name" }, "=", { user: "id" }]], permit: true }],
718
- * delete: [{ conditions: [[{ user: "role" }, "=", "ADMIN"]], permit: true }],
719
- * sendPasswordResetEmail: [{ conditions: [], permit: true }],
720
- * };
721
- */
722
- type IdPPermission<User extends object = InferredAttributeMap> = {
723
- create: readonly IdPActionPermission<User, false>[];
724
- read: readonly IdPActionPermission<User, false>[];
725
- update: readonly IdPActionPermission<User, true>[];
726
- delete: readonly IdPActionPermission<User, false>[];
727
- sendPasswordResetEmail: readonly IdPActionPermission<User, false>[];
728
- };
729
- /**
730
- * Grants full IdP permission access without any conditions.
731
- *
732
- * Unsafe and intended only for local development, prototyping, or tests.
733
- * Do not use this in production environments, as it effectively disables
734
- * authorization checks.
735
- */
736
- declare const unsafeAllowAllIdPPermission: IdPPermission;
737
- //#endregion
738
- //#region src/configure/services/idp/index.d.ts
739
- /**
740
- * Define an IdP service configuration for the Tailor SDK.
741
- * @template TClients
742
- * @param name - IdP service name
743
- * @param config - IdP configuration
744
- * @returns Defined IdP service
745
- */
746
- declare function defineIdp<const TClients extends string[]>(name: string, config: Omit<IdPInput, "name" | "clients" | "permission"> & {
747
- clients: TClients;
748
- permission?: IdPPermission;
749
- }): {
750
- readonly name: string;
751
- readonly provider: (providerName: string, clientName: TClients[number]) => {
752
- readonly name: string;
753
- readonly kind: "BuiltInIdP";
754
- readonly namespace: string;
755
- readonly clientName: TClients[number];
756
- };
757
- readonly authorization?: "insecure" | "loggedIn" | {
758
- cel: string;
759
- } | undefined;
760
- readonly lang?: "en" | "ja" | undefined;
761
- readonly userAuthPolicy?: {
762
- useNonEmailIdentifier?: boolean | undefined;
763
- allowSelfPasswordReset?: boolean | undefined;
764
- passwordRequireUppercase?: boolean | undefined;
765
- passwordRequireLowercase?: boolean | undefined;
766
- passwordRequireNonAlphanumeric?: boolean | undefined;
767
- passwordRequireNumeric?: boolean | undefined;
768
- passwordMinLength?: number | undefined;
769
- passwordMaxLength?: number | undefined;
770
- allowedEmailDomains?: string[] | undefined;
771
- allowGoogleOauth?: boolean | undefined;
772
- allowMicrosoftOauth?: boolean | undefined;
773
- disablePasswordAuth?: boolean | undefined;
774
- } | undefined;
775
- readonly publishUserEvents?: boolean | undefined;
776
- readonly gqlOperations?: "query" | {
777
- create?: boolean | undefined;
778
- update?: boolean | undefined;
779
- delete?: boolean | undefined;
780
- read?: boolean | undefined;
781
- sendPasswordResetEmail?: boolean | undefined;
782
- } | undefined;
783
- readonly emailConfig?: {
784
- fromName?: string | undefined;
785
- passwordResetSubject?: string | undefined;
786
- } | undefined;
787
- readonly clients: TClients;
788
- readonly permission?: IdPPermission;
789
- } & IdpDefinitionBrand;
790
- //#endregion
791
- //#region src/configure/services/secrets/index.d.ts
792
- type SecretsVaultInput = Record<string, string>;
793
- type SecretsVaultInputNullish = Record<string, string | undefined | null>;
794
- type SecretsInput = Record<string, SecretsVaultInput>;
795
- type SecretsInputNullish = Record<string, SecretsVaultInputNullish>;
796
- type SecretsOptions = {
797
- readonly ignoreNullishValues: boolean;
798
- };
799
- type DefinedSecrets<T extends SecretsInputNullish> = {
800
- readonly vaults: T;
801
- readonly options: SecretsOptions;
802
- get<V extends Extract<keyof T, string>, S extends Extract<keyof T[V], string>>(vault: V, secret: S): Promise<string | undefined>;
803
- getAll<V extends Extract<keyof T, string>, S extends Extract<keyof T[V], string>>(vault: V, secrets: readonly S[]): Promise<(string | undefined)[]>;
804
- } & SecretsDefinitionBrand;
805
- /**
806
- * Define secrets configuration for the Tailor SDK.
807
- * Each key is a vault name, and its value is a record of secret name to secret value.
808
- * @param config - Secrets configuration mapping vault names to their secrets
809
- * @returns Defined secrets with typed runtime access methods
810
- */
811
- declare function defineSecretManager<const T extends SecretsInput>(config: T): DefinedSecrets<T>;
812
- /**
813
- * Define secrets configuration for the Tailor SDK with ignoreNullishValues option.
814
- * When `ignoreNullishValues` is true, secrets with nullish values are skipped during deploy
815
- * instead of causing an error. This is useful for CI environments where not all
816
- * secret values are available.
817
- * @param config - Secrets configuration mapping vault names to their secrets
818
- * @param options - Options for secret management behavior
819
- * @param options.ignoreNullishValues - When true, secrets with nullish values are skipped during deploy
820
- * @returns Defined secrets with typed runtime access methods
821
- */
822
- declare function defineSecretManager<const T extends SecretsInputNullish>(config: T, options: {
823
- ignoreNullishValues: true;
824
- }): DefinedSecrets<T>;
825
- //#endregion
826
- //#region src/configure/services/http-adapter/http-adapter.d.ts
827
- /**
828
- * Lowercase HTTP method keys accepted in `input`, derived from the config
829
- * schema via the generated type so they cannot drift.
830
- */
831
- type HttpMethodKey = keyof Required<HttpAdapterConfigInput["input"]>;
832
- /** Incoming HTTP request passed to an `input` handler. */
833
- type HttpAdapterRequest = {
834
- method: Uppercase<HttpMethodKey>;
835
- path: string;
836
- headers: Record<string, string>;
837
- query: Record<string, string>;
838
- body: string;
839
- };
840
- /** GraphQL request returned by an `input` handler. */
841
- type HttpAdapterGraphQLRequest = {
842
- query: string;
843
- variables?: Record<string, unknown>;
844
- operationName?: string;
845
- };
846
- /** Converts an incoming HTTP request into a GraphQL request. */
847
- type HttpAdapterInputFn = (req: HttpAdapterRequest) => HttpAdapterGraphQLRequest;
848
- /** GraphQL execution result passed to the `output` handler. */
849
- type HttpAdapterGraphQLResponse = {
850
- data?: unknown;
851
- errors?: unknown;
852
- extensions?: unknown;
853
- };
854
- /** HTTP response returned by the `output` handler. */
855
- type HttpAdapterResponse = {
856
- statusCode?: number;
857
- headers?: Record<string, string>;
858
- body: string;
859
- };
860
- /** Converts a GraphQL response into an HTTP response. */
861
- type HttpAdapterOutputFn = (resp: HttpAdapterGraphQLResponse) => HttpAdapterResponse;
862
- /**
863
- * Per-method input handlers. At least one method must be provided.
864
- * Each handler transforms an HTTP request into a GraphQL request.
865
- */
866
- type HttpAdapterInput = Partial<Record<HttpMethodKey, HttpAdapterInputFn>>;
867
- /**
868
- * HTTP adapter configuration accepted by `createHttpAdapter` with typed
869
- * `input` and `output` signatures.
870
- */
871
- type HttpAdapter = Omit<HttpAdapterConfigInput, "input" | "output"> & {
872
- input: HttpAdapterInput;
873
- output?: HttpAdapterOutputFn;
874
- };
875
- /**
876
- * Defines an HTTP adapter that translates HTTP requests to GraphQL queries
877
- * and shapes the GraphQL response back into an HTTP response.
878
- *
879
- * The adapter MUST be the default export of its file.
880
- * Files are discovered via the `httpAdapter.files` glob in `defineConfig()`.
881
- *
882
- * `input` is an object keyed by lowercase HTTP method (`get`, `post`, `put`,
883
- * `patch`, `delete`). At least one method must be declared; the methods the
884
- * adapter serves are derived from these keys.
885
- *
886
- * `output` is optional and shared across all methods. If you need different
887
- * response shapes per method, discriminate inside `output` based on the
888
- * GraphQL response shape.
889
- *
890
- * Each handler runs server-side and must be synchronous: Node APIs, `fetch`,
891
- * `async`/`await`, Promises, and top-level `await` are not available.
892
- *
893
- * Optional fields: `enabled` (default `true`; set `false` to deploy the adapter
894
- * without serving it) and `priority` (non-negative integer, default `0`; when
895
- * multiple adapters match the same request path, the lowest value wins).
896
- * @param config - HTTP adapter configuration
897
- * @returns Branded HTTP adapter definition
898
- * @example
899
- * export default createHttpAdapter({
900
- * name: "get-user",
901
- * pathPattern: "/users/*",
902
- * input: {
903
- * get: (req) => ({
904
- * query: `query($id: ID!) { user(id: $id) { id name } }`,
905
- * variables: { id: req.path.split("/")[2] },
906
- * }),
907
- * },
908
- * output: (resp) => ({
909
- * statusCode: 200,
910
- * headers: { "content-type": "application/json" },
911
- * body: JSON.stringify(resp.data),
912
- * }),
913
- * });
914
- */
915
- declare function createHttpAdapter(config: HttpAdapter): HttpAdapter;
916
- //#endregion
917
- //#region src/configure/config/index.d.ts
918
- /**
919
- * Define a Tailor SDK application configuration with shallow exactness.
920
- * @template Config
921
- * @param config - Application configuration
922
- * @returns The same configuration object
923
- */
924
- declare function defineConfig<const Config extends AppConfig & Record<Exclude<keyof Config, keyof AppConfig>, never>>(config: Config): Config;
925
- /**
926
- * Define plugins to be used with the Tailor SDK.
927
- * Plugins can generate additional types, resolvers, and executors
928
- * based on existing TailorDB types.
929
- * @param configs - Plugin configurations
930
- * @returns Plugin configurations as given
931
- */
932
- declare function definePlugins(...configs: Plugin<any, any>[]): Plugin<any, any>[];
933
- //#endregion
934
- //#region src/configure/index.d.ts
935
- type TailorOutput<T> = output$1<T>;
936
- type infer<T> = TailorOutput<T>;
937
- type output<T> = TailorOutput<T>;
938
- /** TailorDB field type builders. */
939
- declare const t: {
940
- uuid: <const Opt extends FieldOptions>(options?: Opt) => TailorField<{
941
- type: "uuid";
942
- array: Opt extends {
943
- array: true;
944
- } ? true : false;
945
- }, Opt["optional"] extends true ? ArrayFieldOutput<string, Opt> | null : ArrayFieldOutput<string, Opt>, FieldMetadata, TailorFieldType>;
946
- string: <const Opt extends FieldOptions>(options?: Opt) => TailorField<{
947
- type: "string";
948
- array: Opt extends {
949
- array: true;
950
- } ? true : false;
951
- }, Opt["optional"] extends true ? ArrayFieldOutput<string, Opt> | null : ArrayFieldOutput<string, Opt>, FieldMetadata, TailorFieldType>;
952
- bool: <const Opt extends FieldOptions>(options?: Opt) => TailorField<{
953
- type: "boolean";
954
- array: Opt extends {
955
- array: true;
956
- } ? true : false;
957
- }, Opt["optional"] extends true ? ArrayFieldOutput<boolean, Opt> | null : ArrayFieldOutput<boolean, Opt>, FieldMetadata, TailorFieldType>;
958
- int: <const Opt extends FieldOptions>(options?: Opt) => TailorField<{
959
- type: "integer";
960
- array: Opt extends {
961
- array: true;
962
- } ? true : false;
963
- }, Opt["optional"] extends true ? ArrayFieldOutput<number, Opt> | null : ArrayFieldOutput<number, Opt>, FieldMetadata, TailorFieldType>;
964
- float: <const Opt extends FieldOptions>(options?: Opt) => TailorField<{
965
- type: "float";
966
- array: Opt extends {
967
- array: true;
968
- } ? true : false;
969
- }, Opt["optional"] extends true ? ArrayFieldOutput<number, Opt> | null : ArrayFieldOutput<number, Opt>, FieldMetadata, TailorFieldType>;
970
- decimal: <const Opt extends FieldOptions>(options?: Opt) => TailorField<{
971
- type: "decimal";
972
- array: Opt extends {
973
- array: true;
974
- } ? true : false;
975
- }, Opt["optional"] extends true ? ArrayFieldOutput<string, Opt> | null : ArrayFieldOutput<string, Opt>, FieldMetadata, TailorFieldType>;
976
- date: <const Opt extends FieldOptions>(options?: Opt) => TailorField<{
977
- type: "date";
978
- array: Opt extends {
979
- array: true;
980
- } ? true : false;
981
- }, Opt["optional"] extends true ? ArrayFieldOutput<string, Opt> | null : ArrayFieldOutput<string, Opt>, FieldMetadata, TailorFieldType>;
982
- datetime: <const Opt extends FieldOptions>(options?: Opt) => TailorField<{
983
- type: "datetime";
984
- array: Opt extends {
985
- array: true;
986
- } ? true : false;
987
- }, Opt["optional"] extends true ? ArrayFieldOutput<string | Date, Opt> | null : ArrayFieldOutput<string | Date, Opt>, FieldMetadata, TailorFieldType>;
988
- time: <const Opt extends FieldOptions>(options?: Opt) => TailorField<{
989
- type: "time";
990
- array: Opt extends {
991
- array: true;
992
- } ? true : false;
993
- }, Opt["optional"] extends true ? ArrayFieldOutput<string, Opt> | null : ArrayFieldOutput<string, Opt>, FieldMetadata, TailorFieldType>;
994
- enum: <const V extends AllowedValues, const Opt extends FieldOptions>(values: V, options?: Opt) => TailorField<{
995
- type: "enum";
996
- array: Opt extends {
997
- array: true;
998
- } ? true : false;
999
- }, FieldOutput<AllowedValuesOutput<V>, Opt>>;
1000
- object: <const F extends Record<string, TailorAnyField>, const Opt extends FieldOptions>(fields: F, options?: Opt) => TailorField<{
1001
- type: "nested";
1002
- array: Opt extends {
1003
- array: true;
1004
- } ? true : false;
1005
- }, FieldOutput<InferFieldsOutput<F>, Opt>, FieldMetadata, TailorFieldType>;
1006
- };
1007
- declare namespace t {
1008
- type output<T> = TailorOutput<T>;
1009
- type infer<T> = TailorOutput<T>;
1010
- }
1011
- //#endregion
1012
- export { authAccessTokenTrigger as $, incomingWebhookTrigger as A, IdpUserCreatedArgs as B, Trigger as C, IncomingWebhookResponseConfig as D, IncomingWebhookResponse as E, AuthAccessTokenIssuedArgs as F, RecordDeletedArgs as G, IdpUserTrigger as H, AuthAccessTokenRefreshedArgs as I, ResolverExecutedTrigger as J, RecordUpdatedArgs as K, AuthAccessTokenRevokedArgs as L, ScheduleTrigger as M, scheduleTrigger as N, IncomingWebhookTrigger as O, AuthAccessTokenArgs as P, authAccessTokenRevokedTrigger as Q, AuthAccessTokenTrigger as R, createExecutor as S, IncomingWebhookRequest as T, IdpUserUpdatedArgs as U, IdpUserDeletedArgs as V, RecordCreatedArgs as W, authAccessTokenIssuedTrigger as X, TailorDBTrigger as Y, authAccessTokenRefreshedTrigger as Z, IdPPermission as _, IdpName as _t, definePlugins as a, recordDeletedTrigger as at, defineAIGateway as b, HttpAdapterGraphQLResponse as c, resolverExecutedTrigger as ct, HttpAdapterOutputFn as d, Operation as dt, idpUserCreatedTrigger as et, HttpAdapterRequest as f, WebhookOperation as ft, defineIdp as g, defineAuth as gt, defineSecretManager as h, createResolver as ht, defineConfig as i, recordCreatedTrigger as it, ScheduleArgs as j, IncomingWebhookTriggerOptions as k, HttpAdapterInput as l, FunctionOperation as lt, createHttpAdapter as m, QueryType as mt, output as n, idpUserTrigger as nt, HttpAdapter as o, recordTrigger as ot, HttpAdapterResponse as p, WorkflowOperation as pt, ResolverExecutedArgs as q, t as r, idpUserUpdatedTrigger as rt, HttpAdapterGraphQLRequest as s, recordUpdatedTrigger as st, infer as t, idpUserDeletedTrigger as tt, HttpAdapterInputFn as u, GqlOperation as ut, IdPPermissionCondition as v, IdpNameRegistry as vt, IncomingWebhookArgs as w, defineStaticWebSite as x, unsafeAllowAllIdPPermission as y, TailorField as yt, IdpUserArgs as z };
1013
- //# sourceMappingURL=index-BI-_j9Z3.d.mts.map