Skip to content
Back

anonymous user not authorized to create document even with label set.

  • 0
  • Self Hosted
  • Auth
  • Databases
  • Web
Mojo
24 Jan, 2025, 20:03

I am trying to create a document as an anonymous user. Setting the create to users did not work, so I tried adding a label for the anon user.

See attached for the user's labels, the READ works fine with label:anon, but the create doesn't.

TL;DR
Anonymous developer is unable to create a document even after setting a label for the user. The error message indicates that the permissions must include 'label:anon'. The READ operation works fine with the label 'anon', but the CREATE operation does not.
Mojo
24 Jan, 2025, 20:07
TypeScript
{
  code: 401,
  type: 'user_unauthorized',
  response: {
    message: 'Permissions must be one of: (any, users, user:6793ef198664357f1abf, user:6793ef198664357f1abf/unverified, users/unverified, label:anon)',
    code: 401,
    type: 'user_unauthorized',
    version: '1.6.0'
  }```
Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more