Newer Version Available
Query Event Monitoring Data with REST
Use the Query resource to retrieve field values from a record. Specify the fields you want to retrieve in the fields parameter and use the GET method of the resource.
You can use Workbench to query event monitoring data. To retrieve
event monitoring records based
on LogDate and EventType, in the Execute text
box, type:
1/services/data/v32.0/query?q=SELECT+Id+,+EventType+,+LogFile+
2,+LogDate+,+LogFileLength+FROM+EventLogFile+WHERE+
3LogDate+>+Yesterday+AND+EventType+=+'API'- Example raw response
-
1{ 2 "totalSize" : 4, 3 "done" : true, 4 "records" : [ { 5 "attributes" : { 6 "type" : "EventLogFile", 7 "url" : "/services/data/v32.0/sobjects/EventLogFile/0ATD000000001bROAQ" } 8 "Id" : "0ATD000000001bROAQ", 9 "EventType" : "API", 10 "LogFile" : "/services/data/v32.0/sobjects/EventLogFile/0ATD000000001bROAQ/LogFile", 11 "LogDate" : "2014-03-14T00:00:00.000+0000", 12 "LogFileLength" : 2692.0 13 }, { 14 "attributes" : { 15 "type" : "EventLogFile", 16 "url" : "/services/data/v32.0/sobjects/EventLogFile/0ATD000000001SdOAI" }, 17 "Id" : "0ATD000000001SdOAI", 18 "EventType" : "API", 19 "LogFile" : "/services/data/v32.0/sobjects/EventLogFile/0ATD000000001SdOAI/LogFile", 20 "LogDate" : "2014-03-13T00:00:00.000+0000", 21 "LogFileLength" : 1345.0 22 }, { 23 "attributes" : { 24 "type" : "EventLogFile", 25 "url" : "/services/data/v32.0/sobjects/EventLogFile/0ATD000000003p1OAA" }, 26 "Id" : "0ATD000000003p1OAA", 27 "EventType" : "API", 28 "LogFile" : "/services/data/v32.0/sobjects/EventLogFile/0ATD000000003p1OAA/LogFile", 29 "LogDate" : "2014-06-21T00:00:00.000+0000", 30 "LogFileLength" : 605.0 }, 31 { "attributes" : { 32 "type" : "EventLogFile", 33 "url" : "/services/data/v32.0/sobjects/EventLogFile/0ATD0000000055eOAA" }, 34 "Id" : "0ATD0000000055eOAA", 35 "EventType" : "API", 36 "LogFile" : "/services/data/v32.0/sobjects/EventLogFile/0ATD0000000055eOAA/LogFile", 37 "LogDate" : "2014-07-03T00:00:00.000+0000", 38 "LogFileLength" : 605.0 39 } ] 40}