@aws-amplify/core 5.8.17 → 5.8.19

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 (196) hide show
  1. package/lib/Amplify.d.ts +10 -0
  2. package/lib/Amplify.js +10 -0
  3. package/lib/AwsClients/CognitoIdentity/base.js +2 -2
  4. package/lib/AwsClients/CognitoIdentity/getCredentialsForIdentity.js +2 -2
  5. package/lib/AwsClients/CognitoIdentity/getId.js +2 -2
  6. package/lib/AwsClients/Pinpoint/getInAppMessages.js +2 -2
  7. package/lib/AwsClients/Pinpoint/putEvents.js +2 -2
  8. package/lib/AwsClients/Pinpoint/updateEndpoint.js +2 -2
  9. package/lib/ClientDevice/browser.js +3 -4
  10. package/lib/ClientDevice/index.d.ts +5 -0
  11. package/lib/ClientDevice/index.js +5 -0
  12. package/lib/Credentials.d.ts +10 -0
  13. package/lib/Credentials.js +18 -8
  14. package/lib/Errors.d.ts +10 -0
  15. package/lib/Errors.js +12 -3
  16. package/lib/Hub.d.ts +20 -0
  17. package/lib/Hub.js +5 -0
  18. package/lib/I18n/index.d.ts +3 -0
  19. package/lib/I18n/index.js +3 -0
  20. package/lib/JS.d.ts +54 -0
  21. package/lib/JS.js +54 -0
  22. package/lib/Logger/ConsoleLogger.d.ts +3 -0
  23. package/lib/Logger/ConsoleLogger.js +6 -2
  24. package/lib/OAuthHelper/FacebookOAuth.js +2 -2
  25. package/lib/OAuthHelper/GoogleOAuth.js +2 -2
  26. package/lib/OAuthHelper/index.d.ts +10 -0
  27. package/lib/OAuthHelper/index.js +10 -0
  28. package/lib/Platform/detectFramework.js +2 -2
  29. package/lib/Platform/detection/Angular.js +2 -3
  30. package/lib/Platform/detection/Expo.js +1 -2
  31. package/lib/Platform/detection/Next.js +2 -3
  32. package/lib/Platform/detection/Nuxt.js +2 -3
  33. package/lib/Platform/detection/React.js +2 -3
  34. package/lib/Platform/detection/ReactNative.js +1 -2
  35. package/lib/Platform/detection/Svelte.js +2 -3
  36. package/lib/Platform/detection/Vue.js +2 -3
  37. package/lib/Platform/detection/Web.js +1 -2
  38. package/lib/Platform/detection/index.js +1 -2
  39. package/lib/Platform/index.d.ts +15 -0
  40. package/lib/Platform/index.js +15 -0
  41. package/lib/Platform/types.d.ts +70 -0
  42. package/lib/Platform/types.js +78 -13
  43. package/lib/Platform/version.d.ts +1 -1
  44. package/lib/Platform/version.js +1 -1
  45. package/lib/Providers/AWSCloudWatchProvider.d.ts +5 -0
  46. package/lib/Providers/AWSCloudWatchProvider.js +7 -2
  47. package/lib/RNComponents/index.d.ts +15 -0
  48. package/lib/RNComponents/index.js +15 -0
  49. package/lib/ServiceWorker/ServiceWorker.d.ts +3 -0
  50. package/lib/ServiceWorker/ServiceWorker.js +3 -0
  51. package/lib/Signer.d.ts +5 -0
  52. package/lib/Signer.js +5 -0
  53. package/lib/StorageHelper/index.d.ts +11 -1
  54. package/lib/StorageHelper/index.js +11 -1
  55. package/lib/UniversalStorage/index.d.ts +5 -0
  56. package/lib/UniversalStorage/index.js +5 -0
  57. package/lib/Util/BackgroundProcessManager.d.ts +9 -0
  58. package/lib/Util/BackgroundProcessManager.js +12 -3
  59. package/lib/Util/Constants.d.ts +35 -0
  60. package/lib/Util/Constants.js +35 -0
  61. package/lib/Util/DateUtils.d.ts +24 -1
  62. package/lib/Util/DateUtils.js +5 -0
  63. package/lib/Util/Mutex.d.ts +5 -0
  64. package/lib/Util/Mutex.js +5 -0
  65. package/lib/Util/Reachability.d.ts +5 -0
  66. package/lib/Util/Reachability.js +5 -0
  67. package/lib/Util/Retry.d.ts +19 -0
  68. package/lib/Util/Retry.js +24 -5
  69. package/lib/Util/StringUtils.d.ts +10 -0
  70. package/lib/Util/StringUtils.js +12 -3
  71. package/lib/clients/handlers/fetch.js +47 -49
  72. package/lib/clients/internal/composeServiceApi.js +2 -2
  73. package/lib/clients/internal/composeTransferHandler.d.ts +1 -1
  74. package/lib/clients/middleware/retry/defaultRetryDecider.js +2 -2
  75. package/lib/clients/middleware/retry/middleware.js +3 -3
  76. package/lib/clients/middleware/signing/middleware.js +2 -2
  77. package/lib/clients/middleware/signing/signer/signatureV4/utils/getCanonicalHeaders.d.ts +1 -1
  78. package/lib/clients/middleware/signing/signer/signatureV4/utils/getHashedPayload.d.ts +1 -1
  79. package/lib/clients/middleware/signing/signer/signatureV4/utils/getSignedHeaders.d.ts +1 -1
  80. package/lib/clients/middleware/userAgent/middleware.js +2 -2
  81. package/lib/clients/serde/json.js +2 -2
  82. package/lib/constants.d.ts +10 -0
  83. package/lib/constants.js +10 -0
  84. package/lib/index.d.ts +5 -0
  85. package/lib/index.js +5 -0
  86. package/lib/parseAWSExports.d.ts +5 -0
  87. package/lib/parseAWSExports.js +5 -0
  88. package/lib/tsconfig.tsbuildinfo +1 -1
  89. package/lib/types/types.d.ts +5 -0
  90. package/lib-esm/Amplify.d.ts +10 -0
  91. package/lib-esm/Amplify.js +10 -0
  92. package/lib-esm/AwsClients/CognitoIdentity/base.js +2 -2
  93. package/lib-esm/AwsClients/CognitoIdentity/getCredentialsForIdentity.js +2 -2
  94. package/lib-esm/AwsClients/CognitoIdentity/getId.js +2 -2
  95. package/lib-esm/AwsClients/Pinpoint/getInAppMessages.js +2 -2
  96. package/lib-esm/AwsClients/Pinpoint/putEvents.js +2 -2
  97. package/lib-esm/AwsClients/Pinpoint/updateEndpoint.js +2 -2
  98. package/lib-esm/ClientDevice/index.d.ts +5 -0
  99. package/lib-esm/ClientDevice/index.js +5 -0
  100. package/lib-esm/Credentials.d.ts +10 -0
  101. package/lib-esm/Credentials.js +18 -8
  102. package/lib-esm/Errors.d.ts +10 -0
  103. package/lib-esm/Errors.js +10 -0
  104. package/lib-esm/Hub.d.ts +20 -0
  105. package/lib-esm/Hub.js +5 -0
  106. package/lib-esm/I18n/index.d.ts +3 -0
  107. package/lib-esm/I18n/index.js +3 -0
  108. package/lib-esm/JS.d.ts +54 -0
  109. package/lib-esm/JS.js +54 -0
  110. package/lib-esm/Logger/ConsoleLogger.d.ts +3 -0
  111. package/lib-esm/Logger/ConsoleLogger.js +5 -1
  112. package/lib-esm/OAuthHelper/FacebookOAuth.js +2 -2
  113. package/lib-esm/OAuthHelper/GoogleOAuth.js +2 -2
  114. package/lib-esm/OAuthHelper/index.d.ts +10 -0
  115. package/lib-esm/OAuthHelper/index.js +10 -0
  116. package/lib-esm/Platform/index.d.ts +15 -0
  117. package/lib-esm/Platform/index.js +15 -0
  118. package/lib-esm/Platform/types.d.ts +70 -0
  119. package/lib-esm/Platform/types.js +65 -0
  120. package/lib-esm/Platform/version.d.ts +1 -1
  121. package/lib-esm/Platform/version.js +1 -1
  122. package/lib-esm/Providers/AWSCloudWatchProvider.d.ts +5 -0
  123. package/lib-esm/Providers/AWSCloudWatchProvider.js +7 -2
  124. package/lib-esm/RNComponents/index.d.ts +15 -0
  125. package/lib-esm/RNComponents/index.js +15 -0
  126. package/lib-esm/ServiceWorker/ServiceWorker.d.ts +3 -0
  127. package/lib-esm/ServiceWorker/ServiceWorker.js +3 -0
  128. package/lib-esm/Signer.d.ts +5 -0
  129. package/lib-esm/Signer.js +5 -0
  130. package/lib-esm/StorageHelper/index.d.ts +11 -1
  131. package/lib-esm/StorageHelper/index.js +11 -1
  132. package/lib-esm/UniversalStorage/index.d.ts +5 -0
  133. package/lib-esm/UniversalStorage/index.js +5 -0
  134. package/lib-esm/Util/BackgroundProcessManager.d.ts +9 -0
  135. package/lib-esm/Util/BackgroundProcessManager.js +11 -2
  136. package/lib-esm/Util/Constants.d.ts +35 -0
  137. package/lib-esm/Util/Constants.js +35 -0
  138. package/lib-esm/Util/DateUtils.d.ts +24 -1
  139. package/lib-esm/Util/DateUtils.js +5 -0
  140. package/lib-esm/Util/Mutex.d.ts +5 -0
  141. package/lib-esm/Util/Mutex.js +5 -0
  142. package/lib-esm/Util/Reachability.d.ts +5 -0
  143. package/lib-esm/Util/Reachability.js +5 -0
  144. package/lib-esm/Util/Retry.d.ts +19 -0
  145. package/lib-esm/Util/Retry.js +21 -2
  146. package/lib-esm/Util/StringUtils.d.ts +10 -0
  147. package/lib-esm/Util/StringUtils.js +10 -0
  148. package/lib-esm/clients/handlers/fetch.js +47 -49
  149. package/lib-esm/clients/internal/composeServiceApi.js +2 -2
  150. package/lib-esm/clients/internal/composeTransferHandler.d.ts +1 -1
  151. package/lib-esm/clients/middleware/retry/defaultRetryDecider.js +2 -2
  152. package/lib-esm/clients/middleware/retry/middleware.js +3 -3
  153. package/lib-esm/clients/middleware/signing/middleware.js +2 -2
  154. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getCanonicalHeaders.d.ts +1 -1
  155. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getHashedPayload.d.ts +1 -1
  156. package/lib-esm/clients/middleware/signing/signer/signatureV4/utils/getSignedHeaders.d.ts +1 -1
  157. package/lib-esm/clients/middleware/userAgent/middleware.js +2 -2
  158. package/lib-esm/clients/serde/json.js +2 -2
  159. package/lib-esm/constants.d.ts +10 -0
  160. package/lib-esm/constants.js +10 -0
  161. package/lib-esm/index.d.ts +5 -0
  162. package/lib-esm/index.js +5 -0
  163. package/lib-esm/parseAWSExports.d.ts +5 -0
  164. package/lib-esm/parseAWSExports.js +5 -0
  165. package/lib-esm/tsconfig.tsbuildinfo +1 -1
  166. package/lib-esm/types/types.d.ts +5 -0
  167. package/package.json +31 -14
  168. package/src/Amplify.ts +10 -0
  169. package/src/ClientDevice/index.ts +5 -0
  170. package/src/Credentials.ts +10 -0
  171. package/src/Errors.ts +10 -0
  172. package/src/Hub.ts +20 -0
  173. package/src/I18n/index.ts +3 -0
  174. package/src/JS.ts +54 -0
  175. package/src/Logger/ConsoleLogger.ts +3 -0
  176. package/src/OAuthHelper/index.ts +10 -0
  177. package/src/Platform/index.ts +15 -0
  178. package/src/Platform/types.ts +70 -0
  179. package/src/Platform/version.ts +1 -1
  180. package/src/Providers/AWSCloudWatchProvider.ts +5 -0
  181. package/src/RNComponents/index.ts +15 -0
  182. package/src/ServiceWorker/ServiceWorker.ts +3 -0
  183. package/src/Signer.ts +5 -0
  184. package/src/StorageHelper/index.ts +11 -1
  185. package/src/UniversalStorage/index.ts +5 -0
  186. package/src/Util/BackgroundProcessManager.ts +9 -0
  187. package/src/Util/Constants.ts +35 -0
  188. package/src/Util/DateUtils.ts +5 -0
  189. package/src/Util/Mutex.ts +5 -0
  190. package/src/Util/Reachability.ts +5 -0
  191. package/src/Util/Retry.ts +19 -0
  192. package/src/Util/StringUtils.ts +10 -0
  193. package/src/constants.ts +10 -0
  194. package/src/index.ts +5 -0
  195. package/src/parseAWSExports.ts +5 -0
  196. package/src/types/types.ts +5 -0
