@tailor-platform/sdk 1.71.0 → 1.73.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +46 -0
- package/dist/aigateway-B3oZZE6v.mjs +15 -0
- package/dist/aigateway-B3oZZE6v.mjs.map +1 -0
- package/dist/application-BhRnH42h.mjs +3 -0
- package/dist/{application-DmjIKQ-a.mjs → application-Dxhdq_nu.mjs} +21 -19
- package/dist/application-Dxhdq_nu.mjs.map +1 -0
- package/dist/{assert-CKfwrmCV.mjs → assert-DBxo8jPo.mjs} +1 -2
- package/dist/{assert-CKfwrmCV.mjs.map → assert-DBxo8jPo.mjs.map} +1 -1
- package/dist/{authconnection-D7lsvsKY.mjs → authconnection-BGQM8FZI.mjs} +2 -3
- package/dist/{authconnection-D7lsvsKY.mjs.map → authconnection-BGQM8FZI.mjs.map} +1 -1
- package/dist/{brand-DlnJ375c.mjs → brand-Eo4pLXPJ.mjs} +1 -2
- package/dist/{brand-DlnJ375c.mjs.map → brand-Eo4pLXPJ.mjs.map} +1 -1
- package/dist/cli/cache/bundle-cache.d.mts +1 -0
- package/dist/cli/cache/store.d.mts +1 -0
- package/dist/cli/cache/types.d.mts +1 -0
- package/dist/cli/commands/api/api-call.d.mts +19 -0
- package/dist/cli/commands/api/index.d.mts +3 -0
- package/dist/cli/commands/deploy/aigateway.d.mts +1 -0
- package/dist/cli/commands/deploy/application.d.mts +1 -0
- package/dist/cli/commands/deploy/auth.d.mts +1 -0
- package/dist/cli/commands/deploy/deploy.d.mts +24 -0
- package/dist/cli/commands/deploy/executor.d.mts +1 -0
- package/dist/cli/commands/deploy/function-registry-types.d.mts +12 -0
- package/dist/cli/commands/deploy/function-registry.d.mts +2 -0
- package/dist/cli/commands/deploy/idp.d.mts +1 -0
- package/dist/cli/commands/deploy/resolver.d.mts +1 -0
- package/dist/cli/commands/deploy/secret-manager.d.mts +1 -0
- package/dist/cli/commands/deploy/staticwebsite.d.mts +1 -0
- package/dist/cli/commands/deploy/tailordb/index.d.mts +1 -0
- package/dist/cli/commands/deploy/types.d.mts +1 -0
- package/dist/cli/commands/deploy/workflow.d.mts +1 -0
- package/dist/cli/commands/executor/get.d.mts +29 -0
- package/dist/cli/commands/executor/jobs.d.mts +123 -0
- package/dist/cli/commands/executor/list.d.mts +19 -0
- package/dist/cli/commands/executor/transform.d.mts +41 -0
- package/dist/cli/commands/executor/trigger.d.mts +41 -0
- package/dist/cli/commands/executor/webhook.d.mts +22 -0
- package/dist/cli/commands/function/get.d.mts +18 -0
- package/dist/cli/commands/function/list.d.mts +22 -0
- package/dist/cli/commands/function/transform.d.mts +11 -0
- package/dist/cli/commands/generate/options.d.mts +7 -0
- package/dist/cli/commands/generate/seed/bundler.d.mts +26 -0
- package/dist/cli/commands/generate/service.d.mts +12 -0
- package/dist/cli/commands/generate/types.d.mts +126 -0
- package/dist/cli/commands/machineuser/list.d.mts +27 -0
- package/dist/cli/commands/machineuser/token.d.mts +22 -0
- package/dist/cli/commands/oauth2client/get.d.mts +18 -0
- package/dist/cli/commands/oauth2client/list.d.mts +20 -0
- package/dist/cli/commands/oauth2client/transform.d.mts +20 -0
- package/dist/cli/commands/organization/folder/create.d.mts +18 -0
- package/dist/cli/commands/organization/folder/delete.d.mts +16 -0
- package/dist/cli/commands/organization/folder/get.d.mts +17 -0
- package/dist/cli/commands/organization/folder/list.d.mts +22 -0
- package/dist/cli/commands/organization/folder/update.d.mts +18 -0
- package/dist/cli/commands/organization/get.d.mts +16 -0
- package/dist/cli/commands/organization/list.d.mts +15 -0
- package/dist/cli/commands/organization/transform.d.mts +27 -0
- package/dist/cli/commands/organization/tree.d.mts +25 -0
- package/dist/cli/commands/organization/update.d.mts +17 -0
- package/dist/cli/commands/remove.d.mts +16 -0
- package/dist/cli/commands/show.d.mts +34 -0
- package/dist/cli/commands/tailordb/migrate/bundler.d.mts +28 -0
- package/dist/cli/commands/tailordb/migrate/config.d.mts +19 -0
- package/dist/cli/commands/tailordb/migrate/diff-calculator.d.mts +211 -0
- package/dist/cli/commands/tailordb/migrate/generate.d.mts +17 -0
- package/dist/cli/commands/tailordb/migrate/snapshot-types.d.mts +202 -0
- package/dist/cli/commands/tailordb/migrate/snapshot.d.mts +113 -0
- package/dist/cli/commands/tailordb/migrate/types.d.mts +7 -0
- package/dist/cli/commands/tailordb/truncate.d.mts +19 -0
- package/dist/cli/commands/workflow/executions.d.mts +75 -0
- package/dist/cli/commands/workflow/get.d.mts +29 -0
- package/dist/cli/commands/workflow/list.d.mts +19 -0
- package/dist/cli/commands/workflow/resume.d.mts +23 -0
- package/dist/cli/commands/workflow/start.d.mts +63 -0
- package/dist/cli/commands/workflow/status.d.mts +5 -0
- package/dist/cli/commands/workflow/transform.d.mts +33 -0
- package/dist/cli/commands/workflow/wait.d.mts +16 -0
- package/dist/cli/commands/workflow/waiter.d.mts +23 -0
- package/dist/cli/commands/workspace/app/health.d.mts +18 -0
- package/dist/cli/commands/workspace/app/list.d.mts +22 -0
- package/dist/cli/commands/workspace/app/transform.d.mts +18 -0
- package/dist/cli/commands/workspace/create.d.mts +25 -0
- package/dist/cli/commands/workspace/delete.d.mts +15 -0
- package/dist/cli/commands/workspace/get.d.mts +17 -0
- package/dist/cli/commands/workspace/list.d.mts +17 -0
- package/dist/cli/commands/workspace/restore.d.mts +15 -0
- package/dist/cli/commands/workspace/transform.d.mts +16 -0
- package/dist/cli/commands/workspace/user/invite.d.mts +22 -0
- package/dist/cli/commands/workspace/user/list.d.mts +22 -0
- package/dist/cli/commands/workspace/user/remove.d.mts +17 -0
- package/dist/cli/commands/workspace/user/transform.d.mts +8 -0
- package/dist/cli/commands/workspace/user/update.d.mts +22 -0
- package/dist/cli/index.d.mts +1 -2
- package/dist/cli/index.mjs +801 -206
- package/dist/cli/index.mjs.map +1 -1
- package/dist/cli/lib.d.mts +80 -21402
- package/dist/cli/lib.mjs +8 -9
- package/dist/cli/lib.mjs.map +1 -1
- package/dist/cli/query/index.d.mts +35 -0
- package/dist/cli/services/application.d.mts +1 -0
- package/dist/cli/services/auth/service.d.mts +1 -0
- package/dist/cli/services/executor/service.d.mts +1 -0
- package/dist/cli/services/http-adapter/bundler.d.mts +1 -0
- package/dist/cli/services/http-adapter/service.d.mts +1 -0
- package/dist/cli/services/resolver/service.d.mts +1 -0
- package/dist/cli/services/tailordb/service.d.mts +1 -0
- package/dist/cli/services/workflow/bundler.d.mts +1 -0
- package/dist/cli/services/workflow/service.d.mts +1 -0
- package/dist/cli/shared/args.d.mts +13 -0
- package/dist/cli/shared/client.d.mts +1273 -0
- package/dist/cli/shared/config-loader.d.mts +44 -0
- package/dist/cli/shared/context.d.mts +28 -0
- package/dist/cli/shared/script-executor.d.mts +74 -0
- package/dist/cli/shared/seed-chunker.d.mts +46 -0
- package/dist/cli/shared/trigger-context.d.mts +1 -0
- package/dist/cli/shared/type-generator.d.mts +20 -0
- package/dist/cli/skills.mjs +1 -2
- package/dist/cli/skills.mjs.map +1 -1
- package/dist/completion/zsh-worker.zsh +124 -25
- package/dist/configure/config/index.d.mts +29 -0
- package/dist/configure/config/types.d.mts +103 -0
- package/dist/configure/index.d.mts +125 -7
- package/dist/configure/index.mjs +5 -6
- package/dist/configure/index.mjs.map +1 -1
- package/dist/configure/services/aigateway/index.d.mts +17 -0
- package/dist/configure/services/aigateway/types.d.mts +11 -0
- package/dist/configure/services/auth/index.d.mts +43 -0
- package/dist/{types-v_ErzNUF.d.mts → configure/services/auth/types.d.mts} +7 -172
- package/dist/configure/services/executor/executor.d.mts +82 -0
- package/dist/configure/services/executor/index.d.mts +8 -0
- package/dist/configure/services/executor/operation.d.mts +46 -0
- package/dist/configure/services/executor/trigger/event.d.mts +272 -0
- package/dist/configure/services/executor/trigger/index.d.mts +8 -0
- package/dist/configure/services/executor/trigger/schedule.d.mts +25 -0
- package/dist/configure/services/executor/trigger/webhook.d.mts +44 -0
- package/dist/configure/services/executor/types.d.mts +2 -0
- package/dist/configure/services/http-adapter/http-adapter.d.mts +125 -0
- package/dist/configure/services/http-adapter/index.d.mts +2 -0
- package/dist/configure/services/idp/index.d.mts +64 -0
- package/dist/configure/services/idp/permission.d.mts +80 -0
- package/dist/configure/services/idp/types.d.mts +20 -0
- package/dist/configure/services/index.d.mts +33 -0
- package/dist/configure/services/resolver/index.d.mts +5 -0
- package/dist/configure/services/resolver/resolver.d.mts +77 -0
- package/dist/configure/services/resolver/types.d.mts +6 -0
- package/dist/configure/services/secrets/index.d.mts +38 -0
- package/dist/configure/services/secrets/types.d.mts +11 -0
- package/dist/configure/services/staticwebsite/index.d.mts +19 -0
- package/dist/configure/services/staticwebsite/types.d.mts +11 -0
- package/dist/configure/services/tailordb/index.d.mts +4 -0
- package/dist/configure/services/tailordb/permission.d.mts +119 -0
- package/dist/configure/services/tailordb/schema.d.mts +451 -0
- package/dist/configure/services/tailordb/types.d.mts +149 -0
- package/dist/configure/services/workflow/index.d.mts +7 -0
- package/dist/configure/services/workflow/job.d.mts +81 -0
- package/dist/configure/services/workflow/test-env-key.d.mts +9 -0
- package/dist/configure/services/workflow/types.d.mts +2 -0
- package/dist/configure/services/workflow/wait-point.d.mts +73 -0
- package/dist/configure/services/workflow/workflow.d.mts +55 -0
- package/dist/configure/types/aigateway-name.d.mts +12 -0
- package/dist/configure/types/connection-name.d.mts +12 -0
- package/dist/configure/types/field.d.mts +9 -0
- package/dist/configure/types/field.types.d.mts +109 -0
- package/dist/configure/types/idp-name.d.mts +12 -0
- package/dist/configure/types/index.d.mts +4 -0
- package/dist/configure/types/machine-user.d.mts +12 -0
- package/dist/configure/types/type.d.mts +99 -0
- package/dist/configure/user.d.mts +7 -0
- package/dist/{context-CDQqIv4u.mjs → context-Bd266-ru.mjs} +2 -3
- package/dist/{context-CDQqIv4u.mjs.map → context-Bd266-ru.mjs.map} +1 -1
- package/dist/{crashreport-BwF8cHF0.mjs → crashreport-Dy4ZzSkd.mjs} +1 -2
- package/dist/{crashreport-BqyvFk-_.mjs → crashreport-ayWANEZ6.mjs} +4 -5
- package/dist/{crashreport-BqyvFk-_.mjs.map → crashreport-ayWANEZ6.mjs.map} +1 -1
- package/dist/{enum-constants-C7DaWeQo.mjs → enum-constants-j9QBF0cB.mjs} +1 -2
- package/dist/{enum-constants-C7DaWeQo.mjs.map → enum-constants-j9QBF0cB.mjs.map} +1 -1
- package/dist/{errors-EsY4XO6O.mjs → errors-Dtf2WPaW.mjs} +1 -2
- package/dist/{errors-EsY4XO6O.mjs.map → errors-Dtf2WPaW.mjs.map} +1 -1
- package/dist/{field-C4zdJLW5.mjs → field-DOsJCPFa.mjs} +1 -2
- package/dist/{field-C4zdJLW5.mjs.map → field-DOsJCPFa.mjs.map} +1 -1
- package/dist/{file-BkxupbYP.mjs → file-_oUZo76X.mjs} +2 -3
- package/dist/{file-BkxupbYP.mjs.map → file-_oUZo76X.mjs.map} +1 -1
- package/dist/{file-utils-BHPxPXmn.mjs → file-utils-DcyIPFQh.mjs} +2 -3
- package/dist/{file-utils-BHPxPXmn.mjs.map → file-utils-DcyIPFQh.mjs.map} +1 -1
- package/dist/{globals-ByrCoDip.mjs → globals-B8XX5TRB.mjs} +3 -3
- package/dist/globals-B8XX5TRB.mjs.map +1 -0
- package/dist/{iconv-D1zmPjvi.mjs → iconv-D2vi8G36.mjs} +2 -3
- package/dist/{iconv-D1zmPjvi.mjs.map → iconv-D2vi8G36.mjs.map} +1 -1
- package/dist/{idp-ynUfzwpz.mjs → idp-Bx25ZBdN.mjs} +2 -3
- package/dist/{idp-ynUfzwpz.mjs.map → idp-Bx25ZBdN.mjs.map} +1 -1
- package/dist/{interceptor-DOqRkCya.mjs → interceptor-D-q1rvRl.mjs} +1 -2
- package/dist/{interceptor-DOqRkCya.mjs.map → interceptor-D-q1rvRl.mjs.map} +1 -1
- package/dist/{job-BpsFXPbi.mjs → job-CtU73PGa.mjs} +3 -4
- package/dist/{job-BpsFXPbi.mjs.map → job-CtU73PGa.mjs.map} +1 -1
- package/dist/kysely/index.d.mts +2 -3
- package/dist/kysely/index.mjs +0 -1
- package/dist/kysely/index.mjs.map +1 -1
- package/dist/{kysely-type-CSoZxVKN.mjs → kysely-type-D-zflMGf.mjs} +2 -3
- package/dist/{kysely-type-CSoZxVKN.mjs.map → kysely-type-D-zflMGf.mjs.map} +1 -1
- package/dist/{logger-DKF-JsAK.mjs → logger-BEiZZ3qT.mjs} +1 -2
- package/dist/{logger-DKF-JsAK.mjs.map → logger-BEiZZ3qT.mjs.map} +1 -1
- package/dist/{mock-wf5qeZLi.mjs → mock-Ce1GCi4-.mjs} +60 -5
- package/dist/mock-Ce1GCi4-.mjs.map +1 -0
- package/dist/{multiline-Cf9ODpr1.mjs → multiline-sfHpTZZK.mjs} +1 -2
- package/dist/{multiline-Cf9ODpr1.mjs.map → multiline-sfHpTZZK.mjs.map} +1 -1
- package/dist/{package-json-DcQApfPQ.mjs → package-json-8b0O9TlX.mjs} +1 -2
- package/dist/{package-json-DcQApfPQ.mjs.map → package-json-8b0O9TlX.mjs.map} +1 -1
- package/dist/package-json-Cv2Z-TqQ.mjs +3 -0
- package/dist/parser/generator-config/schema.d.mts +1 -0
- package/dist/parser/service/auth/index.d.mts +1 -0
- package/dist/parser/service/auth/schema.d.mts +1 -0
- package/dist/parser/service/http-adapter/index.d.mts +1 -0
- package/dist/parser/service/http-adapter/schema.d.mts +1 -0
- package/dist/parser/service/idp/types.d.mts +4 -0
- package/dist/parser/service/tailordb/types.d.mts +126 -0
- package/dist/plugin/builtin/enum-constants/index.d.mts +16 -1
- package/dist/plugin/builtin/enum-constants/index.mjs +1 -2
- package/dist/plugin/builtin/file-utils/index.d.mts +16 -1
- package/dist/plugin/builtin/file-utils/index.mjs +1 -2
- package/dist/plugin/builtin/kysely-type/index.d.mts +16 -1
- package/dist/plugin/builtin/kysely-type/index.mjs +1 -2
- package/dist/plugin/builtin/seed/index.d.mts +45 -1
- package/dist/plugin/builtin/seed/index.mjs +1 -2
- package/dist/plugin/get-generated-type.d.mts +17 -0
- package/dist/plugin/index.d.mts +3 -118
- package/dist/plugin/index.mjs +0 -1
- package/dist/plugin/index.mjs.map +1 -1
- package/dist/plugin/manager.d.mts +1 -0
- package/dist/plugin/types.d.mts +245 -0
- package/dist/plugin/with-context.d.mts +102 -0
- package/dist/{registry-D0uB0OrK.mjs → registry-BozuxbPp.mjs} +1 -2
- package/dist/{registry-D0uB0OrK.mjs.map → registry-BozuxbPp.mjs.map} +1 -1
- package/dist/{repl-editor-DD5YP5mt.mjs → repl-editor-BmQOyZJd.mjs} +2 -3
- package/dist/{repl-editor-DD5YP5mt.mjs.map → repl-editor-BmQOyZJd.mjs.map} +1 -1
- package/dist/{rolldown-runtime-BkoGK1jX.mjs → rolldown-runtime-DXywRVcq.mjs} +0 -1
- package/dist/runtime/aigateway.d.mts +35 -0
- package/dist/runtime/aigateway.mjs +3 -0
- package/dist/runtime/authconnection.d.mts +31 -2
- package/dist/runtime/authconnection.mjs +1 -2
- package/dist/runtime/context.d.mts +67 -2
- package/dist/runtime/context.mjs +1 -2
- package/dist/runtime/file.d.mts +249 -2
- package/dist/runtime/file.mjs +1 -2
- package/dist/runtime/globals.d.mts +31 -20
- package/dist/runtime/globals.mjs +0 -1
- package/dist/runtime/iconv.d.mts +121 -2
- package/dist/runtime/iconv.mjs +1 -2
- package/dist/runtime/idp.d.mts +186 -2
- package/dist/runtime/idp.mjs +1 -2
- package/dist/runtime/index.d.mts +47 -9
- package/dist/runtime/index.mjs +9 -9
- package/dist/runtime/secretmanager.d.mts +54 -2
- package/dist/runtime/secretmanager.mjs +1 -2
- package/dist/{types-DTcZ2Yax.d.mts → runtime/types.d.mts} +1 -2
- package/dist/runtime/workflow.d.mts +107 -2
- package/dist/runtime/workflow.mjs +2 -3
- package/dist/{runtime-Cd375HD-.mjs → runtime-CEFC05qX.mjs} +81 -130
- package/dist/runtime-CEFC05qX.mjs.map +1 -0
- package/dist/{schema-C4fkpWV_.mjs → schema-DAdZSFOd.mjs} +3 -4
- package/dist/{schema-C4fkpWV_.mjs.map → schema-DAdZSFOd.mjs.map} +1 -1
- package/dist/{secret-file-eB3R3Fil.mjs → secret-file-VSVGy1V0.mjs} +2 -3
- package/dist/{secret-file-eB3R3Fil.mjs.map → secret-file-VSVGy1V0.mjs.map} +1 -1
- package/dist/{secretmanager-h3tBJV8f.mjs → secretmanager-BVxw3ih_.mjs} +2 -3
- package/dist/{secretmanager-h3tBJV8f.mjs.map → secretmanager-BVxw3ih_.mjs.map} +1 -1
- package/dist/seed/index.d.mts +1 -2
- package/dist/seed/index.mjs +0 -1
- package/dist/seed/index.mjs.map +1 -1
- package/dist/{seed-YAbtMy65.mjs → seed-DoMTMLcm.mjs} +3 -4
- package/dist/{seed-YAbtMy65.mjs.map → seed-DoMTMLcm.mjs.map} +1 -1
- package/dist/service-BXmdFwSH.mjs +3 -0
- package/dist/{service-DDWgZL_L2.mjs → service-DBFZQloR.mjs} +3 -4
- package/dist/service-DBFZQloR.mjs.map +1 -0
- package/dist/{service-B2Jd9CxS.mjs → service-DiEtAsvc.mjs} +3 -4
- package/dist/{service-B2Jd9CxS.mjs.map → service-DiEtAsvc.mjs.map} +1 -1
- package/dist/{service_pb-BsBR6yW5.mjs → service_pb-CIrhGwHk.mjs} +1 -2
- package/dist/{service_pb-BsBR6yW5.mjs.map → service_pb-CIrhGwHk.mjs.map} +1 -1
- package/dist/{service_pb-BJ9GsAnW.mjs → service_pb-DjwIn4jO.mjs} +1 -2
- package/dist/tailor-proto/src/tailor/v1/aigateway_pb.d.mts +204 -0
- package/dist/tailor-proto/src/tailor/v1/aigateway_resource_pb.d.mts +58 -0
- package/dist/tailor-proto/src/tailor/v1/application_pb.d.mts +316 -0
- package/dist/tailor-proto/src/tailor/v1/application_resource_pb.d.mts +161 -0
- package/dist/tailor-proto/src/tailor/v1/auth_pb.d.mts +2070 -0
- package/dist/tailor-proto/src/tailor/v1/auth_resource_pb.d.mts +861 -0
- package/dist/tailor-proto/src/tailor/v1/events_pb.d.mts +112 -0
- package/dist/tailor-proto/src/tailor/v1/events_resource_pb.d.mts +69 -0
- package/dist/tailor-proto/src/tailor/v1/executor_pb.d.mts +439 -0
- package/dist/tailor-proto/src/tailor/v1/executor_resource_pb.d.mts +564 -0
- package/dist/tailor-proto/src/tailor/v1/function_pb.d.mts +145 -0
- package/dist/tailor-proto/src/tailor/v1/function_registry_pb.d.mts +451 -0
- package/dist/tailor-proto/src/tailor/v1/function_resource_pb.d.mts +192 -0
- package/dist/tailor-proto/src/tailor/v1/http_adapter_resource_pb.d.mts +50 -0
- package/dist/tailor-proto/src/tailor/v1/idp_pb.d.mts +407 -0
- package/dist/tailor-proto/src/tailor/v1/idp_resource_pb.d.mts +430 -0
- package/dist/tailor-proto/src/tailor/v1/metadata_pb.d.mts +73 -0
- package/dist/tailor-proto/src/tailor/v1/metadata_resource_pb.d.mts +17 -0
- package/dist/tailor-proto/src/tailor/v1/meter_pb.d.mts +309 -0
- package/dist/tailor-proto/src/tailor/v1/pipeline_pb.d.mts +591 -0
- package/dist/tailor-proto/src/tailor/v1/pipeline_resource_pb.d.mts +330 -0
- package/dist/tailor-proto/src/tailor/v1/resource_pb.d.mts +113 -0
- package/dist/tailor-proto/src/tailor/v1/secret_manager_pb.d.mts +346 -0
- package/dist/tailor-proto/src/tailor/v1/secret_manager_resource_pb.d.mts +54 -0
- package/dist/tailor-proto/src/tailor/v1/service_pb.d.mts +3576 -0
- package/dist/tailor-proto/src/tailor/v1/stateflow_pb.d.mts +187 -0
- package/dist/tailor-proto/src/tailor/v1/stateflow_resource_pb.d.mts +29 -0
- package/dist/tailor-proto/src/tailor/v1/staticwebsite_pb.d.mts +429 -0
- package/dist/tailor-proto/src/tailor/v1/staticwebsite_resource_pb.d.mts +90 -0
- package/dist/tailor-proto/src/tailor/v1/tailordb_pb.d.mts +684 -0
- package/dist/tailor-proto/src/tailor/v1/tailordb_resource_pb.d.mts +797 -0
- package/dist/tailor-proto/src/tailor/v1/telemetryrouter_pb.d.mts +330 -0
- package/dist/tailor-proto/src/tailor/v1/telemetryrouter_resource_pb.d.mts +183 -0
- package/dist/tailor-proto/src/tailor/v1/workflow_pb.d.mts +842 -0
- package/dist/tailor-proto/src/tailor/v1/workflow_resource_pb.d.mts +276 -0
- package/dist/tailor-proto/src/tailor/v1/workspace_pb.d.mts +2015 -0
- package/dist/tailor-proto/src/tailor/v1/workspace_resource_pb.d.mts +483 -0
- package/dist/{telemetry-BQbbVo2t.mjs → telemetry-CdqJEzkj.mjs} +2 -3
- package/dist/{telemetry-BQbbVo2t.mjs.map → telemetry-CdqJEzkj.mjs.map} +1 -1
- package/dist/telemetry-ClwW5ohF.mjs +3 -0
- package/dist/types/aigateway.generated.d.mts +9 -0
- package/dist/types/app-config.generated.d.mts +4 -0
- package/dist/types/auth-connection.generated.d.mts +20 -0
- package/dist/types/auth.generated.d.mts +150 -0
- package/dist/types/executor.generated.d.mts +177 -0
- package/dist/types/generator-config.generated.d.mts +28 -0
- package/dist/types/helpers.d.mts +39 -0
- package/dist/types/http-adapter.generated.d.mts +17 -0
- package/dist/types/idp.generated.d.mts +584 -0
- package/dist/types/resolver.generated.d.mts +38 -0
- package/dist/types/secrets.generated.d.mts +14 -0
- package/dist/types/staticwebsite.generated.d.mts +10 -0
- package/dist/{types-rj8YJcEe.d.mts → types/tailordb.generated.d.mts} +2 -290
- package/dist/types/workflow.generated.d.mts +12 -0
- package/dist/types-qhFZ8y9B.mjs +4 -0
- package/dist/{types-D4QMmNWh.mjs → types-ywCGpzDZ.mjs} +2 -3
- package/dist/{types-D4QMmNWh.mjs.map → types-ywCGpzDZ.mjs.map} +1 -1
- package/dist/utils/test/index.d.mts +6 -89
- package/dist/utils/test/index.mjs +1 -2
- package/dist/utils/test/index.mjs.map +1 -1
- package/dist/utils/test/mock.d.mts +87 -0
- package/dist/vitest/environment.d.mts +1 -2
- package/dist/vitest/environment.mjs +1 -2
- package/dist/vitest/environment.mjs.map +1 -1
- package/dist/vitest/index.d.mts +4 -392
- package/dist/vitest/index.mjs +4 -5
- package/dist/vitest/index.mjs.map +1 -1
- package/dist/vitest/mock-kysely.d.mts +62 -0
- package/dist/vitest/mock.d.mts +364 -0
- package/dist/vitest/setup.d.mts +1 -2
- package/dist/vitest/setup.mjs +2 -3
- package/dist/vitest/setup.mjs.map +1 -1
- package/dist/{workflow-C8I7shjM.mjs → workflow-DSwnYPPP.mjs} +10 -4
- package/dist/workflow-DSwnYPPP.mjs.map +1 -0
- package/docs/cli/setup.md +129 -19
- package/docs/cli-reference.md +9 -4
- package/docs/runtime.md +5 -1
- package/docs/services/aigateway.md +14 -0
- package/docs/testing.md +48 -2
- package/package.json +6 -1
- package/dist/application-DmjIKQ-a.mjs.map +0 -1
- package/dist/application-a_ApFuPh.mjs +0 -4
- package/dist/authconnection-CqfaJfrC.d.mts +0 -32
- package/dist/context-CUBwSBq4.d.mts +0 -68
- package/dist/file-BzK8z3X-.d.mts +0 -250
- package/dist/globals-ByrCoDip.mjs.map +0 -1
- package/dist/iconv-kwrmd1U_.d.mts +0 -122
- package/dist/idp-BmYwCXnJ.d.mts +0 -187
- package/dist/index-BDBU7x-i.d.mts +0 -18
- package/dist/index-BSlv_YrG.d.mts +0 -46
- package/dist/index-BzGqTY5x.d.mts +0 -1315
- package/dist/index-D3_Au3wu.d.mts +0 -47
- package/dist/index-DtFRlrww.d.mts +0 -18
- package/dist/index-jeE3UvF2.d.mts +0 -18
- package/dist/mock-wf5qeZLi.mjs.map +0 -1
- package/dist/package-json-wzO6nV9O.mjs +0 -4
- package/dist/runtime-Cd375HD-.mjs.map +0 -1
- package/dist/secretmanager-CKLB3wAQ.d.mts +0 -55
- package/dist/service-CRaa4Joe.mjs +0 -4
- package/dist/service-DDWgZL_L2.mjs.map +0 -1
- package/dist/telemetry-w92bvGdC.mjs +0 -4
- package/dist/types-32lUMToj.mjs +0 -5
- package/dist/types-aqnqTCfO.d.mts +0 -602
- package/dist/workflow-C8I7shjM.mjs.map +0 -1
- package/dist/workflow-CMamswkK.d.mts +0 -96
- package/dist/workflow.generated-Da1zECDw.d.mts +0 -1348
|
@@ -0,0 +1,149 @@
|
|
|
1
|
+
import { InferredAttributeMap, TailorUser } from "../../../runtime/types.mjs";
|
|
2
|
+
import { InferFieldsOutput, Prettify, output } from "../../../types/helpers.mjs";
|
|
3
|
+
import { DefinedFieldMetadata, FieldMetadata, TailorField } from "../../types/field.types.mjs";
|
|
4
|
+
import { DBFieldMetadata as DBFieldMetadata$1, GqlOperationsInput, RawPermissions, TailorDBServiceConfigInput } from "../../../types/tailordb.generated.mjs";
|
|
5
|
+
import { NonEmptyObject } from "type-fest";
|
|
6
|
+
|
|
7
|
+
//#region src/configure/services/tailordb/types.d.ts
|
|
8
|
+
type SerialConfig<T extends "string" | "integer" = "string" | "integer"> = Prettify<{
|
|
9
|
+
start: number;
|
|
10
|
+
maxValue?: number;
|
|
11
|
+
} & (T extends "string" ? {
|
|
12
|
+
format?: string;
|
|
13
|
+
} : object)>;
|
|
14
|
+
interface DBFieldMetadata extends FieldMetadata {
|
|
15
|
+
index?: boolean;
|
|
16
|
+
unique?: boolean;
|
|
17
|
+
vector?: boolean;
|
|
18
|
+
foreignKey?: boolean;
|
|
19
|
+
foreignKeyType?: string;
|
|
20
|
+
foreignKeyField?: string;
|
|
21
|
+
/** Lifecycle hooks for the field */
|
|
22
|
+
hooks?: DBFieldMetadata$1["hooks"];
|
|
23
|
+
serial?: SerialConfig;
|
|
24
|
+
relation?: boolean;
|
|
25
|
+
scale?: number;
|
|
26
|
+
}
|
|
27
|
+
interface DefinedDBFieldMetadata extends DefinedFieldMetadata {
|
|
28
|
+
index?: boolean;
|
|
29
|
+
unique?: boolean;
|
|
30
|
+
vector?: boolean;
|
|
31
|
+
foreignKey?: boolean;
|
|
32
|
+
foreignKeyType?: boolean;
|
|
33
|
+
validate?: boolean;
|
|
34
|
+
hooks?: {
|
|
35
|
+
create: boolean;
|
|
36
|
+
update: boolean;
|
|
37
|
+
};
|
|
38
|
+
serial?: boolean;
|
|
39
|
+
relation?: boolean;
|
|
40
|
+
}
|
|
41
|
+
type GqlOperationsConfig = GqlOperationsInput;
|
|
42
|
+
interface RawRelationConfig {
|
|
43
|
+
type: "1-1" | "n-1" | "keyOnly" | "oneToOne" | "manyToOne" | "N-1";
|
|
44
|
+
toward: {
|
|
45
|
+
type: string;
|
|
46
|
+
as?: string;
|
|
47
|
+
key?: string;
|
|
48
|
+
};
|
|
49
|
+
backward?: string;
|
|
50
|
+
}
|
|
51
|
+
interface TailorDBTypeMetadata {
|
|
52
|
+
name: string;
|
|
53
|
+
description?: string;
|
|
54
|
+
settings?: {
|
|
55
|
+
pluralForm?: string;
|
|
56
|
+
aggregation?: boolean;
|
|
57
|
+
bulkUpsert?: boolean;
|
|
58
|
+
gqlOperations?: GqlOperationsConfig;
|
|
59
|
+
publishEvents?: boolean;
|
|
60
|
+
};
|
|
61
|
+
permissions: RawPermissions;
|
|
62
|
+
files: Record<string, string>;
|
|
63
|
+
indexes?: Record<string, {
|
|
64
|
+
fields: string[];
|
|
65
|
+
unique?: boolean;
|
|
66
|
+
}>;
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* Minimal structural interface for TailorDBField.
|
|
70
|
+
* Defines only the properties needed by parser, plugin, cli, and types layers.
|
|
71
|
+
* The full interface with builder methods (relation, index, unique, hooks, validate, etc.)
|
|
72
|
+
* is defined in configure/services/tailordb/schema.ts.
|
|
73
|
+
*/
|
|
74
|
+
interface TailorDBField<Defined extends DefinedDBFieldMetadata = DefinedDBFieldMetadata, Output = any> extends Omit<TailorField<Defined, Output, DBFieldMetadata, Defined["type"]>, "fields"> {
|
|
75
|
+
readonly fields: Record<string, TailorAnyDBField>;
|
|
76
|
+
readonly rawRelation: Readonly<RawRelationConfig> | undefined;
|
|
77
|
+
}
|
|
78
|
+
type TailorAnyDBField = TailorDBField<any, any>;
|
|
79
|
+
/**
|
|
80
|
+
* Minimal structural interface for TailorDBType.
|
|
81
|
+
* Defines only the properties needed by parser, plugin, cli, and types layers.
|
|
82
|
+
* The full interface with builder methods (hooks, validate, features, permission, etc.)
|
|
83
|
+
* is defined in configure/services/tailordb/schema.ts.
|
|
84
|
+
*/
|
|
85
|
+
interface TailorDBType<Fields extends Record<string, TailorAnyDBField> = any, User extends object = InferredAttributeMap> {
|
|
86
|
+
readonly name: string;
|
|
87
|
+
readonly fields: Fields;
|
|
88
|
+
readonly _output: InferFieldsOutput<Fields>;
|
|
89
|
+
readonly metadata: TailorDBTypeMetadata;
|
|
90
|
+
readonly plugins: PluginAttachment[];
|
|
91
|
+
}
|
|
92
|
+
type TailorAnyDBType = TailorDBType<any, any>;
|
|
93
|
+
type TailorDBInstance<Fields extends Record<string, TailorAnyDBField> = any, User extends object = InferredAttributeMap> = TailorDBType<Fields, User>;
|
|
94
|
+
type HookFn<TValue, TData, TReturn> = (args: {
|
|
95
|
+
value: TValue;
|
|
96
|
+
data: TData extends Record<string, unknown> ? { readonly [K in keyof TData]?: TData[K] | null | undefined } : unknown;
|
|
97
|
+
user: TailorUser;
|
|
98
|
+
}) => TReturn;
|
|
99
|
+
type Hook<TData, TReturn> = {
|
|
100
|
+
create?: HookFn<TReturn | null, TData, TReturn>;
|
|
101
|
+
update?: HookFn<TReturn | null, TData, TReturn>;
|
|
102
|
+
};
|
|
103
|
+
type Hooks<F extends Record<string, TailorAnyDBField>, TData = { [K in keyof F]: output<F[K]> }> = NonEmptyObject<{ [K in Exclude<keyof F, "id"> as F[K]["_defined"] extends {
|
|
104
|
+
hooks: unknown;
|
|
105
|
+
} ? never : F[K]["_defined"] extends {
|
|
106
|
+
type: "nested";
|
|
107
|
+
} ? never : K]?: Hook<TData, output<F[K]>> }>;
|
|
108
|
+
type ExcludeNestedDBFields<T extends Record<string, TailorAnyDBField>> = { [K in keyof T]: T[K] extends TailorDBField<{
|
|
109
|
+
type: "nested";
|
|
110
|
+
array: boolean;
|
|
111
|
+
}, any> ? never : T[K] };
|
|
112
|
+
interface TypeFeatures {
|
|
113
|
+
pluralForm?: string;
|
|
114
|
+
aggregation?: true;
|
|
115
|
+
bulkUpsert?: true;
|
|
116
|
+
/** Configure GraphQL operations for this type. Use "query" for read-only mode, or an object for granular control. */
|
|
117
|
+
gqlOperations?: GqlOperationsConfig;
|
|
118
|
+
/**
|
|
119
|
+
* Enable publishing events for this type.
|
|
120
|
+
* When enabled, record creation/update/deletion events are published.
|
|
121
|
+
* If not specified, this is automatically set to true when an executor uses this type
|
|
122
|
+
* with recordCreated/recordUpdated/recordDeleted triggers. If explicitly set to false
|
|
123
|
+
* while an executor uses this type, an error will be thrown during apply.
|
|
124
|
+
*/
|
|
125
|
+
publishEvents?: boolean;
|
|
126
|
+
}
|
|
127
|
+
/**
|
|
128
|
+
* Plugin attachment stored on TailorAnyDBType instances.
|
|
129
|
+
*/
|
|
130
|
+
interface PluginAttachment {
|
|
131
|
+
pluginId: string;
|
|
132
|
+
config: unknown;
|
|
133
|
+
}
|
|
134
|
+
type IndexDef<T extends {
|
|
135
|
+
fields: Record<PropertyKey, unknown>;
|
|
136
|
+
}> = {
|
|
137
|
+
fields: [keyof T["fields"], keyof T["fields"], ...(keyof T["fields"])[]];
|
|
138
|
+
unique?: boolean;
|
|
139
|
+
name?: string;
|
|
140
|
+
};
|
|
141
|
+
type RelationType = "1-1" | "oneToOne" | "n-1" | "manyToOne" | "N-1" | "keyOnly";
|
|
142
|
+
type TailorDBExternalConfig = {
|
|
143
|
+
external: true;
|
|
144
|
+
};
|
|
145
|
+
type TailorDBServiceInput = {
|
|
146
|
+
[namespace: string]: TailorDBServiceConfigInput | TailorDBExternalConfig;
|
|
147
|
+
};
|
|
148
|
+
//#endregion
|
|
149
|
+
export { DBFieldMetadata, DefinedDBFieldMetadata, ExcludeNestedDBFields, GqlOperationsConfig, Hook, Hooks, IndexDef, PluginAttachment, RawRelationConfig, RelationType, SerialConfig, TailorAnyDBField, TailorAnyDBType, TailorDBExternalConfig, TailorDBField, TailorDBInstance, TailorDBServiceInput, TailorDBType, TailorDBTypeMetadata, TypeFeatures };
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { WorkflowServiceConfig, WorkflowServiceInput } from "../../config/types.mjs";
|
|
2
|
+
import { ConcurrencyPolicy, RetryPolicy } from "../../../types/workflow.generated.mjs";
|
|
3
|
+
import { WORKFLOW_TEST_ENV_KEY } from "./test-env-key.mjs";
|
|
4
|
+
import { WorkflowJob, WorkflowJobContext, createWorkflowJob } from "./job.mjs";
|
|
5
|
+
import { Workflow, WorkflowConfig, createWorkflow } from "./workflow.mjs";
|
|
6
|
+
import { WaitPointInstance, defineWaitPoint, defineWaitPoints } from "./wait-point.mjs";
|
|
7
|
+
export { type ConcurrencyPolicy, type RetryPolicy, WORKFLOW_TEST_ENV_KEY, WaitPointInstance, Workflow, WorkflowConfig, WorkflowJob, WorkflowJobContext, type WorkflowServiceConfig, type WorkflowServiceInput, createWorkflow, createWorkflowJob, defineWaitPoint, defineWaitPoints };
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
import { TailorEnv, TailorInvoker } from "../../../runtime/types.mjs";
|
|
2
|
+
import { JsonCompatible } from "../../../types/helpers.mjs";
|
|
3
|
+
import { WORKFLOW_TEST_ENV_KEY } from "./test-env-key.mjs";
|
|
4
|
+
|
|
5
|
+
//#region src/configure/services/workflow/job.d.ts
|
|
6
|
+
/**
|
|
7
|
+
* Context object passed as the second argument to workflow job body functions.
|
|
8
|
+
*/
|
|
9
|
+
type WorkflowJobContext = {
|
|
10
|
+
env: TailorEnv;
|
|
11
|
+
invoker?: TailorInvoker;
|
|
12
|
+
};
|
|
13
|
+
/**
|
|
14
|
+
* The body function type for a workflow job.
|
|
15
|
+
* Resolves to the callable signature when `I` / `O` are JsonValue-compatible,
|
|
16
|
+
* or to a template-literal error string that surfaces at the `body:` property.
|
|
17
|
+
*/
|
|
18
|
+
type JobBody<I, O> = [null] extends [I] ? "ERROR: Input cannot be null at the top level" : [I] extends [undefined] ? [O] extends [JsonCompatible<O> | undefined | void] ? (input: I, context: WorkflowJobContext) => O | Promise<O> : "ERROR: Output must be JsonValue-compatible (plain objects/arrays; no class instances or functions)" : [undefined] extends [I] ? "ERROR: Input cannot include undefined at the top level" : [I] extends [JsonCompatible<I>] ? [O] extends [JsonCompatible<O> | undefined | void] ? (input: I, context: WorkflowJobContext) => O | Promise<O> : "ERROR: Output must be JsonValue-compatible (plain objects/arrays; no class instances or functions)" : "ERROR: Input must be JsonValue-compatible (plain objects/arrays; no class instances or functions)";
|
|
19
|
+
/**
|
|
20
|
+
* WorkflowJob represents a job that can be triggered in a workflow.
|
|
21
|
+
*
|
|
22
|
+
* Type constraints:
|
|
23
|
+
* - Input: Must be JsonValue-compatible (plain objects/arrays; no class instances or functions) or undefined.
|
|
24
|
+
* - Output: Must be JsonValue-compatible (plain objects/arrays; no class instances or functions), undefined, or void.
|
|
25
|
+
* - Trigger returns `Awaited<Output>` as-is (no Jsonify transformation).
|
|
26
|
+
*/
|
|
27
|
+
interface WorkflowJob<Name extends string = string, Input = undefined, Output = undefined> {
|
|
28
|
+
name: Name;
|
|
29
|
+
/**
|
|
30
|
+
* Trigger this job with the given input. Returns a Promise that resolves
|
|
31
|
+
* to the job's output value.
|
|
32
|
+
* @example
|
|
33
|
+
* body: async (input) => {
|
|
34
|
+
* const a = await jobA.trigger({ id: input.id });
|
|
35
|
+
* const b = await jobB.trigger({ id: input.id });
|
|
36
|
+
* return { a, b };
|
|
37
|
+
* }
|
|
38
|
+
*/
|
|
39
|
+
trigger: [Input] extends [undefined] ? () => Promise<Awaited<Output>> : (input: Input) => Promise<Awaited<Output>>;
|
|
40
|
+
body: (input: Input, context: WorkflowJobContext) => Output | Promise<Output>;
|
|
41
|
+
}
|
|
42
|
+
interface CreateWorkflowJobConfig<Name extends string, I, O> {
|
|
43
|
+
readonly name: Name;
|
|
44
|
+
readonly body: JobBody<I, O>;
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
* Create a workflow job definition.
|
|
48
|
+
*
|
|
49
|
+
* All jobs must be named exports from the workflow file.
|
|
50
|
+
* Job names must be unique across the entire project.
|
|
51
|
+
*
|
|
52
|
+
* Input and output must be JsonValue-compatible (primitives, plain objects, arrays).
|
|
53
|
+
* Functions and objects with a `toJSON` method are rejected at the type level;
|
|
54
|
+
* class instances exposing methods are rejected via the property walk.
|
|
55
|
+
* @param config - Job configuration with name and body function.
|
|
56
|
+
* @param config.name - Unique job name across the project.
|
|
57
|
+
* @param config.body - Async function that processes the job input.
|
|
58
|
+
* @returns A WorkflowJob that can be triggered from other jobs.
|
|
59
|
+
* @example
|
|
60
|
+
* // Simple job with async body:
|
|
61
|
+
* export const fetchData = createWorkflowJob({
|
|
62
|
+
* name: "fetch-data",
|
|
63
|
+
* body: async (input: { id: string }) => {
|
|
64
|
+
* const db = getDB("tailordb");
|
|
65
|
+
* return await db.selectFrom("Table").selectAll().where("id", "=", input.id).executeTakeFirst();
|
|
66
|
+
* },
|
|
67
|
+
* });
|
|
68
|
+
* @example
|
|
69
|
+
* // Orchestrator job that fans out to other jobs.
|
|
70
|
+
* export const orchestrate = createWorkflowJob({
|
|
71
|
+
* name: "orchestrate",
|
|
72
|
+
* body: async (input: { orderId: string }) => {
|
|
73
|
+
* const inventory = await checkInventory.trigger({ orderId: input.orderId });
|
|
74
|
+
* const payment = await processPayment.trigger({ orderId: input.orderId });
|
|
75
|
+
* return { inventory, payment };
|
|
76
|
+
* },
|
|
77
|
+
* });
|
|
78
|
+
*/
|
|
79
|
+
declare function createWorkflowJob<const Name extends string, I = undefined, O = undefined>(config: CreateWorkflowJobConfig<Name, I, O>): WorkflowJob<Name, I, Awaited<O>>;
|
|
80
|
+
//#endregion
|
|
81
|
+
export { WORKFLOW_TEST_ENV_KEY, WorkflowJob, WorkflowJobContext, createWorkflowJob };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
//#region src/configure/services/workflow/test-env-key.d.ts
|
|
2
|
+
/**
|
|
3
|
+
* Env-var fallback read by `.trigger()` when `mockWorkflow().setEnv()` is unset.
|
|
4
|
+
* @deprecated Use `mockWorkflow().setEnv()` from `@tailor-platform/sdk/vitest`.
|
|
5
|
+
* @internal
|
|
6
|
+
*/
|
|
7
|
+
declare const WORKFLOW_TEST_ENV_KEY = "TAILOR_TEST_WORKFLOW_ENV";
|
|
8
|
+
//#endregion
|
|
9
|
+
export { WORKFLOW_TEST_ENV_KEY };
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import { JsonCompatible } from "../../../types/helpers.mjs";
|
|
2
|
+
|
|
3
|
+
//#region src/configure/services/workflow/wait-point.d.ts
|
|
4
|
+
/**
|
|
5
|
+
* A single wait point instance with typed `.wait()` and `.resolve()` methods.
|
|
6
|
+
*
|
|
7
|
+
* - `.wait(payload?)` suspends execution until resolved. Returns the result from `.resolve()`.
|
|
8
|
+
* - `.resolve(executionId, callback)` resumes a suspended execution.
|
|
9
|
+
*
|
|
10
|
+
* Both `Payload` and `Result` must be JsonValue-compatible (primitives, plain objects, arrays).
|
|
11
|
+
* Functions and objects with a `toJSON` method are rejected at the type level.
|
|
12
|
+
*/
|
|
13
|
+
interface WaitPointInstance<Payload = undefined, Result = undefined> {
|
|
14
|
+
wait: [Payload] extends [undefined] ? () => Promise<Result> : (payload: Payload) => Promise<Result>;
|
|
15
|
+
resolve: (executionId: string, callback: (payload: [Payload] extends [undefined] ? undefined : Payload) => Result | Promise<Result>) => Promise<void>;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* The type produced by `define<Payload, Result>()` / `defineWaitPoint<Payload, Result>(key)`.
|
|
19
|
+
* Resolves to `WaitPointInstance<Payload, Result>` when both types are JsonValue-compatible,
|
|
20
|
+
* or to a template-literal error string that surfaces at the call site.
|
|
21
|
+
*/
|
|
22
|
+
type WaitPointDef<Payload, Result> = [null] extends [Payload] ? "ERROR: Payload cannot be null at the top level" : [undefined] extends [Result] ? "ERROR: Result cannot be (or include) undefined (resolve callback must return a value)" : [Payload] extends [undefined] ? [Result] extends [JsonCompatible<Result>] ? WaitPointInstance<Payload, Result> : "ERROR: Result must be JsonValue-compatible (plain objects/arrays; no class instances or functions)" : [undefined] extends [Payload] ? "ERROR: Payload cannot include undefined at the top level" : [Payload] extends [JsonCompatible<Payload>] ? [Result] extends [JsonCompatible<Result>] ? WaitPointInstance<Payload, Result> : "ERROR: Result must be JsonValue-compatible (plain objects/arrays; no class instances or functions)" : "ERROR: Payload must be JsonValue-compatible (plain objects/arrays; no class instances or functions)";
|
|
23
|
+
/**
|
|
24
|
+
* The `define` function passed to the `defineWaitPoints` builder callback.
|
|
25
|
+
* Returns an actual WaitPointInstance (not a phantom marker) so that the
|
|
26
|
+
* builder's return type can flow through as-is, preserving JSDoc comments
|
|
27
|
+
* on each property for IDE autocompletion.
|
|
28
|
+
*
|
|
29
|
+
* JSON validation is encoded in the return type rather than in type-parameter
|
|
30
|
+
* constraints, because tsgo rejects self-referential constraints like
|
|
31
|
+
* `Payload extends JsonCompatible<Payload>` as circular.
|
|
32
|
+
*/
|
|
33
|
+
type DefineFn = <Payload = undefined, Result = undefined>() => WaitPointDef<Payload, Result>;
|
|
34
|
+
/**
|
|
35
|
+
* Define a single typed wait point with an explicit key.
|
|
36
|
+
*
|
|
37
|
+
* `Payload` and `Result` must be JsonValue-compatible.
|
|
38
|
+
* Functions and objects with a `toJSON` method are rejected at the type level;
|
|
39
|
+
* class instances exposing methods are rejected via the property walk.
|
|
40
|
+
* @param key - The wait point key used to match wait and resolve calls
|
|
41
|
+
* @returns A WaitPointInstance with typed `.wait()` and `.resolve()` methods
|
|
42
|
+
* @example
|
|
43
|
+
* export const approval = defineWaitPoint<{ message: string }, { approved: boolean }>("approval");
|
|
44
|
+
*
|
|
45
|
+
* await approval.wait({ message: "Please approve" });
|
|
46
|
+
*/
|
|
47
|
+
declare function defineWaitPoint<Payload = undefined, Result = undefined>(key: string): WaitPointDef<Payload, Result>;
|
|
48
|
+
/**
|
|
49
|
+
* Define a group of typed wait points for human-in-the-loop workflows.
|
|
50
|
+
* Property names become the wait point keys.
|
|
51
|
+
*
|
|
52
|
+
* The return type is the same as the builder's return type, so JSDoc on each
|
|
53
|
+
* property is preserved and visible in IDE autocompletion.
|
|
54
|
+
*
|
|
55
|
+
* `Payload` and `Result` must be JsonValue-compatible.
|
|
56
|
+
* Functions and objects with a `toJSON` method are rejected at the type level;
|
|
57
|
+
* class instances exposing methods are rejected via the property walk.
|
|
58
|
+
* @param builder - Callback that receives a `define` factory and returns an object of wait points
|
|
59
|
+
* @returns The same object returned by the builder (with correct keys set on each instance)
|
|
60
|
+
* @example
|
|
61
|
+
* export const waitPoints = defineWaitPoints(define => ({
|
|
62
|
+
* // Preceding JSDoc on this property is shown in IDE autocompletion
|
|
63
|
+
* approval: define<{ message: string }, { approved: boolean }>(),
|
|
64
|
+
* }));
|
|
65
|
+
*
|
|
66
|
+
* // IDE shows the JSDoc when typing `waitPoints.`
|
|
67
|
+
* await waitPoints.approval.wait({ message: "Please approve" });
|
|
68
|
+
*
|
|
69
|
+
* // For 2-level access, use destructured export with JSDoc attached to the export itself.
|
|
70
|
+
*/
|
|
71
|
+
declare function defineWaitPoints<T extends Record<string, WaitPointInstance<any, any>>>(builder: (define: DefineFn) => T): T;
|
|
72
|
+
//#endregion
|
|
73
|
+
export { WaitPointInstance, defineWaitPoint, defineWaitPoints };
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { ConcurrencyPolicy, RetryPolicy } from "../../../types/workflow.generated.mjs";
|
|
2
|
+
import { MachineUserName } from "../../types/machine-user.mjs";
|
|
3
|
+
import { AuthInvoker } from "../auth/index.mjs";
|
|
4
|
+
import { WorkflowJob } from "./job.mjs";
|
|
5
|
+
|
|
6
|
+
//#region src/configure/services/workflow/workflow.d.ts
|
|
7
|
+
interface WorkflowConfig<Job extends WorkflowJob<any, any, any> = WorkflowJob<any, any, any>> {
|
|
8
|
+
name: string;
|
|
9
|
+
mainJob: Job;
|
|
10
|
+
retryPolicy?: RetryPolicy;
|
|
11
|
+
concurrencyPolicy?: ConcurrencyPolicy;
|
|
12
|
+
}
|
|
13
|
+
interface Workflow<Job extends WorkflowJob<any, any, any> = WorkflowJob<any, any, any>> {
|
|
14
|
+
name: string;
|
|
15
|
+
mainJob: Job;
|
|
16
|
+
retryPolicy?: RetryPolicy;
|
|
17
|
+
concurrencyPolicy?: ConcurrencyPolicy;
|
|
18
|
+
trigger: (args: Parameters<Job["trigger"]>[0], options?: {
|
|
19
|
+
authInvoker: AuthInvoker<string> | MachineUserName;
|
|
20
|
+
}) => Promise<string>;
|
|
21
|
+
}
|
|
22
|
+
interface WorkflowDefinition<Job extends WorkflowJob<any, any, any>> {
|
|
23
|
+
name: string;
|
|
24
|
+
mainJob: Job;
|
|
25
|
+
retryPolicy?: RetryPolicy;
|
|
26
|
+
concurrencyPolicy?: ConcurrencyPolicy;
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* Create a workflow definition that can be triggered via the Tailor SDK.
|
|
30
|
+
* In production, bundler transforms .trigger() calls to tailor.workflow.triggerWorkflow().
|
|
31
|
+
*
|
|
32
|
+
* The workflow MUST be the default export of the file.
|
|
33
|
+
* All jobs referenced by the workflow MUST be named exports.
|
|
34
|
+
* @template Job
|
|
35
|
+
* @param config - Workflow configuration
|
|
36
|
+
* @returns Defined workflow
|
|
37
|
+
* @example
|
|
38
|
+
* export const fetchData = createWorkflowJob({ name: "fetch-data", body: async (input: { id: string }) => ({ id: input.id }) });
|
|
39
|
+
* export const processData = createWorkflowJob({
|
|
40
|
+
* name: "process-data",
|
|
41
|
+
* body: async (input: { id: string }) => {
|
|
42
|
+
* const data = await fetchData.trigger({ id: input.id });
|
|
43
|
+
* return { data };
|
|
44
|
+
* },
|
|
45
|
+
* });
|
|
46
|
+
*
|
|
47
|
+
* // Workflow must be default export; mainJob is the entry point
|
|
48
|
+
* export default createWorkflow({
|
|
49
|
+
* name: "data-processing",
|
|
50
|
+
* mainJob: processData,
|
|
51
|
+
* });
|
|
52
|
+
*/
|
|
53
|
+
declare function createWorkflow<Job extends WorkflowJob<any, any, any>>(config: WorkflowDefinition<Job>): Workflow<Job>;
|
|
54
|
+
//#endregion
|
|
55
|
+
export { type ConcurrencyPolicy, type RetryPolicy, Workflow, WorkflowConfig, createWorkflow };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
//#region src/configure/types/aigateway-name.d.ts
|
|
2
|
+
interface AIGatewayNameRegistry {}
|
|
3
|
+
/**
|
|
4
|
+
* AI Gateway name.
|
|
5
|
+
*
|
|
6
|
+
* When `tailor.d.ts` is generated (via `tailor-sdk deploy`/`generate`), this is narrowed
|
|
7
|
+
* to the union of AI Gateway names defined via `defineAIGateway()`. Falls back to
|
|
8
|
+
* `string` before the first generate run.
|
|
9
|
+
*/
|
|
10
|
+
type AIGatewayName = keyof AIGatewayNameRegistry extends never ? string : keyof AIGatewayNameRegistry & string;
|
|
11
|
+
//#endregion
|
|
12
|
+
export { AIGatewayName, AIGatewayNameRegistry };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
//#region src/configure/types/connection-name.d.ts
|
|
2
|
+
interface ConnectionNameRegistry {}
|
|
3
|
+
/**
|
|
4
|
+
* Auth connection name.
|
|
5
|
+
*
|
|
6
|
+
* When `tailor.d.ts` is generated (via `tailor-sdk deploy`/`generate`), this is narrowed
|
|
7
|
+
* to the union of connection names defined in `defineAuth()`'s `connections`. Falls back
|
|
8
|
+
* to `string` before the first generate run.
|
|
9
|
+
*/
|
|
10
|
+
type ConnectionName = keyof ConnectionNameRegistry extends never ? string : keyof ConnectionNameRegistry & string;
|
|
11
|
+
//#endregion
|
|
12
|
+
export { ConnectionName, ConnectionNameRegistry };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { EnumValue } from "./field.types.mjs";
|
|
2
|
+
|
|
3
|
+
//#region src/configure/types/field.d.ts
|
|
4
|
+
type AllowedValues = readonly [string | EnumValue, ...(string | EnumValue)[]];
|
|
5
|
+
type AllowedValuesOutput<V extends AllowedValues> = V[number] extends infer T ? T extends string ? T : T extends {
|
|
6
|
+
value: infer K;
|
|
7
|
+
} ? K : never : never;
|
|
8
|
+
//#endregion
|
|
9
|
+
export { AllowedValues, AllowedValuesOutput };
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
import { TailorUser } from "../../runtime/types.mjs";
|
|
2
|
+
import { InferFieldsOutput, output } from "../../types/helpers.mjs";
|
|
3
|
+
import { NonEmptyObject } from "type-fest";
|
|
4
|
+
|
|
5
|
+
//#region src/configure/types/field.types.d.ts
|
|
6
|
+
interface EnumValue {
|
|
7
|
+
value: string;
|
|
8
|
+
description?: string;
|
|
9
|
+
}
|
|
10
|
+
type TailorFieldType = "uuid" | "string" | "boolean" | "integer" | "float" | "decimal" | "enum" | "date" | "datetime" | "time" | "nested";
|
|
11
|
+
type TailorToTs = {
|
|
12
|
+
string: string;
|
|
13
|
+
integer: number;
|
|
14
|
+
float: number;
|
|
15
|
+
decimal: string;
|
|
16
|
+
boolean: boolean;
|
|
17
|
+
uuid: string;
|
|
18
|
+
date: string;
|
|
19
|
+
datetime: string | Date;
|
|
20
|
+
time: string;
|
|
21
|
+
enum: string;
|
|
22
|
+
object: Record<string, unknown>;
|
|
23
|
+
nested: Record<string, unknown>;
|
|
24
|
+
} & Record<TailorFieldType, unknown>;
|
|
25
|
+
interface FieldMetadata {
|
|
26
|
+
description?: string;
|
|
27
|
+
required?: boolean;
|
|
28
|
+
array?: boolean;
|
|
29
|
+
allowedValues?: EnumValue[];
|
|
30
|
+
validate?: FieldValidateInput<any>[];
|
|
31
|
+
typeName?: string;
|
|
32
|
+
}
|
|
33
|
+
interface DefinedFieldMetadata {
|
|
34
|
+
type: TailorFieldType;
|
|
35
|
+
array: boolean;
|
|
36
|
+
description?: boolean;
|
|
37
|
+
validate?: boolean;
|
|
38
|
+
typeName?: boolean;
|
|
39
|
+
}
|
|
40
|
+
type FieldOptions = {
|
|
41
|
+
optional?: boolean;
|
|
42
|
+
array?: boolean;
|
|
43
|
+
};
|
|
44
|
+
type FieldOutput<T, O extends FieldOptions> = OptionalFieldOutput<ArrayFieldOutput<T, O>, O>;
|
|
45
|
+
type OptionalFieldOutput<T, O extends FieldOptions> = O["optional"] extends true ? T | null : T;
|
|
46
|
+
type ArrayFieldOutput<T, O extends FieldOptions> = [O] extends [{
|
|
47
|
+
array: true;
|
|
48
|
+
}] ? T[] : T;
|
|
49
|
+
/**
|
|
50
|
+
* Validation function type
|
|
51
|
+
*/
|
|
52
|
+
type ValidateFn<O, D = unknown> = (args: {
|
|
53
|
+
value: O;
|
|
54
|
+
data: D;
|
|
55
|
+
user: TailorUser;
|
|
56
|
+
}) => boolean;
|
|
57
|
+
/**
|
|
58
|
+
* Validation configuration with custom error message
|
|
59
|
+
*/
|
|
60
|
+
type ValidateConfig<O, D = unknown> = [ValidateFn<O, D>, string];
|
|
61
|
+
/**
|
|
62
|
+
* Field-level validation function
|
|
63
|
+
*/
|
|
64
|
+
type FieldValidateFn<O> = ValidateFn<O>;
|
|
65
|
+
/**
|
|
66
|
+
* Field-level validation configuration
|
|
67
|
+
*/
|
|
68
|
+
type FieldValidateConfig<O> = ValidateConfig<O>;
|
|
69
|
+
/**
|
|
70
|
+
* Input type for field validation - can be either a function or a tuple of [function, errorMessage]
|
|
71
|
+
*/
|
|
72
|
+
type FieldValidateInput<O> = FieldValidateFn<O> | FieldValidateConfig<O>;
|
|
73
|
+
/**
|
|
74
|
+
* Base validators type for field collections
|
|
75
|
+
* @template F - Record of fields
|
|
76
|
+
* @template ExcludeKeys - Keys to exclude from validation (default: "id" for TailorDB)
|
|
77
|
+
*/
|
|
78
|
+
type ValidatorsBase<F extends Record<string, {
|
|
79
|
+
_defined: any;
|
|
80
|
+
_output: any;
|
|
81
|
+
[key: string]: any;
|
|
82
|
+
}>, ExcludeKeys extends string = "id"> = NonEmptyObject<{ [K in Exclude<keyof F, ExcludeKeys> as F[K]["_defined"] extends {
|
|
83
|
+
validate: unknown;
|
|
84
|
+
} ? never : K]?: ValidateFn<output<F[K]>, InferFieldsOutput<F>> | ValidateConfig<output<F[K]>, InferFieldsOutput<F>> | (ValidateFn<output<F[K]>, InferFieldsOutput<F>> | ValidateConfig<output<F[K]>, InferFieldsOutput<F>>)[] }>;
|
|
85
|
+
/**
|
|
86
|
+
* Validators type (by default excludes "id" field for TailorDB compatibility)
|
|
87
|
+
* Can be used with both TailorField and TailorDBField
|
|
88
|
+
*/
|
|
89
|
+
type Validators<F extends Record<string, {
|
|
90
|
+
_defined: any;
|
|
91
|
+
_output: any;
|
|
92
|
+
[key: string]: any;
|
|
93
|
+
}>> = ValidatorsBase<F, "id">;
|
|
94
|
+
/**
|
|
95
|
+
* Minimal structural interface for TailorField.
|
|
96
|
+
* Defines only the properties needed by parser, plugin, cli, and types layers.
|
|
97
|
+
* The full interface with builder methods (description, typeName, validate, parse)
|
|
98
|
+
* is defined in configure/types/type.ts.
|
|
99
|
+
*/
|
|
100
|
+
interface TailorField<Defined extends DefinedFieldMetadata = DefinedFieldMetadata, Output = any, M extends FieldMetadata = FieldMetadata, T extends TailorFieldType = TailorFieldType> {
|
|
101
|
+
readonly type: T;
|
|
102
|
+
readonly fields: Record<string, TailorAnyField>;
|
|
103
|
+
readonly _defined: Defined;
|
|
104
|
+
readonly _output: Output;
|
|
105
|
+
readonly metadata: M;
|
|
106
|
+
}
|
|
107
|
+
type TailorAnyField = TailorField<any>;
|
|
108
|
+
//#endregion
|
|
109
|
+
export { ArrayFieldOutput, DefinedFieldMetadata, EnumValue, FieldMetadata, FieldOptions, FieldOutput, FieldValidateInput, TailorAnyField, TailorField, TailorFieldType, TailorToTs, ValidateConfig, ValidateFn, Validators };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
//#region src/configure/types/idp-name.d.ts
|
|
2
|
+
interface IdpNameRegistry {}
|
|
3
|
+
/**
|
|
4
|
+
* IdP namespace name.
|
|
5
|
+
*
|
|
6
|
+
* When `tailor.d.ts` is generated (via `tailor-sdk deploy`/`generate`), this is narrowed
|
|
7
|
+
* to the union of defined IdP names. When no IdPs are registered yet, falls back to
|
|
8
|
+
* `string` to avoid blocking editing before the first generate run.
|
|
9
|
+
*/
|
|
10
|
+
type IdpName = keyof IdpNameRegistry extends never ? string : keyof IdpNameRegistry & string;
|
|
11
|
+
//#endregion
|
|
12
|
+
export { IdpName, IdpNameRegistry };
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { AllowedValues, AllowedValuesOutput } from "./field.mjs";
|
|
2
|
+
import { TailorAnyField, TailorField } from "./type.mjs";
|
|
3
|
+
import { MachineUserName, MachineUserNameRegistry } from "./machine-user.mjs";
|
|
4
|
+
export { AllowedValues, AllowedValuesOutput, MachineUserName, MachineUserNameRegistry, TailorAnyField, TailorField };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
//#region src/configure/types/machine-user.d.ts
|
|
2
|
+
interface MachineUserNameRegistry {}
|
|
3
|
+
/**
|
|
4
|
+
* Machine user name.
|
|
5
|
+
*
|
|
6
|
+
* When `tailor.d.ts` is generated (via `tailor-sdk deploy`/`generate`), this is narrowed
|
|
7
|
+
* to the union of defined machine user names. When no machine users are registered yet,
|
|
8
|
+
* falls back to `string` to avoid blocking editing before the first generate run.
|
|
9
|
+
*/
|
|
10
|
+
type MachineUserName = keyof MachineUserNameRegistry extends never ? string : keyof MachineUserNameRegistry & string;
|
|
11
|
+
//#endregion
|
|
12
|
+
export { MachineUserName, MachineUserNameRegistry };
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
import { TailorUser } from "../../runtime/types.mjs";
|
|
2
|
+
import { TypeLevelError } from "../../types/helpers.mjs";
|
|
3
|
+
import { DefinedFieldMetadata, FieldMetadata, FieldValidateInput, TailorField as TailorField$1, TailorFieldType } from "./field.types.mjs";
|
|
4
|
+
import { StandardSchemaV1 } from "@standard-schema/spec";
|
|
5
|
+
|
|
6
|
+
//#region src/configure/types/type.d.ts
|
|
7
|
+
type AnyBuilderMethod = any;
|
|
8
|
+
type TailorAnyField = Omit<TailorField$1<AnyBuilderMethod, AnyBuilderMethod, FieldMetadata, TailorFieldType>, "fields"> & {
|
|
9
|
+
readonly fields: Record<string, AnyBuilderMethod>;
|
|
10
|
+
_metadata: FieldMetadata;
|
|
11
|
+
description: AnyBuilderMethod;
|
|
12
|
+
typeName: AnyBuilderMethod;
|
|
13
|
+
validate: AnyBuilderMethod;
|
|
14
|
+
parse: AnyBuilderMethod;
|
|
15
|
+
_parseInternal: AnyBuilderMethod;
|
|
16
|
+
};
|
|
17
|
+
type IsAny<T> = 0 extends 1 & T ? true : false;
|
|
18
|
+
type WithFieldDescription<Defined> = Defined & {
|
|
19
|
+
description: true;
|
|
20
|
+
};
|
|
21
|
+
type WithFieldTypeName<Defined> = Defined & {
|
|
22
|
+
typeName: true;
|
|
23
|
+
};
|
|
24
|
+
type WithFieldValidate<Defined> = Defined & {
|
|
25
|
+
validate: true;
|
|
26
|
+
};
|
|
27
|
+
type FieldDescriptionFn<Defined extends DefinedFieldMetadata, Output> = (description: string) => TailorField<WithFieldDescription<Defined>, Output>;
|
|
28
|
+
type FieldTypeNameFn<Defined extends DefinedFieldMetadata, Output> = (typeName: string) => TailorField<WithFieldTypeName<Defined>, Output>;
|
|
29
|
+
type FieldValidateFn<Defined extends DefinedFieldMetadata, Output> = (...validate: FieldValidateInput<Output>[]) => TailorField<WithFieldValidate<Defined>, Output>;
|
|
30
|
+
type FieldDescriptionMethod<Defined extends DefinedFieldMetadata, Output> = IsAny<Defined> extends true ? FieldDescriptionFn<Defined, Output> : Defined extends {
|
|
31
|
+
description: unknown;
|
|
32
|
+
} ? TypeLevelError<".description() has already been set"> : FieldDescriptionFn<Defined, Output>;
|
|
33
|
+
type FieldTypeNameMethod<Defined extends DefinedFieldMetadata, Output> = IsAny<Defined> extends true ? TypeLevelError<string> : Defined extends {
|
|
34
|
+
typeName: unknown;
|
|
35
|
+
} ? TypeLevelError<".typeName() has already been set"> : Defined extends {
|
|
36
|
+
type: "enum" | "nested";
|
|
37
|
+
} ? FieldTypeNameFn<Defined, Output> : TypeLevelError<"typeName can only be set on enum or object fields">;
|
|
38
|
+
type FieldValidateMethod<Defined extends DefinedFieldMetadata, Output> = IsAny<Defined> extends true ? FieldValidateFn<Defined, Output> : Defined extends {
|
|
39
|
+
validate: unknown;
|
|
40
|
+
} ? TypeLevelError<".validate() has already been set"> : FieldValidateFn<Defined, Output>;
|
|
41
|
+
/**
|
|
42
|
+
* Full TailorField interface with builder methods.
|
|
43
|
+
* Extends the minimal structural interface from types/ with fluent API methods.
|
|
44
|
+
*/
|
|
45
|
+
interface TailorField<Defined extends DefinedFieldMetadata = DefinedFieldMetadata, Output = any, M extends FieldMetadata = FieldMetadata, T extends TailorFieldType = TailorFieldType> extends TailorField$1<Defined, Output, M, T> {
|
|
46
|
+
readonly fields: Record<string, TailorAnyField>;
|
|
47
|
+
_metadata: M;
|
|
48
|
+
/**
|
|
49
|
+
* Set a description for the field
|
|
50
|
+
* @param description - The description text
|
|
51
|
+
* @returns The field with updated metadata
|
|
52
|
+
*/
|
|
53
|
+
description: FieldDescriptionMethod<Defined, Output>;
|
|
54
|
+
/**
|
|
55
|
+
* Set a custom type name for enum or nested types
|
|
56
|
+
* @param typeName - The custom type name
|
|
57
|
+
* @returns The field with updated metadata
|
|
58
|
+
*/
|
|
59
|
+
typeName: FieldTypeNameMethod<Defined, Output>;
|
|
60
|
+
/**
|
|
61
|
+
* Add validation functions to the field
|
|
62
|
+
* @param validate - One or more validation functions
|
|
63
|
+
* @returns The field with updated metadata
|
|
64
|
+
*/
|
|
65
|
+
validate: FieldValidateMethod<Defined, Output>;
|
|
66
|
+
/**
|
|
67
|
+
* Parse and validate a value against this field's validation rules
|
|
68
|
+
* Returns StandardSchema Result type with success or failure
|
|
69
|
+
* @param args - Value, context data, and user
|
|
70
|
+
* @returns Validation result
|
|
71
|
+
*/
|
|
72
|
+
parse(args: FieldParseArgs): StandardSchemaV1.Result<Output>;
|
|
73
|
+
/**
|
|
74
|
+
* Internal parse method that tracks field path for nested validation
|
|
75
|
+
* @private
|
|
76
|
+
* @param args - Parse arguments
|
|
77
|
+
* @returns Validation result
|
|
78
|
+
*/
|
|
79
|
+
_parseInternal(args: FieldParseInternalArgs): StandardSchemaV1.Result<Output>;
|
|
80
|
+
}
|
|
81
|
+
type FieldParseArgs = {
|
|
82
|
+
value: unknown;
|
|
83
|
+
data: unknown;
|
|
84
|
+
user: TailorUser;
|
|
85
|
+
};
|
|
86
|
+
type FieldParseInternalArgs = {
|
|
87
|
+
value: any;
|
|
88
|
+
data: unknown;
|
|
89
|
+
user: TailorUser;
|
|
90
|
+
pathArray: string[];
|
|
91
|
+
};
|
|
92
|
+
/**
|
|
93
|
+
* Create a UUID field for resolver input/output.
|
|
94
|
+
* @param options - Field configuration options
|
|
95
|
+
* @returns A UUID field
|
|
96
|
+
* @example t.uuid()
|
|
97
|
+
*/
|
|
98
|
+
//#endregion
|
|
99
|
+
export { TailorAnyField, TailorField };
|