n8n-nodes-tenable-community
Version:
n8n node for the Tenable One platform
315 lines (314 loc) • 9.56 kB
JavaScript
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.tenableOneFields = exports.tenableOneOperations = void 0;
exports.tenableOneOperations = [
{
displayName: 'Operation',
name: 'operation',
type: 'options',
noDataExpression: true,
displayOptions: {
show: {
resource: [
'exposureView',
],
},
},
options: [
{
name: 'Search Cards',
value: 'searchCards',
description: 'Returns a list of exposure view cards based on your search criteria',
action: 'Search cards',
},
{
name: 'Get Card Details',
value: 'getCardDetails',
description: 'Retrieves details for the specified exposure view card',
action: 'Get card details',
},
],
default: 'searchCards',
},
{
displayName: 'Operation',
name: 'operation',
type: 'options',
noDataExpression: true,
displayOptions: {
show: {
resource: [
'inventory',
],
},
},
options: [
{
name: 'Search Assets',
value: 'searchAssets',
description: 'Returns a list of assets in your organization that match the specified search criteria',
action: 'Search assets',
},
{
name: 'Search Software',
value: 'searchSoftware',
description: 'Returns a list of software installed on your assets that match the specified search criteria',
action: 'Search software',
},
],
default: 'searchAssets',
},
];
exports.tenableOneFields = [
// EXPOSURE VIEW
{
displayName: 'Card ID',
name: 'cardId',
type: 'string',
required: true,
displayOptions: {
show: {
resource: [
'exposureView',
],
operation: [
'getCardDetails',
],
},
},
default: '',
description: 'The unique ID of the card to retrieve details for',
},
{
displayName: 'Additional Fields',
name: 'additionalFields',
type: 'collection',
placeholder: 'Add Field',
default: {},
displayOptions: {
show: {
resource: [
'exposureView',
],
operation: [
'searchCards',
],
},
},
options: [
{
displayName: 'Is Global Card',
name: 'is_global_card',
type: 'boolean',
default: false,
description: 'Whether to return Tenable-provided global cards or user-created custom cards',
},
{
displayName: 'Limit',
name: 'limit',
type: 'number',
typeOptions: {
minValue: 1,
},
default: 50,
description: 'Max number of results to return',
},
{
displayName: 'Offset',
name: 'offset',
type: 'number',
default: 0,
description: 'The starting record to retrieve',
},
{
displayName: 'Sorting Order',
name: 'sorting_order',
type: 'options',
options: [
{
name: 'Ascending',
value: 'asc',
},
{
name: 'Descending',
value: 'desc',
},
],
default: 'asc',
description: 'The order to sort the results by',
},
{
displayName: 'Text Query',
name: 'text_query',
type: 'string',
default: '',
description: 'Filters the results by card name',
},
],
},
{
displayName: 'Additional Fields',
name: 'additionalFields',
type: 'collection',
placeholder: 'Add Field',
default: {},
displayOptions: {
show: {
resource: [
'exposureView',
],
operation: [
'getCardDetails',
],
},
},
options: [
{
displayName: 'Include Trend Events',
name: 'include_trend_events',
type: 'boolean',
default: false,
description: 'Whether to include trend events',
},
{
displayName: 'SLA Breakdown Filter',
name: 'sla_breakdown_filter',
type: 'options',
options: [
{
name: 'Any',
value: 'ANY',
},
{
name: 'Remediated',
value: 'REMEDIATED',
},
{
name: 'Non-Remediated',
value: 'NON_REMEDIATED',
},
],
default: 'ANY',
description: 'Filter SLA breakdown data by `REMEDIATED`, `NON_REMEDIATED`, or `ANY`',
},
{
displayName: 'SLA Efficiency End Date',
name: 'sla_efficiency_end_date',
type: 'string',
default: '',
description: 'The end date for SLA efficiency data in ISO 8601 format, UTC timezone',
},
{
displayName: 'SLA Efficiency Start Date',
name: 'sla_efficiency_start_date',
type: 'string',
default: '',
description: 'The start date for SLA efficiency data in ISO 8601 format, UTC timezone',
},
{
displayName: 'Trend End Date',
name: 'trend_end_date',
type: 'string',
default: '',
description: 'The end date for trend data in ISO 8601 format, UTC timezone',
},
{
displayName: 'Trend Start Date',
name: 'trend_start_date',
type: 'string',
default: '',
description: 'The start date for trend data in ISO 8601 format, UTC timezone',
},
],
},
// INVENTORY
{
displayName: 'Query',
name: 'query',
type: 'json',
required: true,
displayOptions: {
show: {
resource: [
'inventory',
],
operation: [
'searchAssets',
'searchSoftware',
],
},
},
default: '',
description: 'The search mode and query text',
},
{
displayName: 'Filters',
name: 'filters',
type: 'json',
required: true,
displayOptions: {
show: {
resource: [
'inventory',
],
operation: [
'searchAssets',
'searchSoftware',
],
},
},
default: '',
description: 'A set of properties used to filter the search results',
},
{
displayName: 'Additional Fields',
name: 'additionalFields',
type: 'collection',
placeholder: 'Add Field',
default: {},
displayOptions: {
show: {
resource: [
'inventory',
],
operation: [
'searchAssets',
'searchSoftware',
],
},
},
options: [
{
displayName: 'Extra Properties',
name: 'extra_properties',
type: 'string',
default: '',
description: 'Specifies extra properties to include in the search results',
},
{
displayName: 'Offset',
name: 'offset',
type: 'number',
default: 0,
description: 'The starting record to retrieve',
},
{
displayName: 'Limit',
name: 'limit',
type: 'number',
typeOptions: {
minValue: 1,
},
default: 50,
description: 'Max number of results to return',
},
{
displayName: 'Sort',
name: 'sort',
type: 'string',
default: '',
description: 'The property and direction to sort the results by, in the format `property:direction`',
},
],
},
];