> ## Documentation Index
> Fetch the complete documentation index at: https://baileys.wiki/llms.txt
> Use this file to discover all available pages before exploring further.

# InvoiceMessage

> Protobuf class InvoiceMessage generated from WAProto.

Defined in: [WAProto/index.d.ts:7041](https://github.com/WhiskeySockets/Baileys/blob/master/WAProto/index.d.ts#L7041)

## Implements

* [`IInvoiceMessage`](/proto-reference/Message/interfaces/IInvoiceMessage)

## Constructors

### new InvoiceMessage()

> **new InvoiceMessage**(`p`?): [`InvoiceMessage`](/proto-reference/Message/classes/InvoiceMessage)

Defined in: [WAProto/index.d.ts:7042](https://github.com/WhiskeySockets/Baileys/blob/master/WAProto/index.d.ts#L7042)

#### Parameters

##### p?

[`IInvoiceMessage`](/proto-reference/Message/interfaces/IInvoiceMessage)

#### Returns

[`InvoiceMessage`](/proto-reference/Message/classes/InvoiceMessage)

## Properties

### attachmentDirectPath?

> `optional` **attachmentDirectPath**: `null` | `string`

Defined in: [WAProto/index.d.ts:7051](https://github.com/WhiskeySockets/Baileys/blob/master/WAProto/index.d.ts#L7051)

#### Implementation of

[`IInvoiceMessage`](/proto-reference/Message/interfaces/IInvoiceMessage).[`attachmentDirectPath`](/proto-reference/Message/interfaces/IInvoiceMessage#attachmentdirectpath)

***

### attachmentFileEncSha256?

> `optional` **attachmentFileEncSha256**: `null` | `Uint8Array`\<`ArrayBufferLike`>

Defined in: [WAProto/index.d.ts:7050](https://github.com/WhiskeySockets/Baileys/blob/master/WAProto/index.d.ts#L7050)

#### Implementation of

[`IInvoiceMessage`](/proto-reference/Message/interfaces/IInvoiceMessage).[`attachmentFileEncSha256`](/proto-reference/Message/interfaces/IInvoiceMessage#attachmentfileencsha256)

***

### attachmentFileSha256?

> `optional` **attachmentFileSha256**: `null` | `Uint8Array`\<`ArrayBufferLike`>

Defined in: [WAProto/index.d.ts:7049](https://github.com/WhiskeySockets/Baileys/blob/master/WAProto/index.d.ts#L7049)

#### Implementation of

[`IInvoiceMessage`](/proto-reference/Message/interfaces/IInvoiceMessage).[`attachmentFileSha256`](/proto-reference/Message/interfaces/IInvoiceMessage#attachmentfilesha256)

***

### attachmentJpegThumbnail?

> `optional` **attachmentJpegThumbnail**: `null` | `Uint8Array`\<`ArrayBufferLike`>

Defined in: [WAProto/index.d.ts:7052](https://github.com/WhiskeySockets/Baileys/blob/master/WAProto/index.d.ts#L7052)

#### Implementation of

[`IInvoiceMessage`](/proto-reference/Message/interfaces/IInvoiceMessage).[`attachmentJpegThumbnail`](/proto-reference/Message/interfaces/IInvoiceMessage#attachmentjpegthumbnail)

***

### attachmentMediaKey?

> `optional` **attachmentMediaKey**: `null` | `Uint8Array`\<`ArrayBufferLike`>

Defined in: [WAProto/index.d.ts:7047](https://github.com/WhiskeySockets/Baileys/blob/master/WAProto/index.d.ts#L7047)

#### Implementation of

[`IInvoiceMessage`](/proto-reference/Message/interfaces/IInvoiceMessage).[`attachmentMediaKey`](/proto-reference/Message/interfaces/IInvoiceMessage#attachmentmediakey)

***

### attachmentMediaKeyTimestamp?

> `optional` **attachmentMediaKeyTimestamp**: `null` | `number` | `Long`

Defined in: [WAProto/index.d.ts:7048](https://github.com/WhiskeySockets/Baileys/blob/master/WAProto/index.d.ts#L7048)

#### Implementation of

[`IInvoiceMessage`](/proto-reference/Message/interfaces/IInvoiceMessage).[`attachmentMediaKeyTimestamp`](/proto-reference/Message/interfaces/IInvoiceMessage#attachmentmediakeytimestamp)

***

### attachmentMimetype?

> `optional` **attachmentMimetype**: `null` | `string`

Defined in: [WAProto/index.d.ts:7046](https://github.com/WhiskeySockets/Baileys/blob/master/WAProto/index.d.ts#L7046)

#### Implementation of

[`IInvoiceMessage`](/proto-reference/Message/interfaces/IInvoiceMessage).[`attachmentMimetype`](/proto-reference/Message/interfaces/IInvoiceMessage#attachmentmimetype)

***

### attachmentType?

> `optional` **attachmentType**: `null` | [`AttachmentType`](/proto-reference/Message/InvoiceMessage/enumerations/AttachmentType)

Defined in: [WAProto/index.d.ts:7045](https://github.com/WhiskeySockets/Baileys/blob/master/WAProto/index.d.ts#L7045)

#### Implementation of

[`IInvoiceMessage`](/proto-reference/Message/interfaces/IInvoiceMessage).[`attachmentType`](/proto-reference/Message/interfaces/IInvoiceMessage#attachmenttype)

***

### note?

> `optional` **note**: `null` | `string`

Defined in: [WAProto/index.d.ts:7043](https://github.com/WhiskeySockets/Baileys/blob/master/WAProto/index.d.ts#L7043)

#### Implementation of

[`IInvoiceMessage`](/proto-reference/Message/interfaces/IInvoiceMessage).[`note`](/proto-reference/Message/interfaces/IInvoiceMessage#note)

***

### token?

> `optional` **token**: `null` | `string`

Defined in: [WAProto/index.d.ts:7044](https://github.com/WhiskeySockets/Baileys/blob/master/WAProto/index.d.ts#L7044)

#### Implementation of

[`IInvoiceMessage`](/proto-reference/Message/interfaces/IInvoiceMessage).[`token`](/proto-reference/Message/interfaces/IInvoiceMessage#token)

## Methods

### create()

> `static` **create**(`properties`?): [`InvoiceMessage`](/proto-reference/Message/classes/InvoiceMessage)

Defined in: [WAProto/index.d.ts:7053](https://github.com/WhiskeySockets/Baileys/blob/master/WAProto/index.d.ts#L7053)

#### Parameters

##### properties?

[`IInvoiceMessage`](/proto-reference/Message/interfaces/IInvoiceMessage)

#### Returns

[`InvoiceMessage`](/proto-reference/Message/classes/InvoiceMessage)

***

### decode()

> `static` **decode**(`r`, `l`?): [`InvoiceMessage`](/proto-reference/Message/classes/InvoiceMessage)

Defined in: [WAProto/index.d.ts:7055](https://github.com/WhiskeySockets/Baileys/blob/master/WAProto/index.d.ts#L7055)

#### Parameters

##### r

`Uint8Array`\<`ArrayBufferLike`> | `Reader`

##### l?

`number`

#### Returns

[`InvoiceMessage`](/proto-reference/Message/classes/InvoiceMessage)

***

### encode()

> `static` **encode**(`m`, `w`?): `Writer`

Defined in: [WAProto/index.d.ts:7054](https://github.com/WhiskeySockets/Baileys/blob/master/WAProto/index.d.ts#L7054)

#### Parameters

##### m

[`IInvoiceMessage`](/proto-reference/Message/interfaces/IInvoiceMessage)

##### w?

`Writer`

#### Returns

`Writer`

***

### fromObject()

> `static` **fromObject**(`d`): [`InvoiceMessage`](/proto-reference/Message/classes/InvoiceMessage)

Defined in: [WAProto/index.d.ts:7056](https://github.com/WhiskeySockets/Baileys/blob/master/WAProto/index.d.ts#L7056)

#### Parameters

##### d

#### Returns

[`InvoiceMessage`](/proto-reference/Message/classes/InvoiceMessage)

***

### getTypeUrl()

> `static` **getTypeUrl**(`typeUrlPrefix`?): `string`

Defined in: [WAProto/index.d.ts:7059](https://github.com/WhiskeySockets/Baileys/blob/master/WAProto/index.d.ts#L7059)

#### Parameters

##### typeUrlPrefix?

`string`

#### Returns

`string`

***

### toJSON()

> **toJSON**(): `object`

Defined in: [WAProto/index.d.ts:7058](https://github.com/WhiskeySockets/Baileys/blob/master/WAProto/index.d.ts#L7058)

#### Returns

`object`

***

### toObject()

> `static` **toObject**(`m`, `o`?): `object`

Defined in: [WAProto/index.d.ts:7057](https://github.com/WhiskeySockets/Baileys/blob/master/WAProto/index.d.ts#L7057)

#### Parameters

##### m

[`InvoiceMessage`](/proto-reference/Message/classes/InvoiceMessage)

##### o?

`IConversionOptions`

#### Returns

`object`
