Back

[SOLVED] The current user is not authorized to perform the requested action.

  • 0
  • Android
Andrewwww
9 Mar, 2023, 05:57

Hi, I'am using Android SDK and after createEmailSession i receive "The current user is not authorized to perform the requested action." when ai try to query database

TL;DR
User is having an issue with not having permission to create a new post in a specific channel. They also need help finding the Appwrite Android Studio JAVA documentation. The user is then informed about where they can find the documentation and is advised to create a new post if they still need assistance. The user also asks for help with setting up SMTP and is given a link to the documentation. The user confirms that their problem is solved. The user asks about where they can check collection permissions and what permissions were set on the collection and document. They are also asked if the get document call happens after login. The user then asks about adding headers in
Drake
9 Mar, 2023, 06:01

What's your code?

Andrewwww
9 Mar, 2023, 06:02

override suspend fun login(email: String, password: String): Response<Session, Exception> { return try { Response.Success(account.createEmailSession(email, password)) }catch (e: Exception){ Response.Failure(e) } }

Andrewwww
9 Mar, 2023, 06:03

var respose = databases.getDocument( databaseId = Constants.AppWriteData.db_id, collectionId = Constants.AppWriteData.Collections.admins_id, documentId = userId ).toMap()

Andrewwww
9 Mar, 2023, 06:03

client it's injected

Andrewwww
9 Mar, 2023, 06:05

For database needs add headers in client?

Drake
9 Mar, 2023, 06:05

What permissions did you set on the collection and document?

Also, are you sure the get document call happens after login?

Andrewwww
9 Mar, 2023, 06:06

Where I can check collection permissions?

Andrewwww
9 Mar, 2023, 06:06

Yes, I'm sure. The get document happens after login

Drake
9 Mar, 2023, 06:07

Appwrite Console. For collection, look at the collection settings. For document, look at the document

Andrewwww
9 Mar, 2023, 06:11

Ooo, thx a lot!!

Drake
9 Mar, 2023, 06:13

Did that fix your problem?

Andrewwww
9 Mar, 2023, 06:13

Yes

Andrewwww
9 Mar, 2023, 06:14

Can you help my with " SMTP is disabled on your Appwrite instance. You can <a href="/docs/email-delivery">learn more about setting up SMTP</a> in our docs." too?

Drake
9 Mar, 2023, 14:27

You can refer to our docs https://appwrite.io/docs/email-delivery and search the <#1072905050399191082> posts. If you still need help, feel free to create a new post

Drake
9 Mar, 2023, 14:28

[SOLVED] The current user is not authorized to perform the requested action.

asapsonter
16 Mar, 2023, 13:53

where can i find AppWrites' android studio JAVA documentation?

Drake
16 Mar, 2023, 15:59

best to create a new post instead of posting in here

asapsonter
16 Mar, 2023, 21:23

Thanks. But, I dont have permission to make a post in the Appwrite <#564175492778033152> channel.

Drake
16 Mar, 2023, 21:23

Create a new post in <#1072905050399191082> please

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