Merge branch 'feat/inda-383-daily-stat' into 'main'
[ProtonMail-WebClient.git] / packages / recovery-kit / README.md
blob47b3281d9cc185a64477265a5e2c94568136a8ee
1 # Recovery kit
3 Enables the programmatic generation of the recovery kit pdf.
5 ## Usage
7 ```ts
8 import { generatePDFKit } from '@proton/recovery-kit';
9 import downloadFile from '@proton/shared/lib/helpers/downloadFile';
11 const pdf = await generatePDFKit({
12     emailAddress: 'eric.norbert@gmail.com',
13     recoveryPhrase: 'auto pottery age relief turkey face tide useful near lottery alley wolf',
14     password: '12341234',
15 });
17 // Browser
18 const blob = new Blob([pdf.buffer], { type: 'application/pdf' });
19 downloadFile(blob, 'recovery_kit.pdf');
20 ```