ByteChef LogoByteChef

Hacker News

Hacker News is a social news website focused on computer science, startups and technology-related topics.

Categories: Social Media

Type: hackerNews/v1


Actions

Fetch Top Stories

Name: fetchTopStories

Fetch top stories from Hacker News.

Properties

NameLabelTypeDescriptionRequired
numberOfStoriesNumber Of StoriesINTEGERNumber of stories to fetch.true

Example JSON Structure

{
  "label" : "Fetch Top Stories",
  "name" : "fetchTopStories",
  "parameters" : {
    "numberOfStories" : 1
  },
  "type" : "hackerNews/v1/fetchTopStories"
}

Output

Type: ARRAY

Items Type: OBJECT

Properties

NameTypeDescription
bySTRINGThe username of the item's author.
descendantsINTEGERIn the case of stories or polls, the total comment count.
idINTEGERThe item's unique id.
kidsARRAY
Items [INTEGER]
The ids of the item's comments, in ranked display order.
scoreINTEGERThe story's score, or the votes for a pollopt.
timeINTEGERCreation date of the item, in Unix Time.
titleSTRINGThe title of the story, poll or job. HTML.
typeSTRINGThe type of item.
urlSTRINGThe URL of the story.

Output Example

[ {
  "by" : "",
  "descendants" : 1,
  "id" : 1,
  "kids" : [ 1 ],
  "score" : 1,
  "time" : 1,
  "title" : "",
  "type" : "",
  "url" : ""
} ]

What to do if your action is not listed here?

If this component doesn't have the action you need, you can use Custom Action to create your own. Custom Actions empower you to define HTTP requests tailored to your specific requirements, allowing for greater flexibility in integrating with external services or APIs.

To create a Custom Action, simply specify the desired HTTP method, path, and any necessary parameters. This way, you can extend the functionality of your component beyond the predefined actions, ensuring that you can meet all your integration needs effectively.

How is this guide?

Last updated on

On this page