Skip to content
Lira APILira API

Audit Logs

The audit log records all significant actions taken within your organization: API key creation, member changes, webhook updates, and more.

Requires ORG_ADMIN role.


Query audit logs

Terminal
curl "https://api.lira.com/api/v1/client/audit-logs?startDate=2026-03-01T00:00:00Z&limit=50" \
  -H "Authorization: Bearer YOUR_TOKEN"

Query parameters

ParameterTypeDescription
userIdstring (UUID)Filter by the user who performed the action
actionstringFilter by action name (e.g. api_key.created)
resourcestringFilter by resource type (e.g. api_key, webhook)
startDatestring (ISO 8601)Filter entries from this date
endDatestring (ISO 8601)Filter entries up to this date
searchstringFree-text search across log entries
pageintegerPage number for paginated results
limitintegerResults per page (max 100)

Note

Providing page and/or limit returns a paginated response with a meta object. Omitting both returns a plain array.


Response

Plain array (no pagination)

JSON
[
  {
    "id": "log_...",
    "organizationId": "org_...",
    "userId": "usr_...",
    "action": "api_key.created",
    "resource": "api_key",
    "metadata": { "keyId": "key_...", "name": "My sandbox key" },
    "ipAddress": "102.88.12.1",
    "userAgent": "Mozilla/5.0 ...",
    "createdAt": "2026-03-09T10:00:00.000Z"
  }
]

Paginated response

JSON
{
  "data": [ ... ],
  "meta": {
    "page": 1,
    "limit": 50,
    "total": 240,
    "totalPages": 5
  }
}

Response fields

FieldTypeDescription
idstringUnique log entry ID
organizationIdstringYour organization's ID
userIdstringID of the user who performed the action
actionstringMachine-readable action name
resourcestringResource type affected
metadataobjectAdditional context for the action
ipAddressstringIP address of the request
userAgentstringUser agent of the request
createdAtstringTimestamp of the action

Next steps