I have requirement where i need to fetch modified lwcComponent with the user who modified it programmatically. Is there any soql query we can use or by apex schema we can get it.Audit trail does not capture LWC details.

Please suggest

  • You can query on "LightningComponentBundle" to get those details Jan 11 at 7:55
  • getting error- sObject type 'LightningComponentBundle' is not supported.
    – sam
    Jan 11 at 7:56
  • in developer console
    – sam
    Jan 11 at 7:56
  • 3
    Please check "Use Tooling API" Jan 11 at 8:10

You can query on object LightningComponentBundle.

SELECT Id,masterlabel,lastmodifiedby.name,lastmodifieddate FROM LightningComponentBundle 

Remember to check Tooling API checkbox when querying via developer console.

Note : We could query AuraDefinitionBundle without checking tooling api as well.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.