toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  return {
    'event': eventType.eventName,
    'version': version,
    'build': buildNumber,
    'mode': releaseMode,
    'platforms': platforms,
    if (commit != null) 'commit': commit,
    if (tag != null) 'tag': tag,
    if (releaseNotes != null) 'releaseNotes': releaseNotes,
    if (artifacts.isNotEmpty) 'artifacts': artifacts,
    'deploymentStatus': deploymentStatus,
    if (environment != null) 'environment': environment,
    if (flavor != null) 'flavor': flavor,
    'timestamp': timestamp.toIso8601String(),
    if (error != null) 'error': error,
    'isPatch': isPatch,
  };
}