Skip to content

Commit

Permalink
fix: use correct curl command for creating notes (#727)
Browse files Browse the repository at this point in the history
The original request body of the example has parsing issues once executed, I've updated it with the payload that worked for me
  • Loading branch information
Mingyang-Li committed Aug 17, 2023
1 parent d91ff5c commit 70cb023
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion _chapters/secure-our-serverless-apis.md
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ While this might look intimidating, just keep in mind that behind the scenes all
If you are on Windows, use the command below. The space between each option is very important.
```bash
$ npx aws-api-gateway-cli-test --username admin@example.com --password Passw0rd! --user-pool-id USER_POOL_ID --app-client-id USER_POOL_CLIENT_ID --cognito-region COGNITO_REGION --identity-pool-id IDENTITY_POOL_ID --invoke-url API_ENDPOINT --api-gateway-region API_REGION --path-template /notes --method POST --body "{\"content\":\"hello world\",\"attachment\":\"hello.jpg\"}"
$ npx aws-api-gateway-cli-test --username admin@example.com --password Passw0rd! --user-pool-id USER_POOL_ID --app-client-id USER_POOL_CLIENT_ID --cognito-region COGNITO_REGION --identity-pool-id IDENTITY_POOL_ID --invoke-url API_ENDPOINT --api-gateway-region API_REGION --path-template /notes --method POST --body '{""content\":\"hello world\",\"attachment\":\"hello.jpg\"}'
```
If the command is successful, the response will look similar to this.
Expand Down

0 comments on commit 70cb023

Please sign in to comment.