@tailor-platform/sdk 1.22.0 → 1.24.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (69) hide show
  1. package/CHANGELOG.md +74 -0
  2. package/dist/app-config-BNKHurwr.d.mts +174 -0
  3. package/dist/{application-CTQe2HSB.mjs → application-DThE2HW7.mjs} +200 -215
  4. package/dist/application-DThE2HW7.mjs.map +1 -0
  5. package/dist/application-P1by1htu.mjs +8 -0
  6. package/dist/{brand-DyPrAzpM.mjs → brand-64NrPh_e.mjs} +1 -1
  7. package/dist/{brand-DyPrAzpM.mjs.map → brand-64NrPh_e.mjs.map} +1 -1
  8. package/dist/cli/index.d.mts +0 -1
  9. package/dist/cli/index.mjs +7 -7
  10. package/dist/cli/index.mjs.map +1 -1
  11. package/dist/cli/lib.d.mts +8 -9
  12. package/dist/cli/lib.mjs +7 -7
  13. package/dist/cli/lib.mjs.map +1 -1
  14. package/dist/cli/skills.d.mts +0 -1
  15. package/dist/configure/index.d.mts +5 -5
  16. package/dist/configure/index.mjs +3 -3
  17. package/dist/configure/index.mjs.map +1 -1
  18. package/dist/enum-constants-B5Nl-yzx.mjs.map +1 -1
  19. package/dist/env-CHwmMyfF.d.mts +32 -0
  20. package/dist/file-utils-sEOwAdJ4.mjs.map +1 -1
  21. package/dist/{index-Cwi86SUR.d.mts → index-BrIZ1rm2.d.mts} +2 -3
  22. package/dist/{index-BiutQT7m.d.mts → index-Df0aH5zp.d.mts} +55 -5
  23. package/dist/{index-DPN_P0w3.d.mts → index-DhtKJmgi.d.mts} +2 -3
  24. package/dist/{index-ClS0NClx.d.mts → index-DkRJwNw2.d.mts} +2 -3
  25. package/dist/{index-BGPX26_D.d.mts → index-zZUL7_2B.d.mts} +2 -3
  26. package/dist/{interceptor-DiARwPfw.mjs → interceptor-B-0OmiDZ.mjs} +1 -1
  27. package/dist/{interceptor-DiARwPfw.mjs.map → interceptor-B-0OmiDZ.mjs.map} +1 -1
  28. package/dist/{job-CRavYLLk.mjs → job-CnqcfVTI.mjs} +2 -2
  29. package/dist/{job-CRavYLLk.mjs.map → job-CnqcfVTI.mjs.map} +1 -1
  30. package/dist/kysely/index.d.mts +0 -1
  31. package/dist/kysely-type-CSlcwNFH.mjs.map +1 -1
  32. package/dist/{package-json-iVBhE5Ef.mjs → package-json-4G3gLWMd.mjs} +1 -1
  33. package/dist/{package-json-iVBhE5Ef.mjs.map → package-json-4G3gLWMd.mjs.map} +1 -1
  34. package/dist/package-json-BqvUKPBM.mjs +3 -0
  35. package/dist/plugin/builtin/enum-constants/index.d.mts +2 -3
  36. package/dist/plugin/builtin/file-utils/index.d.mts +2 -3
  37. package/dist/plugin/builtin/kysely-type/index.d.mts +2 -3
  38. package/dist/plugin/builtin/seed/index.d.mts +2 -3
  39. package/dist/plugin/builtin/seed/index.mjs +1 -1
  40. package/dist/plugin/index.d.mts +2 -2
  41. package/dist/plugin/index.mjs.map +1 -1
  42. package/dist/{types-bcuNRo1Y.d.mts → plugin-CE-BZZgX.d.mts} +1069 -1763
  43. package/dist/{query-Bz2oDGhw.mjs → query-CV5n7DRd.mjs} +496 -115
  44. package/dist/query-CV5n7DRd.mjs.map +1 -0
  45. package/dist/{schema-Cjm-OvPF.mjs → schema-0ByCZ2Ym.mjs} +2 -2
  46. package/dist/schema-0ByCZ2Ym.mjs.map +1 -0
  47. package/dist/{seed-CXvCW3Xc.mjs → seed-Cl5QXYsL.mjs} +13 -3
  48. package/dist/seed-Cl5QXYsL.mjs.map +1 -0
  49. package/dist/{telemetry-C46fds1l.mjs → telemetry-BPviAbME.mjs} +2 -2
  50. package/dist/{telemetry-C46fds1l.mjs.map → telemetry-BPviAbME.mjs.map} +1 -1
  51. package/dist/telemetry-Dq5FZUH0.mjs +3 -0
  52. package/dist/utils/test/index.d.mts +3 -4
  53. package/dist/utils/test/index.mjs +2 -2
  54. package/docs/cli/tailordb.md +1 -1
  55. package/docs/cli-reference.md +8 -8
  56. package/docs/services/auth.md +2 -2
  57. package/package.json +27 -25
  58. package/postinstall.mjs +4 -14
  59. package/dist/application-CTQe2HSB.mjs.map +0 -1
  60. package/dist/application-DdSu3baZ.mjs +0 -8
  61. package/dist/package-json-BI0ng3_5.mjs +0 -3
  62. package/dist/query-Bz2oDGhw.mjs.map +0 -1
  63. package/dist/schema-Cjm-OvPF.mjs.map +0 -1
  64. package/dist/seed-CXvCW3Xc.mjs.map +0 -1
  65. package/dist/telemetry-BAxP8-PR.mjs +0 -3
  66. package/dist/types-CBTSg-LK.mjs +0 -13
  67. package/dist/types-CBTSg-LK.mjs.map +0 -1
  68. package/dist/types-DVMQNdTs.d.mts +0 -246
  69. package/dist/user-defined.d.ts +0 -13
