{
  "id": "AUDIT-001",
  "name": "CREATE emits a V2 audit head row",
  "description": "Asserts that POST /sobjects/Account writes a _System_AuditLog head row with FieldName=__record__ and Action=CREATE under AUDIT_V2_ENABLED=true. Read back via /services/data/v63.0/admin/audit/log.",
  "scene": "audit_log",
  "object": "_System_AuditLog",
  "setup": [
    {
      "name": "create-account",
      "method": "POST",
      "endpoint": "/services/data/v63.0/sobjects/Account",
      "payload": {
        "Name": "Audit CREATE {timestamp}",
        "Industry": "Others"
      },
      "expected_status": 201,
      "id_var": "acct_id"
    }
  ],
  "method": "GET",
  "endpoint": "/services/data/v63.0/admin/audit/log?object=Account&recordId={acct_id}&limit=50",
  "expects": {
    "status_code": 200
  },
  "response_assertions": [
    {"field": "records.0.ObjectApiName", "operator": "eq", "value": "Account"},
    {"field": "records.0.FieldName", "operator": "eq", "value": "__record__"},
    {"field": "records.0.Action", "operator": "eq", "value": "CREATE"},
    {"field": "records.0.RequestId", "operator": "is_not_null", "value": true}
  ],
  "priority": "P1"
}
