appsync-auth-and-unauth
appsync-auth-and-unauth copied to clipboard
listTodos should be Query?
I noticed that in the IAM access policies, all roles are mutations, including listTodos. I believe that one should be a query for both auth and unauthenticated identities.
Also, why is 'fields' there? What does 'fields' mean, and why isn't it just 'query/[QUERY_NAME]'
For the unauthenticated inline policy, I simplified it to this:
"Resource": [
"arn:aws:appsync:<REGION>:<ACCOUNT>:apis/<API_ID>/types/Query/*"
]
But use of .../fields/...
allows more fine-grained control: https://docs.aws.amazon.com/IAM/latest/UserGuide/list_awsappsync.html