toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  final customerIdentifier = this.customerIdentifier;
  final dimension = this.dimension;
  final timestamp = this.timestamp;
  final quantity = this.quantity;
  final usageAllocations = this.usageAllocations;
  return {
    'CustomerIdentifier': customerIdentifier,
    'Dimension': dimension,
    'Timestamp': unixTimestampToJson(timestamp),
    if (quantity != null) 'Quantity': quantity,
    if (usageAllocations != null) 'UsageAllocations': usageAllocations,
  };
}