Internal ActivityLog API Subsystem

From GrandCare Systems
Jump to navigation Jump to search

The ActivityLog subsystem allows you to view and add activity log entries from a system via Internal GCAPI. Introduced in Como 4.4.0.

Operations

read

Reads entries out of the activity log matching your parameters or all if none specified

Parameters

  • id - [optional] log entry ID
  • key - [optional]
  • value - [optional]

Results

SUCCESS, returns back log entries

json

$ curl "http://10.100.1.2/api/activitylog.php?op=read&id=1encoding=json&passcode=x
{
 "gcapi": {
   "result": "SUCCESS",
   "activitylog": [
     {
       "id": "1",
       "key": "ui.module.slideshow.activate",
       "value": "messages",
       "datetime": "2013-06-03 13:21:33"
     }
   ]
 }
}

add

Adds an entry to the activity log

Parameters

  • key - required
  • value - required

Results

SUCCESS, returns back the new log entry

json

$ curl "http://10.100.1.2/api/activitylog.php?op=add&key=foo&value=bar&encoding=json&passcode=x
{
 "gcapi": {
   "result": "SUCCESS",
   "activitylog": {
       "id": "125",
       "key": "foo",
       "value": "bar",
       "datetime": "2013-06-17 13:21:33"
   }
 }
}