A wrapper around the iOS Backup Extraction Go program. It is based on a fork which has some modifications, most importantly replacing the first argument with the path to the backup rather than the GUID.
The Go binary can be installed globally:
npm i -g irestore
The Node.js package can also be installed locally:
npm i irestore
The Go binary README documents the command line arguments.
A backup can be restored with the following commands:
const IRestore = require('irestore');
const iRestore = new IRestore('/path/to/backup');
await iRestore.restore('HomeDomain', '/path/to/decrypted-backup');
MIT.