Skip to main content
NervesHub writes an audit log entry when a person, a device or a deployment group does something worth tracing later: a reboot, a firmware push, a release approval, a webhook change. Use it to answer who did what to a device or a deployment group, and when.

What an entry holds

Each entry records:
  • the actor: a user, a device, or a deployment group acting on its own,
  • the resource it acted on,
  • a description, cut at 500 characters,
  • when it happened.
Actions taken from Slack are recorded as the linked NervesHub user, with “from Slack” in the description. See Slack.
Product API keys can also be the actor of an entry. They are on the main branch but in no tagged release as of NervesHub 2.5.4. See CI/CD.

What is recorded

Where to see it

A device

Open the device and select the Activity tab. Entries are listed newest first, grouped by day. The tab shows entries where the device is the actor or the resource. Click Download CSV to export the device’s entries.

A deployment group

Open the deployment group and select the Activity tab. Click Download CSV to export the group’s entries. Members of a role limited to tagged devices cannot open deployment groups, so they cannot see this tab.

Products and organizations

Entries about a product or an organization are recorded, but as of NervesHub 2.5.4 no page in the web UI and no API endpoint lists them.

The CSV export

The export has one row per entry, with these columns: id, org_id, actor_id, actor_type, description, kind, params, resource_id, resource_type, reference_id and inserted_at. kind classifies the entries a device’s Activity tab shows. Entries written before kinds existed, and entries about other resources, have none.

Retention

How long entries are kept is decided by the instance. Each organization can have its own number of days, which takes the place of the instance default. Neither the web UI nor the API sets it. It is a value on the organization’s record (audit_log_days_to_keep), so ask whoever runs your instance. Truncation deletes entries for good. If you need them for longer, export them first. See Feature prerequisites for the instance side.