$this->id, 'person' => [ 'id' => $this->person->id, 'name' => $this->person->name, 'email' => $this->person->email, 'crowd_type' => $this->whenLoaded('person', fn () => $this->person->crowdType?->name ), 'event' => $this->whenLoaded('person', fn () => [ 'id' => $this->person->event_id, 'name' => $this->person->event?->name, ]), ], 'matched_user' => [ 'id' => $this->matchedUser->id, 'first_name' => $this->matchedUser->first_name, 'last_name' => $this->matchedUser->last_name, 'full_name' => $this->matchedUser->full_name, 'email' => $this->matchedUser->email, 'date_of_birth' => $this->matchedUser->date_of_birth?->toDateString(), ], 'matched_on' => $this->matched_on->value, 'matched_on_label' => $this->matched_on->label(), 'confidence' => $this->confidence->value, 'confidence_label' => $this->confidence->label(), 'status' => $this->status->value, 'status_label' => $this->status->label(), 'match_details' => $this->match_details, 'confirmed_by' => $this->when($this->confirmedBy, fn () => [ 'id' => $this->confirmedBy->id, 'full_name' => $this->confirmedBy->full_name, ]), 'confirmed_at' => $this->confirmed_at?->toIso8601String(), 'dismissed_at' => $this->dismissed_at?->toIso8601String(), 'reverted_at' => $this->reverted_at?->toIso8601String(), 'resolved_by' => $this->when($this->resolvedBy, fn () => [ 'id' => $this->resolvedBy->id, 'full_name' => $this->resolvedBy->full_name, ]), 'resolved_at' => $this->resolved_at?->toIso8601String(), 'created_at' => $this->created_at->toIso8601String(), ]; } }