{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/bookmyhost/json-schema/bookmyhost-paginated-audit-log-response-schema.json",
  "title": "PaginatedAuditLogResponse",
  "description": "Response model for paginated audit logs",
  "x-generated": "2026-11-12",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/bookmyhost-audit-logging-api-openapi.yml#/components/schemas/PaginatedAuditLogResponse",
  "properties": {
    "audit_logs": {
      "items": {
        "$ref": "#/$defs/AuditLogResponse"
      },
      "type": "array",
      "title": "Audit Logs"
    },
    "total": {
      "type": "integer",
      "title": "Total",
      "description": "Total number of audit logs matching the filters"
    },
    "page": {
      "type": "integer",
      "title": "Page",
      "description": "Current page number"
    },
    "page_size": {
      "type": "integer",
      "title": "Page Size",
      "description": "Number of items per page"
    },
    "total_pages": {
      "type": "integer",
      "title": "Total Pages",
      "description": "Total number of pages"
    }
  },
  "type": "object",
  "required": [
    "audit_logs",
    "total",
    "page",
    "page_size",
    "total_pages"
  ],
  "$defs": {
    "AuditLogResponse": {
      "properties": {
        "id": {
          "type": "string",
          "title": "Id"
        },
        "updated_at": {
          "type": "string",
          "format": "date-time",
          "title": "Updated At"
        },
        "changed_by": {
          "type": "string",
          "title": "Changed By"
        },
        "changed_by_api_key": {
          "type": "string",
          "title": "Changed By Api Key"
        },
        "action": {
          "type": "string",
          "title": "Action"
        },
        "table_name": {
          "type": "string",
          "title": "Table Name"
        },
        "object_id": {
          "type": "string",
          "title": "Object Id"
        },
        "before_value": {
          "anyOf": [
            {
              "additionalProperties": true,
              "type": "object"
            },
            {
              "type": "null"
            }
          ],
          "title": "Before Value"
        },
        "updated_values": {
          "anyOf": [
            {
              "additionalProperties": true,
              "type": "object"
            },
            {
              "type": "null"
            }
          ],
          "title": "Updated Values"
        }
      },
      "type": "object",
      "required": [
        "id",
        "updated_at",
        "changed_by",
        "changed_by_api_key",
        "action",
        "table_name",
        "object_id"
      ],
      "title": "AuditLogResponse",
      "description": "Response model for a single audit log entry"
    }
  }
}