{"_id":"@arindam1729/devtoblog","_rev":"1-d68ede2bcd26923d0a1d649229706a25","name":"@arindam1729/devtoblog","dist-tags":{"latest":"1.0.1"},"versions":{"1.0.0":{"name":"@arindam1729/devtoblog","version":"1.0.0","description":"Package to publish Blogs to Dev.to","main":"index.js","scripts":{"start":"node index.js"},"author":{"name":"Arindam Majumder"},"license":"MIT","dependencies":{"axios":"^1.6.8"},"keywords":["devtoblog","dev.to","dev","devto","blog","dev.to api","dev.to article","dev.to-article","dev.to-blog","blog article","blog post","blog api","blog article api","blog post api","dev.to blog api","dev.to blog article","recent articles","article api"],"_id":"@arindam1729/devtoblog@1.0.0","gitHead":"0b1f189d1c82e049815b3f79b57f33640f9230fa","_nodeVersion":"20.11.1","_npmVersion":"10.2.4","dist":{"integrity":"sha512-uV2YNzmdH0h+iogzK4H3yJJsxJ3QH3ignZZtVjk3S8vV/job/gF9BdhdZf9/wlxlSGK/3iScnp1JQMXY3LGURg==","shasum":"bb04a5bda006a8fbe6789ed619a81be163640e74","tarball":"https://registry.npmjs.org/@arindam1729/devtoblog/-/devtoblog-1.0.0.tgz","fileCount":3,"unpackedSize":3874,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHE9K7hRGI5kZyDvKoI7c1E4RGgyFimjy3967oduNfV9AiEAmfgWO3NNZeUFJd4R5YtnNupyvx4qLGDGmiVgbR5mYFM="}]},"_npmUser":{"name":"arindam1729","email":"arindammajumder2020@gmail.com"},"directories":{},"maintainers":[{"name":"arindam1729","email":"arindammajumder2020@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/devtoblog_1.0.0_1714916656461_0.6563093563679396"},"_hasShrinkwrap":false},"1.0.1":{"name":"@arindam1729/devtoblog","version":"1.0.1","description":"Package to publish Blogs to Dev.to","main":"index.js","scripts":{"start":"node index.js"},"author":{"name":"Arindam Majumder"},"license":"MIT","dependencies":{"axios":"^1.6.8"},"repository":{"type":"git","url":"git+https://github.com/Arindam200/devtoblog.git"},"keywords":["devtoblog","dev.to","dev","devto","blog","dev.to api","dev.to article","dev.to-article","dev.to-blog","blog article","blog post","blog api","blog article api","blog post api","dev.to blog api","dev.to blog article","recent articles","article api"],"_id":"@arindam1729/devtoblog@1.0.1","gitHead":"0b1f189d1c82e049815b3f79b57f33640f9230fa","bugs":{"url":"https://github.com/Arindam200/devtoblog/issues"},"homepage":"https://github.com/Arindam200/devtoblog#readme","_nodeVersion":"20.11.1","_npmVersion":"10.2.4","dist":{"integrity":"sha512-jmFDrsFF0a0qr3eSnGKGVWfaHJ4sEX5EapX18X8x2vEJGgzFYgQQwcfFTnkwCz3PnjcQnTrJt0y9skuE9nwUoA==","shasum":"1e9a4e246ea492bb48102cc401a8dba831bf9dfc","tarball":"https://registry.npmjs.org/@arindam1729/devtoblog/-/devtoblog-1.0.1.tgz","fileCount":3,"unpackedSize":3991,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIBJTCBrxVneAeX7yV2XNKCi/kn08pDQldx2bw3mEtJrlAiEAoH+mM5j1lriTXlZ2UN1rk/NKott9kndBXmUPnCVI9Hg="}]},"_npmUser":{"name":"arindam1729","email":"arindammajumder2020@gmail.com"},"directories":{},"maintainers":[{"name":"arindam1729","email":"arindammajumder2020@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/devtoblog_1.0.1_1714917012323_0.12231462209919752"},"_hasShrinkwrap":false}},"time":{"created":"2024-05-05T13:44:16.366Z","1.0.0":"2024-05-05T13:44:16.618Z","modified":"2024-05-05T13:50:12.658Z","1.0.1":"2024-05-05T13:50:12.473Z"},"maintainers":[{"name":"arindam1729","email":"arindammajumder2020@gmail.com"}],"description":"Package to publish Blogs to Dev.to","keywords":["devtoblog","dev.to","dev","devto","blog","dev.to api","dev.to article","dev.to-article","dev.to-blog","blog article","blog post","blog api","blog article api","blog post api","dev.to blog api","dev.to blog article","recent articles","article api"],"author":{"name":"Arindam Majumder"},"license":"MIT","readme":"# @arindam1729/devtoblog\r\n\r\nA Node.js package for interacting with the dev.to API to retrieve and post blog articles.\r\n\r\n## Installation\r\n\r\n```bash\r\nnpm install @arindam1729/devtoblog\r\n```\r\n\r\n## Usage\r\n\r\n```javascript\r\nconst { getBlog, postBlog } = require('@arindam1729/devtoblog');\r\n\r\n// Retrieve a list of published blog articles\r\nconst apiKey = 'YOUR_API_KEY';\r\ngetBlog(apiKey)\r\n  .then((articles) => {\r\n    console.log(articles);\r\n  })\r\n  .catch((error) => {\r\n    console.error(error);\r\n  });\r\n\r\n// Post a blog article\r\n\r\n  const article: {\r\n    body_markdown: \"###  content for the body markdown. It can contain various details, sections, and formatting like headers, lists, and more.\",\r\n    description: \"A brief overviecontent and its purpose\",\r\n    published: true,\r\n    title: \"Publishing Article on DevTo | by Arindam\",\r\n    canonical_url: \"https://arindam1729.hashnode.dev\",\r\n    tags: [\"DevTo\", \"Arindam\", \"Test\",\"Blog\"]\r\n  }\r\n\r\npostBlog(article, apiKey)\r\n  .then((response) => {\r\n    console.log(response);\r\n  })\r\n  .catch((error) => {\r\n    console.error(error);\r\n  });\r\n```\r\n\r\n## API\r\n\r\n### `getBlog(apiKey: string): Promise<Array>`\r\n\r\nRetrieves a list of published blog articles from the dev.to API.\r\n\r\n- `apiKey` - The API key required to access the dev.to API.\r\n\r\nReturns a promise that resolves to an array of blog articles.\r\n\r\n### `postBlog(article: Object, apiKey: string): Promise<Object>`\r\n\r\nPosts a blog article to the dev.to API.\r\n\r\n- `article` - The article object to be posted.\r\n- `apiKey` - The API key required to access the dev.to API.\r\n\r\nReturns a promise that resolves to the response data from the API.\r\n\r\n## License\r\n\r\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.","readmeFilename":"README.md","homepage":"https://github.com/Arindam200/devtoblog#readme","repository":{"type":"git","url":"git+https://github.com/Arindam200/devtoblog.git"},"bugs":{"url":"https://github.com/Arindam200/devtoblog/issues"}}