@aws-sdk/client-amplify 3.629.0 → 3.631.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/dist-cjs/index.js CHANGED
@@ -28,6 +28,7 @@ __export(src_exports, {
28
28
  AutoBranchCreationConfigFilterSensitiveLog: () => AutoBranchCreationConfigFilterSensitiveLog,
29
29
  BadRequestException: () => BadRequestException,
30
30
  BranchFilterSensitiveLog: () => BranchFilterSensitiveLog,
31
+ CacheConfigType: () => CacheConfigType,
31
32
  CertificateType: () => CertificateType,
32
33
  CreateAppCommand: () => CreateAppCommand,
33
34
  CreateAppRequestFilterSensitiveLog: () => CreateAppRequestFilterSensitiveLog,
@@ -288,6 +289,10 @@ var Stage = {
288
289
  PRODUCTION: "PRODUCTION",
289
290
  PULL_REQUEST: "PULL_REQUEST"
290
291
  };
292
+ var CacheConfigType = {
293
+ AMPLIFY_MANAGED: "AMPLIFY_MANAGED",
294
+ AMPLIFY_MANAGED_NO_COOKIES: "AMPLIFY_MANAGED_NO_COOKIES"
295
+ };
291
296
  var Platform = {
292
297
  WEB: "WEB",
293
298
  WEB_COMPUTE: "WEB_COMPUTE",
@@ -548,6 +553,7 @@ var se_CreateAppCommand = /* @__PURE__ */ __name(async (input, context) => {
548
553
  autoBranchCreationPatterns: (_) => (0, import_smithy_client._json)(_),
549
554
  basicAuthCredentials: [],
550
555
  buildSpec: [],
556
+ cacheConfig: (_) => (0, import_smithy_client._json)(_),
551
557
  customHeaders: [],
552
558
  customRules: (_) => (0, import_smithy_client._json)(_),
553
559
  description: [],
@@ -1018,6 +1024,7 @@ var se_UpdateAppCommand = /* @__PURE__ */ __name(async (input, context) => {
1018
1024
  autoBranchCreationPatterns: (_) => (0, import_smithy_client._json)(_),
1019
1025
  basicAuthCredentials: [],
1020
1026
  buildSpec: [],
1027
+ cacheConfig: (_) => (0, import_smithy_client._json)(_),
1021
1028
  customHeaders: [],
1022
1029
  customRules: (_) => (0, import_smithy_client._json)(_),
1023
1030
  description: [],
@@ -1764,6 +1771,7 @@ var de_App = /* @__PURE__ */ __name((output, context) => {
1764
1771
  autoBranchCreationPatterns: import_smithy_client._json,
1765
1772
  basicAuthCredentials: import_smithy_client.expectString,
1766
1773
  buildSpec: import_smithy_client.expectString,
1774
+ cacheConfig: import_smithy_client._json,
1767
1775
  createTime: (_) => (0, import_smithy_client.expectNonNull)((0, import_smithy_client.parseEpochTimestamp)((0, import_smithy_client.expectNumber)(_))),
1768
1776
  customHeaders: import_smithy_client.expectString,
1769
1777
  customRules: import_smithy_client._json,
@@ -2627,6 +2635,7 @@ var paginateListJobs = (0, import_core.createPaginator)(AmplifyClient, ListJobsC
2627
2635
  paginateListJobs,
2628
2636
  BadRequestException,
2629
2637
  Stage,
2638
+ CacheConfigType,
2630
2639
  Platform,
2631
2640
  RepositoryCloneMethod,
2632
2641
  DependentServiceFailureException,
@@ -19,6 +19,10 @@ export const Stage = {
19
19
  PRODUCTION: "PRODUCTION",
20
20
  PULL_REQUEST: "PULL_REQUEST",
21
21
  };
22
+ export const CacheConfigType = {
23
+ AMPLIFY_MANAGED: "AMPLIFY_MANAGED",
24
+ AMPLIFY_MANAGED_NO_COOKIES: "AMPLIFY_MANAGED_NO_COOKIES",
25
+ };
22
26
  export const Platform = {
23
27
  WEB: "WEB",
24
28
  WEB_COMPUTE: "WEB_COMPUTE",
@@ -16,6 +16,7 @@ export const se_CreateAppCommand = async (input, context) => {
16
16
  autoBranchCreationPatterns: (_) => _json(_),
17
17
  basicAuthCredentials: [],
18
18
  buildSpec: [],
19
+ cacheConfig: (_) => _json(_),
19
20
  customHeaders: [],
20
21
  customRules: (_) => _json(_),
21
22
  description: [],
@@ -466,6 +467,7 @@ export const se_UpdateAppCommand = async (input, context) => {
466
467
  autoBranchCreationPatterns: (_) => _json(_),
467
468
  basicAuthCredentials: [],
468
469
  buildSpec: [],
470
+ cacheConfig: (_) => _json(_),
469
471
  customHeaders: [],
470
472
  customRules: (_) => _json(_),
471
473
  description: [],
@@ -1205,6 +1207,7 @@ const de_App = (output, context) => {
1205
1207
  autoBranchCreationPatterns: _json,
1206
1208
  basicAuthCredentials: __expectString,
1207
1209
  buildSpec: __expectString,
1210
+ cacheConfig: _json,
1208
1211
  createTime: (_) => __expectNonNull(__parseEpochTimestamp(__expectNumber(_))),
1209
1212
  customHeaders: __expectString,
1210
1213
  customRules: _json,
@@ -80,6 +80,9 @@ declare const CreateAppCommand_base: {
80
80
  * enablePullRequestPreview: true || false,
81
81
  * pullRequestEnvironmentName: "STRING_VALUE",
82
82
  * },
83
+ * cacheConfig: { // CacheConfig
84
+ * type: "AMPLIFY_MANAGED" || "AMPLIFY_MANAGED_NO_COOKIES", // required
85
+ * },
83
86
  * };
84
87
  * const command = new CreateAppCommand(input);
85
88
  * const response = await client.send(command);
@@ -140,6 +143,9 @@ declare const CreateAppCommand_base: {
140
143
  * // pullRequestEnvironmentName: "STRING_VALUE",
141
144
  * // },
142
145
  * // repositoryCloneMethod: "SSH" || "TOKEN" || "SIGV4",
146
+ * // cacheConfig: { // CacheConfig
147
+ * // type: "AMPLIFY_MANAGED" || "AMPLIFY_MANAGED_NO_COOKIES", // required
148
+ * // },
143
149
  * // },
144
150
  * // };
145
151
  *
@@ -96,6 +96,9 @@ declare const DeleteAppCommand_base: {
96
96
  * // pullRequestEnvironmentName: "STRING_VALUE",
97
97
  * // },
98
98
  * // repositoryCloneMethod: "SSH" || "TOKEN" || "SIGV4",
99
+ * // cacheConfig: { // CacheConfig
100
+ * // type: "AMPLIFY_MANAGED" || "AMPLIFY_MANAGED_NO_COOKIES", // required
101
+ * // },
99
102
  * // },
100
103
  * // };
101
104
  *
@@ -96,6 +96,9 @@ declare const GetAppCommand_base: {
96
96
  * // pullRequestEnvironmentName: "STRING_VALUE",
97
97
  * // },
98
98
  * // repositoryCloneMethod: "SSH" || "TOKEN" || "SIGV4",
99
+ * // cacheConfig: { // CacheConfig
100
+ * // type: "AMPLIFY_MANAGED" || "AMPLIFY_MANAGED_NO_COOKIES", // required
101
+ * // },
99
102
  * // },
100
103
  * // };
101
104
  *
@@ -98,6 +98,9 @@ declare const ListAppsCommand_base: {
98
98
  * // pullRequestEnvironmentName: "STRING_VALUE",
99
99
  * // },
100
100
  * // repositoryCloneMethod: "SSH" || "TOKEN" || "SIGV4",
101
+ * // cacheConfig: { // CacheConfig
102
+ * // type: "AMPLIFY_MANAGED" || "AMPLIFY_MANAGED_NO_COOKIES", // required
103
+ * // },
101
104
  * // },
102
105
  * // ],
103
106
  * // nextToken: "STRING_VALUE",
@@ -78,6 +78,9 @@ declare const UpdateAppCommand_base: {
78
78
  * repository: "STRING_VALUE",
79
79
  * oauthToken: "STRING_VALUE",
80
80
  * accessToken: "STRING_VALUE",
81
+ * cacheConfig: { // CacheConfig
82
+ * type: "AMPLIFY_MANAGED" || "AMPLIFY_MANAGED_NO_COOKIES", // required
83
+ * },
81
84
  * };
82
85
  * const command = new UpdateAppCommand(input);
83
86
  * const response = await client.send(command);
@@ -138,6 +141,9 @@ declare const UpdateAppCommand_base: {
138
141
  * // pullRequestEnvironmentName: "STRING_VALUE",
139
142
  * // },
140
143
  * // repositoryCloneMethod: "SSH" || "TOKEN" || "SIGV4",
144
+ * // cacheConfig: { // CacheConfig
145
+ * // type: "AMPLIFY_MANAGED" || "AMPLIFY_MANAGED_NO_COOKIES", // required
146
+ * // },
141
147
  * // },
142
148
  * // };
143
149
  *
@@ -88,6 +88,37 @@ export interface AutoBranchCreationConfig {
88
88
  */
89
89
  pullRequestEnvironmentName?: string;
90
90
  }
91
+ /**
92
+ * @public
93
+ * @enum
94
+ */
95
+ export declare const CacheConfigType: {
96
+ readonly AMPLIFY_MANAGED: "AMPLIFY_MANAGED";
97
+ readonly AMPLIFY_MANAGED_NO_COOKIES: "AMPLIFY_MANAGED_NO_COOKIES";
98
+ };
99
+ /**
100
+ * @public
101
+ */
102
+ export type CacheConfigType = (typeof CacheConfigType)[keyof typeof CacheConfigType];
103
+ /**
104
+ * <p>Describes the cache configuration for an Amplify app.</p>
105
+ * <p>For more
106
+ * information about how Amplify applies an optimal cache configuration for
107
+ * your app based on the type of content that is being served, see <a href="https://docs.aws.amazon.com/amplify/latest/userguide/managing-cache-configuration">Managing cache configuration</a> in the <i>Amplify User
108
+ * guide</i>.</p>
109
+ * @public
110
+ */
111
+ export interface CacheConfig {
112
+ /**
113
+ * <p>The type of cache configuration to use for an Amplify app.</p>
114
+ * <p>The <code>AMPLIFY_MANAGED</code> cache configuration automatically applies an
115
+ * optimized cache configuration for your app based on its platform, routing rules, and
116
+ * rewrite rules. This is the default setting.</p>
117
+ * <p>The <code>AMPLIFY_MANAGED_NO_COOKIES</code> cache configuration type is the same as <code>AMPLIFY_MANAGED</code>, except that it excludes all cookies from the cache key.</p>
118
+ * @public
119
+ */
120
+ type: CacheConfigType | undefined;
121
+ }
91
122
  /**
92
123
  * <p>Describes a custom rewrite or redirect rule. </p>
93
124
  * @public
@@ -282,6 +313,11 @@ export interface CreateAppRequest {
282
313
  * @public
283
314
  */
284
315
  autoBranchCreationConfig?: AutoBranchCreationConfig;
316
+ /**
317
+ * <p>The cache configuration for the Amplify app.</p>
318
+ * @public
319
+ */
320
+ cacheConfig?: CacheConfig;
285
321
  }
286
322
  /**
287
323
  * <p>Describes the information about a production branch for an Amplify app. </p>
@@ -466,6 +502,13 @@ export interface App {
466
502
  * @public
467
503
  */
468
504
  repositoryCloneMethod?: RepositoryCloneMethod;
505
+ /**
506
+ * <p>The cache configuration for the Amplify app. If you don't specify the
507
+ * cache configuration <code>type</code>, Amplify uses the default
508
+ * <code>AMPLIFY_MANAGED</code> setting.</p>
509
+ * @public
510
+ */
511
+ cacheConfig?: CacheConfig;
469
512
  }
470
513
  /**
471
514
  * @public
@@ -1080,7 +1123,7 @@ export interface Certificate {
1080
1123
  * import) the certificate in the US East (N. Virginia) Region (us-east-1). For more
1081
1124
  * information about using ACM, see <a href="https://docs.aws.amazon.com/acm/latest/userguide/import-certificate.html">Importing certificates into
1082
1125
  * Certificate Manager</a> in the <i>ACM User
1083
- * guide</i> .</p>
1126
+ * guide</i>.</p>
1084
1127
  * @public
1085
1128
  */
1086
1129
  type: CertificateType | undefined;
@@ -2547,6 +2590,11 @@ export interface UpdateAppRequest {
2547
2590
  * @public
2548
2591
  */
2549
2592
  accessToken?: string;
2593
+ /**
2594
+ * <p>The cache configuration for the Amplify app.</p>
2595
+ * @public
2596
+ */
2597
+ cacheConfig?: CacheConfig;
2550
2598
  }
2551
2599
  /**
2552
2600
  * <p>The result structure for an Amplify app update request. </p>
@@ -27,6 +27,15 @@ export interface AutoBranchCreationConfig {
27
27
  enablePullRequestPreview?: boolean;
28
28
  pullRequestEnvironmentName?: string;
29
29
  }
30
+ export declare const CacheConfigType: {
31
+ readonly AMPLIFY_MANAGED: "AMPLIFY_MANAGED";
32
+ readonly AMPLIFY_MANAGED_NO_COOKIES: "AMPLIFY_MANAGED_NO_COOKIES";
33
+ };
34
+ export type CacheConfigType =
35
+ (typeof CacheConfigType)[keyof typeof CacheConfigType];
36
+ export interface CacheConfig {
37
+ type: CacheConfigType | undefined;
38
+ }
30
39
  export interface CustomRule {
31
40
  source: string | undefined;
32
41
  target: string | undefined;
@@ -59,6 +68,7 @@ export interface CreateAppRequest {
59
68
  enableAutoBranchCreation?: boolean;
60
69
  autoBranchCreationPatterns?: string[];
61
70
  autoBranchCreationConfig?: AutoBranchCreationConfig;
71
+ cacheConfig?: CacheConfig;
62
72
  }
63
73
  export interface ProductionBranch {
64
74
  lastDeployTime?: Date;
@@ -98,6 +108,7 @@ export interface App {
98
108
  autoBranchCreationPatterns?: string[];
99
109
  autoBranchCreationConfig?: AutoBranchCreationConfig;
100
110
  repositoryCloneMethod?: RepositoryCloneMethod;
111
+ cacheConfig?: CacheConfig;
101
112
  }
102
113
  export interface CreateAppResult {
103
114
  app: App | undefined;
@@ -598,6 +609,7 @@ export interface UpdateAppRequest {
598
609
  repository?: string;
599
610
  oauthToken?: string;
600
611
  accessToken?: string;
612
+ cacheConfig?: CacheConfig;
601
613
  }
602
614
  export interface UpdateAppResult {
603
615
  app: App | undefined;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@aws-sdk/client-amplify",
3
3
  "description": "AWS SDK for JavaScript Amplify Client for Node.js, Browser and React Native",
4
- "version": "3.629.0",
4
+ "version": "3.631.0",
5
5
  "scripts": {
6
6
  "build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
7
7
  "build:cjs": "node ../../scripts/compilation/inline client-amplify",
@@ -20,17 +20,17 @@
20
20
  "dependencies": {
21
21
  "@aws-crypto/sha256-browser": "5.2.0",
22
22
  "@aws-crypto/sha256-js": "5.2.0",
23
- "@aws-sdk/client-sso-oidc": "3.629.0",
24
- "@aws-sdk/client-sts": "3.629.0",
23
+ "@aws-sdk/client-sso-oidc": "3.631.0",
24
+ "@aws-sdk/client-sts": "3.631.0",
25
25
  "@aws-sdk/core": "3.629.0",
26
- "@aws-sdk/credential-provider-node": "3.629.0",
26
+ "@aws-sdk/credential-provider-node": "3.631.0",
27
27
  "@aws-sdk/middleware-host-header": "3.620.0",
28
28
  "@aws-sdk/middleware-logger": "3.609.0",
29
29
  "@aws-sdk/middleware-recursion-detection": "3.620.0",
30
- "@aws-sdk/middleware-user-agent": "3.620.0",
30
+ "@aws-sdk/middleware-user-agent": "3.631.0",
31
31
  "@aws-sdk/region-config-resolver": "3.614.0",
32
32
  "@aws-sdk/types": "3.609.0",
33
- "@aws-sdk/util-endpoints": "3.614.0",
33
+ "@aws-sdk/util-endpoints": "3.631.0",
34
34
  "@aws-sdk/util-user-agent-browser": "3.609.0",
35
35
  "@aws-sdk/util-user-agent-node": "3.614.0",
36
36
  "@smithy/config-resolver": "^3.0.5",