Skip to main content
The /actions endpoints give you programmatic access to Avalex’s audit log — a chronological record of every entity mutation performed through the platform, including license creation, customer updates, and staff activity. You can use these endpoints to build compliance reports, power dashboards, or stream events into an external logging system. Both routes require the actions:read permission on your token.
Both endpoints on this page require authentication. Include your JWT token as Authorization: Bearer <token>, or use HTTP Basic Auth.

GET /actions

Retrieve a list of audit log records sorted in reverse-chronological order (most recent first). Use the limit query parameter to control how many records are returned.
Required permission: actions:read

Query Parameters

integer
The maximum number of audit log records to return. Defaults to 200 if omitted. The maximum accepted value is 1000; requests with a higher value will be capped or rejected.

Request Example

Response — 200 OK

Returns an array of Action objects sorted reverse-chronologically.
string
The unique identifier for this audit log entry, for example act_999.
string
A dot-namespaced event name describing what occurred, for example customers.create or licenses.update. The first segment identifies the resource type; the second identifies the operation.
string
The username of the staff member who triggered this action.
number
The Unix timestamp (in milliseconds) at which the action was recorded. Divide by 1000 to convert to seconds for use with standard date libraries.
string
A JSON-encoded string containing a snapshot of the affected entity at the time the action was performed. Parse this string as JSON to access individual fields.

Response Example


GET /actions/

Retrieve a single audit log record by its unique ID.
Required permission: actions:read

Path Parameters

string
required
The unique identifier of the action to retrieve, for example act_999.

Request Example

Response — 200 OK

Returns a single Action object with the same fields as described in the GET /actions response above.

Error Responses

The data field is a JSON-encoded string, not an inline object. You must parse it separately after deserializing the outer Action response. For example, in JavaScript: JSON.parse(action.data).