import 'package:chat/models/user_info_model.dart'; class AuthModel { String tokenType; String accessToken; String userSig; String userID; UserInfoModel userInfo; String get userToken => '$tokenType $accessToken'; AuthModel({ required this.tokenType, required this.accessToken, required this.userID, required this.userSig, required this.userInfo, }); factory AuthModel.fromJson(Map json) => AuthModel( tokenType: json['token_type'], accessToken: json['access_token'], userID: json['user_id'], userSig: json['user_sig'], userInfo: UserInfoModel.fromJson(json['user_info']), ); }