From 51ec5b5290a26e0089e032f3907e5ee4150c1fb7 Mon Sep 17 00:00:00 2001
From: Kha Truong <64438356+khatruong2009@users.noreply.github.com>
Date: Wed, 15 May 2024 12:20:25 -0700
Subject: [PATCH 01/19] chore: remove callout that should be in migration guide
---
src/fragments/lib-v1/analytics/flutter/identifyuser.mdx | 9 ---------
1 file changed, 9 deletions(-)
diff --git a/src/fragments/lib-v1/analytics/flutter/identifyuser.mdx b/src/fragments/lib-v1/analytics/flutter/identifyuser.mdx
index 63d0e75bda2..a8f0f10580a 100644
--- a/src/fragments/lib-v1/analytics/flutter/identifyuser.mdx
+++ b/src/fragments/lib-v1/analytics/flutter/identifyuser.mdx
@@ -4,15 +4,6 @@ You can get the current user's ID from the Amplify Auth category as shown per th
If you have asked for location access and received permission, you can also provide that in `UserProfileLocation`
-
-
-Breaking changes from v0 to v1:
-
-The Analytics- prefix of the original `AnalyticsUserProfile` and `AnalyticsUserProfileLocation` classes is removed. Furthermore, `AnalyticsProperties` is renamed to `CustomProperties`.
-
-
-
-
```dart
Future addAnalyticsWithLocation({
required String userId,
From 5d0f0f9728cd0d4a015867c20a4b9eddedede648 Mon Sep 17 00:00:00 2001
From: Kha Truong <64438356+khatruong2009@users.noreply.github.com>
Date: Wed, 15 May 2024 12:23:37 -0700
Subject: [PATCH 02/19] chore: remove unnecessary code snippet that originates
from vCurrent
---
src/fragments/lib-v1/analytics/flutter/identifyuser.mdx | 4 ----
1 file changed, 4 deletions(-)
diff --git a/src/fragments/lib-v1/analytics/flutter/identifyuser.mdx b/src/fragments/lib-v1/analytics/flutter/identifyuser.mdx
index a8f0f10580a..f43af9dc852 100644
--- a/src/fragments/lib-v1/analytics/flutter/identifyuser.mdx
+++ b/src/fragments/lib-v1/analytics/flutter/identifyuser.mdx
@@ -34,7 +34,3 @@ Future addAnalyticsWithLocation({
);
}
```
-
-import flutter0 from "/src/fragments/lib/analytics/native_common/identify-use-cases.mdx";
-
-
From d9fe525df0601cc97e2944732bbe768ee3cc3d0e Mon Sep 17 00:00:00 2001
From: Kha Truong <64438356+khatruong2009@users.noreply.github.com>
Date: Wed, 15 May 2024 12:52:08 -0700
Subject: [PATCH 03/19] chore: fix incorrect references to vCurrent fragments
inside vPrev pages
---
.../getting_started/50_configureBackend.mdx | 188 ++++++++++++++++
.../getting_started/70_configureBackend.mdx | 2 +-
.../getting_started/50_configureBackend.mdx | 200 ++++++++++++++++++
.../native_common/getting_started/common.mdx | 6 +-
4 files changed, 392 insertions(+), 4 deletions(-)
create mode 100644 src/fragments/lib-v1/auth/android/getting_started/50_configureBackend.mdx
create mode 100644 src/fragments/lib-v1/auth/ios/getting_started/50_configureBackend.mdx
diff --git a/src/fragments/lib-v1/auth/android/getting_started/50_configureBackend.mdx b/src/fragments/lib-v1/auth/android/getting_started/50_configureBackend.mdx
new file mode 100644
index 00000000000..edd49e24ead
--- /dev/null
+++ b/src/fragments/lib-v1/auth/android/getting_started/50_configureBackend.mdx
@@ -0,0 +1,188 @@
+
+
+
+> Prerequisites: [Install and configure](/gen1/[platform]/prev/start/project-setup/prerequisites/#install-and-configure-the-amplify-cli) the Amplify CLI in addition to the Amplify libraries and [necessary dependencies](/gen1/[platform]/prev/build-a-backend/auth/set-up-auth/#install-amplify-libraries).
+
+To start provisioning auth resources in the backend, go to your project directory and **execute the command**:
+
+```bash
+amplify add auth
+```
+
+Enter the following when prompted:
+
+```console
+? Do you want to use the default authentication and security configuration?
+ `Default configuration`
+? How do you want users to be able to sign in?
+ `Username`
+? Do you want to configure advanced settings?
+ `No, I am done.`
+```
+
+> If you have previously enabled an Amplify category that uses Auth behind the scenes (e.g. API category), you can run the `amplify update auth` command to edit your configuration if needed.
+
+To push your changes to the cloud, **execute the command**:
+
+```bash
+amplify push
+```
+
+import android5 from '/src/fragments/lib/auth/android/getting_started/12_amplifyConfig.mdx';
+
+
+
+
+
+
+
+> Prerequisites: [Install and configure](/gen1/[platform]/start/project-setup/prerequisites/#install-and-configure-the-amplify-cli) the Amplify CLI in addition to the Amplify libraries and [necessary dependencies](/gen1/[platform]/build-a-backend/auth/set-up-auth/#install-amplify-libraries).
+
+To import existing Amazon Cognito resources into your Amplify project, **execute the command**:
+
+```bash
+amplify import auth
+```
+
+```console
+? What type of auth resource do you want to import?
+ Cognito User Pool and Identity Pool
+ Cognito User Pool only
+```
+
+Once you've selected an option, you'll be able to search for and import an existing Cognito User Pool and Identity Pool (or User Pool only) within your AWS account. The `amplify import auth` command will also do the following:
+
+- Automatically populate your Amplify Library configuration file (`amplifyconfiguration.json`) with your chosen Amazon Cognito resource information
+- Provide your designated existing Cognito resource as the authentication & authorization mechanism for all auth-dependent categories (API, Storage and more)
+- Enable Lambda functions to access the chosen Cognito resource if you permit it
+
+> If you have previously enabled an Amplify category that uses Auth behind the scenes (e.g. API category), you can run the `amplify update auth` command to edit your configuration if needed.
+
+After configuring your Authentication options, update your backend and deploy the service by running the `push` command:
+
+```bash
+amplify push
+```
+
+Now, the authentication service has been deployed and you can start using it. To view the deployed services in your project at any time, go to Amplify Console by running the following command:
+
+```bash
+amplify console
+```
+
+For more details, see how to [Use an existing Cognito User Pool and Identity Pool](/gen1/[platform]/tools/cli/commands/#auth-import).
+
+
+
+
+
+> Prerequisites: [Install and configure](/gen1/[platform]/start/project-setup/prerequisites/#install-and-configure-the-amplify-cli) the Amplify CLI in addition to the Amplify libraries and [necessary dependencies](/gen1/[platform]/build-a-backend/auth/set-up-auth/#install-amplify-libraries).
+
+Amplify Studio allows you create auth resources, set up authorization rules, implement Multi-factor authentication (MFA), and more via an intuitive UI. To set up Authentication through the Amplify Studio, take the following steps:
+
+1. **Sign in** to the [AWS Management Console](https://console.aws.amazon.com/console/home) and open [AWS Amplify](https://console.aws.amazon.com/amplify).
+2. In the navigation pane, **choose an application**.
+3. On the application information page, choose the **Backend environments** tab, then choose **Launch Studio**.
+4. On the **Set up** menu, choose **Authentication**.
+5. In the **Configure log in** section, choose a login mechanism to add from the **Add login mechanism** list. Valid options are _Username_, _Phone number_, _Facebook_, _Google_, _Amazon_, and _Sign in with Apple_. If you choose one of the social sign-in mechanisms (i.e. _Facebook_, _Google_, _Amazon_, or _Sign in with Apple_), you will also need to enter your _App ID_, _App Secret_, and redirect URLs.
+6. (Optional) Add multi-factor authentication (MFA). MFA is set to **Off** by default. To turn on MFA, do the following in the **Multi-factor authentication** section:
+
+- Choose **Enforced** to require MFA for all users or choose **Optional** to allow individual users to enable MFA.
+- (Optional) Choose **SMS**, and enter your SMS message.
+- (Optional) Choose **Authenticator Application** if you want your app to load with an authentication flow that includes sign up and sign in.
+
+7. In the **Configure sign up** section, expand **Password protection settings** and customize the password policy settings to enforce. u6. Choose **Save and Deploy**. This starts a CloudFormation deployment with the progress displayed in the upper right corner of the page.
+8. After creating and configuring your auth resources, you'll need to pull them down from Amplify Studio. To do so, simply click on "Local setup instructions" in the upper right hand corner of the Studio console and execute the CLI command it provides at the root directory of your app.
+
+> You can also [import](/gen1/[platform]/tools/console/auth/import/) existing Amazon Cognito resources and [manage users and groups](/gen1/[platform]/tools/console/auth/user-management/) through the Amplify Studio UI.
+
+
+
+
+
+If you are not using the Amplify CLI, existing Authentication resources from AWS (e.g. Amazon Cognito UserPools or Identity Pools) can be used with the Amplify Libraries by [manually creating a configuration file](/gen1/[platform]/start/project-setup/use-existing-resources/#add-an-existing-aws-resource-to-an-android-application) (`amplifyconfiguration.json`) and then updating the associated Plugin within it:
+
+```jsx
+{
+ "auth": {
+ "plugins": {
+ "awsCognitoAuthPlugin": {
+ "IdentityManager": {
+ "Default": {}
+ },
+ "CredentialsProvider": {
+ "CognitoIdentity": {
+ "Default": {
+ "PoolId": "[COGNITO IDENTITY POOL ID]",
+ "Region": "[REGION]"
+ }
+ }
+ },
+ "CognitoUserPool": {
+ "Default": {
+ "PoolId": "[COGNITO USER POOL ID]",
+ "AppClientId": "[COGNITO USER POOL APP CLIENT ID]",
+ "Region": "[REGION]"
+ }
+ },
+ "Auth": {
+ "Default": {
+ "authenticationFlowType": "USER_SRP_AUTH",
+ "socialProviders": [],
+ "usernameAttributes": [],
+ "signupAttributes": [
+ "[SIGNUP MECHANISM]"
+ ],
+ "passwordProtectionSettings": {
+ "passwordPolicyMinLength": [PASSWORD LENGTH],
+ "passwordPolicyCharacters": []
+ },
+ "mfaConfiguration": "OFF",
+ "mfaTypes": [
+ "[MFA TYPE]"
+ ],
+ "verificationMechanisms": [
+ "[VERIFICATION MECHANISM]"
+ ],
+ "OAuth": {
+ "WebDomain": "[YOUR COGNITO DOMAIN ]",
+ "AppClientId": "[COGNITO USER POOL APP CLIENT ID]",
+ "SignInRedirectURI": "[CUSTOM REDIRECT SCHEME AFTER SIGN IN, e.g. myapp://]",
+ "SignOutRedirectURI": "[CUSTOM REDIRECT SCHEME AFTER SIGN OUT, e.g. myapp://]",
+ "Scopes": [
+ "phone",
+ "email",
+ "openid",
+ "profile",
+ "aws.cognito.signin.user.admin"
+ ]
+ }
+ }
+ }
+ }
+ }
+ }
+}
+```
+
+- **CredentialsProvider**:
+ - **Cognito Identity**:
+ - **Default**:
+ - **PoolID**: ID of the Amazon Cognito Identity Pool (e.g. `us-east-1:123e4567-e89b-12d3-a456-426614174000`)
+ - **Region**: AWS Region where the resources are provisioned (e.g. `us-east-1`)
+- **CognitoUserPool**:
+ - **Default**:
+ - **PoolId**: ID of the Amazon Cognito User Pool (e.g. `us-east-1_abcdefghi`)
+ - **AppClientId**: ID for the client used to authenticate against the user pool
+ - **Region**: AWS Region where the resources are provisioned (e.g. `us-east-1`)
+- **Auth**:
+ - **Default**:
+ - **authenticationFlowType**: The authentication flow type, takes values `USER_SRP_AUTH`, `CUSTOM_AUTH`, and `USER_PASSWORD_AUTH`. Default is `USER_SRP_AUTH`.
+ - **OAuth**: Hosted UI Configuration (only include this if using the Hosted UI flow)
+ - **Scopes:** Scopes should match the scopes enables in Cognito under "App client settings"
+
+If you are using a Cognito User Pool without a Cognito Identity Pool, you can omit the **CredentialsProvider** section in the configuration.
+
+
+
+
diff --git a/src/fragments/lib-v1/auth/flutter/getting_started/70_configureBackend.mdx b/src/fragments/lib-v1/auth/flutter/getting_started/70_configureBackend.mdx
index c2c99e7707f..401c91aed23 100644
--- a/src/fragments/lib-v1/auth/flutter/getting_started/70_configureBackend.mdx
+++ b/src/fragments/lib-v1/auth/flutter/getting_started/70_configureBackend.mdx
@@ -1,7 +1,7 @@
-> Prerequisites: [Install and configure](/[platform]/start/project-setup/prerequisites/#install-and-configure-the-amplify-cli) the Amplify CLI in addition to the Amplify libraries and [necessary dependencies](/[platform]/build-a-backend/auth/set-up-auth/#install-amplify-libraries).
+> Prerequisites: [Install and configure](/gen1/[platform]/prev/start/project-setup/prerequisites/#install-and-configure-the-amplify-cli) the Amplify CLI in addition to the Amplify libraries and [necessary dependencies](/gen1/[platform]/prev/build-a-backend/auth/set-up-auth/#install-amplify-libraries).
To start provisioning auth resources in the backend, go to your project directory and **execute the command**:
diff --git a/src/fragments/lib-v1/auth/ios/getting_started/50_configureBackend.mdx b/src/fragments/lib-v1/auth/ios/getting_started/50_configureBackend.mdx
new file mode 100644
index 00000000000..e11b6c6f264
--- /dev/null
+++ b/src/fragments/lib-v1/auth/ios/getting_started/50_configureBackend.mdx
@@ -0,0 +1,200 @@
+
+
+
+> Prerequisites: [Install and configure](/gen1/prev/[platform]/start/project-setup/prerequisites/#install-and-configure-the-amplify-cli) the Amplify CLI in addition to the Amplify libraries and [necessary dependencies](/gen1/prev/[platform]/build-a-backend/auth/set-up-auth/#install-amplify-libraries).
+
+To start provisioning auth resources in the backend, go to your project directory and **execute the command**:
+
+```bash
+amplify add auth
+```
+
+Enter the following when prompted:
+
+```console
+? Do you want to use the default authentication and security configuration?
+ `Default configuration`
+? How do you want users to be able to sign in?
+ `Username`
+? Do you want to configure advanced settings?
+ `No, I am done.`
+```
+
+> If you have previously enabled an Amplify category that uses Auth behind the scenes (e.g. API category), you can run the `amplify update auth` command to edit your configuration if needed.
+
+To push your changes to the cloud, **execute the command**:
+
+```bash
+amplify push
+```
+
+import ios3 from '/src/fragments/lib/auth/ios/getting_started/12_amplifyConfig.mdx';
+
+
+
+import android4 from '/src/fragments/lib/auth/android/getting_started/12_amplifyConfig.mdx';
+
+
+
+import flutter5 from '/src/fragments/lib/auth/flutter/getting_started/12_amplifyConfig.mdx';
+
+
+
+
+
+
+
+> Prerequisites: [Install and configure](/gen1/[platform]/start/project-setup/prerequisites/#install-and-configure-the-amplify-cli) the Amplify CLI in addition to the Amplify libraries and [necessary dependencies](/gen1/[platform]/build-a-backend/auth/set-up-auth/#install-amplify-libraries).
+
+To import existing Amazon Cognito resources into your Amplify project, **execute the command**:
+
+```bash
+amplify import auth
+```
+
+```console
+? What type of auth resource do you want to import?
+ Cognito User Pool and Identity Pool
+ Cognito User Pool only
+```
+
+Once you've selected an option, you'll be able to search for and import an existing Cognito User Pool and Identity Pool (or User Pool only) within your AWS account. The `amplify import auth` command will also do the following:
+
+- Automatically populate your Amplify Library configuration file (`awsconfiguration.json`) with your chosen Amazon Cognito resource information
+- Provide your designated existing Cognito resource as the authentication & authorization mechanism for all auth-dependent categories (API, Storage and more)
+- Enable Lambda functions to access the chosen Cognito resource if you permit it
+
+> If you have previously enabled an Amplify category that uses Auth behind the scenes (e.g. API category), you can run the `amplify update auth` command to edit your configuration if needed.
+
+After configuring your Authentication options, update your backend and deploy the service by running the `push` command:
+
+```bash
+amplify push
+```
+
+Upon completion, `amplifyconfiguration.json` should be updated to reference provisioned backend auth resources.
+
+Now, the authentication service has been deployed and you can start using it. To view the deployed services in your project at any time, go to Amplify Console by running the following command:
+
+```bash
+amplify console
+```
+
+For more details, see how to [Use an existing Cognito User Pool and Identity Pool](/gen1/[platform]/tools/cli/commands/#auth-import).
+
+
+
+
+
+> Prerequisites: [Install and configure](/gen1/[platform]/start/project-setup/prerequisites/#install-and-configure-the-amplify-cli) the Amplify CLI in addition to the Amplify libraries and [necessary dependencies](/gen1/[platform]/build-a-backend/auth/set-up-auth/#install-amplify-libraries).
+
+Amplify Studio allows you create auth resources, set up authorization rules, implement Multi-factor authentication (MFA), and more via an intuitive UI. To set up Authentication through the Amplify Studio, take the following steps:
+
+1. **Sign in** to the [AWS Management Console](https://console.aws.amazon.com/console/home) and open AWS Amplify.
+2. In the navigation pane, **choose an application**.
+3. On the application information page, choose the **Backend environments** tab, then choose **Launch Studio**.
+4. On the **Set up** menu, choose **Authentication**.
+5. In the **Configure log in** section, choose a login mechanism to add from the **Add login mechanism** list. Valid options are _Username_, _Phone number_, _Facebook_, _Google_, _Amazon_, and _Sign in with Apple_. If you choose one of the social sign-in mechanisms (i.e. _Facebook_, _Google_, _Amazon_, or _Sign in with Apple_), you will also need to enter your _App ID_, _App Secret_, and redirect URLs.
+6. (Optional) Add multi-factor authentication (MFA). MFA is set to **Off** by default. To turn on MFA, do the following in the **Multi-factor authentication** section:
+
+- Choose **Enforced** to require MFA for all users or choose **Optional** to allow individual users to enable MFA.
+- (Optional) Choose **SMS**, and enter your SMS message.
+- (Optional) Choose **Authenticator Application** if you want your app to load with an authentication flow that includes sign up and sign in.
+
+7. In the **Configure sign up** section, expand **Password protection settings** and customize the password policy settings to enforce. u6. Choose **Save and Deploy**. This starts a CloudFormation deployment with the progress displayed in the upper right corner of the page.
+8. After creating and configuring your auth resources, you'll need to pull them down from Amplify Studio. To do so, simply click on "Local setup instructions" in the upper right hand corner of the Studio console and execute the CLI command it provides at the root directory of your app.
+
+> You can also [import](/gen1/[platform]/tools/console/auth/import/) existing Amazon Cognito resources and [manage users and groups](/gen1/[platform]/tools/console/auth/user-management/) through the Amplify Studio UI.
+
+
+
+
+
+If you are not using the Amplify CLI, existing Authentication resources from AWS (e.g. Amazon Cognito UserPools or Identity Pools) can be used with the Amplify Libraries by [manually creating a configuration file](/gen1/[platform]/start/project-setup/use-existing-resources/#1-manually-create-the-amplify-configuration-file-for-your-ios-project) (`amplifyconfiguration.json`) and then updating the associated Plugin within it:
+
+```jsx
+{
+ "auth": {
+ "plugins": {
+ "awsCognitoAuthPlugin": {
+ "IdentityManager": {
+ "Default": {}
+ },
+ "CredentialsProvider": {
+ "CognitoIdentity": {
+ "Default": {
+ "PoolId": "[COGNITO IDENTITY POOL ID]",
+ "Region": "[REGION]"
+ }
+ }
+ },
+ "CognitoUserPool": {
+ "Default": {
+ "PoolId": "[COGNITO USER POOL ID]",
+ "AppClientId": "[COGNITO USER POOL APP CLIENT ID]",
+ "Region": "[REGION]"
+ }
+ },
+ "Auth": {
+ "Default": {
+ "authenticationFlowType": "USER_SRP_AUTH",
+ "socialProviders": [],
+ "usernameAttributes": [],
+ "signupAttributes": [
+ "[SIGNUP MECHANISM]"
+ ],
+ "passwordProtectionSettings": {
+ "passwordPolicyMinLength": [PASSWORD LENGTH],
+ "passwordPolicyCharacters": []
+ },
+ "mfaConfiguration": "OFF",
+ "mfaTypes": [
+ "[MFA TYPE]"
+ ],
+ "verificationMechanisms": [
+ "[VERIFICATION MECHANISM]"
+ ],
+ "OAuth": {
+ "WebDomain": "[YOUR COGNITO DOMAIN ]",
+ "AppClientId": "[COGNITO USER POOL APP CLIENT ID]",
+ "SignInRedirectURI": "[CUSTOM REDIRECT SCHEME AFTER SIGN IN, e.g. myapp://]",
+ "SignOutRedirectURI": "[CUSTOM REDIRECT SCHEME AFTER SIGN OUT, e.g. myapp://]",
+ "Scopes": [
+ "phone",
+ "email",
+ "openid",
+ "profile",
+ "aws.cognito.signin.user.admin"
+ ]
+ }
+ }
+ }
+ }
+ }
+ }
+}
+```
+
+> For more information on Plugins, see the instructions on [installing Amplify Libraries](/gen1/[platform]/start/project-setup/create-application/#2-install-amplify-libraries).
+
+- **CredentialsProvider**:
+ - **Cognito Identity**:
+ - **Default**:
+ - **PoolID**: ID of the Amazon Cognito Identity Pool (e.g. `us-east-1:123e4567-e89b-12d3-a456-426614174000`)
+ - **Region**: AWS Region where the resources are provisioned (e.g. `us-east-1`)
+- **CognitoUserPool**:
+ - **Default**:
+ - **PoolId**: ID of the Amazon Cognito User Pool (e.g. `us-east-1_abcdefghi`)
+ - **AppClientId**: ID for the client used to authenticate against the user pool
+ - **Region**: AWS Region where the resources are provisioned (e.g. `us-east-1`)
+- **Auth**:
+ - **Default**:
+ - **authenticationFlowType**: The authentication flow type, takes values `USER_SRP_AUTH`, `CUSTOM_AUTH`, and `USER_PASSWORD_AUTH`. Default is `USER_SRP_AUTH`.
+ - **OAuth**: Hosted UI Configuration (only include this if using the Hosted UI flow)
+ - **Scopes:** Scopes should match the scopes enables in Cognito under "App client settings"
+
+If you are using a Cognito User Pool without a Cognito Identity Pool, you can omit the **CredentialsProvider** section in the configuration.
+
+
+
+
diff --git a/src/fragments/lib-v1/auth/native_common/getting_started/common.mdx b/src/fragments/lib-v1/auth/native_common/getting_started/common.mdx
index 70b152ced70..1a96f622afe 100644
--- a/src/fragments/lib-v1/auth/native_common/getting_started/common.mdx
+++ b/src/fragments/lib-v1/auth/native_common/getting_started/common.mdx
@@ -36,15 +36,15 @@ import flutter8 from '/src/fragments/lib-v1/auth/flutter/getting_started/20_inst
The most common way to use Authentication with Amplify is via the Amplify CLI, which allows you to create new Amazon Cognito resources or import existing ones. However, you can also use the Amplify Studio console to configure authentication or use the `Amplify.configure()` method to set up authentication with existing resources.
-import ios50 from '/src/fragments/lib/auth/ios/getting_started/50_configureBackend.mdx';
+import ios50 from '/src/fragments/lib-v1/auth/ios/getting_started/50_configureBackend.mdx';
-import android50 from '/src/fragments/lib/auth/android/getting_started/50_configureBackend.mdx';
+import android50 from '/src/fragments/lib-v1/auth/android/getting_started/50_configureBackend.mdx';
-import flutter70 from '/src/fragments/lib/auth/flutter/getting_started/70_configureBackend.mdx';
+import flutter70 from '/src/fragments/lib-v1/auth/flutter/getting_started/70_configureBackend.mdx';
From f0f6eaf50a01953406ff4bbe0153d657aee6900d Mon Sep 17 00:00:00 2001
From: Kha Truong <64438356+khatruong2009@users.noreply.github.com>
Date: Wed, 15 May 2024 12:53:48 -0700
Subject: [PATCH 04/19] chore: remove unnecessary line for flutter custom
challenge in both prev and current
---
.../flutter/signin_with_custom_flow/40_custom_challenge.mdx | 2 --
.../flutter/signin_with_custom_flow/40_custom_challenge.mdx | 2 --
2 files changed, 4 deletions(-)
diff --git a/src/fragments/lib-v1/auth/flutter/signin_with_custom_flow/40_custom_challenge.mdx b/src/fragments/lib-v1/auth/flutter/signin_with_custom_flow/40_custom_challenge.mdx
index 25d5d2e5831..4bfbd82ef9f 100644
--- a/src/fragments/lib-v1/auth/flutter/signin_with_custom_flow/40_custom_challenge.mdx
+++ b/src/fragments/lib-v1/auth/flutter/signin_with_custom_flow/40_custom_challenge.mdx
@@ -19,6 +19,4 @@ Once the user provides the correct response, they should be authenticated in you
Special Handling on ConfirmSignIn
During a `confirmSignIn` call, if `failAuthentication: true` is returned by the Lambda, the session of the request gets invalidated by Cognito, and a `NotAuthorizedException` is thrown. To recover, the user must initiate a new sign in by calling `Amplify.Auth.signIn`.
-
-Exception: `NotAuthorizedException` with a message `Invalid session for the user.`
diff --git a/src/fragments/lib/auth/flutter/signin_with_custom_flow/40_custom_challenge.mdx b/src/fragments/lib/auth/flutter/signin_with_custom_flow/40_custom_challenge.mdx
index 25d5d2e5831..4bfbd82ef9f 100644
--- a/src/fragments/lib/auth/flutter/signin_with_custom_flow/40_custom_challenge.mdx
+++ b/src/fragments/lib/auth/flutter/signin_with_custom_flow/40_custom_challenge.mdx
@@ -19,6 +19,4 @@ Once the user provides the correct response, they should be authenticated in you
Special Handling on ConfirmSignIn
During a `confirmSignIn` call, if `failAuthentication: true` is returned by the Lambda, the session of the request gets invalidated by Cognito, and a `NotAuthorizedException` is thrown. To recover, the user must initiate a new sign in by calling `Amplify.Auth.signIn`.
-
-Exception: `NotAuthorizedException` with a message `Invalid session for the user.`
From 68a814fc14a5a553cded92ccbdf128952f308582 Mon Sep 17 00:00:00 2001
From: Kha Truong <64438356+khatruong2009@users.noreply.github.com>
Date: Wed, 15 May 2024 12:55:56 -0700
Subject: [PATCH 05/19] chore: make function public in prev and current
---
.../auth/flutter/user_attributes/50_custom_attributes.mdx | 4 ++--
.../lib/auth/flutter/user_attributes/50_custom_attributes.mdx | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/src/fragments/lib-v1/auth/flutter/user_attributes/50_custom_attributes.mdx b/src/fragments/lib-v1/auth/flutter/user_attributes/50_custom_attributes.mdx
index db31a1933f5..28223df913b 100644
--- a/src/fragments/lib-v1/auth/flutter/user_attributes/50_custom_attributes.mdx
+++ b/src/fragments/lib-v1/auth/flutter/user_attributes/50_custom_attributes.mdx
@@ -2,7 +2,7 @@
Amplify Flutter supports [standard OIDC user attributes](https://openid.net/specs/openid-connect-core-1_0.html#StandardClaims) as well as custom attributes. Custom attributes can be instantiated via the custom attribute constructor:
```dart
-Future _signUp({
+Future signUp({
required String username,
required String password,
required String email,
@@ -23,4 +23,4 @@ Future _signUp({
}
```
-When working with a Cognito UserPool, you can set up [custom attributes](https://docs.aws.amazon.com/cognito/latest/developerguide/user-pool-settings-attributes.html#user-pool-settings-custom-attributes) via the Cognito console or AWS CLI. Although Cognito prepends a "custom:" prefix on the attribute name, there is no need for you to add this in Amplify Flutter's custom attribute constructor.
\ No newline at end of file
+When working with a Cognito UserPool, you can set up [custom attributes](https://docs.aws.amazon.com/cognito/latest/developerguide/user-pool-settings-attributes.html#user-pool-settings-custom-attributes) via the Cognito console or AWS CLI. Although Cognito prepends a "custom:" prefix on the attribute name, there is no need for you to add this in Amplify Flutter's custom attribute constructor.
diff --git a/src/fragments/lib/auth/flutter/user_attributes/50_custom_attributes.mdx b/src/fragments/lib/auth/flutter/user_attributes/50_custom_attributes.mdx
index db31a1933f5..28223df913b 100644
--- a/src/fragments/lib/auth/flutter/user_attributes/50_custom_attributes.mdx
+++ b/src/fragments/lib/auth/flutter/user_attributes/50_custom_attributes.mdx
@@ -2,7 +2,7 @@
Amplify Flutter supports [standard OIDC user attributes](https://openid.net/specs/openid-connect-core-1_0.html#StandardClaims) as well as custom attributes. Custom attributes can be instantiated via the custom attribute constructor:
```dart
-Future _signUp({
+Future signUp({
required String username,
required String password,
required String email,
@@ -23,4 +23,4 @@ Future _signUp({
}
```
-When working with a Cognito UserPool, you can set up [custom attributes](https://docs.aws.amazon.com/cognito/latest/developerguide/user-pool-settings-attributes.html#user-pool-settings-custom-attributes) via the Cognito console or AWS CLI. Although Cognito prepends a "custom:" prefix on the attribute name, there is no need for you to add this in Amplify Flutter's custom attribute constructor.
\ No newline at end of file
+When working with a Cognito UserPool, you can set up [custom attributes](https://docs.aws.amazon.com/cognito/latest/developerguide/user-pool-settings-attributes.html#user-pool-settings-custom-attributes) via the Cognito console or AWS CLI. Although Cognito prepends a "custom:" prefix on the attribute name, there is no need for you to add this in Amplify Flutter's custom attribute constructor.
From e36ae80cc6796f802022787c44217ced9a46edec Mon Sep 17 00:00:00 2001
From: Kha Truong <64438356+khatruong2009@users.noreply.github.com>
Date: Wed, 15 May 2024 12:57:46 -0700
Subject: [PATCH 06/19] chore: remove "suppports-only-mobile"
---
.../lib-v1/datastore/flutter/getting-started/20_installLib.mdx | 2 +-
.../lib/datastore/flutter/getting-started/20_installLib.mdx | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/fragments/lib-v1/datastore/flutter/getting-started/20_installLib.mdx b/src/fragments/lib-v1/datastore/flutter/getting-started/20_installLib.mdx
index 206bfaea652..f037d40c76f 100644
--- a/src/fragments/lib-v1/datastore/flutter/getting-started/20_installLib.mdx
+++ b/src/fragments/lib-v1/datastore/flutter/getting-started/20_installLib.mdx
@@ -7,7 +7,7 @@ dependencies:
flutter:
sdk: flutter
- amplify_datastore: ^1.0.0-supports-only-mobile
+ amplify_datastore: ^1.0.0
amplify_flutter: ^1.0.0
```
diff --git a/src/fragments/lib/datastore/flutter/getting-started/20_installLib.mdx b/src/fragments/lib/datastore/flutter/getting-started/20_installLib.mdx
index 08f767302e3..e10d4d2f91d 100644
--- a/src/fragments/lib/datastore/flutter/getting-started/20_installLib.mdx
+++ b/src/fragments/lib/datastore/flutter/getting-started/20_installLib.mdx
@@ -7,7 +7,7 @@ dependencies:
flutter:
sdk: flutter
- amplify_datastore: 2.0.0-supports-only-mobile
+ amplify_datastore: 2.0.0
amplify_flutter: ^2.0.0
```
From 207b9e5fa6e8d45bbcf03aec203b18e05bb499a4 Mon Sep 17 00:00:00 2001
From: Kha Truong <64438356+khatruong2009@users.noreply.github.com>
Date: Wed, 15 May 2024 13:17:42 -0700
Subject: [PATCH 07/19] chore: remove unnecessary inline filters and put back
an upload fragment
---
src/fragments/lib-v1/storage/flutter/upload.mdx | 14 --------------
.../native_common/getting-started/common.mdx | 13 +++++--------
2 files changed, 5 insertions(+), 22 deletions(-)
diff --git a/src/fragments/lib-v1/storage/flutter/upload.mdx b/src/fragments/lib-v1/storage/flutter/upload.mdx
index e185ed2b4a7..343d98e9fe9 100644
--- a/src/fragments/lib-v1/storage/flutter/upload.mdx
+++ b/src/fragments/lib-v1/storage/flutter/upload.mdx
@@ -1,22 +1,8 @@
-
## Upload File
To upload to S3 from a file, specify the `key` to upload the file to and the `localFile` to be uploaded. `localFile` can be an instance of `AWSFile` created from either an OS platform `File` instance or the result of Flutter file picker plugins such as [file_picker](https://pub.dev/packages/file_picker).
-
-
-## Upload File
-
-To upload to S3 from a file, specify the key and the local file to be uploaded. A file can be created locally, or retrieved from the user's device using a package such as [image_picker](https://pub.dev/packages/image_picker) or [file_picker](https://pub.dev/packages/file_picker).
-
-
-
-### Upload a local file
-
-
-
### Upload platform `File`
-
diff --git a/src/fragments/lib-v1/storage/native_common/getting-started/common.mdx b/src/fragments/lib-v1/storage/native_common/getting-started/common.mdx
index 1cbac772919..62bf17891a7 100644
--- a/src/fragments/lib-v1/storage/native_common/getting-started/common.mdx
+++ b/src/fragments/lib-v1/storage/native_common/getting-started/common.mdx
@@ -99,11 +99,9 @@ import flutter11 from '/src/fragments/lib-v1/storage/flutter/getting-started/30_
-
## Uploading data to your bucket
To upload to S3 from a data object, specify the key and the data object to be uploaded.
-
import ios12 from '/src/fragments/lib-v1/storage/ios/getting-started/40_upload.mdx';
@@ -113,7 +111,10 @@ import android13 from '/src/fragments/lib-v1/storage/android/getting-started/40_
-
+import flutter14 from '/src/fragments/lib-v1/storage/flutter/getting-started/40_upload.mdx';
+
+
+
Upon successfully executing this code, you should see a new folder in your bucket, called `public`. It should contain a file called `ExampleKey`, whose contents is `Example file contents`.
## Next Steps
@@ -126,8 +127,4 @@ Congratulations! You've uploaded a file to an s3 bucket. Check out the following
- [Remove Files](/gen1/[platform]/prev/build-a-backend/storage/remove/)
- [File Access Levels](/gen1/[platform]/prev/build-a-backend/storage/configure-access/)
- [Using Lambda Triggers](/gen1/[platform]/prev/build-a-backend/storage/lambda-triggers/)
-
-
-
- - [Escape Hatch](/gen1/[platform]/prev/build-a-backend/storage/sdk/)
-
+- [Escape Hatch](/gen1/[platform]/prev/build-a-backend/storage/sdk/)
From 62fea4327bf32d984ba722acb4844a6c309ec5d1 Mon Sep 17 00:00:00 2001
From: Kha Truong <64438356+khatruong2009@users.noreply.github.com>
Date: Wed, 15 May 2024 13:21:26 -0700
Subject: [PATCH 08/19] chore: remove unnecessary inline filter from graphql
link
---
.../lib/graphqlapi/native_common/getting-started/common.mdx | 2 --
1 file changed, 2 deletions(-)
diff --git a/src/fragments/lib/graphqlapi/native_common/getting-started/common.mdx b/src/fragments/lib/graphqlapi/native_common/getting-started/common.mdx
index fa7be102d72..873eff2a373 100644
--- a/src/fragments/lib/graphqlapi/native_common/getting-started/common.mdx
+++ b/src/fragments/lib/graphqlapi/native_common/getting-started/common.mdx
@@ -141,8 +141,6 @@ Congratulations! You've created a `Todo` object in your database. Check out the
- [Update data](/gen1/[platform]/build-a-backend/graphqlapi/mutate-data/)
- [Subscribe to data](/gen1/[platform]/build-a-backend/graphqlapi/subscribe-data/)
- [Concepts](/gen1/[platform]/build-a-backend/graphqlapi/api-graphql-concepts/)
-
- [Configure authorization modes](/gen1/[platform]/build-a-backend/graphqlapi/customize-authorization-rules)
-
{/* TODO: * [Authorizing API calls with Cognito User Pool] */}
From 113084d4a1527e5bd2a36b8bc8ff85beed4722e6 Mon Sep 17 00:00:00 2001
From: Kha Truong <64438356+khatruong2009@users.noreply.github.com>
Date: Wed, 15 May 2024 13:22:02 -0700
Subject: [PATCH 09/19] chore: remove unintentionally added line
---
src/fragments/lib/storage/flutter/list.mdx | 1 -
1 file changed, 1 deletion(-)
diff --git a/src/fragments/lib/storage/flutter/list.mdx b/src/fragments/lib/storage/flutter/list.mdx
index 0d361e77f4a..149be23d0cb 100644
--- a/src/fragments/lib/storage/flutter/list.mdx
+++ b/src/fragments/lib/storage/flutter/list.mdx
@@ -54,4 +54,3 @@ Future listAll() async {
}
}
```
-import { delimiter } from "path"
From e4882797752855a9bb1da31eca0a70de157a86f3 Mon Sep 17 00:00:00 2001
From: Kha Truong <64438356+khatruong2009@users.noreply.github.com>
Date: Wed, 15 May 2024 13:23:27 -0700
Subject: [PATCH 10/19] chore: move flutter back to the top of the platforms
list
---
.../build-a-backend/graphqlapi/customize-authz-modes/index.mdx | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/customize-authz-modes/index.mdx b/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/customize-authz-modes/index.mdx
index 145cdc29265..2cefbe378b8 100644
--- a/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/customize-authz-modes/index.mdx
+++ b/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/customize-authz-modes/index.mdx
@@ -4,11 +4,11 @@ export const meta = {
title: 'Customize your auth rules',
description: "Learn more about how to configure authorization modes in Amplify's API category",
platforms: [
+ 'flutter',
'javascript',
'react-native',
'swift',
'android',
- 'flutter',
'angular',
'nextjs',
'react',
From 185486c6d8f3fbcbaecd19a8d77f1325db7103fb Mon Sep 17 00:00:00 2001
From: Kha Truong <64438356+khatruong2009@users.noreply.github.com>
Date: Wed, 15 May 2024 13:46:57 -0700
Subject: [PATCH 11/19] chore: delete before you begin snippet for grapql vprev
---
.../prev/build-a-backend/graphqlapi/mutate-data/index.mdx | 4 ----
.../prev/build-a-backend/graphqlapi/query-data/index.mdx | 5 -----
.../prev/build-a-backend/graphqlapi/subscribe-data/index.mdx | 5 -----
3 files changed, 14 deletions(-)
diff --git a/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/mutate-data/index.mdx b/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/mutate-data/index.mdx
index 12007c02301..13411e6f6a2 100644
--- a/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/mutate-data/index.mdx
+++ b/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/mutate-data/index.mdx
@@ -56,10 +56,6 @@ import flutter3 from '/src/fragments/lib-v1/graphqlapi/flutter/mutate-data.mdx';
In this guide, you will learn how to create, update, and delete your data using Amplify Libraries' GraphQL client.
-Before you begin, you will need:
-
-- An [application connected to the API](/gen1/[platform]/prev/build-a-backend/graphqlapi/set-up-graphql-api/)
-
## Run mutations to create, update, and delete application data
In GraphQL, mutations are APIs that are used to create, update, or delete data. This is different than queries, which are used to read the data but not change it. The following examples demonstrate how you can create, update, and delete items using the Amplify GraphQL client.
diff --git a/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/query-data/index.mdx b/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/query-data/index.mdx
index 64e69379031..37725328575 100644
--- a/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/query-data/index.mdx
+++ b/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/query-data/index.mdx
@@ -33,11 +33,6 @@ export function getStaticProps(context) {
You can read application data using the Amplify GraphQL client. In this guide, we will review the difference between reading data and getting data, how to filter query results to get just the data you need, and how to paginate results to make your data more manageable. We will also show you how to cancel these requests when needed.
-Before you begin, you will need:
-
-- An [application connected to the API](/gen1/[platform]/prev/build-a-backend/graphqlapi/set-up-graphql-api/)
-- Data already created to view
-
## List and get your data
Queries are used to read data through the API and include the `list` and `get` operations.
diff --git a/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/subscribe-data/index.mdx b/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/subscribe-data/index.mdx
index 75864a69620..92101b2d692 100644
--- a/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/subscribe-data/index.mdx
+++ b/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/subscribe-data/index.mdx
@@ -33,11 +33,6 @@ export function getStaticProps(context) {
In this guide, we will outline the benefits of enabling real-time data integrations and how to set up and filter these subscriptions. We will also cover how to unsubscribe from subscriptions.
-Before you begin, you will need:
-
-- An [application connected to the API](/gen1/[platform]/prev/build-a-backend/graphqlapi/set-up-graphql-api/)
-- Data already created to modify
-
## Set up a real-time subscription
Subscriptions is a GraphQL feature that allows the server to send data to its clients when a specific event happens. For example, you can subscribe to an event when a new record is created, updated, or deleted through the API. You can enable real-time data integration in your app with a subscription.
From 9c4daf57a9c39faf14823520fe848f091e0d7887 Mon Sep 17 00:00:00 2001
From: Kha Truong <64438356+khatruong2009@users.noreply.github.com>
Date: Wed, 15 May 2024 13:56:10 -0700
Subject: [PATCH 12/19] chore: add picture back in to vprev flutter storage
page
---
.../[platform]/prev/build-a-backend/storage/index.mdx | 11 -----------
1 file changed, 11 deletions(-)
diff --git a/src/pages/gen1/[platform]/prev/build-a-backend/storage/index.mdx b/src/pages/gen1/[platform]/prev/build-a-backend/storage/index.mdx
index 55d9c346910..37b9a4b0a5b 100644
--- a/src/pages/gen1/[platform]/prev/build-a-backend/storage/index.mdx
+++ b/src/pages/gen1/[platform]/prev/build-a-backend/storage/index.mdx
@@ -39,18 +39,7 @@ import flutter_maintenance from '/src/fragments/lib-v1/flutter-maintenance.mdx';
AWS Amplify storage module provides a simple mechanism for managing user content for your app in public, protected or private storage buckets. The storage category comes with built-in support for [Amazon S3 (Simple Storage Service)](https://docs.aws.amazon.com/AmazonS3/latest/dev/Welcome.html).
-

-
## S3 Core Concepts
From 1339de93e363b84c3309ed0ad5bfa7a1b051b31f Mon Sep 17 00:00:00 2001
From: Kha Truong <64438356+khatruong2009@users.noreply.github.com>
Date: Wed, 15 May 2024 13:58:00 -0700
Subject: [PATCH 13/19] chore: revert flutter import changes back to original
---
.../graphqlapi/native_common/getting-started/common.mdx | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/fragments/lib-v1/graphqlapi/native_common/getting-started/common.mdx b/src/fragments/lib-v1/graphqlapi/native_common/getting-started/common.mdx
index 5af5112b801..4f6f601aedb 100644
--- a/src/fragments/lib-v1/graphqlapi/native_common/getting-started/common.mdx
+++ b/src/fragments/lib-v1/graphqlapi/native_common/getting-started/common.mdx
@@ -83,9 +83,9 @@ import android8 from '/src/fragments/lib-v1/graphqlapi/android/getting-started/4
-import flutter18 from '/src/fragments/lib-v1/graphqlapi/flutter/getting-started/40_codegen.mdx';
+import flutter7 from '/src/fragments/lib-v1/graphqlapi/flutter/getting-started/40_codegen.mdx';
-
+
## Install Amplify Libraries
From caead540006e1bfd8ba5c00edb5b0849af2a0f4b Mon Sep 17 00:00:00 2001
From: Kha Truong <64438356+khatruong2009@users.noreply.github.com>
Date: Wed, 15 May 2024 14:32:07 -0700
Subject: [PATCH 14/19] chore: clean up preReq snippets
---
.../analytics/flutter/getting-started/10_preReq.mdx | 10 ++--------
.../graphqlapi/flutter/getting-started/10_preReq.mdx | 10 +---------
.../restapi/flutter/getting-started/10_preReq.mdx | 10 +---------
.../storage/flutter/getting-started/10_preReq.mdx | 11 ++---------
.../analytics/flutter/getting-started/10_preReq.mdx | 10 ++--------
.../lib/auth/flutter/getting_started/10_preReq.mdx | 4 +++-
.../graphqlapi/flutter/getting-started/10_preReq.mdx | 10 +---------
.../restapi/flutter/getting-started/10_preReq.mdx | 10 +---------
.../storage/flutter/getting-started/10_preReq.mdx | 10 ++--------
.../analytics/set-up-analytics/index.mdx | 10 ++--------
.../build-a-backend/storage/set-up-storage/index.mdx | 12 +++---------
11 files changed, 20 insertions(+), 87 deletions(-)
diff --git a/src/fragments/lib-v1/analytics/flutter/getting-started/10_preReq.mdx b/src/fragments/lib-v1/analytics/flutter/getting-started/10_preReq.mdx
index 3f7febfd2b4..16c98fc9109 100644
--- a/src/fragments/lib-v1/analytics/flutter/getting-started/10_preReq.mdx
+++ b/src/fragments/lib-v1/analytics/flutter/getting-started/10_preReq.mdx
@@ -1,9 +1,3 @@
- The following are required, depending on which platforms you are targeting:
+* [Install and configure Amplify CLI](/gen1/[platform]/tools/cli/start/set-up-cli/)
- - An iOS configuration targeting at least iOS 13.0 and XCode version >=13.2
- - An Android configuration targeting at least Android API level 24 (Android 7.0) or above
- - Any browser supported by Flutter for Web (you can check the list of supported browsers [here](https://docs.flutter.dev/development/platform-integration/web/faq#which-web-browsers-are-supported-by-flutter))
- - Any Windows OS meeting Flutter minimums
- - macOS version 10.15 or higher
- - Any Ubuntu Linux distribution meeting Flutter minimums
- - For a full example please follow the [project setup walkthrough](/gen1/[platform]/prev/start/project-setup/create-application/)
+Amplify Flutter requires a minimum target platform for iOS (13.0), Android (API level 24), and macOS (10.15). Additional setup is required for some target platforms. Please see the [platform setup](/gen1/[platform]/prev/start/project-setup/platform-setup/) guide for more details on platform specific setup.
diff --git a/src/fragments/lib-v1/graphqlapi/flutter/getting-started/10_preReq.mdx b/src/fragments/lib-v1/graphqlapi/flutter/getting-started/10_preReq.mdx
index ded735d6f00..16c98fc9109 100644
--- a/src/fragments/lib-v1/graphqlapi/flutter/getting-started/10_preReq.mdx
+++ b/src/fragments/lib-v1/graphqlapi/flutter/getting-started/10_preReq.mdx
@@ -1,11 +1,3 @@
* [Install and configure Amplify CLI](/gen1/[platform]/tools/cli/start/set-up-cli/)
-
- The following are required, depending on which platforms you are targeting:
- * An iOS configuration targeting at least iOS 13.0 and XCode version >=13.2
- * An Android configuration targeting at least Android API level 24 (Android 7.0) or above
- * Any browser supported by Flutter for Web (you can check the list of supported browsers [here](https://docs.flutter.dev/development/platform-integration/web/faq#which-web-browsers-are-supported-by-flutter))
- * Any Windows OS meeting Flutter minimums
- * macOS version 10.15 or higher
- * Any Ubuntu Linux distribution meeting Flutter minimums
- * For a full example please follow the [project setup walkthrough](/gen1/[platform]/prev/start/project-setup/create-application/)
+Amplify Flutter requires a minimum target platform for iOS (13.0), Android (API level 24), and macOS (10.15). Additional setup is required for some target platforms. Please see the [platform setup](/gen1/[platform]/prev/start/project-setup/platform-setup/) guide for more details on platform specific setup.
diff --git a/src/fragments/lib-v1/restapi/flutter/getting-started/10_preReq.mdx b/src/fragments/lib-v1/restapi/flutter/getting-started/10_preReq.mdx
index 2898b280a8a..16c98fc9109 100644
--- a/src/fragments/lib-v1/restapi/flutter/getting-started/10_preReq.mdx
+++ b/src/fragments/lib-v1/restapi/flutter/getting-started/10_preReq.mdx
@@ -1,11 +1,3 @@
* [Install and configure Amplify CLI](/gen1/[platform]/tools/cli/start/set-up-cli/)
-
- The following are required, depending on which platforms you are targeting:
- * An iOS configuration targeting at least iOS 13.0 and XCode version >=13.2
- * An Android configuration targeting at least Android API level 24 (Android 7.0) or above
- * Any browser supported by Flutter for Web (you can check the list of supported browsers [here](https://docs.flutter.dev/development/platform-integration/web/faq#which-web-browsers-are-supported-by-flutter))
- * Any Windows OS meeting Flutter minimums
- * macOS version 10.15 or higher
- * Any Ubuntu Linux distribution meeting Flutter minimums
- * For a full example please follow the [project setup walkthrough](/gen1/[platform]/start/project-setup/create-application/)
+Amplify Flutter requires a minimum target platform for iOS (13.0), Android (API level 24), and macOS (10.15). Additional setup is required for some target platforms. Please see the [platform setup](/gen1/[platform]/prev/start/project-setup/platform-setup/) guide for more details on platform specific setup.
diff --git a/src/fragments/lib-v1/storage/flutter/getting-started/10_preReq.mdx b/src/fragments/lib-v1/storage/flutter/getting-started/10_preReq.mdx
index 234c7fdac2c..16c98fc9109 100644
--- a/src/fragments/lib-v1/storage/flutter/getting-started/10_preReq.mdx
+++ b/src/fragments/lib-v1/storage/flutter/getting-started/10_preReq.mdx
@@ -1,10 +1,3 @@
+* [Install and configure Amplify CLI](/gen1/[platform]/tools/cli/start/set-up-cli/)
- The following are required, depending on which platforms you are targeting:
-
- * An iOS configuration targeting at least iOS 13.0 and XCode version >=13.2
- * An Android configuration targeting at least Android API level 24 (Android 7.0) or above
- * Any browser supported by Flutter for Web (you can check the list of supported browsers [here](https://docs.flutter.dev/development/platform-integration/web/faq#which-web-browsers-are-supported-by-flutter))
- * Any Windows OS meeting Flutter minimums
- * macOS version 10.15 or higher
- * Any Ubuntu Linux distribution meeting Flutter minimums
- * For a full example please follow the [project setup walkthrough](/gen1/[platform]/start/project-setup/create-application/)
+Amplify Flutter requires a minimum target platform for iOS (13.0), Android (API level 24), and macOS (10.15). Additional setup is required for some target platforms. Please see the [platform setup](/gen1/[platform]/prev/start/project-setup/platform-setup/) guide for more details on platform specific setup.
diff --git a/src/fragments/lib/analytics/flutter/getting-started/10_preReq.mdx b/src/fragments/lib/analytics/flutter/getting-started/10_preReq.mdx
index 25b3facc2a9..1acefc397fd 100644
--- a/src/fragments/lib/analytics/flutter/getting-started/10_preReq.mdx
+++ b/src/fragments/lib/analytics/flutter/getting-started/10_preReq.mdx
@@ -1,9 +1,3 @@
- The following are required, depending on which platforms you are targeting:
+* [Install and configure Amplify CLI](/gen1/[platform]/tools/cli/start/set-up-cli/)
- - An iOS configuration targeting at least iOS 13.0 and XCode version >=13.2
- - An Android configuration targeting at least Android API level 24 (Android 7.0) or above
- - Any browser supported by Flutter for Web (you can check the list of supported browsers [here](https://docs.flutter.dev/development/platform-integration/web/faq#which-web-browsers-are-supported-by-flutter))
- - Any Windows OS meeting Flutter minimums
- - macOS version 10.15 or higher
- - Any Ubuntu Linux distribution meeting Flutter minimums
- - For a full example please follow the [project setup walkthrough](/gen1/[platform]/start/project-setup/create-application/)
+Amplify Flutter requires a minimum target platform for iOS (13.0), Android (API level 24), and macOS (10.15). Additional setup is required for some target platforms. Please see the [platform setup](/gen1/[platform]/start/project-setup/platform-setup/) guide for more details on platform specific setup.
diff --git a/src/fragments/lib/auth/flutter/getting_started/10_preReq.mdx b/src/fragments/lib/auth/flutter/getting_started/10_preReq.mdx
index f5aea597eb7..1acefc397fd 100644
--- a/src/fragments/lib/auth/flutter/getting_started/10_preReq.mdx
+++ b/src/fragments/lib/auth/flutter/getting_started/10_preReq.mdx
@@ -1 +1,3 @@
-Amplify requires a minimum target platform for iOS (13.0), Android (API level 24), and macOS (10.15). Additional setup is required for some target platforms. Please see the [platform setup](/gen1/[platform]/start/project-setup/platform-setup/) guide for more details on platform specific setup.
+* [Install and configure Amplify CLI](/gen1/[platform]/tools/cli/start/set-up-cli/)
+
+Amplify Flutter requires a minimum target platform for iOS (13.0), Android (API level 24), and macOS (10.15). Additional setup is required for some target platforms. Please see the [platform setup](/gen1/[platform]/start/project-setup/platform-setup/) guide for more details on platform specific setup.
diff --git a/src/fragments/lib/graphqlapi/flutter/getting-started/10_preReq.mdx b/src/fragments/lib/graphqlapi/flutter/getting-started/10_preReq.mdx
index 2898b280a8a..1acefc397fd 100644
--- a/src/fragments/lib/graphqlapi/flutter/getting-started/10_preReq.mdx
+++ b/src/fragments/lib/graphqlapi/flutter/getting-started/10_preReq.mdx
@@ -1,11 +1,3 @@
* [Install and configure Amplify CLI](/gen1/[platform]/tools/cli/start/set-up-cli/)
-
- The following are required, depending on which platforms you are targeting:
- * An iOS configuration targeting at least iOS 13.0 and XCode version >=13.2
- * An Android configuration targeting at least Android API level 24 (Android 7.0) or above
- * Any browser supported by Flutter for Web (you can check the list of supported browsers [here](https://docs.flutter.dev/development/platform-integration/web/faq#which-web-browsers-are-supported-by-flutter))
- * Any Windows OS meeting Flutter minimums
- * macOS version 10.15 or higher
- * Any Ubuntu Linux distribution meeting Flutter minimums
- * For a full example please follow the [project setup walkthrough](/gen1/[platform]/start/project-setup/create-application/)
+Amplify Flutter requires a minimum target platform for iOS (13.0), Android (API level 24), and macOS (10.15). Additional setup is required for some target platforms. Please see the [platform setup](/gen1/[platform]/start/project-setup/platform-setup/) guide for more details on platform specific setup.
diff --git a/src/fragments/lib/restapi/flutter/getting-started/10_preReq.mdx b/src/fragments/lib/restapi/flutter/getting-started/10_preReq.mdx
index 2898b280a8a..1acefc397fd 100644
--- a/src/fragments/lib/restapi/flutter/getting-started/10_preReq.mdx
+++ b/src/fragments/lib/restapi/flutter/getting-started/10_preReq.mdx
@@ -1,11 +1,3 @@
* [Install and configure Amplify CLI](/gen1/[platform]/tools/cli/start/set-up-cli/)
-
- The following are required, depending on which platforms you are targeting:
- * An iOS configuration targeting at least iOS 13.0 and XCode version >=13.2
- * An Android configuration targeting at least Android API level 24 (Android 7.0) or above
- * Any browser supported by Flutter for Web (you can check the list of supported browsers [here](https://docs.flutter.dev/development/platform-integration/web/faq#which-web-browsers-are-supported-by-flutter))
- * Any Windows OS meeting Flutter minimums
- * macOS version 10.15 or higher
- * Any Ubuntu Linux distribution meeting Flutter minimums
- * For a full example please follow the [project setup walkthrough](/gen1/[platform]/start/project-setup/create-application/)
+Amplify Flutter requires a minimum target platform for iOS (13.0), Android (API level 24), and macOS (10.15). Additional setup is required for some target platforms. Please see the [platform setup](/gen1/[platform]/start/project-setup/platform-setup/) guide for more details on platform specific setup.
diff --git a/src/fragments/lib/storage/flutter/getting-started/10_preReq.mdx b/src/fragments/lib/storage/flutter/getting-started/10_preReq.mdx
index 094bbfa9d3d..1acefc397fd 100644
--- a/src/fragments/lib/storage/flutter/getting-started/10_preReq.mdx
+++ b/src/fragments/lib/storage/flutter/getting-started/10_preReq.mdx
@@ -1,9 +1,3 @@
- The following are required, depending on which platforms you are targeting:
+* [Install and configure Amplify CLI](/gen1/[platform]/tools/cli/start/set-up-cli/)
- * An iOS configuration targeting at least iOS 13.0 and XCode version >=13.2
- * An Android configuration targeting at least Android API level 24 (Android 7.0) or above
- * Any browser supported by Flutter for Web (you can check the list of supported browsers [here](https://docs.flutter.dev/development/platform-integration/web/faq#which-web-browsers-are-supported-by-flutter))
- * Any Windows OS meeting Flutter minimums
- * macOS version 10.15 or higher
- * Any Ubuntu Linux distribution meeting Flutter minimums
- * For a full example please follow the [project setup walkthrough](/gen1/[platform]/start/project-setup/create-application/)
+Amplify Flutter requires a minimum target platform for iOS (13.0), Android (API level 24), and macOS (10.15). Additional setup is required for some target platforms. Please see the [platform setup](/gen1/[platform]/start/project-setup/platform-setup/) guide for more details on platform specific setup.
diff --git a/src/pages/[platform]/build-a-backend/add-aws-services/analytics/set-up-analytics/index.mdx b/src/pages/[platform]/build-a-backend/add-aws-services/analytics/set-up-analytics/index.mdx
index a50de0854cf..0789ac9b503 100644
--- a/src/pages/[platform]/build-a-backend/add-aws-services/analytics/set-up-analytics/index.mdx
+++ b/src/pages/[platform]/build-a-backend/add-aws-services/analytics/set-up-analytics/index.mdx
@@ -60,14 +60,8 @@ For more information on how to use the `visionos-preview` branch, see [Platform
- The following are required, depending on which platforms you are targeting:
-
- - An iOS configuration targeting at least iOS 13.0 and XCode version >=13.2
- - An Android configuration targeting at least Android API level 24 (Android 7.0) or above
- - Any browser supported by Flutter for Web (you can check the list of supported browsers [here](https://docs.flutter.dev/development/platform-integration/web/faq#which-web-browsers-are-supported-by-flutter))
- - Any Windows OS meeting Flutter minimums
- - macOS version 10.15 or higher
- - Any Ubuntu Linux distribution meeting Flutter minimums
+Amplify Flutter requires a minimum target platform for iOS (13.0), Android (API level 24), and macOS (10.15). Additional setup is required for some target platforms. Please see the [platform setup](/[platform]/start/) guide for more details on platform specific setup.
+
diff --git a/src/pages/[platform]/build-a-backend/storage/set-up-storage/index.mdx b/src/pages/[platform]/build-a-backend/storage/set-up-storage/index.mdx
index 6477829867a..4cb0031afe7 100644
--- a/src/pages/[platform]/build-a-backend/storage/set-up-storage/index.mdx
+++ b/src/pages/[platform]/build-a-backend/storage/set-up-storage/index.mdx
@@ -410,15 +410,9 @@ Note that because the storage category requires auth, you will need to either co
### Prerequisites
- The following are required, depending on which platforms you are targeting:
-
- * An iOS configuration targeting at least iOS 13.0 and XCode version >=13.2
- * An Android configuration targeting at least Android API level 24 (Android 7.0) or above
- * Any browser supported by Flutter for Web (you can check the list of supported browsers [here](https://docs.flutter.dev/development/platform-integration/web/faq#which-web-browsers-are-supported-by-flutter))
- * Any Windows OS meeting Flutter minimums
- * macOS version 10.15 or higher
- * Any Ubuntu Linux distribution meeting Flutter minimums
- * For a full example please follow the [project setup walkthrough](/[platform]/start/quickstart/)
+* [Install and configure Amplify CLI](/gen1/[platform]/tools/cli/start/set-up-cli/)
+
+Amplify Flutter requires a minimum target platform for iOS (13.0), Android (API level 24), and macOS (10.15). Additional setup is required for some target platforms. Please see the [platform setup](/gen1/[platform]/start/) guide for more details on platform specific setup.
### Install Amplify library
From afe203c86006e4afb0e3db9cf17d62d275cd95f6 Mon Sep 17 00:00:00 2001
From: Kha Truong <64438356+khatruong2009@users.noreply.github.com>
Date: Thu, 16 May 2024 07:31:08 -0700
Subject: [PATCH 15/19] chore: add title="Terminal" showLineNumbers={false} to
terminal snippets
---
.../android/getting_started/50_configureBackend.mdx | 10 +++++-----
.../auth/ios/getting_started/50_configureBackend.mdx | 10 +++++-----
2 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/src/fragments/lib-v1/auth/android/getting_started/50_configureBackend.mdx b/src/fragments/lib-v1/auth/android/getting_started/50_configureBackend.mdx
index edd49e24ead..244879cac22 100644
--- a/src/fragments/lib-v1/auth/android/getting_started/50_configureBackend.mdx
+++ b/src/fragments/lib-v1/auth/android/getting_started/50_configureBackend.mdx
@@ -5,7 +5,7 @@
To start provisioning auth resources in the backend, go to your project directory and **execute the command**:
-```bash
+```bash title="Terminal" showLineNumbers={false}
amplify add auth
```
@@ -24,7 +24,7 @@ Enter the following when prompted:
To push your changes to the cloud, **execute the command**:
-```bash
+```bash title="Terminal" showLineNumbers={false}
amplify push
```
@@ -40,7 +40,7 @@ import android5 from '/src/fragments/lib/auth/android/getting_started/12_amplify
To import existing Amazon Cognito resources into your Amplify project, **execute the command**:
-```bash
+```bash title="Terminal" showLineNumbers={false}
amplify import auth
```
@@ -60,13 +60,13 @@ Once you've selected an option, you'll be able to search for and import an exist
After configuring your Authentication options, update your backend and deploy the service by running the `push` command:
-```bash
+```bash title="Terminal" showLineNumbers={false}
amplify push
```
Now, the authentication service has been deployed and you can start using it. To view the deployed services in your project at any time, go to Amplify Console by running the following command:
-```bash
+```bash title="Terminal" showLineNumbers={false}
amplify console
```
diff --git a/src/fragments/lib-v1/auth/ios/getting_started/50_configureBackend.mdx b/src/fragments/lib-v1/auth/ios/getting_started/50_configureBackend.mdx
index e11b6c6f264..8bb583f4603 100644
--- a/src/fragments/lib-v1/auth/ios/getting_started/50_configureBackend.mdx
+++ b/src/fragments/lib-v1/auth/ios/getting_started/50_configureBackend.mdx
@@ -5,7 +5,7 @@
To start provisioning auth resources in the backend, go to your project directory and **execute the command**:
-```bash
+```bash title="Terminal" showLineNumbers={false}
amplify add auth
```
@@ -24,7 +24,7 @@ Enter the following when prompted:
To push your changes to the cloud, **execute the command**:
-```bash
+```bash title="Terminal" showLineNumbers={false}
amplify push
```
@@ -48,7 +48,7 @@ import flutter5 from '/src/fragments/lib/auth/flutter/getting_started/12_amplify
To import existing Amazon Cognito resources into your Amplify project, **execute the command**:
-```bash
+```bash title="Terminal" showLineNumbers={false}
amplify import auth
```
@@ -68,7 +68,7 @@ Once you've selected an option, you'll be able to search for and import an exist
After configuring your Authentication options, update your backend and deploy the service by running the `push` command:
-```bash
+```bash title="Terminal" showLineNumbers={false}
amplify push
```
@@ -76,7 +76,7 @@ Upon completion, `amplifyconfiguration.json` should be updated to reference prov
Now, the authentication service has been deployed and you can start using it. To view the deployed services in your project at any time, go to Amplify Console by running the following command:
-```bash
+```bash title="Terminal" showLineNumbers={false}
amplify console
```
From 74f81389d093e9e05a58a9393d094807532c7d1b Mon Sep 17 00:00:00 2001
From: Kha Truong <64438356+khatruong2009@users.noreply.github.com>
Date: Thu, 16 May 2024 12:44:31 -0700
Subject: [PATCH 16/19] chore: revert changes that are out of scope
---
.../getting_started/50_configureBackend.mdx | 188 ----------------
.../getting_started/50_configureBackend.mdx | 200 ------------------
.../native_common/getting_started/common.mdx | 6 +-
3 files changed, 3 insertions(+), 391 deletions(-)
delete mode 100644 src/fragments/lib-v1/auth/android/getting_started/50_configureBackend.mdx
delete mode 100644 src/fragments/lib-v1/auth/ios/getting_started/50_configureBackend.mdx
diff --git a/src/fragments/lib-v1/auth/android/getting_started/50_configureBackend.mdx b/src/fragments/lib-v1/auth/android/getting_started/50_configureBackend.mdx
deleted file mode 100644
index 244879cac22..00000000000
--- a/src/fragments/lib-v1/auth/android/getting_started/50_configureBackend.mdx
+++ /dev/null
@@ -1,188 +0,0 @@
-
-
-
-> Prerequisites: [Install and configure](/gen1/[platform]/prev/start/project-setup/prerequisites/#install-and-configure-the-amplify-cli) the Amplify CLI in addition to the Amplify libraries and [necessary dependencies](/gen1/[platform]/prev/build-a-backend/auth/set-up-auth/#install-amplify-libraries).
-
-To start provisioning auth resources in the backend, go to your project directory and **execute the command**:
-
-```bash title="Terminal" showLineNumbers={false}
-amplify add auth
-```
-
-Enter the following when prompted:
-
-```console
-? Do you want to use the default authentication and security configuration?
- `Default configuration`
-? How do you want users to be able to sign in?
- `Username`
-? Do you want to configure advanced settings?
- `No, I am done.`
-```
-
-> If you have previously enabled an Amplify category that uses Auth behind the scenes (e.g. API category), you can run the `amplify update auth` command to edit your configuration if needed.
-
-To push your changes to the cloud, **execute the command**:
-
-```bash title="Terminal" showLineNumbers={false}
-amplify push
-```
-
-import android5 from '/src/fragments/lib/auth/android/getting_started/12_amplifyConfig.mdx';
-
-
-
-
-
-
-
-> Prerequisites: [Install and configure](/gen1/[platform]/start/project-setup/prerequisites/#install-and-configure-the-amplify-cli) the Amplify CLI in addition to the Amplify libraries and [necessary dependencies](/gen1/[platform]/build-a-backend/auth/set-up-auth/#install-amplify-libraries).
-
-To import existing Amazon Cognito resources into your Amplify project, **execute the command**:
-
-```bash title="Terminal" showLineNumbers={false}
-amplify import auth
-```
-
-```console
-? What type of auth resource do you want to import?
- Cognito User Pool and Identity Pool
- Cognito User Pool only
-```
-
-Once you've selected an option, you'll be able to search for and import an existing Cognito User Pool and Identity Pool (or User Pool only) within your AWS account. The `amplify import auth` command will also do the following:
-
-- Automatically populate your Amplify Library configuration file (`amplifyconfiguration.json`) with your chosen Amazon Cognito resource information
-- Provide your designated existing Cognito resource as the authentication & authorization mechanism for all auth-dependent categories (API, Storage and more)
-- Enable Lambda functions to access the chosen Cognito resource if you permit it
-
-> If you have previously enabled an Amplify category that uses Auth behind the scenes (e.g. API category), you can run the `amplify update auth` command to edit your configuration if needed.
-
-After configuring your Authentication options, update your backend and deploy the service by running the `push` command:
-
-```bash title="Terminal" showLineNumbers={false}
-amplify push
-```
-
-Now, the authentication service has been deployed and you can start using it. To view the deployed services in your project at any time, go to Amplify Console by running the following command:
-
-```bash title="Terminal" showLineNumbers={false}
-amplify console
-```
-
-For more details, see how to [Use an existing Cognito User Pool and Identity Pool](/gen1/[platform]/tools/cli/commands/#auth-import).
-
-
-
-
-
-> Prerequisites: [Install and configure](/gen1/[platform]/start/project-setup/prerequisites/#install-and-configure-the-amplify-cli) the Amplify CLI in addition to the Amplify libraries and [necessary dependencies](/gen1/[platform]/build-a-backend/auth/set-up-auth/#install-amplify-libraries).
-
-Amplify Studio allows you create auth resources, set up authorization rules, implement Multi-factor authentication (MFA), and more via an intuitive UI. To set up Authentication through the Amplify Studio, take the following steps:
-
-1. **Sign in** to the [AWS Management Console](https://console.aws.amazon.com/console/home) and open [AWS Amplify](https://console.aws.amazon.com/amplify).
-2. In the navigation pane, **choose an application**.
-3. On the application information page, choose the **Backend environments** tab, then choose **Launch Studio**.
-4. On the **Set up** menu, choose **Authentication**.
-5. In the **Configure log in** section, choose a login mechanism to add from the **Add login mechanism** list. Valid options are _Username_, _Phone number_, _Facebook_, _Google_, _Amazon_, and _Sign in with Apple_. If you choose one of the social sign-in mechanisms (i.e. _Facebook_, _Google_, _Amazon_, or _Sign in with Apple_), you will also need to enter your _App ID_, _App Secret_, and redirect URLs.
-6. (Optional) Add multi-factor authentication (MFA). MFA is set to **Off** by default. To turn on MFA, do the following in the **Multi-factor authentication** section:
-
-- Choose **Enforced** to require MFA for all users or choose **Optional** to allow individual users to enable MFA.
-- (Optional) Choose **SMS**, and enter your SMS message.
-- (Optional) Choose **Authenticator Application** if you want your app to load with an authentication flow that includes sign up and sign in.
-
-7. In the **Configure sign up** section, expand **Password protection settings** and customize the password policy settings to enforce. u6. Choose **Save and Deploy**. This starts a CloudFormation deployment with the progress displayed in the upper right corner of the page.
-8. After creating and configuring your auth resources, you'll need to pull them down from Amplify Studio. To do so, simply click on "Local setup instructions" in the upper right hand corner of the Studio console and execute the CLI command it provides at the root directory of your app.
-
-> You can also [import](/gen1/[platform]/tools/console/auth/import/) existing Amazon Cognito resources and [manage users and groups](/gen1/[platform]/tools/console/auth/user-management/) through the Amplify Studio UI.
-
-
-
-
-
-If you are not using the Amplify CLI, existing Authentication resources from AWS (e.g. Amazon Cognito UserPools or Identity Pools) can be used with the Amplify Libraries by [manually creating a configuration file](/gen1/[platform]/start/project-setup/use-existing-resources/#add-an-existing-aws-resource-to-an-android-application) (`amplifyconfiguration.json`) and then updating the associated Plugin within it:
-
-```jsx
-{
- "auth": {
- "plugins": {
- "awsCognitoAuthPlugin": {
- "IdentityManager": {
- "Default": {}
- },
- "CredentialsProvider": {
- "CognitoIdentity": {
- "Default": {
- "PoolId": "[COGNITO IDENTITY POOL ID]",
- "Region": "[REGION]"
- }
- }
- },
- "CognitoUserPool": {
- "Default": {
- "PoolId": "[COGNITO USER POOL ID]",
- "AppClientId": "[COGNITO USER POOL APP CLIENT ID]",
- "Region": "[REGION]"
- }
- },
- "Auth": {
- "Default": {
- "authenticationFlowType": "USER_SRP_AUTH",
- "socialProviders": [],
- "usernameAttributes": [],
- "signupAttributes": [
- "[SIGNUP MECHANISM]"
- ],
- "passwordProtectionSettings": {
- "passwordPolicyMinLength": [PASSWORD LENGTH],
- "passwordPolicyCharacters": []
- },
- "mfaConfiguration": "OFF",
- "mfaTypes": [
- "[MFA TYPE]"
- ],
- "verificationMechanisms": [
- "[VERIFICATION MECHANISM]"
- ],
- "OAuth": {
- "WebDomain": "[YOUR COGNITO DOMAIN ]",
- "AppClientId": "[COGNITO USER POOL APP CLIENT ID]",
- "SignInRedirectURI": "[CUSTOM REDIRECT SCHEME AFTER SIGN IN, e.g. myapp://]",
- "SignOutRedirectURI": "[CUSTOM REDIRECT SCHEME AFTER SIGN OUT, e.g. myapp://]",
- "Scopes": [
- "phone",
- "email",
- "openid",
- "profile",
- "aws.cognito.signin.user.admin"
- ]
- }
- }
- }
- }
- }
- }
-}
-```
-
-- **CredentialsProvider**:
- - **Cognito Identity**:
- - **Default**:
- - **PoolID**: ID of the Amazon Cognito Identity Pool (e.g. `us-east-1:123e4567-e89b-12d3-a456-426614174000`)
- - **Region**: AWS Region where the resources are provisioned (e.g. `us-east-1`)
-- **CognitoUserPool**:
- - **Default**:
- - **PoolId**: ID of the Amazon Cognito User Pool (e.g. `us-east-1_abcdefghi`)
- - **AppClientId**: ID for the client used to authenticate against the user pool
- - **Region**: AWS Region where the resources are provisioned (e.g. `us-east-1`)
-- **Auth**:
- - **Default**:
- - **authenticationFlowType**: The authentication flow type, takes values `USER_SRP_AUTH`, `CUSTOM_AUTH`, and `USER_PASSWORD_AUTH`. Default is `USER_SRP_AUTH`.
- - **OAuth**: Hosted UI Configuration (only include this if using the Hosted UI flow)
- - **Scopes:** Scopes should match the scopes enables in Cognito under "App client settings"
-
-If you are using a Cognito User Pool without a Cognito Identity Pool, you can omit the **CredentialsProvider** section in the configuration.
-
-
-
-
diff --git a/src/fragments/lib-v1/auth/ios/getting_started/50_configureBackend.mdx b/src/fragments/lib-v1/auth/ios/getting_started/50_configureBackend.mdx
deleted file mode 100644
index 8bb583f4603..00000000000
--- a/src/fragments/lib-v1/auth/ios/getting_started/50_configureBackend.mdx
+++ /dev/null
@@ -1,200 +0,0 @@
-
-
-
-> Prerequisites: [Install and configure](/gen1/prev/[platform]/start/project-setup/prerequisites/#install-and-configure-the-amplify-cli) the Amplify CLI in addition to the Amplify libraries and [necessary dependencies](/gen1/prev/[platform]/build-a-backend/auth/set-up-auth/#install-amplify-libraries).
-
-To start provisioning auth resources in the backend, go to your project directory and **execute the command**:
-
-```bash title="Terminal" showLineNumbers={false}
-amplify add auth
-```
-
-Enter the following when prompted:
-
-```console
-? Do you want to use the default authentication and security configuration?
- `Default configuration`
-? How do you want users to be able to sign in?
- `Username`
-? Do you want to configure advanced settings?
- `No, I am done.`
-```
-
-> If you have previously enabled an Amplify category that uses Auth behind the scenes (e.g. API category), you can run the `amplify update auth` command to edit your configuration if needed.
-
-To push your changes to the cloud, **execute the command**:
-
-```bash title="Terminal" showLineNumbers={false}
-amplify push
-```
-
-import ios3 from '/src/fragments/lib/auth/ios/getting_started/12_amplifyConfig.mdx';
-
-
-
-import android4 from '/src/fragments/lib/auth/android/getting_started/12_amplifyConfig.mdx';
-
-
-
-import flutter5 from '/src/fragments/lib/auth/flutter/getting_started/12_amplifyConfig.mdx';
-
-
-
-
-
-
-
-> Prerequisites: [Install and configure](/gen1/[platform]/start/project-setup/prerequisites/#install-and-configure-the-amplify-cli) the Amplify CLI in addition to the Amplify libraries and [necessary dependencies](/gen1/[platform]/build-a-backend/auth/set-up-auth/#install-amplify-libraries).
-
-To import existing Amazon Cognito resources into your Amplify project, **execute the command**:
-
-```bash title="Terminal" showLineNumbers={false}
-amplify import auth
-```
-
-```console
-? What type of auth resource do you want to import?
- Cognito User Pool and Identity Pool
- Cognito User Pool only
-```
-
-Once you've selected an option, you'll be able to search for and import an existing Cognito User Pool and Identity Pool (or User Pool only) within your AWS account. The `amplify import auth` command will also do the following:
-
-- Automatically populate your Amplify Library configuration file (`awsconfiguration.json`) with your chosen Amazon Cognito resource information
-- Provide your designated existing Cognito resource as the authentication & authorization mechanism for all auth-dependent categories (API, Storage and more)
-- Enable Lambda functions to access the chosen Cognito resource if you permit it
-
-> If you have previously enabled an Amplify category that uses Auth behind the scenes (e.g. API category), you can run the `amplify update auth` command to edit your configuration if needed.
-
-After configuring your Authentication options, update your backend and deploy the service by running the `push` command:
-
-```bash title="Terminal" showLineNumbers={false}
-amplify push
-```
-
-Upon completion, `amplifyconfiguration.json` should be updated to reference provisioned backend auth resources.
-
-Now, the authentication service has been deployed and you can start using it. To view the deployed services in your project at any time, go to Amplify Console by running the following command:
-
-```bash title="Terminal" showLineNumbers={false}
-amplify console
-```
-
-For more details, see how to [Use an existing Cognito User Pool and Identity Pool](/gen1/[platform]/tools/cli/commands/#auth-import).
-
-
-
-
-
-> Prerequisites: [Install and configure](/gen1/[platform]/start/project-setup/prerequisites/#install-and-configure-the-amplify-cli) the Amplify CLI in addition to the Amplify libraries and [necessary dependencies](/gen1/[platform]/build-a-backend/auth/set-up-auth/#install-amplify-libraries).
-
-Amplify Studio allows you create auth resources, set up authorization rules, implement Multi-factor authentication (MFA), and more via an intuitive UI. To set up Authentication through the Amplify Studio, take the following steps:
-
-1. **Sign in** to the [AWS Management Console](https://console.aws.amazon.com/console/home) and open AWS Amplify.
-2. In the navigation pane, **choose an application**.
-3. On the application information page, choose the **Backend environments** tab, then choose **Launch Studio**.
-4. On the **Set up** menu, choose **Authentication**.
-5. In the **Configure log in** section, choose a login mechanism to add from the **Add login mechanism** list. Valid options are _Username_, _Phone number_, _Facebook_, _Google_, _Amazon_, and _Sign in with Apple_. If you choose one of the social sign-in mechanisms (i.e. _Facebook_, _Google_, _Amazon_, or _Sign in with Apple_), you will also need to enter your _App ID_, _App Secret_, and redirect URLs.
-6. (Optional) Add multi-factor authentication (MFA). MFA is set to **Off** by default. To turn on MFA, do the following in the **Multi-factor authentication** section:
-
-- Choose **Enforced** to require MFA for all users or choose **Optional** to allow individual users to enable MFA.
-- (Optional) Choose **SMS**, and enter your SMS message.
-- (Optional) Choose **Authenticator Application** if you want your app to load with an authentication flow that includes sign up and sign in.
-
-7. In the **Configure sign up** section, expand **Password protection settings** and customize the password policy settings to enforce. u6. Choose **Save and Deploy**. This starts a CloudFormation deployment with the progress displayed in the upper right corner of the page.
-8. After creating and configuring your auth resources, you'll need to pull them down from Amplify Studio. To do so, simply click on "Local setup instructions" in the upper right hand corner of the Studio console and execute the CLI command it provides at the root directory of your app.
-
-> You can also [import](/gen1/[platform]/tools/console/auth/import/) existing Amazon Cognito resources and [manage users and groups](/gen1/[platform]/tools/console/auth/user-management/) through the Amplify Studio UI.
-
-
-
-
-
-If you are not using the Amplify CLI, existing Authentication resources from AWS (e.g. Amazon Cognito UserPools or Identity Pools) can be used with the Amplify Libraries by [manually creating a configuration file](/gen1/[platform]/start/project-setup/use-existing-resources/#1-manually-create-the-amplify-configuration-file-for-your-ios-project) (`amplifyconfiguration.json`) and then updating the associated Plugin within it:
-
-```jsx
-{
- "auth": {
- "plugins": {
- "awsCognitoAuthPlugin": {
- "IdentityManager": {
- "Default": {}
- },
- "CredentialsProvider": {
- "CognitoIdentity": {
- "Default": {
- "PoolId": "[COGNITO IDENTITY POOL ID]",
- "Region": "[REGION]"
- }
- }
- },
- "CognitoUserPool": {
- "Default": {
- "PoolId": "[COGNITO USER POOL ID]",
- "AppClientId": "[COGNITO USER POOL APP CLIENT ID]",
- "Region": "[REGION]"
- }
- },
- "Auth": {
- "Default": {
- "authenticationFlowType": "USER_SRP_AUTH",
- "socialProviders": [],
- "usernameAttributes": [],
- "signupAttributes": [
- "[SIGNUP MECHANISM]"
- ],
- "passwordProtectionSettings": {
- "passwordPolicyMinLength": [PASSWORD LENGTH],
- "passwordPolicyCharacters": []
- },
- "mfaConfiguration": "OFF",
- "mfaTypes": [
- "[MFA TYPE]"
- ],
- "verificationMechanisms": [
- "[VERIFICATION MECHANISM]"
- ],
- "OAuth": {
- "WebDomain": "[YOUR COGNITO DOMAIN ]",
- "AppClientId": "[COGNITO USER POOL APP CLIENT ID]",
- "SignInRedirectURI": "[CUSTOM REDIRECT SCHEME AFTER SIGN IN, e.g. myapp://]",
- "SignOutRedirectURI": "[CUSTOM REDIRECT SCHEME AFTER SIGN OUT, e.g. myapp://]",
- "Scopes": [
- "phone",
- "email",
- "openid",
- "profile",
- "aws.cognito.signin.user.admin"
- ]
- }
- }
- }
- }
- }
- }
-}
-```
-
-> For more information on Plugins, see the instructions on [installing Amplify Libraries](/gen1/[platform]/start/project-setup/create-application/#2-install-amplify-libraries).
-
-- **CredentialsProvider**:
- - **Cognito Identity**:
- - **Default**:
- - **PoolID**: ID of the Amazon Cognito Identity Pool (e.g. `us-east-1:123e4567-e89b-12d3-a456-426614174000`)
- - **Region**: AWS Region where the resources are provisioned (e.g. `us-east-1`)
-- **CognitoUserPool**:
- - **Default**:
- - **PoolId**: ID of the Amazon Cognito User Pool (e.g. `us-east-1_abcdefghi`)
- - **AppClientId**: ID for the client used to authenticate against the user pool
- - **Region**: AWS Region where the resources are provisioned (e.g. `us-east-1`)
-- **Auth**:
- - **Default**:
- - **authenticationFlowType**: The authentication flow type, takes values `USER_SRP_AUTH`, `CUSTOM_AUTH`, and `USER_PASSWORD_AUTH`. Default is `USER_SRP_AUTH`.
- - **OAuth**: Hosted UI Configuration (only include this if using the Hosted UI flow)
- - **Scopes:** Scopes should match the scopes enables in Cognito under "App client settings"
-
-If you are using a Cognito User Pool without a Cognito Identity Pool, you can omit the **CredentialsProvider** section in the configuration.
-
-
-
-
diff --git a/src/fragments/lib-v1/auth/native_common/getting_started/common.mdx b/src/fragments/lib-v1/auth/native_common/getting_started/common.mdx
index 1a96f622afe..70b152ced70 100644
--- a/src/fragments/lib-v1/auth/native_common/getting_started/common.mdx
+++ b/src/fragments/lib-v1/auth/native_common/getting_started/common.mdx
@@ -36,15 +36,15 @@ import flutter8 from '/src/fragments/lib-v1/auth/flutter/getting_started/20_inst
The most common way to use Authentication with Amplify is via the Amplify CLI, which allows you to create new Amazon Cognito resources or import existing ones. However, you can also use the Amplify Studio console to configure authentication or use the `Amplify.configure()` method to set up authentication with existing resources.
-import ios50 from '/src/fragments/lib-v1/auth/ios/getting_started/50_configureBackend.mdx';
+import ios50 from '/src/fragments/lib/auth/ios/getting_started/50_configureBackend.mdx';
-import android50 from '/src/fragments/lib-v1/auth/android/getting_started/50_configureBackend.mdx';
+import android50 from '/src/fragments/lib/auth/android/getting_started/50_configureBackend.mdx';
-import flutter70 from '/src/fragments/lib-v1/auth/flutter/getting_started/70_configureBackend.mdx';
+import flutter70 from '/src/fragments/lib/auth/flutter/getting_started/70_configureBackend.mdx';
From c4fabd04b9ddb615d3fe7d1ebcbd60b62999feb6 Mon Sep 17 00:00:00 2001
From: Kha Truong <64438356+khatruong2009@users.noreply.github.com>
Date: Thu, 16 May 2024 12:50:34 -0700
Subject: [PATCH 17/19] chore: revert removal of inline filter and addition of
white space
---
src/fragments/lib-v1/auth/common/sms/flows.mdx | 2 +-
.../lib-v1/storage/native_common/getting-started/common.mdx | 3 +++
2 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/src/fragments/lib-v1/auth/common/sms/flows.mdx b/src/fragments/lib-v1/auth/common/sms/flows.mdx
index 7e35bf24ecf..ecc8ee7feac 100644
--- a/src/fragments/lib-v1/auth/common/sms/flows.mdx
+++ b/src/fragments/lib-v1/auth/common/sms/flows.mdx
@@ -156,4 +156,4 @@ If MFA is **ON** or enabled for the user, you must call `confirmSignIn` with the
import flutter9 from "/src/fragments/lib-v1/auth/flutter/sms/confirm_sign_in.mdx";
-
+
\ No newline at end of file
diff --git a/src/fragments/lib-v1/storage/native_common/getting-started/common.mdx b/src/fragments/lib-v1/storage/native_common/getting-started/common.mdx
index 62bf17891a7..33d815c841f 100644
--- a/src/fragments/lib-v1/storage/native_common/getting-started/common.mdx
+++ b/src/fragments/lib-v1/storage/native_common/getting-started/common.mdx
@@ -127,4 +127,7 @@ Congratulations! You've uploaded a file to an s3 bucket. Check out the following
- [Remove Files](/gen1/[platform]/prev/build-a-backend/storage/remove/)
- [File Access Levels](/gen1/[platform]/prev/build-a-backend/storage/configure-access/)
- [Using Lambda Triggers](/gen1/[platform]/prev/build-a-backend/storage/lambda-triggers/)
+
+
- [Escape Hatch](/gen1/[platform]/prev/build-a-backend/storage/sdk/)
+
\ No newline at end of file
From fc684402806247a0a05bca9b21029ca942292987 Mon Sep 17 00:00:00 2001
From: Kha Truong <64438356+khatruong2009@users.noreply.github.com>
Date: Thu, 16 May 2024 12:58:32 -0700
Subject: [PATCH 18/19] chore: revert changes that removed before you begin
snippet
---
.../prev/build-a-backend/graphqlapi/mutate-data/index.mdx | 4 ++++
.../prev/build-a-backend/graphqlapi/query-data/index.mdx | 5 +++++
.../prev/build-a-backend/graphqlapi/subscribe-data/index.mdx | 5 +++++
3 files changed, 14 insertions(+)
diff --git a/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/mutate-data/index.mdx b/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/mutate-data/index.mdx
index 13411e6f6a2..12007c02301 100644
--- a/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/mutate-data/index.mdx
+++ b/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/mutate-data/index.mdx
@@ -56,6 +56,10 @@ import flutter3 from '/src/fragments/lib-v1/graphqlapi/flutter/mutate-data.mdx';
In this guide, you will learn how to create, update, and delete your data using Amplify Libraries' GraphQL client.
+Before you begin, you will need:
+
+- An [application connected to the API](/gen1/[platform]/prev/build-a-backend/graphqlapi/set-up-graphql-api/)
+
## Run mutations to create, update, and delete application data
In GraphQL, mutations are APIs that are used to create, update, or delete data. This is different than queries, which are used to read the data but not change it. The following examples demonstrate how you can create, update, and delete items using the Amplify GraphQL client.
diff --git a/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/query-data/index.mdx b/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/query-data/index.mdx
index 37725328575..64e69379031 100644
--- a/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/query-data/index.mdx
+++ b/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/query-data/index.mdx
@@ -33,6 +33,11 @@ export function getStaticProps(context) {
You can read application data using the Amplify GraphQL client. In this guide, we will review the difference between reading data and getting data, how to filter query results to get just the data you need, and how to paginate results to make your data more manageable. We will also show you how to cancel these requests when needed.
+Before you begin, you will need:
+
+- An [application connected to the API](/gen1/[platform]/prev/build-a-backend/graphqlapi/set-up-graphql-api/)
+- Data already created to view
+
## List and get your data
Queries are used to read data through the API and include the `list` and `get` operations.
diff --git a/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/subscribe-data/index.mdx b/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/subscribe-data/index.mdx
index 92101b2d692..ef467c2fba7 100644
--- a/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/subscribe-data/index.mdx
+++ b/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/subscribe-data/index.mdx
@@ -33,6 +33,11 @@ export function getStaticProps(context) {
In this guide, we will outline the benefits of enabling real-time data integrations and how to set up and filter these subscriptions. We will also cover how to unsubscribe from subscriptions.
+Before you begin, you will need:
+
+- An [application connected to the API](/gen1/[platform]/prev/build-a-backend/graphqlapi/set-up-graphql-api/)
+- Data already created to view
+
## Set up a real-time subscription
Subscriptions is a GraphQL feature that allows the server to send data to its clients when a specific event happens. For example, you can subscribe to an event when a new record is created, updated, or deleted through the API. You can enable real-time data integration in your app with a subscription.
From bc863f4ff76548967b36a7828b2b9745c00b13c0 Mon Sep 17 00:00:00 2001
From: Kha Truong <64438356+khatruong2009@users.noreply.github.com>
Date: Thu, 16 May 2024 13:07:29 -0700
Subject: [PATCH 19/19] chore: revert change to wording
---
.../prev/build-a-backend/graphqlapi/subscribe-data/index.mdx | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/subscribe-data/index.mdx b/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/subscribe-data/index.mdx
index ef467c2fba7..75864a69620 100644
--- a/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/subscribe-data/index.mdx
+++ b/src/pages/gen1/[platform]/prev/build-a-backend/graphqlapi/subscribe-data/index.mdx
@@ -36,7 +36,7 @@ In this guide, we will outline the benefits of enabling real-time data integrati
Before you begin, you will need:
- An [application connected to the API](/gen1/[platform]/prev/build-a-backend/graphqlapi/set-up-graphql-api/)
-- Data already created to view
+- Data already created to modify
## Set up a real-time subscription