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

# HistorySyncOnDemandRequest

> Protobuf class HistorySyncOnDemandRequest generated from WAProto.

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

## Implements

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

## Constructors

### new HistorySyncOnDemandRequest()

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

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

#### Parameters

##### p?

[`IHistorySyncOnDemandRequest`](/proto-reference/Message/PeerDataOperationRequestMessage/interfaces/IHistorySyncOnDemandRequest)

#### Returns

[`HistorySyncOnDemandRequest`](/proto-reference/Message/PeerDataOperationRequestMessage/classes/HistorySyncOnDemandRequest)

## Properties

### accountLid?

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

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

#### Implementation of

[`IHistorySyncOnDemandRequest`](/proto-reference/Message/PeerDataOperationRequestMessage/interfaces/IHistorySyncOnDemandRequest).[`accountLid`](/proto-reference/Message/PeerDataOperationRequestMessage/interfaces/IHistorySyncOnDemandRequest#accountlid)

***

### chatJid?

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

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

#### Implementation of

[`IHistorySyncOnDemandRequest`](/proto-reference/Message/PeerDataOperationRequestMessage/interfaces/IHistorySyncOnDemandRequest).[`chatJid`](/proto-reference/Message/PeerDataOperationRequestMessage/interfaces/IHistorySyncOnDemandRequest#chatjid)

***

### oldestMsgFromMe?

> `optional` **oldestMsgFromMe**: `null` | `boolean`

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

#### Implementation of

[`IHistorySyncOnDemandRequest`](/proto-reference/Message/PeerDataOperationRequestMessage/interfaces/IHistorySyncOnDemandRequest).[`oldestMsgFromMe`](/proto-reference/Message/PeerDataOperationRequestMessage/interfaces/IHistorySyncOnDemandRequest#oldestmsgfromme)

***

### oldestMsgId?

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

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

#### Implementation of

[`IHistorySyncOnDemandRequest`](/proto-reference/Message/PeerDataOperationRequestMessage/interfaces/IHistorySyncOnDemandRequest).[`oldestMsgId`](/proto-reference/Message/PeerDataOperationRequestMessage/interfaces/IHistorySyncOnDemandRequest#oldestmsgid)

***

### oldestMsgTimestampMs?

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

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

#### Implementation of

[`IHistorySyncOnDemandRequest`](/proto-reference/Message/PeerDataOperationRequestMessage/interfaces/IHistorySyncOnDemandRequest).[`oldestMsgTimestampMs`](/proto-reference/Message/PeerDataOperationRequestMessage/interfaces/IHistorySyncOnDemandRequest#oldestmsgtimestampms)

***

### onDemandMsgCount?

> `optional` **onDemandMsgCount**: `null` | `number`

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

#### Implementation of

[`IHistorySyncOnDemandRequest`](/proto-reference/Message/PeerDataOperationRequestMessage/interfaces/IHistorySyncOnDemandRequest).[`onDemandMsgCount`](/proto-reference/Message/PeerDataOperationRequestMessage/interfaces/IHistorySyncOnDemandRequest#ondemandmsgcount)

## Methods

### create()

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

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

#### Parameters

##### properties?

[`IHistorySyncOnDemandRequest`](/proto-reference/Message/PeerDataOperationRequestMessage/interfaces/IHistorySyncOnDemandRequest)

#### Returns

[`HistorySyncOnDemandRequest`](/proto-reference/Message/PeerDataOperationRequestMessage/classes/HistorySyncOnDemandRequest)

***

### decode()

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

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

#### Parameters

##### r

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

##### l?

`number`

#### Returns

[`HistorySyncOnDemandRequest`](/proto-reference/Message/PeerDataOperationRequestMessage/classes/HistorySyncOnDemandRequest)

***

### encode()

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

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

#### Parameters

##### m

[`IHistorySyncOnDemandRequest`](/proto-reference/Message/PeerDataOperationRequestMessage/interfaces/IHistorySyncOnDemandRequest)

##### w?

`Writer`

#### Returns

`Writer`

***

### fromObject()

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

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

#### Parameters

##### d

#### Returns

[`HistorySyncOnDemandRequest`](/proto-reference/Message/PeerDataOperationRequestMessage/classes/HistorySyncOnDemandRequest)

***

### getTypeUrl()

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

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

#### Parameters

##### typeUrlPrefix?

`string`

#### Returns

`string`

***

### toJSON()

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

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

#### Returns

`object`

***

### toObject()

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

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

#### Parameters

##### m

[`HistorySyncOnDemandRequest`](/proto-reference/Message/PeerDataOperationRequestMessage/classes/HistorySyncOnDemandRequest)

##### o?

`IConversionOptions`

#### Returns

`object`
