Aurora API: Admin Activity
Using this controller you can manage log records of admin user activity via the API.
Add
Deferred: No
Allow adding of logging admin user activity via the API:
- This leaves the responsibility of logging to the server accessing the API
- This reflects the same audit trail as a user accessing the Aurora Backend.
- Activity logs are visible in Aurora Backend > Tools > Logs > Administrator Log
Example request
Example request
<?xml version="1.0" encoding="utf-8"?>
<AuroraRequestEnvelope>
<Header>
<AuthToken>...</AuthToken>
</Header>
<Requests>
<Request>
<Admin>
<Activity>
<Add>
<AdminUserID>1</AdminUserID>
<ItemType>order</ItemType>
<ItemSubType>refund</ItemSubType>
<ItemID>123</ItemID>
<Message>Refunded order #123</Message>
</Add>
</Activity>
</Admin>
</Request>
</Requests>
</AuroraRequestEnvelope>
Example response
Example response
<?xml version="1.0" encoding="utf-8"?>
<AuroraResponseEnvelope>
<Header>
<Version>1.5</Version>
<Timestamp>2017-06-28T08:21:10+01:00</Timestamp>
<RequestDetails></RequestDetails>
<Summary>
<Ack>OK</Ack>
<RequestsProcessed>1</RequestsProcessed>
<RequestsSucceeded>1</RequestsSucceeded>
<RequestErrors>0</RequestErrors>
</Summary>
</Header>
<Responses>
<Response>
<RequestID>1</RequestID>
<Ack>OK</Ack>
<Data>
<AdminActivityID>8</AdminActivityID>
</Data>
</Response>
</Responses>
</AuroraResponseEnvelope>
Request fields
Field | Values | API Version | Description | Required |
---|---|---|---|---|
AdminUserID | Integer | 1.5+ | Must be a valid User ID. Failure to match to an existing user results in an API error. | Conditional (one of “AdminUserID” or “AdminUserEmailAddress” required) |
AdminUserEmailAddress | String | 1.5+ | Must be an email of a valid user. Failure to match to an existing user results in an API error. | Conditional (one of “AdminUserID” or “AdminUserEmailAddress” required) |
AdminUserIpAddress | String | 1.5+ | Must be a valid IPv4 Address. | No |
ItemType | String | 1.5+ | Selected from a pre-defined list of types: order category product return * user | Yes |
ItemSubType | String | 1.5+ | Selected from a pre-defined list of types: view add edit refund | Yes |
ItemID | Integer | 1.5+ | Must be a valid ID for an item based on the specified ItemType. | Conditional (required if ItemIDFromAdminUser not present) |
ItemIDFromAdminUser | Boolean | 1.5+ | If specified, must be "1". Useful when AdminUserID is not known, but AdminUserEmailAddress is. This communicates to the API that the “ItemID” should be set to the same id that is used to log this activity e.g. AdminUserID. | Conditional (required if ItemID not present) |
Message | String | 1.5+ | If provided, the custom message will be stored against the admin log entry. If not provided, Aurora will attempt to auto-generate a message based on the ItemType, ItemSubType and ItemID provided. For example: "Refund Amount: £29.75" | No |
Response fields
Aurora Field | Type | Example Data | Description |
---|---|---|---|
AdminActivityID | Integer | 8 | ID of the created activity record. |
Updated over 2 years ago