How to find access logs
# support
n
How to Retrieve Access Logs for Medplum and Systems utilizing Medplum API or Client: Tracking User Access to Resources and Activity Frequency
r
Hi @nikulkhatik , Medplum produces AuditEvent resources for certain actions, such as Bot Invocations. You can see these here: https://app.medplum.com/AuditEvent
More advanced logging, including logs on all resource accesses and logins, are a feature of our enterprise offering, and you can reach out here! https://www.medplum.com/pricing
B/c of the high volume, we typically pipe these logs into your own logging infrastructure, such as datadog, splunk, etc.
r
@rahul1 We seek guidance on best practices for effectively viewing access logs within our Medplum AWS Self-Hosted Environment. Specifically, we're interested in understanding who (such as patients or Medplum client credentials for our public website) is accessing what health data at the resource level. Currently, we've implemented AWS Athena following the provided guide: https://www.medplum.com/docs/self-hosting/aws-athena-guide. However, this setup only provides the Client's IP address, Request Method, and URL. Our goal is to gain insight into who accessed what and when. What request payload was used, and what specific resources have been delivered? Should we be using AuditEvent towards this end? Or approach to achieving this visibility?
@cody @reshma @rahul1 Any insights on it.
c
Hi @ravindratc - are you using the "logRequests" setting? https://www.medplum.com/docs/self-hosting/config-settings
AuditEvent will provide specific access patterns (i.e., which user accessed which resources)
However, AuditEvents can be quite verbose, so will typically require significant post processing and filtering to find what you want. For example, if a search includes 20 results, there will be 1 AuditEvent for the search and 20 additional AuditEvents for "reading" each of the search results.
r
@cody No, It’s not enabled. And currently AuditEvent only has Subscription and Bots execution record.
c
Ah, there should be many more AuditEvent in AWS CloudWatch logs.
144 Views