@@ -1,246 +0,0 @@
1
- /// <reference path="./user-defined.d.ts" />
2
- import { P as ExecutorServiceInput, Pt as ResolverServiceInput, W as AuthConfig, Y as BuiltinIdP, qt as TailorDBServiceInput } from "./types-bcuNRo1Y.mjs";
3
- import { z } from "zod";
4
-
5
- //#region src/parser/service/workflow/types.d.ts
6
- type WorkflowServiceConfig = {
7
- files: string[];
8
- job_files?: string[];
9
- ignores?: string[];
10
- job_ignores?: string[];
11
- };
12
- type WorkflowServiceInput = WorkflowServiceConfig;
13
- //#endregion
14
- //#region src/parser/service/staticwebsite/schema.d.ts
15
- declare const StaticWebsiteSchema: z.core.$ZodBranded<z.ZodObject<{
16
- name: z.ZodString;
17
- description: z.ZodOptional<z.ZodString>;
18
- allowedIpAddresses: z.ZodOptional<z.ZodArray<z.ZodString>>;
19
- }, z.core.$strip>, "StaticWebsiteConfig", "out">;
20
- //#endregion
21
- //#region src/parser/service/staticwebsite/types.d.ts
22
- type StaticWebsiteInput = z.input<typeof StaticWebsiteSchema>;
23
- //#endregion
24
- //#region src/configure/services/staticwebsite/index.d.ts
25
- declare const staticWebsiteDefinitionBrand: unique symbol;
26
- type StaticWebsiteDefinitionBrand = {
27
- readonly [staticWebsiteDefinitionBrand]: true;
28
- };
29
- /**
30
- * Define a static website configuration for the Tailor SDK.
31
- * @param name - Static website name
32
- * @param config - Static website configuration
33
- * @returns Defined static website
34
- */
35
- declare function defineStaticWebSite(name: string, config: Omit<StaticWebsiteInput, "name">): {
36
- readonly name: string;
37
- readonly url: `${string}:url`;
38
- readonly description?: string | undefined;
39
- readonly allowedIpAddresses?: string[] | undefined;
40
- } & StaticWebsiteDefinitionBrand;
41
- type StaticWebsiteConfig = Omit<ReturnType<typeof defineStaticWebSite>, "url">;
42
- //#endregion
43
- //#region src/parser/service/idp/schema.d.ts
44
- declare const IdPSchema: z.core.$ZodBranded<z.ZodObject<{
45
- name: z.ZodString;
46
- authorization: z.ZodUnion<readonly [z.ZodLiteral<"insecure">, z.ZodLiteral<"loggedIn">, z.ZodObject<{
47
- cel: z.ZodString;
48
- }, z.core.$strip>]>;
49
- clients: z.ZodArray<z.ZodString>;
50
- lang: z.ZodOptional<z.ZodEnum<{
51
- en: "en";
52
- ja: "ja";
53
- }>>;
54
- userAuthPolicy: z.ZodOptional<z.ZodPipe<z.ZodObject<{
55
- useNonEmailIdentifier: z.ZodOptional<z.ZodBoolean>;
56
- allowSelfPasswordReset: z.ZodOptional<z.ZodBoolean>;
57
- passwordRequireUppercase: z.ZodOptional<z.ZodBoolean>;
58
- passwordRequireLowercase: z.ZodOptional<z.ZodBoolean>;
59
- passwordRequireNonAlphanumeric: z.ZodOptional<z.ZodBoolean>;
60
- passwordRequireNumeric: z.ZodOptional<z.ZodBoolean>;
61
- passwordMinLength: z.ZodOptional<z.ZodNumber>;
62
- passwordMaxLength: z.ZodOptional<z.ZodNumber>;
63
- allowedEmailDomains: z.ZodOptional<z.ZodArray<z.ZodString>>;
64
- allowGoogleOauth: z.ZodOptional<z.ZodBoolean>;
65
- allowMicrosoftOauth: z.ZodOptional<z.ZodBoolean>;
66
- disablePasswordAuth: z.ZodOptional<z.ZodBoolean>;
67
- }, z.core.$strip>, z.ZodTransform<{
68
- useNonEmailIdentifier?: boolean | undefined;
69
- allowSelfPasswordReset?: boolean | undefined;
70
- passwordRequireUppercase?: boolean | undefined;
71
- passwordRequireLowercase?: boolean | undefined;
72
- passwordRequireNonAlphanumeric?: boolean | undefined;
73
- passwordRequireNumeric?: boolean | undefined;
74
- passwordMinLength?: number | undefined;
75
- passwordMaxLength?: number | undefined;
76
- allowedEmailDomains?: string[] | undefined;
77
- allowGoogleOauth?: boolean | undefined;
78
- allowMicrosoftOauth?: boolean | undefined;
79
- disablePasswordAuth?: boolean | undefined;
80
- }, {
81
- useNonEmailIdentifier?: boolean | undefined;
82
- allowSelfPasswordReset?: boolean | undefined;
83
- passwordRequireUppercase?: boolean | undefined;
84
- passwordRequireLowercase?: boolean | undefined;
85
- passwordRequireNonAlphanumeric?: boolean | undefined;
86
- passwordRequireNumeric?: boolean | undefined;
87
- passwordMinLength?: number | undefined;
88
- passwordMaxLength?: number | undefined;
89
- allowedEmailDomains?: string[] | undefined;
90
- allowGoogleOauth?: boolean | undefined;
91
- allowMicrosoftOauth?: boolean | undefined;
92
- disablePasswordAuth?: boolean | undefined;
93
- }>>>;
94
- publishUserEvents: z.ZodOptional<z.ZodBoolean>;
95
- gqlOperations: z.ZodOptional<z.ZodPipe<z.ZodUnion<readonly [z.ZodLiteral<"query">, z.ZodObject<{
96
- create: z.ZodOptional<z.ZodBoolean>;
97
- update: z.ZodOptional<z.ZodBoolean>;
98
- delete: z.ZodOptional<z.ZodBoolean>;
99
- read: z.ZodOptional<z.ZodBoolean>;
100
- sendPasswordResetEmail: z.ZodOptional<z.ZodBoolean>;
101
- }, z.core.$strip>]>, z.ZodTransform<IdPGqlOperations, "query" | {
102
- create?: boolean | undefined;
103
- update?: boolean | undefined;
104
- delete?: boolean | undefined;
105
- read?: boolean | undefined;
106
- sendPasswordResetEmail?: boolean | undefined;
107
- }>>>;
108
- }, z.core.$strip>, "IdPConfig", "out">;
109
- //#endregion
110
- //#region src/configure/services/idp/index.d.ts
111
- /**
112
- * Configuration for GraphQL operations on IdP users.
113
- * All operations are enabled by default (undefined or true = enabled, false = disabled).
114
- */
115
- interface IdPGqlOperations {
116
- /** Enable _createUser mutation (default: true) */
117
- create?: boolean;
118
- /** Enable _updateUser mutation (default: true) */
119
- update?: boolean;
120
- /** Enable _deleteUser mutation (default: true) */
121
- delete?: boolean;
122
- /** Enable _users and _user queries (default: true) */
123
- read?: boolean;
124
- /** Enable _sendPasswordResetEmail mutation (default: true) */
125
- sendPasswordResetEmail?: boolean;
126
- }
127
- /**
128
- * Alias for common IdPGqlOperations configurations.
129
- * - "query": Read-only mode - disables all mutations (create, update, delete, sendPasswordResetEmail)
130
- */
131
- type IdPGqlOperationsAliasQuery = "query";
132
- /**
133
- * Configuration for GraphQL operations - either an alias string or detailed object.
134
- */
135
- type IdPGqlOperationsConfig = IdPGqlOperationsAliasQuery | IdPGqlOperations;
136
- /**
137
- * Define an IdP service configuration for the Tailor SDK.
138
- * @template TClients
139
- * @param name - IdP service name
140
- * @param config - IdP configuration
141
- * @returns Defined IdP service
142
- */
143
- declare function defineIdp<const TClients extends string[]>(name: string, config: Omit<IdPInput, "name" | "clients"> & {
144
- clients: TClients;
145
- }): {
146
- readonly name: string;
147
- readonly provider: (providerName: string, clientName: TClients[number]) => {
148
- readonly name: string;
149
- readonly kind: "BuiltInIdP";
150
- readonly namespace: string;
151
- readonly clientName: TClients[number];
152
- };
153
- readonly authorization: "insecure" | "loggedIn" | {
154
- cel: string;
155
- };
156
- readonly lang?: "en" | "ja" | undefined;
157
- readonly userAuthPolicy?: {
158
- useNonEmailIdentifier?: boolean | undefined;
159
- allowSelfPasswordReset?: boolean | undefined;
160
- passwordRequireUppercase?: boolean | undefined;
161
- passwordRequireLowercase?: boolean | undefined;
162
- passwordRequireNonAlphanumeric?: boolean | undefined;
163
- passwordRequireNumeric?: boolean | undefined;
164
- passwordMinLength?: number | undefined;
165
- passwordMaxLength?: number | undefined;
166
- allowedEmailDomains?: string[] | undefined;
167
- allowGoogleOauth?: boolean | undefined;
168
- allowMicrosoftOauth?: boolean | undefined;
169
- disablePasswordAuth?: boolean | undefined;
170
- } | undefined;
171
- readonly publishUserEvents?: boolean | undefined;
172
- readonly gqlOperations?: "query" | {
173
- create?: boolean | undefined;
174
- update?: boolean | undefined;
175
- delete?: boolean | undefined;
176
- read?: boolean | undefined;
177
- sendPasswordResetEmail?: boolean | undefined;
178
- } | undefined;
179
- readonly clients: TClients;
180
- } & IdpDefinitionBrand;
181
- //#endregion
182
- //#region src/parser/service/idp/types.d.ts
183
- type IdPInput = z.input<typeof IdPSchema>;
184
- declare const idpDefinitionBrand: unique symbol;
185
- type IdpDefinitionBrand = {
186
- readonly [idpDefinitionBrand]: true;
187
- };
188
- type DefinedIdp<Name extends string, Config, ClientNames extends string> = Config & {
189
- name: Name;
190
- provider(providerName: string, clientName: ClientNames): BuiltinIdP;
191
- } & IdpDefinitionBrand;
192
- type IdPExternalConfig = {
193
- name: string;
194
- external: true;
195
- };
196
- type IdPOwnConfig = Omit<DefinedIdp<string, IdPInput, string>, "provider">;
197
- type IdPConfig = IdPOwnConfig | IdPExternalConfig;
198
- //#endregion
199
- //#region src/parser/app-config/types.d.ts
200
- /**
201
- * Application configuration for `defineConfig()`.
202
- *
203
- * Key fields:
204
- * - `name` (required): Application name
205
- * - `cors`: Array of allowed origins, e.g. `["https://example.com"]`
206
- * - `auth`: Single auth config object (not an array)
207
- * - `idp`: Array of IdP configs, e.g. `[myIdp]`
208
- * - `staticWebsites`: Array of static website configs, e.g. `[website]`
209
- * - `db`, `resolver`, `executor`, `workflow`: Service configs with file globs
210
- */
211
- interface AppConfig<Auth extends AuthConfig = AuthConfig, Idp extends IdPConfig[] = IdPConfig[], StaticWebsites extends StaticWebsiteConfig[] = StaticWebsiteConfig[], Env extends Record<string, string | number | boolean> = Record<string, string | number | boolean>> {
212
- /** Application name (required). */
213
- name: string;
214
- /** Environment variables accessible via `context.env` in resolvers and via the second argument `{ env }` in workflow job bodies. */
215
- env?: Env;
216
- /** Allowed CORS origins. Must be an array of strings, e.g. `["https://example.com"]`. */
217
- cors?: string[];
218
- /** IP addresses allowed to access the application. */
219
- allowedIpAddresses?: string[];
220
- /** Disable GraphQL introspection in production. */
221
- disableIntrospection?: boolean;
222
- /** TailorDB service configuration with type definition files. */
223
- db?: TailorDBServiceInput;
224
- /** Resolver service configuration with resolver files. */
225
- resolver?: ResolverServiceInput;
226
- /** Identity Provider configurations. Must be an array, e.g. `[myIdp]`. */
227
- idp?: Idp;
228
- /** Auth configuration (single object, not an array). */
229
- auth?: Auth;
230
- /** Executor service configuration with executor files. */
231
- executor?: ExecutorServiceInput;
232
- /** Workflow service configuration with workflow files. */
233
- workflow?: WorkflowServiceInput;
234
- /** Static website configurations. Must be an array, e.g. `[website]`. */
235
- staticWebsites?: StaticWebsites;
236
- /**
237
- * Enable inline sourcemaps in bundled functions for better error stack traces.
238
- * When enabled, sourcemaps are embedded directly in the bundle file.
239
- * Set to `false` to disable (e.g. if bundle size exceeds limits).
240
- * @default true
241
- */
242
- inlineSourcemap?: boolean;
243
- }
244
- //#endregion
245
- export { IdPGqlOperationsAliasQuery as a, StaticWebsiteConfig as c, WorkflowServiceInput as d, IdPGqlOperations as i, defineStaticWebSite as l, IdPConfig as n, IdPGqlOperationsConfig as o, IdPExternalConfig as r, defineIdp as s, AppConfig as t, WorkflowServiceConfig as u };
246
- //# sourceMappingURL=types-DVMQNdTs.d.mts.map
@@ -1,13 +0,0 @@
1
- // This file is auto-generated by @tailor-platform/sdk
2
- // Do not edit this file manually
3
- // Regenerated automatically when running 'tailor-sdk apply' or 'tailor-sdk generate'
4
-
5
- declare module "@tailor-platform/sdk" {
6
- interface AttributeMap {}
7
- interface AttributeList {
8
- __tuple: string[];
9
- }
10
- interface Env {}
11
- }
12
-
13
- export {};