import 'package:json_annotation/json_annotation.dart';

part 'JwtToken.g.dart';

@JsonSerializable(explicitToJson: true)

class JwtToken {
  @JsonKey(name: 'access_token')
  String accessToken;
  @JsonKey(name: 'token_type')
  String tokenType;
  @JsonKey(name: 'expires_in')
  int expiresIn;

  JwtToken(this.accessToken, this.tokenType, this.expiresIn);

  factory JwtToken.fromJson(Map<String, dynamic> json) => _$JwtTokenFromJson(json);

  Map<String, dynamic> toJson() => _$JwtTokenToJson(this);
}