@@ -1,8 +1,43 @@
1
+ /**
2
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
3
+ * See the migration guide:
4
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
5
+ */
1
6
  declare const AWS_CLOUDWATCH_BASE_BUFFER_SIZE = 26;
7
+ /**
8
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
9
+ * See the migration guide:
10
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
11
+ */
2
12
  declare const AWS_CLOUDWATCH_MAX_BATCH_EVENT_SIZE = 1048576;
13
+ /**
14
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
15
+ * See the migration guide:
16
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
17
+ */
3
18
  declare const AWS_CLOUDWATCH_MAX_EVENT_SIZE = 256000;
19
+ /**
20
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
21
+ * See the migration guide:
22
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
23
+ */
4
24
  declare const AWS_CLOUDWATCH_CATEGORY = "Logging";
25
+ /**
26
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
27
+ * See the migration guide:
28
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
29
+ */
5
30
  declare const AWS_CLOUDWATCH_PROVIDER_NAME = "AWSCloudWatch";
31
+ /**
32
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
33
+ * See the migration guide:
34
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
35
+ */
6
36
  declare const NO_CREDS_ERROR_STRING = "No credentials";
37
+ /**
38
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
39
+ * See the migration guide:
40
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
41
+ */
7
42
  declare const RETRY_ERROR_CODES: string[];
