{"id":13623773,"url":"https://github.com/bencevans/screenshot-desktop","last_synced_at":"2025-05-14T09:06:41.417Z","repository":{"id":10151756,"uuid":"64657832","full_name":"bencevans/screenshot-desktop","owner":"bencevans","description":"💻 Capture a screenshot of your local machine","archived":false,"fork":false,"pushed_at":"2025-05-05T20:30:08.000Z","size":1539,"stargazers_count":463,"open_issues_count":23,"forks_count":96,"subscribers_count":10,"default_branch":"main","last_synced_at":"2025-05-14T09:05:30.143Z","etag":null,"topics":["hacktoberfest","linux","osx","screenshot","windows"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/screenshot-desktop","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/bencevans.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null},"funding":{"github":"bencevans","custom":"https://buymeacoffee.com/bencevans"}},"created_at":"2016-08-01T10:22:27.000Z","updated_at":"2025-05-13T17:02:13.000Z","dependencies_parsed_at":"2023-02-19T07:00:35.808Z","dependency_job_id":"85f6883a-555d-414f-9153-ae2e9d0c7988","html_url":"https://github.com/bencevans/screenshot-desktop","commit_stats":{"total_commits":261,"total_committers":26,"mean_commits":"10.038461538461538","dds":0.6704980842911877,"last_synced_commit":"744c174d895ee26d6575c66f91e62e050e7da131"},"previous_names":[],"tags_count":34,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bencevans%2Fscreenshot-desktop","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bencevans%2Fscreenshot-desktop/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bencevans%2Fscreenshot-desktop/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bencevans%2Fscreenshot-desktop/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bencevans","download_url":"https://codeload.github.com/bencevans/screenshot-desktop/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254110374,"owners_count":22016391,"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":["hacktoberfest","linux","osx","screenshot","windows"],"created_at":"2024-08-01T21:01:35.476Z","updated_at":"2025-05-14T09:06:41.370Z","avatar_url":"https://github.com/bencevans.png","language":"JavaScript","funding_links":["https://github.com/sponsors/bencevans","https://buymeacoffee.com/bencevans"],"categories":["hacktoberfest","windows"],"sub_categories":[],"readme":"# screenshot-desktop\n\n\u003e Capture a screenshot of your local machine\n\n* Multi/Cross Platform\n  * Linux: required ImageMagick `apt-get install imagemagick`\n  * OSX: No dependencies required!\n  * Windows: No dependencies required!\n* Promise based API\n* JPG output (by default)\n\n## Install\n\n    $ npm install --save screenshot-desktop\n\n## Usage\n\n```js\nconst screenshot = require('screenshot-desktop')\n\nscreenshot().then((img) =\u003e {\n  // img: Buffer filled with jpg goodness\n  // ...\n}).catch((err) =\u003e {\n  // ...\n})\n```\n\n```js\nconst screenshot = require('screenshot-desktop')\n\nscreenshot({format: 'png'}).then((img) =\u003e {\n  // img: Buffer filled with png goodness\n  // ...\n}).catch((err) =\u003e {\n  // ...\n})\n```\n\n```js\nscreenshot.listDisplays().then((displays) =\u003e {\n  // displays: [{ id, name }, { id, name }]\n  screenshot({ screen: displays[displays.length - 1].id })\n    .then((img) =\u003e {\n      // img: Buffer of screenshot of the last display\n    });\n})\n```\n\n```js\nscreenshot.all().then((imgs) =\u003e {\n  // imgs: an array of Buffers, one for each screen\n})\n```\n\n```js\nscreenshot({ filename: 'shot.jpg' }).then((imgPath) =\u003e {\n  // imgPath: absolute path to screenshot\n  // created in current working directory named shot.png\n});\n\n// absolute paths work too. so do pngs\nscreenshot({ filename: '/Users/brian/Desktop/demo.png' })\n```\n\n## screenshot() options\n\n- `filename` Optional. Absolute or relative path to save output.\n- `format` Optional. Valid values `png|jpg`. \n- `linuxLibrary` Optional. Linux only. Valid values `scrot|imagemagick`. Which library to use. Note that scrot does not support format or screen selection.\n\n## Licence\n\nMIT \u0026copy; [Ben Evans](https://bencevans.io)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbencevans%2Fscreenshot-desktop","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbencevans%2Fscreenshot-desktop","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbencevans%2Fscreenshot-desktop/lists"}