{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/atlassian/json-schema/atlassian-audit-record-create-schema.json",
  "title": "AuditRecordCreate",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/atlassian-audit-api-openapi.yml#/components/schemas/AuditRecordCreate",
  "required": [
    "remoteAddress"
  ],
  "type": "object",
  "properties": {
    "author": {
      "required": [
        "type"
      ],
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "description": "Set to 'user'.",
          "default": "user",
          "enum": [
            "user"
          ]
        },
        "displayName": {
          "type": "string",
          "description": "The name that is displayed on the audit log in the Confluence UI."
        },
        "operations": {
          "type": "object",
          "properties": {},
          "description": "Always defaults to null."
        },
        "username": {
          "$ref": "#/$defs/GenericUserName"
        },
        "userKey": {
          "$ref": "#/$defs/GenericUserKey"
        }
      },
      "description": "The user that actioned the event. If `author` is not specified, then all\n`author` properties will be set to null/empty, except for `type` which\nwill be set to 'user'."
    },
    "remoteAddress": {
      "type": "string",
      "description": "The IP address of the computer where the event was initiated from."
    },
    "creationDate": {
      "type": "integer",
      "description": "The creation date-time of the audit record, as a timestamp. This is converted\nto a date-time display in the Confluence UI. If the `creationDate` is not\nspecified, then it will be set to the timestamp for the current date-time.",
      "format": "int64"
    },
    "summary": {
      "type": "string",
      "description": "The summary of the event, which is displayed in the 'Change' column on\nthe audit log in the Confluence UI."
    },
    "description": {
      "type": "string",
      "description": "A long description of the event, which is displayed in the 'Description'\nfield on the audit log in the Confluence UI."
    },
    "category": {
      "type": "string",
      "description": "The category of the event, which is displayed in the 'Event type' column\non the audit log in the Confluence UI."
    },
    "sysAdmin": {
      "type": "boolean",
      "description": "Indicates whether the event was actioned by a system administrator.",
      "default": false
    },
    "affectedObject": {
      "$ref": "#/$defs/AffectedObject"
    },
    "changedValues": {
      "type": "array",
      "description": "The values that were changed in the event.",
      "items": {
        "$ref": "#/$defs/ChangedValue"
      }
    },
    "associatedObjects": {
      "type": "array",
      "description": "Objects that were associated with the event. For example, if the event\nwas a space permission change then the associated object would be the\nspace.",
      "items": {
        "$ref": "#/$defs/AffectedObject"
      }
    }
  },
  "$defs": {
    "AffectedObject": {
      "required": [
        "name",
        "objectType"
      ],
      "type": "object",
      "properties": {
        "name": {
          "type": "string"
        },
        "objectType": {
          "type": "string"
        }
      }
    },
    "ChangedValue": {
      "required": [
        "name",
        "newValue",
        "oldValue"
      ],
      "type": "object",
      "properties": {
        "name": {
          "type": "string"
        },
        "oldValue": {
          "type": "string"
        },
        "hiddenOldValue": {
          "type": "string"
        },
        "newValue": {
          "type": "string"
        },
        "hiddenNewValue": {
          "type": "string"
        }
      }
    },
    "GenericUserKey": {
      "type": [
        "string",
        "null"
      ],
      "description": "This property is no longer available and will be removed from the documentation soon.\nUse `accountId` instead.\nSee the [deprecation notice](/cloud/confluence/deprecation-notice-user-privacy-api-migration-guide/) for details."
    },
    "GenericUserName": {
      "type": [
        "string",
        "null"
      ],
      "description": "This property is no longer available and will be removed from the documentation soon.\nUse `accountId` instead.\nSee the [deprecation notice](/cloud/confluence/deprecation-notice-user-privacy-api-migration-guide/) for details."
    }
  }
}