Skip to content

GramIO API Reference / @gramio/contexts/dist / PassportFile

Class: PassportFile

Defined in: contexts/index.d.ts:2405

This object represents a file uploaded to Telegram Passport. Currently all Telegram Passport files are in JPEG format when decrypted and don't exceed 10MB.

Constructors

Constructor

new PassportFile(payload): PassportFile

Defined in: contexts/index.d.ts:2407

Parameters

ParameterType
payloadTelegramPassportFile

Returns

PassportFile

Properties

PropertyTypeDefined in
payloadTelegramPassportFilecontexts/index.d.ts:2406

Accessors

[toStringTag]

Get Signature

get [toStringTag](): string

Defined in: contexts/index.d.ts:2409

MDN

Returns

string


fileDate

Get Signature

get fileDate(): number

Defined in: contexts/index.d.ts:2422

Unix time when the file was uploaded

Returns

number


fileId

Get Signature

get fileId(): string

Defined in: contexts/index.d.ts:2413

Identifier for this file, which can be used to download or reuse the file

Returns

string


fileSize

Get Signature

get fileSize(): number

Defined in: contexts/index.d.ts:2420

File size

Returns

number


fileUniqueId

Get Signature

get fileUniqueId(): string

Defined in: contexts/index.d.ts:2418

Unique identifier for this file, which is supposed to be the same over time and for different bots. Can't be used to download or reuse the file.

Returns

string