{"_id":"@apicomponents/get-notebook","_rev":"1-ceea20580447894c025ccdf5c0abe9e2","name":"@apicomponents/get-notebook","dist-tags":{"latest":"1.0.0"},"versions":{"1.0.0":{"name":"@apicomponents/get-notebook","version":"1.0.0","description":"Download an Observable notebook","main":"download-notebook.js","bin":{"get-notebook":"./get-notebook.js"},"scripts":{},"keywords":["observable","literate-programming"],"author":{"name":"Benjamin Atkin","email":"ben@benatkin.com","url":"https://github.com/benatkin"},"repository":{"type":"git","url":"git+https://github.com/apicomponents/notebook-scripts.git"},"bugs":{"url":"https://github.com/apicomponents/notebook-scripts/issues"},"homepage":"https://github.com/apicomponents/notebook-scripts#readme","_id":"@apicomponents/get-notebook@1.0.0","_npmVersion":"6.1.0","_nodeVersion":"8.11.3","_npmUser":{"name":"bat","email":"ben@benatkin.com"},"dist":{"integrity":"sha512-+tqtXRS6W0ym5/msngOFXNAiUkDHSppnPTRxGREmdljnZaxckKXnakVXrZ02mG9LytX0eqet9K0jnBlXEkWEtg==","shasum":"91b7768a8e8ea4acdd4fe83782cc3c21cb24a06e","tarball":"https://registry.npmjs.org/@apicomponents/get-notebook/-/get-notebook-1.0.0.tgz","fileCount":3,"unpackedSize":2678,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbVTKBCRA9TVsSAnZWagAAuK4P/i5ga+JE/JG6LKzCnn3E\nJDtkz6xuio/08kFoS0A4sx+2+n3+TcwcV5Tfw1ZsD8XZdONHtNpLBsIiQT+N\nvVqw8r/Kr8HkOiiDId3RFRbLSzMPG+K+bwvZa0V+UnExayZWGSktI+KYBf60\nu5o7iLZyV9VAmCRcBCtbYLdYWt9Gt+s+sq/A/7Ph0mEYHPSPDfhylvKnl7Lm\nF3gZxYE0xOEN56FEkXTGBiXzwQG5+wuLUjwL5KASItbKvvXhhuw/SmwsXTzf\nBWSX6ONVlOY1FgeFwApf5qWdInGquuYfSwBM6aL/ap34IfuIsxtJE9q2zth3\nfkwBsgCfYRpqtI8PGijFFmDTP6oN4mvoKLUjxKbXIw/O79g4W0lXKGpWXuEh\npVElhez6Hph5qDCv3DAl3yUzVLb7zHdwgjKZDKMr+V6tvZR3HiqVUZ9GaoeA\nk29F8n7L00zo55nsg25LsVxmLUxjUefu9tN47OLPkuNPRFObXMuTteY4zxnm\n0DYWcqTYOKUAW+kFAQ6K0tzyfu82GpnWF6sapTEFktmpOM4zD2C828gLK2Iz\nGS6VbNKIUPmzid7hgQ7TtDp0/HAC6Q48G904G92YcvKmz7sKdTxNbPmHKll6\noGfKgyd2Reh96eVq7d9NosKOISH1XY+78+XFIuWpovrgFlLQt2WbbFehldIL\nzHfN\r\n=cst4\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQCUU94C2DmP7xLDzTaV0kuBHwve+Tryp96OqjpyMAIJzAIgR11EC6Y7j+Af1rBY5gRzfcf3NIdewbmZ/bxN09PfyMk="}]},"maintainers":[{"name":"bat","email":"ben@benatkin.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/get-notebook_1.0.0_1532310145560_0.09203386031919658"},"_hasShrinkwrap":false}},"time":{"created":"2018-07-23T01:42:25.511Z","1.0.0":"2018-07-23T01:42:25.648Z","modified":"2022-04-04T14:35:01.021Z"},"maintainers":[{"name":"bat","email":"ben@benatkin.com"}],"description":"Download an Observable notebook","homepage":"https://github.com/apicomponents/notebook-scripts#readme","keywords":["observable","literate-programming"],"repository":{"type":"git","url":"git+https://github.com/apicomponents/notebook-scripts.git"},"author":{"name":"Benjamin Atkin","email":"ben@benatkin.com","url":"https://github.com/benatkin"},"bugs":{"url":"https://github.com/apicomponents/notebook-scripts/issues"},"readme":"## Get a notebook\n\nThis downloads a notebook to `notebook.js`. It's recommended to commit the notebook source to the repository, so it can be checked against the notebook on observablehq.com in case it changes.\n\n### Usage\n\nTo install:\n\n```\nnpm install @apicomponents/get-notebook --save-dev\n```\n\nTo configure, add the `notebook-scripts` custom property to `package.json` and a script to download the notebook. The notebook URL will be converted to an API URL by changing `beta.observablehq.com` to `api.observablehq.com` and appending `.js` to it.\n\n```\n  \"notebookScripts\": {\n    \"notebook\": \"https://beta.observablehq.com/@benatkin/building-an-npm-module-with-observable\"\n  },\n  \"scripts\": {\n    \"get-notebook\": \"get-notebook\"\n  }\n```\n\nTo run the script, first set `OBSERVABLE_API_KEY` to the key in the URL for downloading a notebook (found at the end of the URL obtained by clicking *Download code* from the dot menu next to the *Publish* button at the top of the notebook), and then run the npm script:\n\n```\nexport OBSERVABLE_API_KEY=YOUR_KEY\nnpm run get-notebook\n```","readmeFilename":"README.md"}