Back

a new comer question about databases/collections access logging

  • 0
  • Self Hosted
  • Webhooks
  • Web
  • REST API
louis
18 Mar, 2024, 07:15

Hi everyone,

I am new to appwrite and currently evaluate it. Thanks for this great tools first of all.

I ran into a question about logging. I would like to log some incoming request (i.e. users logging in/out, documents the user access, etc ... ) to particular collection in appwrite( say logs).

May I know is there any "common" practice to implement this ?

Thanks for help in advace.

BR, louis

TL;DR
Developers can track Events for general logging purposes in Appwrite. However, directly tracking specific Collection & Document reads may not be possible. A workaround is to manually update a `logs` collection using Functions. Check the Usage Stats tab for overall data. More information can be found at https://appwrite.io/docs/advanced/platform/events
darShan
18 Mar, 2024, 07:28

You could use Events to some extent for this. But tracking Collection & Document reads may not be possible. There is a Usage Stat tab usually on the console to see an overall data.

Regarding your use-case for a User accessing a particular document, you can manually do this by firing a Function that'll update the logs collection.

See - https://appwrite.io/docs/advanced/platform/events

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