toJson method

Map<String, dynamic> toJson()

Converts this event to a JSON-compatible map.

Implementation

Map<String, dynamic> toJson() => {
  'timestamp': timestamp.toIso8601String(),
  'cidOrMultihash': cidOrMultihash,
  'action': action,
  'source': source,
  if (reason != null) 'reason': reason,
};