Line data Source code
1 : 2 : 3 : import 'package:json_annotation/json_annotation.dart'; 4 : 5 : import 'chatwoot_action_data.dart'; 6 : 7 : part 'chatwoot_action.g.dart'; 8 : 9 : @JsonSerializable(explicitToJson: true) 10 : class ChatwootAction{ 11 : 12 : @JsonKey() 13 : final String identifier; 14 : 15 : @JsonKey() 16 : final String command; 17 : 18 : @JsonKey() 19 : final ChatwootActionData? data; 20 : 21 1 : ChatwootAction({ 22 : required this.identifier, 23 : this.data, 24 : required this.command 25 : }); 26 : 27 0 : factory ChatwootAction.fromJson(Map<String, dynamic> json) => _$ChatwootActionFromJson(json); 28 : 29 2 : Map<String, dynamic> toJson() => _$ChatwootActionToJson(this); 30 : 31 : }