Hacker News API Wrapper
Installation
pip install hackernews-python
Usage
>>> from hackernews import HackerNews
>>> hn = HackerNews()
>>> hn.top_stories()
[8422599, 8422087, 8422928, 8422581, 8423825...
>>> hn.item(1).title
'Y Combinator'
>>> hn.item(1).time
datetime.datetime(2006, 10, 9, 11, 21, 51)
>>> hn.user('pg').created
datetime.datetime(2006, 10, 9, 11, 21, 32)
>>> hn.user('pg').karma
155040
>>> hn.max_item()
8424314
>>> hn.updates()
{'items': [8423690, 8424315, 8424299...], 'profiles': ['exampleuser',...]}
API Documentation
Release History
0.3.1 (2014-10-12)
Fix README examples
0.3.0 (2014-10-12)
Returns Item and User objects instead of dicts.
0.2.0 (2014-10-10)
Convert timestamps to native datetime objects (breaking change)
Added tests.py (100% line coverage)
Add link to official API docs to README.rst
0.1.1 (2014-10-09)
Improve syntax highlighting in README.rst
0.1.0 (2014-10-07)
1st release
Metadata
Release files for hackernews-python 0.3.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| hackernews-python-0.3.2.tar.gz | 3.3 kB | Without provenance | Details |
Release files / hackernews-python-0.3.2.tar.gz
| Download URL | hackernews-python-0.3.2.tar.gz |
|---|---|
| Size | 3.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
28863e2623ad63aae3d6c69f67d39a9906205b681918bea4a83a0b1a4795374c
|
|
BLAKE2b-256 checksum How to use checksums |
1ddf007d8726e829d54f0f1ee7f843389d3872d20be717b163a06d373b91a26f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for hackernews-python 0.3.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.