Skip to main content
Documentation

Audit

Actions in the audit namespace of the Nexigon Hub API.

Badges mark actions of the Device API and the Admin API, whose compatibility differs from other actions.

audit_QueryAuditLogEvents

POST/api/v1/actions/invoke/audit_QueryAuditLogEventsAdmin API

Query the events recorded in the audit log.

Requires administrator permissions.

Request QueryAuditLogEventsAction

  • pageobjectPageRequestoptional

    Opt into cursor pagination. Without this field, the existing limit applies.

    2 fields
    • limitintegeroptional

      Maximum number of items. The default depends on the endpoint and the ceiling is configured by the Hub operator (1000 by default).

      • Page limit must be positive.
    • cursorstringPageCursoroptional

      Continue the same endpoint, scope, filters, and ordering.

Response QueryAuditLogEventsOutput

  • pageobjectPageInfooptional

    Present when cursor pagination was requested.

    1 field
    • nextCursorstringPageCursoroptional

      Cursor for the next page; absent when no more matching rows were visible.

  • eventsarray<object>AuditLogEvent

    List of audit events.

    7 fields
    • eventIdstringAuditLogEventId

      ID of the audit log event.

    • actorobjectActor

      Actor causing the event.

      7 variants

      One of the following, identified by actor:

      • actor: "Anonymous"

        An anonymous, unauthenticated actor.

      • actor: "System"

        The system itself, typically used for internal actions.

      • actor: "Device"

        A device authenticated via a specific deployment token.

        • deviceIdstringDeviceId

          ID of the device.

        • tokenIdstringDeploymentTokenId

          ID of the deployment token used for authentication.

      • actor: "User"

        A user typically authenticated via a user session.

        • userIdstringUserId

          ID of the user.

      • actor: "UserToken"

        A user authenticated via a specific token.

        • userIdstringUserId

          ID of the user.

        • tokenIdstringUserTokenId

          ID of the user token used for authentication.

      • actor: "ClusterNode"

        A cluster node.

        • nodeIdstringClusterNodeId

          ID of the cluster node.

      • actor: "OrganizationApiToken"

        An organization API token.

        • organizationIdstringOrganizationId

          ID of the organization.

        • tokenIdstringOrganizationApiTokenId

          ID of the API token.

    • eventstring

      Type of the event that was recorded.

    • dataanyJsonValue

      Additional audit data associated with the event.

    • createdAtstring (date-time)Timestamp

      Timestamp indicating when the audit log event was recorded.

    • actionobjectAuditLogEventActionoptional

      Action the event has been caused by (if any).

      1 field
      • actionIdstringAuditLogActionId

        ID of the action.

    • jobobjectAuditLogEventJoboptional

      Job the event has been caused by (if any).

      1 field
      • jobIdstringJobId

        ID of the job.

  • referencesobjectAuditLogReferencesoptional

    Names of the actors of the returned events.

    Absent in responses of Nexigon Hub 2026.3 and earlier.

    3 fields
    • usersarray<object>AuditLogUserReference

      Users acting directly or through a user token.

      3 fields
      • userIdstringUserId

        ID of the user.

      • displayNamestringoptional

        Name of the user.

      • emailstring

        Email of the user.

    • devicesarray<object>AuditLogDeviceReference

      Devices.

      2 fields
      • deviceIdstringDeviceId

        ID of the device.

      • namestring

        Name of the device.

    • organizationApiTokensarray<object>AuditLogOrganizationApiTokenReference

      Organization API tokens.

      2 fields
      • tokenIdstringOrganizationApiTokenId

        ID of the API token.

      • namestring

        Name of the API token.

Example

curl --fail-with-body \
  -H "Authorization: Bearer $NEXIGON_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{}' \
  $NEXIGON_HUB_URL/api/v1/actions/invoke/audit_QueryAuditLogEvents
{
  "events": [
    {
      "eventId": "<audit-log-event-id>",
      "actor": {
        "actor": "Device",
        "deviceId": "<device-id>",
        "tokenId": "<deployment-token-id>"
      },
      "event": "<event>",
      "data": {},
      "createdAt": "2026-01-01T12:00:00Z"
    }
  ]
}

