Skip to content

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

Class: FileAttachment<T>

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

Attachment with fileId and fileUniqueId properties

Extends

Extended by

Type Parameters

Type ParameterDefault type
T extends DefaultAttachmentDefaultAttachment

Constructors

Constructor

new FileAttachment<T>(payload): FileAttachment<T>

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

Parameters

ParameterType
payloadT

Returns

FileAttachment<T>

Overrides

Attachment.constructor

Properties

PropertyModifierTypeDescriptionOverridesDefined in
attachmentType?publicAttachmentTypeReturns attachment's type (e.g. 'audio', 'photo')Attachment.attachmentTypecontexts/index.d.ts:326
payloadprotectedT--contexts/index.d.ts:324

Accessors

[toStringTag]

Get Signature

get [toStringTag](): string

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

MDN

Returns

string

Inherited from

Attachment.[toStringTag]


fileId

Get Signature

get fileId(): string

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

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

Returns

string


fileUniqueId

Get Signature

get fileUniqueId(): string

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

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