8
43
  export { AWS_CLOUDWATCH_BASE_BUFFER_SIZE, AWS_CLOUDWATCH_CATEGORY, AWS_CLOUDWATCH_MAX_BATCH_EVENT_SIZE, AWS_CLOUDWATCH_MAX_EVENT_SIZE, AWS_CLOUDWATCH_PROVIDER_NAME, NO_CREDS_ERROR_STRING, RETRY_ERROR_CODES, };
@@ -1,12 +1,47 @@
1
1
  // Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
2
2
  // SPDX-License-Identifier: Apache-2.0
3
3
  // Logging constants
4
+ /**
5
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
6
+ * See the migration guide:
7
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
8
+ */
4
9
  var AWS_CLOUDWATCH_BASE_BUFFER_SIZE = 26;
10
+ /**
11
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
12
+ * See the migration guide:
13
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
14
+ */
5
15
  var AWS_CLOUDWATCH_MAX_BATCH_EVENT_SIZE = 1048576;
16
+ /**
17
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
18
+ * See the migration guide:
19
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
20
+ */
6
21
  var AWS_CLOUDWATCH_MAX_EVENT_SIZE = 256000;
22
+ /**
23
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
24
+ * See the migration guide:
25
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
26
+ */
7
27
  var AWS_CLOUDWATCH_CATEGORY = 'Logging';
