@awsless/awsless 0.0.136 → 0.0.138

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/dist/index.d.ts CHANGED
@@ -1860,22 +1860,41 @@ declare const AppSchema: z.ZodObject<{
1860
1860
  } | undefined;
1861
1861
  } | undefined;
1862
1862
  }>>>;
1863
- domains: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodArray<z.ZodObject<{
1864
- name: z.ZodOptional<z.ZodString>;
1865
- type: z.ZodEnum<["A", "AAAA", "CAA", "CNAME", "DS", "MX", "NAPTR", "NS", "PTR", "SOA", "SPF", "SRV", "TXT"]>;
1866
- ttl: z.ZodEffects<z.ZodString, Duration, string>;
1867
- records: z.ZodArray<z.ZodString, "many">;
1863
+ domains: z.ZodOptional<z.ZodRecord<z.ZodEffects<z.ZodString, string, string>, z.ZodObject<{
1864
+ domain: z.ZodString;
1865
+ dns: z.ZodOptional<z.ZodArray<z.ZodObject<{
1866
+ name: z.ZodOptional<z.ZodString>;
1867
+ type: z.ZodEnum<["A", "AAAA", "CAA", "CNAME", "DS", "MX", "NAPTR", "NS", "PTR", "SOA", "SPF", "SRV", "TXT"]>;
1868
+ ttl: z.ZodEffects<z.ZodString, Duration, string>;
1869
+ records: z.ZodArray<z.ZodString, "many">;
1870
+ }, "strip", z.ZodTypeAny, {
1871
+ type: "A" | "AAAA" | "CAA" | "CNAME" | "DS" | "MX" | "NAPTR" | "NS" | "PTR" | "SOA" | "SPF" | "SRV" | "TXT";
1872
+ ttl: Duration;
1873
+ records: string[];
1874
+ name?: string | undefined;
1875
+ }, {
1876
+ type: "A" | "AAAA" | "CAA" | "CNAME" | "DS" | "MX" | "NAPTR" | "NS" | "PTR" | "SOA" | "SPF" | "SRV" | "TXT";
1877
+ ttl: string;
1878
+ records: string[];
1879
+ name?: string | undefined;
1880
+ }>, "many">>;
1868
1881
  }, "strip", z.ZodTypeAny, {
1869
- type: "A" | "AAAA" | "CAA" | "CNAME" | "DS" | "MX" | "NAPTR" | "NS" | "PTR" | "SOA" | "SPF" | "SRV" | "TXT";
1870
- ttl: Duration;
1871
- records: string[];
1872
- name?: string | undefined;
1882
+ domain: string;
1883
+ dns?: {
1884
+ type: "A" | "AAAA" | "CAA" | "CNAME" | "DS" | "MX" | "NAPTR" | "NS" | "PTR" | "SOA" | "SPF" | "SRV" | "TXT";
1885
+ ttl: Duration;
1886
+ records: string[];
1887
+ name?: string | undefined;
1888
+ }[] | undefined;
1873
1889
  }, {
1874
- type: "A" | "AAAA" | "CAA" | "CNAME" | "DS" | "MX" | "NAPTR" | "NS" | "PTR" | "SOA" | "SPF" | "SRV" | "TXT";
1875
- ttl: string;
1876
- records: string[];
1877
- name?: string | undefined;
1878
- }>, "many">>>;
1890
+ domain: string;
1891
+ dns?: {
1892
+ type: "A" | "AAAA" | "CAA" | "CNAME" | "DS" | "MX" | "NAPTR" | "NS" | "PTR" | "SOA" | "SPF" | "SRV" | "TXT";
1893
+ ttl: string;
1894
+ records: string[];
1895
+ name?: string | undefined;
1896
+ }[] | undefined;
1897
+ }>>>;
1879
1898
  function: z.ZodDefault<z.ZodObject<{
1880
1899
  handler: z.ZodDefault<z.ZodString>;
1881
1900
  minify: z.ZodDefault<z.ZodBoolean>;
@@ -1991,7 +2010,7 @@ declare const AppSchema: z.ZodObject<{
1991
2010
  maxBatchingWindow?: string | undefined;
1992
2011
  }>>;
1993
2012
  graphql: z.ZodOptional<z.ZodRecord<z.ZodEffects<z.ZodString, string, string>, z.ZodObject<{
1994
- domain: z.ZodOptional<z.ZodString>;
2013
+ domain: z.ZodOptional<z.ZodEffects<z.ZodString, string, string>>;
1995
2014
  subDomain: z.ZodOptional<z.ZodString>;
1996
2015
  auth: z.ZodOptional<z.ZodEffects<z.ZodString, string, string>>;
1997
2016
  resolver: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
@@ -2007,7 +2026,7 @@ declare const AppSchema: z.ZodObject<{
2007
2026
  resolver?: string | undefined;
2008
2027
  }>>>;
2009
2028
  http: z.ZodOptional<z.ZodRecord<z.ZodEffects<z.ZodString, string, string>, z.ZodObject<{
2010
- domain: z.ZodString;
2029
+ domain: z.ZodEffects<z.ZodString, string, string>;
2011
2030
  subDomain: z.ZodOptional<z.ZodString>;
2012
2031
  auth: z.ZodOptional<z.ZodEffects<z.ZodString, string, string>>;
2013
2032
  }, "strip", z.ZodTypeAny, {
@@ -2020,7 +2039,7 @@ declare const AppSchema: z.ZodObject<{
2020
2039
  auth?: string | undefined;
2021
2040
  }>>>;
2022
2041
  rest: z.ZodOptional<z.ZodRecord<z.ZodEffects<z.ZodString, string, string>, z.ZodObject<{
2023
- domain: z.ZodString;
2042
+ domain: z.ZodEffects<z.ZodString, string, string>;
2024
2043
  subDomain: z.ZodOptional<z.ZodString>;
2025
2044
  }, "strip", z.ZodTypeAny, {
2026
2045
  domain: string;
@@ -2317,11 +2336,14 @@ declare const AppSchema: z.ZodObject<{
2317
2336
  maxBatchingWindow?: Duration | undefined;
2318
2337
  };
2319
2338
  domains?: Record<string, {
2320
- type: "A" | "AAAA" | "CAA" | "CNAME" | "DS" | "MX" | "NAPTR" | "NS" | "PTR" | "SOA" | "SPF" | "SRV" | "TXT";
2321
- ttl: Duration;
2322
- records: string[];
2323
- name?: string | undefined;
2324
- }[]> | undefined;
2339
+ domain: string;
2340
+ dns?: {
2341
+ type: "A" | "AAAA" | "CAA" | "CNAME" | "DS" | "MX" | "NAPTR" | "NS" | "PTR" | "SOA" | "SPF" | "SRV" | "TXT";
2342
+ ttl: Duration;
2343
+ records: string[];
2344
+ name?: string | undefined;
2345
+ }[] | undefined;
2346
+ }> | undefined;
2325
2347
  graphql?: Record<string, {
2326
2348
  domain?: string | undefined;
2327
2349
  subDomain?: string | undefined;
@@ -2591,11 +2613,14 @@ declare const AppSchema: z.ZodObject<{
2591
2613
  } | undefined;
2592
2614
  }> | undefined;
2593
2615
  domains?: Record<string, {
2594
- type: "A" | "AAAA" | "CAA" | "CNAME" | "DS" | "MX" | "NAPTR" | "NS" | "PTR" | "SOA" | "SPF" | "SRV" | "TXT";
2595
- ttl: string;
2596
- records: string[];
2597
- name?: string | undefined;
2598
- }[]> | undefined;
2616
+ domain: string;
2617
+ dns?: {
2618
+ type: "A" | "AAAA" | "CAA" | "CNAME" | "DS" | "MX" | "NAPTR" | "NS" | "PTR" | "SOA" | "SPF" | "SRV" | "TXT";
2619
+ ttl: string;
2620
+ records: string[];
2621
+ name?: string | undefined;
2622
+ }[] | undefined;
2623
+ }> | undefined;
2599
2624
  function?: {
2600
2625
  handler?: string | undefined;
2601
2626
  minify?: boolean | undefined;
@@ -2939,11 +2964,14 @@ declare const AppSchema: z.ZodObject<{
2939
2964
  maxBatchingWindow?: Duration | undefined;
2940
2965
  };
2941
2966
  domains?: Record<string, {
2942
- type: "A" | "AAAA" | "CAA" | "CNAME" | "DS" | "MX" | "NAPTR" | "NS" | "PTR" | "SOA" | "SPF" | "SRV" | "TXT";
2943
- ttl: Duration;
2944
- records: string[];
2945
- name?: string | undefined;
2946
- }[]> | undefined;
2967
+ domain: string;
2968
+ dns?: {
2969
+ type: "A" | "AAAA" | "CAA" | "CNAME" | "DS" | "MX" | "NAPTR" | "NS" | "PTR" | "SOA" | "SPF" | "SRV" | "TXT";
2970
+ ttl: Duration;
2971
+ records: string[];
2972
+ name?: string | undefined;
2973
+ }[] | undefined;
2974
+ }> | undefined;
2947
2975
  graphql?: Record<string, {
2948
2976
  domain?: string | undefined;
2949
2977
  subDomain?: string | undefined;
@@ -3221,11 +3249,14 @@ declare const AppSchema: z.ZodObject<{
3221
3249
  } | undefined;
3222
3250
  }> | undefined;
3223
3251
  domains?: Record<string, {
3224
- type: "A" | "AAAA" | "CAA" | "CNAME" | "DS" | "MX" | "NAPTR" | "NS" | "PTR" | "SOA" | "SPF" | "SRV" | "TXT";
3225
- ttl: string;
3226
- records: string[];
3227
- name?: string | undefined;
3228
- }[]> | undefined;
3252
+ domain: string;
3253
+ dns?: {
3254
+ type: "A" | "AAAA" | "CAA" | "CNAME" | "DS" | "MX" | "NAPTR" | "NS" | "PTR" | "SOA" | "SPF" | "SRV" | "TXT";
3255
+ ttl: string;
3256
+ records: string[];
3257
+ name?: string | undefined;
3258
+ }[] | undefined;
3259
+ }> | undefined;
3229
3260
  function?: {
3230
3261
  handler?: string | undefined;
3231
3262
  minify?: boolean | undefined;
@@ -6864,7 +6895,7 @@ declare const StackSchema: z.ZodObject<{
6864
6895
  }>>>;
6865
6896
  searchs: z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodString, string, string>, "many">>;
6866
6897
  sites: z.ZodOptional<z.ZodRecord<z.ZodEffects<z.ZodString, string, string>, z.ZodObject<{
6867
- domain: z.ZodString;
6898
+ domain: z.ZodEffects<z.ZodString, string, string>;
6868
6899
  subDomain: z.ZodOptional<z.ZodString>;
6869
6900
  static: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>>;
6870
6901
  ssr: z.ZodOptional<z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, z.ZodObject<{
package/dist/json.js CHANGED
@@ -452,7 +452,7 @@ import { z as z13 } from "zod";
452
452
  var GraphQLDefaultSchema = z13.record(
453
453
  ResourceIdSchema,
454
454
  z13.object({
455
- domain: z13.string().optional(),
455
+ domain: ResourceIdSchema.describe("The domain id to link your API with.").optional(),
456
456
  subDomain: z13.string().optional(),
457
457
  auth: ResourceIdSchema.optional(),
458
458
  // authorization: z.object({
@@ -536,12 +536,12 @@ var RouteSchema = z15.string().regex(/^(POST|GET|PUT|DELETE|HEAD|OPTIONS)(\s\/[a
536
536
  var HttpDefaultSchema = z15.record(
537
537
  ResourceIdSchema,
538
538
  z15.object({
539
- domain: z15.string().describe("The domain to link your api with."),
539
+ domain: ResourceIdSchema.describe("The domain id to link your API with."),
540
540
  subDomain: z15.string().optional(),
541
541
  auth: ResourceIdSchema.optional()
542
542
  })
543
- ).optional().describe("Define your global http api's.");
544
- var HttpSchema = z15.record(ResourceIdSchema, z15.record(RouteSchema, FunctionSchema)).optional().describe("Define routes in your stack for your global http api.");
543
+ ).optional().describe("Define your global HTTP API's.");
544
+ var HttpSchema = z15.record(ResourceIdSchema, z15.record(RouteSchema, FunctionSchema)).optional().describe("Define routes in your stack for your global HTTP API.");
545
545
 
546
546
  // src/plugins/store/schema.ts
547
547
  import { z as z16 } from "zod";
@@ -645,7 +645,7 @@ var RouteSchema2 = z20.union([
645
645
  var RestDefaultSchema = z21.record(
646
646
  ResourceIdSchema,
647
647
  z21.object({
648
- domain: z21.string().describe("The domain to link your API with."),
648
+ domain: ResourceIdSchema.describe("The domain id to link your API with."),
649
649
  subDomain: z21.string().optional()
650
650
  })
651
651
  ).optional().describe("Define your global REST API's.");
@@ -687,7 +687,7 @@ var ErrorResponseSchema = z23.union([
687
687
  var SitesSchema = z23.record(
688
688
  ResourceIdSchema,
689
689
  z23.object({
690
- domain: z23.string().describe("The domain to link your site with."),
690
+ domain: ResourceIdSchema.describe("The domain id to link your site with."),
691
691
  subDomain: z23.string().optional(),
692
692
  static: LocalDirectorySchema.optional().describe("Specifies the path to the static files directory."),
693
693
  ssr: FunctionSchema.optional().describe("Specifies the ssr file."),
@@ -847,13 +847,16 @@ var DNSTypeSchema = z27.enum(["A", "AAAA", "CAA", "CNAME", "DS", "MX", "NAPTR",
847
847
  var TTLSchema = DurationSchema.describe("The resource record cache time to live (TTL).");
848
848
  var RecordsSchema = z27.string().array().describe("One or more values that correspond with the value that you specified for the Type property.");
849
849
  var DomainsDefaultSchema = z27.record(
850
- DomainNameSchema,
850
+ ResourceIdSchema,
851
851
  z27.object({
852
- name: DomainNameSchema.optional(),
853
- type: DNSTypeSchema,
854
- ttl: TTLSchema,
855
- records: RecordsSchema
856
- }).array()
852
+ domain: DomainNameSchema.describe("Define the domain name"),
853
+ dns: z27.object({
854
+ name: DomainNameSchema.optional(),
855
+ type: DNSTypeSchema,
856
+ ttl: TTLSchema,
857
+ records: RecordsSchema
858
+ }).array().optional().describe("Define the domain dns records")
859
+ })
857
860
  ).optional().describe("Define the domains for your application.");
858
861
 
859
862
  // src/config/app.ts