EncryptedCredentials constructor

const EncryptedCredentials({
  1. @JsonKey(name: 'data') required String data,
  2. @JsonKey(name: 'hash') required String hash,
  3. @JsonKey(name: 'secret') required String secret,
})

Creates a new EncryptedCredentials object.

Implementation

const factory EncryptedCredentials({
  /// Base64-encoded encrypted JSON-serialized data with unique user's
  /// payload, data hashes, and secrets required for EncryptedPassportElement
  /// decryption and authentication
  @JsonKey(name: 'data') required String data,

  /// Base64-encoded data hash for data authentication
  @JsonKey(name: 'hash') required String hash,

  /// Base64-encoded secret, encrypted with the bot's public RSA key, required
  /// for data decryption
  @JsonKey(name: 'secret') required String secret,
}) = _EncryptedCredentials;