class WelcomeVideoModel { int totalItemsCount; int statusCode; String message; String welcomeVideoUrl; WelcomeVideoModel({this.totalItemsCount, this.statusCode, this.message, this.welcomeVideoUrl}); WelcomeVideoModel.fromJson(Map json) { totalItemsCount = json['totalItemsCount']; statusCode = json['statusCode']; message = json['message']; if (json['data'] != null) { welcomeVideoUrl = json['data']['welcomevideoUrl']; } } Map toJson() { final Map data = new Map(); data['totalItemsCount'] = this.totalItemsCount; data['statusCode'] = this.statusCode; data['message'] = this.message; if (this.welcomeVideoUrl != null) { data['data']['welcomevideoUrl'] = this.welcomeVideoUrl; } return data; } }