warning: Model XX has auth with authStrategy public of which is not yet supported in DataStore

Viewed 69

Here is my GraphQL schema:

type XX @model
@aws_cognito_user_pools
@aws_iam
@auth(
  rules: [
      { allow: owner, operations: [create, read, update, delete] },
      { allow: public, provider: iam, operations: [read] },
      { allow: private, provider: userPools, operations: [read] }
  ]
){
id: ID!
data: String!
}

I have two auth providers, Cognito user pools and IAM. Cognito for authenticated access and IAM for un-authenticated access. the first line in the rules' section is for the authenticated owner, the second line is for un-authenticated access and the last line is for authenticated non-owners. but when I run "amplify codegen models" the above warning rises.

0 Answers
Related