How to use API to get user who last modified file

Soong, Brendon 0 Reputation points


Using Python SDK, is it possible when calling the 'listblobs' API, to get the user who modified a certain file? The listblobs API returns the 'lastaccessed' and 'last_modified' fields but there is no user who modified/accessed those files.

Azure Blob Storage
Azure Blob Storage
An Azure service that stores unstructured data in the cloud as blobs.
2,414 questions
{count} votes

1 answer

Sort by: Most helpful
  1. SaiKishor-MSFT 17,176 Reputation points

    @Soong, Brendon Thanks for reaching out to Microsoft Q&A.

    The listblobs API does not return the user who modified a certain file. However, you can use Azure Blob Storage logs to monitor the activity of your storage account and identify the security principal used to authorize a request. The logs show the operation name, authentication type, requester object ID, and other information. You can use the requester object ID to identify the security principal in Azure Active Directory.

    For more information, see the article "Best practices for monitoring Azure Blob Storage" in the Azure documentation. The article provides information on how to monitor your Azure Blob Storage using metrics and logs -

    Please let me know if this helps or if you are looking for anything else and I will be glad to assist you further. Thank you!


    Please accept an answer if correct. Original posters help the community find answers faster by identifying the correct answer. Here is how.

    Want a reminder to come back and check responses? Here is how to subscribe to a notification.

    0 comments No comments