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

# downloadHistory

> Function downloadHistory in the Baileys API.

> **downloadHistory**(`msg`, `options`): `Promise`\<[`HistorySync`](/proto-reference/classes/HistorySync)>

Defined in: [src/Utils/history.ts:33](https://github.com/WhiskeySockets/Baileys/blob/master/src/Utils/history.ts#L33)

## Parameters

### msg

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

### options

`RequestInit`

## Returns

`Promise`\<[`HistorySync`](/proto-reference/classes/HistorySync)>
