{"id":13510253,"url":"https://github.com/75lb/handbrake-js","last_synced_at":"2025-05-15T08:08:47.523Z","repository":{"id":6955457,"uuid":"8207539","full_name":"75lb/handbrake-js","owner":"75lb","description":"Video encoding / transcoding / converting for node.js","archived":false,"fork":false,"pushed_at":"2023-05-03T15:22:21.000Z","size":5730,"stargazers_count":549,"open_issues_count":5,"forks_count":69,"subscribers_count":17,"default_branch":"master","last_synced_at":"2024-05-22T03:03:25.069Z","etag":null,"topics":["batch","ffmpeg","handbrake","javascript","nodejs","video","video-encoding"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/75lb.png","metadata":{"files":{"readme":"README.hbs","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2013-02-14T20:59:47.000Z","updated_at":"2024-05-21T00:07:55.000Z","dependencies_parsed_at":"2024-01-13T19:26:02.453Z","dependency_job_id":"a8faffd6-074c-48a1-aca6-12072055c500","html_url":"https://github.com/75lb/handbrake-js","commit_stats":{"total_commits":421,"total_committers":12,"mean_commits":"35.083333333333336","dds":0.04275534441805229,"last_synced_commit":"66c395c3ebf4a9ada9a8f08dc6e146ddb0a4548f"},"previous_names":[],"tags_count":77,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/75lb%2Fhandbrake-js","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/75lb%2Fhandbrake-js/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/75lb%2Fhandbrake-js/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/75lb%2Fhandbrake-js/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/75lb","download_url":"https://codeload.github.com/75lb/handbrake-js/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247584110,"owners_count":20962075,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["batch","ffmpeg","handbrake","javascript","nodejs","video","video-encoding"],"created_at":"2024-08-01T02:01:30.653Z","updated_at":"2025-04-07T03:12:14.084Z","avatar_url":"https://github.com/75lb.png","language":"JavaScript","funding_links":[],"categories":["JavaScript","video"],"sub_categories":[],"readme":"[![view on npm](https://badgen.net/npm/v/handbrake-js)](https://www.npmjs.org/package/handbrake-js)\n[![npm module downloads](https://badgen.net/npm/dt/handbrake-js)](https://www.npmjs.org/package/handbrake-js)\n[![Gihub repo dependents](https://badgen.net/github/dependents-repo/75lb/handbrake-js)](https://github.com/75lb/handbrake-js/network/dependents?dependent_type=REPOSITORY)\n[![Gihub package dependents](https://badgen.net/github/dependents-pkg/75lb/handbrake-js)](https://github.com/75lb/handbrake-js/network/dependents?dependent_type=PACKAGE)\n[![Node.js CI](https://github.com/75lb/handbrake-js/actions/workflows/node.js.yml/badge.svg)](https://github.com/75lb/handbrake-js/actions/workflows/node.js.yml)\n[![js-standard-style](https://img.shields.io/badge/code%20style-standard-brightgreen.svg)](https://github.com/feross/standard)\n\n***Upgraders, please read the [release notes](https://github.com/75lb/handbrake-js/releases).***\n\n# handbrake-js\n\nHandbrake-js is [Handbrake](http://handbrake.fr) ([v1.6.1](https://github.com/HandBrake/HandBrake/releases/tag/1.6.1)) for [node.js](http://nodejs.org). It aspires to provide a lean and stable foundation for building video transcoding software in node.js.\n\nHandBrake is a tool for converting video from nearly any format to a selection of modern, widely supported codecs. It can process most common multimedia files and any DVD or BluRay sources that do not contain any copy protection.\n\nOutputs:\n\n* File Containers: .MP4(.M4V) and .MKV\n* Video Encoders: H.264(x264), H.265(x265) MPEG-4 and MPEG-2 (libav), VP8 (libvpx) and Theora(libtheora)\n* Audio Encoders: AAC, CoreAudio AAC/HE-AAC (OS X Only), MP3, Flac, AC3, or Vorbis\n* Audio Pass-thru: AC-3, DTS, DTS-HD, AAC and MP3 tracks\n\n[Read more about the features](https://handbrake.fr/features.php).\n\n### Compatible Platforms\nTested on Mac OSX, Ubuntu 14, Windows XP, Windows 7 and Windows 8.1.\n\n**Ubuntu 14.04 notice**: Transcoding to MP4 fails on Ubuntu since 14.04 [for this reason](https://forum.handbrake.fr/viewtopic.php?f=13\u0026t=30044).\n\n## Installation\n### System Requirements\nJust [node.js](http://nodejs.org). On Mac and Windows, every else is installed automatically. However on Linux, you must install HandbrakeCLI manually with these commands:\n\n```\nsudo add-apt-repository --yes ppa:stebbins/handbrake-releases\nsudo apt-get update -qq\nsudo apt-get install -qq handbrake-cli\n```\n\n### As a library\nMove into your project directory then run:\n```sh\n$ npm install handbrake-js --save\n```\n*Mac / Linux users may need to run with `sudo`*.\n\nNow you can begin encoding from your app.\n\n```js\nconst hbjs = require('handbrake-js')\n\nhbjs.spawn({ input: 'something.avi', output: 'something.m4v' })\n  .on('error', err =\u003e {\n    // invalid user input, no video found etc\n  })\n  .on('progress', progress =\u003e {\n    console.log(\n      'Percent complete: %s, ETA: %s',\n      progress.percentComplete,\n      progress.eta\n    )\n  })\n```\n### As a command-line app\nFrom any directory run the following:\n```sh\n$ npm install -g handbrake-js\n```\n*Mac / Linux users may need to run with `sudo`*.\n\nNow, you can call `handbrake` as you would HandbrakeCLI, using all the usual [options](https://handbrake.fr/docs/en/latest/cli/cli-guide.html). By default, just statistics are output, passing `--verbose` prints the raw HandbrakeCLI output. This command will transcode an AVI to the more universal H.264 (mp4):\n```\n$ handbrake --input 'some episode.avi' --output 'some episode.mp4' --preset Normal\nTask      % done     FPS       Avg FPS   ETA\nEncoding  1.07       131.76    158.12    00h21m11s\n```\n\n## HandbrakeCLI Path\n\nIn some situations or environments (e.g. Docker) you may need to specify a custom HandbrakeCLI path. You can either specify the path in an environment variable:\n\n```sh\nHANDBRAKECLI_PATH=\"./example/HandbrakeCLI\"\n```\n\n..or pass `HandbrakeCLIPath` as an option, programmatically. See the API documentation below for instructions. Also, see the [examples folder](https://github.com/75lb/handbrake-js/tree/master/examples) for example code.\n\n# API Reference\n{{#module name=\"handbrake-js\"}}\n{{\u003ebody~}}\n{{\u003emember-index~}}\n{{\u003eseparator~}}\n{{\u003emembers~}}\n{{/module}}\n\n* * *\n\n\u0026copy; 2013-25 Lloyd Brookes \u0026lt;opensource@75lb.com\u0026gt;.\n\nTested by [test-runner](https://github.com/test-runner-js/test-runner). Documented by [jsdoc-to-markdown](https://github.com/jsdoc2md/jsdoc-to-markdown).\n\nHandbrake ([Authors](https://github.com/HandBrake/HandBrake/blob/master/AUTHORS.markdown)) is licensed by [GNU General Public License Version 2](https://github.com/HandBrake/HandBrake/blob/master/LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F75lb%2Fhandbrake-js","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F75lb%2Fhandbrake-js","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F75lb%2Fhandbrake-js/lists"}