hackerNews.json•3.6 kB
{
"nodeType": "n8n-nodes-base.hackerNews",
"displayName": "Hacker News",
"description": "Consume Hacker News API",
"version": 1,
"properties": [
{
"name": "resource",
"displayName": "Resource",
"type": "options",
"default": "article",
"options": [
{
"name": "All",
"value": "all"
},
{
"name": "Article",
"value": "article"
},
{
"name": "User",
"value": "user"
}
]
},
{
"name": "operation",
"displayName": "Operation",
"type": "options",
"default": "getAll",
"description": "Get many items",
"options": [
{
"name": "Get Many",
"value": "getAll",
"description": "Get many items"
}
],
"displayOptions": {
"show": {
"resource": [
"all"
]
}
}
},
{
"name": "articleId",
"displayName": "Article ID",
"type": "string",
"default": "",
"description": "The ID of the Hacker News article to be returned",
"required": true,
"displayOptions": {
"show": {
"resource": [
"article"
],
"operation": [
"get"
]
}
}
},
{
"name": "username",
"displayName": "Username",
"type": "string",
"default": "",
"description": "The Hacker News user to be returned",
"required": true,
"displayOptions": {
"show": {
"resource": [
"user"
],
"operation": [
"get"
]
}
}
},
{
"name": "returnAll",
"displayName": "Return All",
"type": "boolean",
"default": false,
"description": "Whether to return all results or only up to a given limit",
"displayOptions": {
"show": {
"resource": [
"all"
],
"operation": [
"getAll"
]
}
}
},
{
"name": "limit",
"displayName": "Limit",
"type": "number",
"default": 100,
"description": "Max number of results to return",
"typeOptions": {
"minValue": 1
},
"displayOptions": {
"show": {
"resource": [
"all"
],
"operation": [
"getAll"
],
"returnAll": [
false
]
}
}
},
{
"name": "additionalFields",
"displayName": "Additional Fields",
"type": "collection",
"default": {},
"description": "Whether to include all the comments in a Hacker News article",
"placeholder": "Add Field",
"options": [
{
"name": "includeComments",
"displayName": "Include Comments",
"type": "boolean",
"default": false,
"description": "Whether to include all the comments in a Hacker News article"
}
],
"displayOptions": {
"show": {
"resource": [
"article"
],
"operation": [
"get"
]
}
}
}
],
"credentialsConfig": [],
"io": {
"inputs": [
"Main"
],
"outputs": [
"Main"
],
"outputNames": [],
"hints": {}
},
"wiring": {
"role": "generic",
"requires": [],
"optional": [],
"consumedBy": [],
"consumes": [
"Main"
],
"produces": [
"Main"
]
}
}