Skip to content

Commit c1fdeb1

Browse files
committed
fix(doc): update documentation for correct region
1 parent 1709358 commit c1fdeb1

3 files changed

Lines changed: 20 additions & 4 deletions

File tree

docs/guides/USER_GUIDE.md

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,26 +25,33 @@ The Task API uses Amazon Cognito for authentication. Self-signup is disabled; an
2525

2626
### Get stack outputs
2727

28-
After deployment, retrieve the API URL and Cognito identifiers:
28+
After deployment, retrieve the API URL and Cognito identifiers. Set `REGION` to the AWS region where you deployed the stack (for example `us-east-1`). Use the same value for all `aws` and `bgagent configure` commands below — a mismatch often surfaces as a confusing Cognito “app client does not exist” error.
2929

3030
```bash
31+
REGION=<your-deployment-region>
32+
3133
API_URL=$(aws cloudformation describe-stacks --stack-name backgroundagent-dev \
34+
--region "$REGION" \
3235
--query 'Stacks[0].Outputs[?OutputKey==`ApiUrl`].OutputValue' --output text)
3336
USER_POOL_ID=$(aws cloudformation describe-stacks --stack-name backgroundagent-dev \
37+
--region "$REGION" \
3438
--query 'Stacks[0].Outputs[?OutputKey==`UserPoolId`].OutputValue' --output text)
3539
APP_CLIENT_ID=$(aws cloudformation describe-stacks --stack-name backgroundagent-dev \
40+
--region "$REGION" \
3641
--query 'Stacks[0].Outputs[?OutputKey==`AppClientId`].OutputValue' --output text)
3742
```
3843

3944
### Create a user (admin)
4045

4146
```bash
4247
aws cognito-idp admin-create-user \
48+
--region "$REGION" \
4349
--user-pool-id $USER_POOL_ID \
4450
--username user@example.com \
4551
--temporary-password 'TempPass123!@'
4652

4753
aws cognito-idp admin-set-user-password \
54+
--region "$REGION" \
4855
--user-pool-id $USER_POOL_ID \
4956
--username user@example.com \
5057
--password 'YourPerm@nent1Pass!' \
@@ -57,6 +64,7 @@ Password requirements: minimum 12 characters, uppercase, lowercase, digits, and
5764

5865
```bash
5966
TOKEN=$(aws cognito-idp initiate-auth \
67+
--region "$REGION" \
6068
--client-id $APP_CLIENT_ID \
6169
--auth-flow USER_PASSWORD_AUTH \
6270
--auth-parameters USERNAME=user@example.com,PASSWORD='YourPerm@nent1Pass!' \
@@ -228,7 +236,7 @@ npx projen build
228236
# Configure with your stack outputs (run from cli/)
229237
node lib/bin/bgagent.js configure \
230238
--api-url $API_URL \
231-
--region us-east-1 \
239+
--region "$REGION" \
232240
--user-pool-id $USER_POOL_ID \
233241
--client-id $APP_CLIENT_ID
234242

docs/src/content/docs/user-guide/Authentication.md

Lines changed: 9 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/src/content/docs/user-guide/Using-the-cli.md

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)