---
title: "List audit logs"
method: GET
path: "/audit_logs"
tags: ["Troubleshooting"]
---

# List audit logs

`GET /audit_logs`

## Request

- Base URL: `https://HOSTNAME:8887/api`
- URL: `https://HOSTNAME:8887/api/audit_logs`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/portsip/apis/portsip-pbx-rest-api/docs/audit_logs/get.ts> (a function with typed inputs; its response is checked against the schema)

Retrieve a collection of audit logs.

## Response `200`

OK

- object
  - `count` integer: Total number of resource.
  - `items` object[]
    - `id` string: The unique ID of the resource.
    - `created_at` string, date_time: The RFC 3339 format is defined by The date_time notation as defined by [RFC 3339, section 5.6](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6), for example, 2017-07-21T17:32:28Z
    - `source` string: The source of the audit log.
    - `ip` string, date_time: The RFC 3339 format is defined by The date_time notation as defined by [RFC 3339, section 5.6](https://datatracker.ietf.org/doc/html/rfc3339#section-5.6), for example, 2017-07-21T17:32:28Z
    - `action` 'CREATE' | 'UPDATE' | 'DELETE' | 'LOGIN' | 'LOGOUT' | 'RECHARGE': The audit log actions. Can be either: - `CREATE` created some resources. - `UPDATE` updated some resources. - `DELETE` deleted some resources. - `LOGIN` user logged in. - `LOGOUT` user logged out. - `RECHARGE` user account balance changed.
    - `object_type` 'ALLOWED_COUNTRY_CODES' | 'AUTOMATIC_CALLBACK' | 'BILLING' | 'BLACKLISTED_NUMBER' | 'BLOCK_CODE' | 'CALL_PARK_GROUP' | 'CALL_PARK_SERVER' | 'CALL_PICKUP_GROUP' | 'CALL_QUEUE' | 'CALL_QUEUE_BLACKLISTED_NUM' | 'CALL_QUEUE_SERVER' | 'CALL_RECORDING' | 'CALL_REPORT' | 'CONFERENCE_ROOM' | 'CONFERENCE_SERVER' | 'CONTACT' | 'CONTACT_GROUP' | 'CUSTOM_EMAIL_TEMPLATE' | 'DEALER' | 'EMERGENCY_NUMBER' | 'EXCLUSIVE_NUMBER' | 'FEATURE_ACCESS_CODE' | 'HOLIDAY' | 'HOT_DESKING' | 'INBOUND_RULE' | 'IP_BLACKLIST' | 'IVR' | 'IVR_SERVER' | 'LOGIN' | 'MEDIA_SERVER' | 'MICROSOFT_365_INTEGRATION' | 'MOBILE_PUSH' | 'MOH' | 'MONITOR_GROUP' | 'MONITOR_SERVER' | 'OUTBOUND_RULE' | 'PHONE_TEMPLATE' | 'PROVIDER' | 'RATING' | 'RING_GROUP' | 'ROLE' | 'SHARED_VOICEMAIL' | 'SYSTEM' | 'TENANT' | 'TRANSPORT' | 'USER' | 'USER_GROUP' | 'VIP_NUMBER' | 'VOICEMAIL_SERVER': The audit log type.
    - `user_name` string: The user name of the audit log.
    - `object_name` string: The object name of the audit log.
    - `old_state` string: The old state of the audit log.
    - `new_state` string: The new state of the audit log.

## Other responses

- `4XX`: Error

---

[API](https://skmtc.dev/portsip/apis/portsip-pbx-rest-api.md) - [All operations](https://skmtc.dev/portsip/apis/portsip-pbx-rest-api/llms.txt) - [OpenAPI document](https://skmtc.dev/portsip/apis/portsip-pbx-rest-api/revisions/577415d4a3d5?raw)