28
+ /**
29
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
30
+ * See the migration guide:
31
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
32
+ */
8
33
  var AWS_CLOUDWATCH_PROVIDER_NAME = 'AWSCloudWatch';
34
+ /**
35
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
36
+ * See the migration guide:
37
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
38
+ */
9
39
  var NO_CREDS_ERROR_STRING = 'No credentials';
40
+ /**
41
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
42
+ * See the migration guide:
43
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
44
+ */
10
45
  var RETRY_ERROR_CODES = [
11
46
  'ResourceNotFoundException',
12
47
  'InvalidSequenceTokenException',
@@ -4,4 +4,27 @@
4
4
  *
5
5
  * @see https://github.com/aws/aws-sdk-js/blob/6edf586dcc1de7fe8fbfbbd9a0d2b1847921e6e1/lib/util.js#L262
6
6
  */
7
- export declare const DateUtils: any;
7
+ /**
8
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
9
+ * See the migration guide:
10
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
11
+ */
12
+ export declare const DateUtils: {
13
+ /**
14
+ * Milliseconds to offset the date to compensate for clock skew between device & services
15
+ */
16
+ clockOffset: number;
17
+ getDateWithClockOffset(): Date;
18
+ /**
19
+ * @returns {number} Clock offset in milliseconds
20
+ */
21
+ getClockOffset(): number;
22
+ getHeaderStringFromDate(date?: Date): string;
23
+ getDateFromHeaderString(header: string): Date;
24
+ isClockSkewed(serverDate: Date): boolean;
25
+ isClockSkewError(error: any): boolean;
26
+ /**
27
+ * @param {number} offset Clock offset in milliseconds
28
+ */
29
+ setClockOffset(offset: number): void;
30
+ };
@@ -24,6 +24,11 @@ var __read = (this && this.__read) || function (o, n) {
24
24
  };
25
25
  // Comment - TODO: remove
26
26
  var FIVE_MINUTES_IN_MS = 1000 * 60 * 5;
27
+ /**
28
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
29
+ * See the migration guide:
30
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
31
+ */
27
32
  export var DateUtils = {
28
33
  /**
29
34
  * Milliseconds to offset the date to compensate for clock skew between device & services
@@ -34,6 +34,11 @@ declare namespace MutexInterface {
34
34
  (): Promise<T> | T;
35
35
  }
36
36
  }
37
+ /**
38
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
39
+ * See the migration guide:
40
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
41
+ */
37
42
  declare class Mutex implements MutexInterface {
38
43
  isLocked(): boolean;
39
44
  acquire(): Promise<MutexInterface.Releaser>;
@@ -23,6 +23,11 @@
23
23
  * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
24
24
  * THE SOFTWARE.
25
25
  */
26
+ /**
27
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
28
+ * See the migration guide:
29
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
30
+ */
26
31
  var Mutex = /** @class */ (function () {
27
32
  function Mutex() {
28
33
  this._queue = [];
@@ -2,6 +2,11 @@ import Observable from 'zen-observable-ts';
2
2
  type NetworkStatus = {
3
3
  online: boolean;
4
4
  };
5
+ /**
6
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
7
+ * See the migration guide:
8
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
9
+ */
5
10
  export default class ReachabilityNavigator implements Reachability {
6
11
  private static _observers;
7
12
  networkMonitor(netInfo?: any): Observable<NetworkStatus>;
@@ -13,6 +13,11 @@ var __values = (this && this.__values) || function(o) {
13
13
  // SPDX-License-Identifier: Apache-2.0
14
14
  import { browserOrNode, isWebWorker } from '@aws-amplify/core';
15
15
  import Observable from 'zen-observable-ts';
16
+ /**
17
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
18
+ * See the migration guide:
19
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
20
+ */
16
21
  var ReachabilityNavigator = /** @class */ (function () {
17
22
  function ReachabilityNavigator() {
18
23
  }
@@ -1,21 +1,40 @@
1
1
  import { DelayFunction } from '../types';
2
+ /**
3
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
4
+ * See the migration guide:
5
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
6
+ */
2
7
  export declare class NonRetryableError extends Error {
3
8
  readonly nonRetryable = true;
4
9
  constructor(message: string);
5
10
  }
11
+ /**
12
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
13
+ * See the migration guide:
14
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
15
+ */
6
16
  export declare const isNonRetryableError: (obj: any) => obj is NonRetryableError;
7
17
  /**
8
18
  * @private
9
19
  * Internal use of Amplify only
20
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
21
+ * See the migration guide:
22
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
10
23
  */
11
24
  export declare function retry<T>(functionToRetry: (...args: any[]) => T, args: any[], delayFn: DelayFunction, onTerminate?: Promise<void>): Promise<T>;
12
25
  /**
13
26
  * @private
14
27
  * Internal use of Amplify only
28
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
29
+ * See the migration guide:
30
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
15
31
  */
16
32
  export declare function jitteredBackoff(maxDelayMs?: number): DelayFunction;
17
33
  /**
18
34
  * @private
19
35
  * Internal use of Amplify only
36
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
37
+ * See the migration guide:
38
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
20
39
  */
21
40
  export declare const jitteredExponentialRetry: <T>(functionToRetry: (...args: any[]) => T, args: any[], maxDelayMs?: number, onTerminate?: Promise<void>) => Promise<T>;
@@ -23,8 +23,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
23
23
  });
24
24
  };
25
25
  var __generator = (this && this.__generator) || function (thisArg, body) {
26
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
27
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
26
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
27
+ return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
28
28
  function verb(n) { return function (v) { return step([n, v]); }; }
29
29
  function step(op) {
30
30
  if (f) throw new TypeError("Generator is already executing.");
@@ -76,6 +76,11 @@ var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
76
76
  };
77
77
  import { ConsoleLogger as Logger } from '../Logger/ConsoleLogger';
78
78
  var logger = new Logger('Util');
79
+ /**
80
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
81
+ * See the migration guide:
82
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
83
+ */
79
84
  var NonRetryableError = /** @class */ (function (_super) {
80
85
  __extends(NonRetryableError, _super);
81
86
  function NonRetryableError(message) {
@@ -86,6 +91,11 @@ var NonRetryableError = /** @class */ (function (_super) {
86
91
  return NonRetryableError;
87
92
  }(Error));
88
93
  export { NonRetryableError };
94
+ /**
95
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
96
+ * See the migration guide:
97
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
98
+ */
89
99
  export var isNonRetryableError = function (obj) {
90
100
  var key = 'nonRetryable';
91
101
  return obj && obj[key];
@@ -93,6 +103,9 @@ export var isNonRetryableError = function (obj) {
93
103
  /**
94
104
  * @private
95
105
  * Internal use of Amplify only
106
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
107
+ * See the migration guide:
108
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
96
109
  */
97
110
  export function retry(functionToRetry, args, delayFn, onTerminate) {
98
111
  return __awaiter(this, void 0, void 0, function () {
@@ -178,6 +191,9 @@ var MAX_DELAY_MS = 5 * 60 * 1000;
178
191
  /**
179
192
  * @private
180
193
  * Internal use of Amplify only
194
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
195
+ * See the migration guide:
196
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
181
197
  */
182
198
  export function jitteredBackoff(maxDelayMs) {
183
199
  if (maxDelayMs === void 0) { maxDelayMs = MAX_DELAY_MS; }
@@ -191,6 +207,9 @@ export function jitteredBackoff(maxDelayMs) {
191
207
  /**
192
208
  * @private
193
209
  * Internal use of Amplify only
210
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
211
+ * See the migration guide:
212
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
194
213
  */
195
214
  export var jitteredExponentialRetry = function (functionToRetry, args, maxDelayMs, onTerminate) {
196
215
  if (maxDelayMs === void 0) { maxDelayMs = MAX_DELAY_MS; }
@@ -1,2 +1,12 @@
1
+ /**
2
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
3
+ * See the migration guide:
4
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
5
+ */
1
6
  export declare function urlSafeEncode(str: string): string;
7
+ /**
8
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
9
+ * See the migration guide:
10
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
11
+ */
2
12
  export declare function urlSafeDecode(hex: string): string;
@@ -1,5 +1,10 @@
1
1
  // Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
2
2
  // SPDX-License-Identifier: Apache-2.0
3
+ /**
4
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
5
+ * See the migration guide:
6
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
7
+ */
3
8
  export function urlSafeEncode(str) {
4
9
  return str
5
10
  .split('')
@@ -11,6 +16,11 @@ export function urlSafeEncode(str) {
11
16
  })
12
17
  .join('');
13
18
  }
19
+ /**
20
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
21
+ * See the migration guide:
22
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
23
+ */
14
24
  export function urlSafeDecode(hex) {
15
25
  return hex
16
26
  .match(/.{2}/g)
@@ -21,8 +21,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
21
21
  });
22
22
  };
23
23
  var __generator = (this && this.__generator) || function (thisArg, body) {
24
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
25
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
24
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
25
+ return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
26
26
  function verb(n) { return function (v) { return step([n, v]); }; }
27
27
  function step(op) {
28
28
  if (f) throw new TypeError("Generator is already executing.");
@@ -52,51 +52,49 @@ import { withMemoization } from '../utils/memoization';
52
52
  var shouldSendBody = function (method) {
53
53
  return !['HEAD', 'GET', 'DELETE'].includes(method.toUpperCase());
54
54
  };
55
- export var fetchTransferHandler = function (_a, _b) {
56
- var url = _a.url, method = _a.method, headers = _a.headers, body = _a.body;
57
- var abortSignal = _b.abortSignal;
58
- return __awaiter(void 0, void 0, void 0, function () {
59
- var resp, e_1, responseHeaders, httpResponse, bodyWithMixin;
60
- var _c, _d;
61
- return __generator(this, function (_e) {
62
- switch (_e.label) {
63
- case 0:
64
- _e.trys.push([0, 2, , 3]);
65
- return [4 /*yield*/, fetch(url, {
66
- method: method,
67
- headers: headers,
68
- body: shouldSendBody(method) ? body : undefined,
69
- signal: abortSignal,
70
- })];
71
- case 1:
72
- resp = _e.sent();
73
- return [3 /*break*/, 3];
74
- case 2:
75
- e_1 = _e.sent();
76
- // TODO: needs to revise error handling in v6
77
- // For now this is a thin wrapper over original fetch error similar to cognito-identity-js package.
78
- // Ref: https://github.com/aws-amplify/amplify-js/blob/4fbc8c0a2be7526aab723579b4c95b552195a80b/packages/amazon-cognito-identity-js/src/Client.js#L103-L108
79
- if (e_1 instanceof TypeError) {
80
- throw new Error('Network error');
81
- }
82
- throw e_1;
83
- case 3:
84
- responseHeaders = {};
85
- (_c = resp.headers) === null || _c === void 0 ? void 0 : _c.forEach(function (value, key) {
86
- responseHeaders[key.toLowerCase()] = value;
87
- });
88
- httpResponse = {
89
- statusCode: resp.status,
90
- headers: responseHeaders,
91
- body: null,
92
- };
93
- bodyWithMixin = Object.assign((_d = resp.body) !== null && _d !== void 0 ? _d : {}, {
94
- text: withMemoization(function () { return resp.text(); }),
95
- blob: withMemoization(function () { return resp.blob(); }),
96
- json: withMemoization(function () { return resp.json(); }),
97
- });
98
- return [2 /*return*/, __assign(__assign({}, httpResponse), { body: bodyWithMixin })];
99
- }
100
- });
55
+ export var fetchTransferHandler = function (_a, _b) { return __awaiter(void 0, [_a, _b], void 0, function (_c, _d) {
56
+ var resp, e_1, responseHeaders, httpResponse, bodyWithMixin;
57
+ var _e, _f;
58
+ var url = _c.url, method = _c.method, headers = _c.headers, body = _c.body;
59
+ var abortSignal = _d.abortSignal;
60
+ return __generator(this, function (_g) {
61
+ switch (_g.label) {
62
+ case 0:
63
+ _g.trys.push([0, 2, , 3]);
64
+ return [4 /*yield*/, fetch(url, {
65
+ method: method,
66
+ headers: headers,
67
+ body: shouldSendBody(method) ? body : undefined,
68
+ signal: abortSignal,
69
+ })];
70
+ case 1:
71
+ resp = _g.sent();
72
+ return [3 /*break*/, 3];
73
+ case 2:
74
+ e_1 = _g.sent();
75
+ // TODO: needs to revise error handling in v6
76
+ // For now this is a thin wrapper over original fetch error similar to cognito-identity-js package.
77
+ // Ref: https://github.com/aws-amplify/amplify-js/blob/4fbc8c0a2be7526aab723579b4c95b552195a80b/packages/amazon-cognito-identity-js/src/Client.js#L103-L108
78
+ if (e_1 instanceof TypeError) {
79
+ throw new Error('Network error');
80
+ }
81
+ throw e_1;
82
+ case 3:
83
+ responseHeaders = {};
84
+ (_e = resp.headers) === null || _e === void 0 ? void 0 : _e.forEach(function (value, key) {
85
+ responseHeaders[key.toLowerCase()] = value;
86
+ });
87
+ httpResponse = {
88
+ statusCode: resp.status,
89
+ headers: responseHeaders,
90
+ body: null,
91
+ };
92
+ bodyWithMixin = Object.assign((_f = resp.body) !== null && _f !== void 0 ? _f : {}, {
93
+ text: withMemoization(function () { return resp.text(); }),
94
+ blob: withMemoization(function () { return resp.blob(); }),
95
+ json: withMemoization(function () { return resp.json(); }),
96
+ });
97
+ return [2 /*return*/, __assign(__assign({}, httpResponse), { body: bodyWithMixin })];
98
+ }
101
99
  });
102
- };
100
+ }); };
@@ -21,8 +21,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
21
21
  });
22
22
  };
23
23
  var __generator = (this && this.__generator) || function (thisArg, body) {
24
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
25
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
24
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
25
+ return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
26
26
  function verb(n) { return function (v) { return step([n, v]); }; }
27
27
  function step(op) {
28
28
  if (f) throw new TypeError("Generator is already executing.");
@@ -7,7 +7,7 @@ import { Middleware, TransferHandler, Request as RequestBase, Response as Respon
7
7
  * transfer handler's option type and the middleware's option type.
8
8
  * @internal
9
9
  */
10
- export declare const composeTransferHandler: <MiddlewareOptionsArr extends any[] = [], Request_1 extends RequestBase = RequestBase, Response_1 extends ResponseBase = ResponseBase, CoreHandler extends TransferHandler<Request_1, Response_1, any> = TransferHandler<Request_1, Response_1, {}>>(coreHandler: CoreHandler, middleware: OptionToMiddleware<Request_1, Response_1, MiddlewareOptionsArr>) => (request: Request_1, options: MergeNoConflictKeys<[...MiddlewareOptionsArr, InferOptionTypeFromTransferHandler<CoreHandler>]>) => Promise<Response_1>;
10
+ export declare const composeTransferHandler: <MiddlewareOptionsArr extends any[] = [], Request extends RequestBase = RequestBase, Response extends ResponseBase = ResponseBase, CoreHandler extends TransferHandler<Request, Response, any> = TransferHandler<Request, Response, {}>>(coreHandler: CoreHandler, middleware: OptionToMiddleware<Request, Response, MiddlewareOptionsArr>) => (request: Request, options: MergeNoConflictKeys<[...MiddlewareOptionsArr, InferOptionTypeFromTransferHandler<CoreHandler>]>) => Promise<Response>;
11
11
  /**
12
12
  * Type to convert a middleware option type to a middleware type with the given
13
13
  * option type.
@@ -10,8 +10,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
10
10
  });
11
11
  };
12
12
  var __generator = (this && this.__generator) || function (thisArg, body) {
13
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
14
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
13
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
14
+ return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
15
15
  function verb(n) { return function (v) { return step([n, v]); }; }
16
16
  function step(op) {
17
17
  if (f) throw new TypeError("Generator is already executing.");
@@ -21,8 +21,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
21
21
  });
22
22
  };
23
23
  var __generator = (this && this.__generator) || function (thisArg, body) {
24
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
25
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
24
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
25
+ return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
26
26
  function verb(n) { return function (v) { return step([n, v]); }; }
27
27
  function step(op) {
28
28
  if (f) throw new TypeError("Generator is already executing.");
@@ -58,9 +58,9 @@ export var retryMiddleware = function (_a) {
58
58
  }
59
59
  return function (next, context) {
60
60
  return function retryMiddleware(request) {
61
- var _a;
62
61
  return __awaiter(this, void 0, void 0, function () {
63
62
  var error, attemptsCount, response, handleTerminalErrorOrResponse, e_1, delay;
63
+ var _a;
64
64
  return __generator(this, function (_b) {
65
65
  switch (_b.label) {
66
66
  case 0:
@@ -10,8 +10,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
10
10
  });
11
11
  };
12
12
  var __generator = (this && this.__generator) || function (thisArg, body) {
13
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
14
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
13
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
14
+ return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
15
15
  function verb(n) { return function (v) { return step([n, v]); }; }
16
16
  function step(op) {
17
17
  if (f) throw new TypeError("Generator is already executing.");
@@ -10,4 +10,4 @@ import { HttpRequest } from '../../../../../types';
10
10
  *
11
11
  * @internal
12
12
  */
13
- export declare const getCanonicalHeaders: (headers: HttpRequest['headers']) => string;
13
+ export declare const getCanonicalHeaders: (headers: HttpRequest["headers"]) => string;
@@ -8,4 +8,4 @@ import { HttpRequest } from '../../../../../types';
8
8
  *
9
9
  * @internal
10
10
  */
11
- export declare const getHashedPayload: (body: HttpRequest['body']) => string;
11
+ export declare const getHashedPayload: (body: HttpRequest["body"]) => string;
@@ -8,4 +8,4 @@ import { HttpRequest } from '../../../../../types';
8
8
  *
9
9
  * @internal
10
10
  */
11
- export declare const getSignedHeaders: (headers: HttpRequest['headers']) => string;
11
+ export declare const getSignedHeaders: (headers: HttpRequest["headers"]) => string;
@@ -10,8 +10,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
10
10
  });
11
11
  };
12
12
  var __generator = (this && this.__generator) || function (thisArg, body) {
13
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
14
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
13
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
14
+ return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
15
15
  function verb(n) { return function (v) { return step([n, v]); }; }
16
16
  function step(op) {
17
17
  if (f) throw new TypeError("Generator is already executing.");
@@ -10,8 +10,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
10
10
  });
11
11
  };
12
12
  var __generator = (this && this.__generator) || function (thisArg, body) {
13
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
14
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
13
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
14
+ return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
15
15
  function verb(n) { return function (v) { return step([n, v]); }; }
16
16
  function step(op) {
17
17
  if (f) throw new TypeError("Generator is already executing.");
@@ -1,2 +1,12 @@
1
+ /**
2
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
3
+ * See the migration guide:
4
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
5
+ */
1
6
  export declare const INTERNAL_AWS_APPSYNC_REALTIME_PUBSUB_PROVIDER: string | symbol;
7
+ /**
8
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
9
+ * See the migration guide:
10
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
11
+ */
2
12
  export declare const USER_AGENT_HEADER = "x-amz-user-agent";
@@ -5,7 +5,17 @@
5
5
  * is used for AppSync/GraphQL subscriptions in the API category.
6
6
  */
7
7
  var hasSymbol = typeof Symbol !== 'undefined' && typeof Symbol.for === 'function';
8
+ /**
9
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
10
+ * See the migration guide:
11
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
12
+ */
8
13
  export var INTERNAL_AWS_APPSYNC_REALTIME_PUBSUB_PROVIDER = hasSymbol
9
14
  ? Symbol.for('INTERNAL_AWS_APPSYNC_REALTIME_PUBSUB_PROVIDER')
10
15
  : '@@INTERNAL_AWS_APPSYNC_REALTIME_PUBSUB_PROVIDER';
16
+ /**
17
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
18
+ * See the migration guide:
19
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
20
+ */
11
21
  export var USER_AGENT_HEADER = 'x-amz-user-agent';
@@ -20,6 +20,11 @@ export { UniversalStorage } from './UniversalStorage';
20
20
  export { Platform, getAmplifyUserAgentObject, getAmplifyUserAgent, } from './Platform';
21
21
  export { ApiAction, AuthAction, AnalyticsAction, Category, CustomUserAgentDetails, DataStoreAction, Framework, GeoAction, InteractionsAction, InAppMessagingAction, PredictionsAction, PubSubAction, PushNotificationAction, StorageAction, } from './Platform/types';
22
22
  export { INTERNAL_AWS_APPSYNC_REALTIME_PUBSUB_PROVIDER, USER_AGENT_HEADER, } from './constants';
23
+ /**
24
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
25
+ * See the migration guide:
26
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
27
+ */
23
28
  export declare const Constants: {
24
29
  userAgent: string;
25
30
  };
package/lib-esm/index.js CHANGED
@@ -22,6 +22,11 @@ export { UniversalStorage } from './UniversalStorage';
22
22
  export { Platform, getAmplifyUserAgentObject, getAmplifyUserAgent, } from './Platform';
23
23
  export { ApiAction, AuthAction, AnalyticsAction, Category, DataStoreAction, Framework, GeoAction, InteractionsAction, InAppMessagingAction, PredictionsAction, PubSubAction, PushNotificationAction, StorageAction, } from './Platform/types';
24
24
  export { INTERNAL_AWS_APPSYNC_REALTIME_PUBSUB_PROVIDER, USER_AGENT_HEADER, } from './constants';
25
+ /**
26
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
27
+ * See the migration guide:
28
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
29
+ */
25
30
  export var Constants = {
26
31
  userAgent: Platform.userAgent,
27
32
  };
@@ -1,2 +1,7 @@
1
1
  import { AmplifyConfig } from './types';
2
+ /**
3
+ * @deprecated Amplify JavaScript v5 is in maintenance mode. Upgrade to v6.
4
+ * See the migration guide:
5
+ * https://docs.amplify.aws/gen1/javascript/build-a-backend/troubleshooting/migrate-from-javascript-v5-to-v6/
6
+ */
2
7
  export declare const parseAWSExports: (config: any) => AmplifyConfig;