diff --git a/src/fragments/lib-v1/analytics/android/existing-resources.mdx b/src/fragments/lib-v1/analytics/android/existing-resources.mdx index 0c9c82c504a..f4d62ed2d69 100644 --- a/src/fragments/lib-v1/analytics/android/existing-resources.mdx +++ b/src/fragments/lib-v1/analytics/android/existing-resources.mdx @@ -24,4 +24,20 @@ Existing Amazon Pinpoint resources can be used with the Amplify Libraries by ref - **pinpointTargeting** - **region**: AWS Region where the resources are provisioned (e.g. `us-east-1`) -Note that before you can add an AWS resource to your application, the application must have the Amplify libraries installed. If you need to perform this step, see [Install Amplify Libraries](/gen1/[platform]/prev/start/project-setup/create-application/#n2-install-amplify-libraries). +Note that before you can add an AWS resource to your application, the application must have the Amplify libraries installed. If you need to perform this step, see [Install Amplify Libraries](/gen1/[platform]/prev/start/project-setup/create-application/#n2-install-amplify-libraries). + +## Update your IAM Policy + +Amazon Pinpoint requires an AWS Identity and Access Management (IAM) policy in order to use the `record` and `identifyUser` APIs: +```json +{ + "Version": "2012-10-17", + "Statement": [ + { + "Effect": "Allow", + "Action": ["mobiletargeting:UpdateEndpoint", "mobiletargeting:PutEvents"], + "Resource": ["arn:aws:mobiletargeting:*::apps/*"] + } + ] +} +``` diff --git a/src/fragments/lib-v1/analytics/flutter/existing-resources.mdx b/src/fragments/lib-v1/analytics/flutter/existing-resources.mdx index 6736650326c..6e0c46afcdf 100644 --- a/src/fragments/lib-v1/analytics/flutter/existing-resources.mdx +++ b/src/fragments/lib-v1/analytics/flutter/existing-resources.mdx @@ -25,3 +25,19 @@ Existing Amazon Pinpoint resources can be used with the Amplify Libraries by ref - **region**: AWS Region where the resources are provisioned (e.g. `us-east-1`) Note that before you can add an AWS resource to your application, the application must have the Amplify libraries installed. If you need to perform this step, see [Install Amplify Libraries](/gen1/[platform]/prev/start/project-setup/create-application/#n2-install-amplify-libraries). + +## Update your IAM Policy + +Amazon Pinpoint requires an AWS Identity and Access Management (IAM) policy in order to use the `record` and `identifyUser` APIs: +```json +{ + "Version": "2012-10-17", + "Statement": [ + { + "Effect": "Allow", + "Action": ["mobiletargeting:UpdateEndpoint", "mobiletargeting:PutEvents"], + "Resource": ["arn:aws:mobiletargeting:*::apps/*"] + } + ] +} +``` diff --git a/src/fragments/lib-v1/analytics/ios/existing-resources.mdx b/src/fragments/lib-v1/analytics/ios/existing-resources.mdx index 830ee3fc4cb..b7b59a16abf 100644 --- a/src/fragments/lib-v1/analytics/ios/existing-resources.mdx +++ b/src/fragments/lib-v1/analytics/ios/existing-resources.mdx @@ -27,3 +27,19 @@ Existing Amazon Pinpoint resources can be used with the Amplify Libraries by ref - **region**: AWS Region where the resources are provisioned (e.g. `us-east-1`) Note that before you can add an AWS resource to your application, the application must have the Amplify libraries installed. If you need to perform this step, see [Install Amplify Libraries](/gen1/[platform]/prev/start/project-setup/create-application/#n2-install-amplify-libraries). + +## Update your IAM Policy + +Amazon Pinpoint requires an AWS Identity and Access Management (IAM) policy in order to use the `record` and `identifyUser` APIs: +```json +{ + "Version": "2012-10-17", + "Statement": [ + { + "Effect": "Allow", + "Action": ["mobiletargeting:UpdateEndpoint", "mobiletargeting:PutEvents"], + "Resource": ["arn:aws:mobiletargeting:*::apps/*"] + } + ] +} +``` diff --git a/src/fragments/lib/analytics/android/existing-resources.mdx b/src/fragments/lib/analytics/android/existing-resources.mdx index 9e5dba6c853..f60d994e248 100644 --- a/src/fragments/lib/analytics/android/existing-resources.mdx +++ b/src/fragments/lib/analytics/android/existing-resources.mdx @@ -25,3 +25,19 @@ Existing Amazon Pinpoint resources can be used with the Amplify Libraries by ref - **region**: AWS Region where the resources are provisioned (e.g. `us-east-1`) Note that before you can add an AWS resource to your application, the application must have the Amplify libraries installed. If you need to perform this step, see [Install Amplify Libraries](/gen1/[platform]/start/project-setup/create-application/#n2-install-amplify-libraries). + +## Update your IAM Policy + +Amazon Pinpoint requires an AWS Identity and Access Management (IAM) policy in order to use the `record` and `identifyUser` APIs: +```json +{ + "Version": "2012-10-17", + "Statement": [ + { + "Effect": "Allow", + "Action": ["mobiletargeting:UpdateEndpoint", "mobiletargeting:PutEvents"], + "Resource": ["arn:aws:mobiletargeting:*::apps/*"] + } + ] +} +``` diff --git a/src/fragments/lib/analytics/flutter/existing-resources.mdx b/src/fragments/lib/analytics/flutter/existing-resources.mdx index 1ac7ff0c0fd..67aca05df31 100644 --- a/src/fragments/lib/analytics/flutter/existing-resources.mdx +++ b/src/fragments/lib/analytics/flutter/existing-resources.mdx @@ -25,3 +25,19 @@ Existing Amazon Pinpoint resources can be used with the Amplify Libraries by ref - **region**: AWS Region where the resources are provisioned (e.g. `us-east-1`) Note that before you can add an AWS resource to your application, the application must have the Amplify libraries installed. If you need to perform this step, see [Install Amplify Libraries](/gen1/[platform]/start/project-setup/create-application/#n2-install-amplify-libraries). + +## Update your IAM Policy + +Amazon Pinpoint requires an AWS Identity and Access Management (IAM) policy in order to use the `record` and `identifyUser` APIs: +```json +{ + "Version": "2012-10-17", + "Statement": [ + { + "Effect": "Allow", + "Action": ["mobiletargeting:UpdateEndpoint", "mobiletargeting:PutEvents"], + "Resource": ["arn:aws:mobiletargeting:*::apps/*"] + } + ] +} +``` diff --git a/src/fragments/lib/analytics/ios/existing-resources.mdx b/src/fragments/lib/analytics/ios/existing-resources.mdx index 9f38b9cff6d..798dfdf723a 100644 --- a/src/fragments/lib/analytics/ios/existing-resources.mdx +++ b/src/fragments/lib/analytics/ios/existing-resources.mdx @@ -19,4 +19,20 @@ Existing Amazon Pinpoint resources can be used with the Amplify Libraries by ref - **appId**: Amazon Pinpoint application ID - **region**: AWS Region where the resources are provisioned (e.g. `us-east-1`) -Note that before you can add an AWS resource to your application, the application must have the Amplify libraries installed. If you need to perform this step, see [Install Amplify Libraries](/gen1/[platform]/start/project-setup/create-application/#n2-install-amplify-libraries). +Note that before you can add an AWS resource to your application, the application must have the Amplify libraries installed. If you need to perform this step, see [Install Amplify Libraries](/gen1/[platform]/start/project-setup/create-application/#n2-install-amplify-libraries). + +## Update your IAM Policy + +Amazon Pinpoint requires an AWS Identity and Access Management (IAM) policy in order to use the `record` and `identifyUser` APIs: +```json +{ + "Version": "2012-10-17", + "Statement": [ + { + "Effect": "Allow", + "Action": ["mobiletargeting:UpdateEndpoint", "mobiletargeting:PutEvents"], + "Resource": ["arn:aws:mobiletargeting:*::apps/*"] + } + ] +} +``` diff --git a/src/pages/[platform]/build-a-backend/add-aws-services/analytics/existing-resources/index.mdx b/src/pages/[platform]/build-a-backend/add-aws-services/analytics/existing-resources/index.mdx index dd46eb278ac..c34c2762f6f 100644 --- a/src/pages/[platform]/build-a-backend/add-aws-services/analytics/existing-resources/index.mdx +++ b/src/pages/[platform]/build-a-backend/add-aws-services/analytics/existing-resources/index.mdx @@ -80,6 +80,7 @@ Amplify.configure({ } }); ``` + ## Update your IAM Policy @@ -97,4 +98,3 @@ Amazon Pinpoint requires an AWS Identity and Access Management (IAM) policy in o } ``` -