@datafire/hacker_news
v5.0.0
Published
DataFire integration for Hacker News
Downloads
9
Readme
@datafire/hacker_news
Client library for Hacker News
Installation and Usage
npm install --save @datafire/hacker_news
let hacker_news = require('@datafire/hacker_news').create();
.then(data => {
console.log(data);
});
Description
Hacker News is a social news website focusing on computer science and entrepreneurship
Actions
getStories
Get an up-to-date list of stories for the given type
hacker_news.getStories({}, context)
Input
- input
object
- storyType
string
(values: top, new, job, show, ask): The type of stories to retrieve
- storyType
Output
- output
array
- items
integer
- items
getItem
Get details for a given item
hacker_news.getItem({
"itemID": 0
}, context)
Input
- input
object
- itemID required
integer
: The ID of the item to retrieve
- itemID required
Output
- output Item
getUser
Get details for a given user
hacker_news.getUser({
"username": ""
}, context)
Input
- input
object
- username required
string
: The unique username for this user
- username required
Output
- output User
Definitions
Item
- Item
object
- id
integer
- title
string
- deleted
boolean
- by
string
- time
string
- text
string
- dead
boolean
- parent
integer
- kids
array
- items
integer
- items
- url
string
- score
integer
- parts
array
- items
integer
- items
- descendants
array
- items
integer
- items
- id
User
- User
object
- id
string
- created
integer
- delay
integer
- karma
integer
- about
string
- submitted
array
- items
integer
- items
- id