audit_QueryAuditLogActions

POST/api/v1/actions/invoke/audit_QueryAuditLogActionsAdmin API

Query the actions recorded in the audit log.

Requires administrator permissions.

Request QueryAuditLogActionsAction

  • pageobjectPageRequestoptional

    Opt into cursor pagination. Without this field, the existing limit applies.

    2 fields
    • limitintegeroptional

      Maximum number of items. The default depends on the endpoint and the ceiling is configured by the Hub operator (1000 by default).

      • Page limit must be positive.
    • cursorstringPageCursoroptional

      Continue the same endpoint, scope, filters, and ordering.

Response QueryAuditLogActionsOutput

  • pageobjectPageInfooptional

    Present when cursor pagination was requested.

    1 field
    • nextCursorstringPageCursoroptional

      Cursor for the next page; absent when no more matching rows were visible.

  • actionsarray<object>AuditLogAction

    List of actions.

    6 fields
    • actionIdstringAuditLogActionId

      ID of the audit log action.

    • actorobjectActor

      Actor that performed the action.

      7 variants

      One of the following, identified by actor:

      • actor: "Anonymous"

        An anonymous, unauthenticated actor.

      • actor: "System"

        The system itself, typically used for internal actions.

      • actor: "Device"

        A device authenticated via a specific deployment token.

        • deviceIdstringDeviceId

          ID of the device.

        • tokenIdstringDeploymentTokenId

          ID of the deployment token used for authentication.

      • actor: "User"

        A user typically authenticated via a user session.

        • userIdstringUserId

          ID of the user.

      • actor: "UserToken"

        A user authenticated via a specific token.

        • userIdstringUserId

          ID of the user.

        • tokenIdstringUserTokenId

          ID of the user token used for authentication.

      • actor: "ClusterNode"

        A cluster node.

        • nodeIdstringClusterNodeId

          ID of the cluster node.

      • actor: "OrganizationApiToken"

        An organization API token.

        • organizationIdstringOrganizationId

          ID of the organization.

        • tokenIdstringOrganizationApiTokenId

          ID of the API token.

    • actionstring

      Type of the action that was performed.

    • datamap<string, any>JsonValue

      Additional audit data associated with the action.

    • statusstringAuditLogActionStatus

      Status associated with the action

      • "Rejected"

        Action got rejected (failed precondition check).

      • "Panicked"

        Action or precondition check panicked (e.g., due to a bug).

      • "Succeeded"

        Action was executed successfully.

      • "Failed"

        Action execution failed (e.g., due to missing permissions).

      • "Pending"

        Action is being executed.

    • createdAtstring (date-time)Timestamp

      Timestamp indicating when the audit log action was recorded.

  • referencesobjectAuditLogReferencesoptional

    Names of the actors of the returned actions.

    Absent in responses of Nexigon Hub 2026.3 and earlier.

    3 fields
    • usersarray<object>AuditLogUserReference

      Users acting directly or through a user token.

      3 fields
      • userIdstringUserId

        ID of the user.

      • displayNamestringoptional

        Name of the user.

      • emailstring

        Email of the user.

    • devicesarray<object>AuditLogDeviceReference

      Devices.

      2 fields
      • deviceIdstringDeviceId

        ID of the device.

      • namestring

        Name of the device.

    • organizationApiTokensarray<object>AuditLogOrganizationApiTokenReference

      Organization API tokens.

      2 fields
      • tokenIdstringOrganizationApiTokenId

        ID of the API token.

      • namestring

        Name of the API token.

Example

curl --fail-with-body \
  -H "Authorization: Bearer $NEXIGON_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{}' \
  $NEXIGON_HUB_URL/api/v1/actions/invoke/audit_QueryAuditLogActions
{
  "actions": [
    {
      "actionId": "<audit-log-action-id>",
      "actor": {
        "actor": "Device",
        "deviceId": "<device-id>",
        "tokenId": "<deployment-token-id>"
      },
      "action": "<action>",
      "data": {
        "<key>": {}
      },
      "status": "Rejected",
      "createdAt": "2026-01-01T12:00:00Z"
    }
  ]
}