{"id":13681811,"url":"https://github.com/cheeaun/node-hnapi","last_synced_at":"2025-04-30T06:32:20.581Z","repository":{"id":37359298,"uuid":"2678033","full_name":"cheeaun/node-hnapi","owner":"cheeaun","description":"Unofficial Hacker News API","archived":false,"fork":false,"pushed_at":"2024-09-14T05:32:14.000Z","size":494,"stargazers_count":341,"open_issues_count":14,"forks_count":42,"subscribers_count":6,"default_branch":"master","last_synced_at":"2024-09-14T17:32:00.342Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","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/cheeaun.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},"funding":{"github":["cheeaun"],"custom":["https://www.buymeacoffee.com/cheeaun","https://revolut.me/cheeaun","https://donate.stripe.com/9AQeVfbr40ZB9nGaEF","https://paypal.me/cheeaun"]}},"created_at":"2011-10-31T01:17:15.000Z","updated_at":"2024-09-05T15:51:09.000Z","dependencies_parsed_at":"2024-08-02T13:34:07.975Z","dependency_job_id":null,"html_url":"https://github.com/cheeaun/node-hnapi","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cheeaun%2Fnode-hnapi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cheeaun%2Fnode-hnapi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cheeaun%2Fnode-hnapi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cheeaun%2Fnode-hnapi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cheeaun","download_url":"https://codeload.github.com/cheeaun/node-hnapi/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":224201743,"owners_count":17272632,"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":[],"created_at":"2024-08-02T13:01:36.162Z","updated_at":"2024-11-12T01:30:34.037Z","avatar_url":"https://github.com/cheeaun.png","language":"JavaScript","funding_links":["https://github.com/sponsors/cheeaun","https://www.buymeacoffee.com/cheeaun","https://revolut.me/cheeaun","https://donate.stripe.com/9AQeVfbr40ZB9nGaEF","https://paypal.me/cheeaun"],"categories":["JavaScript"],"sub_categories":[],"readme":"Hacker News (unofficial) API\r\n============================\r\n\r\nYet another unofficial API for [Hacker News](http://news.ycombinator.com/). Currently being used by [my other project](https://github.com/cheeaun/hackerweb). Feel free to fork and contribute.\r\n\r\n- API (Cloudflare CDN, faster response time): \u003chttp://api.hackerwebapp.com/\u003e\r\n- API Documentation: \u003chttps://github.com/cheeaun/node-hnapi/wiki/API-Documentation\u003e\r\n\r\n---\r\n\r\n☕️ Buy me a coffee ☕ (server, domain \u0026 maintenance)\r\n--\r\n\r\n[![Donate](https://d1iczxrky3cnb2.cloudfront.net/button-small-blue.png)](https://donorbox.org/support-cheeaun) [![Buy me a coffee](https://www.buymeacoffee.com/assets/img/custom_images/orange_img.png)](https://www.buymeacoffee.com/cheeaun)\r\n\r\n---\r\n\r\n🚧 PLEASE READ THIS 🚧\r\n---\r\n\r\nIf you are planning to scrape a *huge* amount of posts or (historical) data from HN, please **don't use this API**. Use the official [Hacker News API](https://github.com/HackerNews/API) or [HN Search API](http://hn.algolia.com/api) instead.\r\n\r\n---\r\n\r\nQuick Start\r\n----------\r\n\r\n1. `git clone` this repo.\r\n2. `cd` to repo folder.\r\n3. Optionally download, install and start [redis](http://redis.io/download).\r\n4. `npm i`\r\n5. `npm start`\r\n6. Load `localhost:1337` in your web browser.\r\n\r\n\r\nExample\r\n-------------\r\n\r\n\u003e \u003chttp://api.hackerwebapp.com/news?page=2\u003e\r\n\r\nConfiguration\r\n-------------\r\n\r\nHNapi uses [dotenv](https://github.com/motdotla/dotenv) for configuration.\r\n\r\n- `PORT` - (default: `1337`) Server port\r\n- `CACHE_EXP` - (default: `600`) Cache expiry in seconds\r\n- `LOG_REFERER` - (default: `false`) Logs referers\r\n- `LOG_USERAGENT` - (default: `false`) Logs user-agent strings\r\n- `CACHE_MEMORY` - (default: `true`) Use in-memory caching\r\n- `CACHE_STORE` - (`redis`, default: none) Specify the cache store\r\n- `CACHE_SERVER` - `HOST:PORT` for Redis server\r\n\r\nLicense\r\n-------\r\n\r\nLicensed under the [MIT License](http://cheeaun.mit-license.org/).\r\n\r\nOther APIs\r\n----------\r\n\r\n- [The official Hacker News API](https://github.com/HackerNews/API)\r\n- \u003chttp://hn.algolia.com/api\u003e\r\n- \u003chttp://api.ihackernews.com/\u003e\r\n- \u003chttp://hndroidapi.appspot.com/\u003e\r\n- \u003chttp://www.hnsearch.com/api\u003e\r\n- \u003chttps://github.com/Boxyco/hackernews-api\u003e\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcheeaun%2Fnode-hnapi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcheeaun%2Fnode-hnapi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcheeaun%2Fnode-hnapi/lists"}