2022-08-17 08:50:24 -07:00
import { INodeProperties } from 'n8n-workflow' ;
2020-04-05 18:06:23 -07:00
2021-12-03 00:44:16 -08:00
export const logEntryOperations : INodeProperties [ ] = [
2020-04-05 18:06:23 -07:00
{
displayName : 'Operation' ,
name : 'operation' ,
type : 'options' ,
2022-05-20 14:47:24 -07:00
noDataExpression : true ,
2020-04-05 18:06:23 -07:00
displayOptions : {
show : {
2022-08-17 08:50:24 -07:00
resource : [ 'logEntry' ] ,
2020-04-05 18:06:23 -07:00
} ,
} ,
options : [
{
name : 'Get' ,
value : 'get' ,
description : 'Get a log entry' ,
2022-07-10 13:50:51 -07:00
action : 'Get a log entry' ,
2020-04-05 18:06:23 -07:00
} ,
{
2022-09-07 07:51:14 -07:00
name : 'Get Many' ,
2020-04-05 18:06:23 -07:00
value : 'getAll' ,
description : 'Get all log entries' ,
2022-09-08 08:10:13 -07:00
action : 'Get many log entries' ,
2020-04-05 18:06:23 -07:00
} ,
] ,
default : 'get' ,
} ,
2021-12-03 00:44:16 -08:00
] ;
2020-04-05 18:06:23 -07:00
2021-12-03 00:44:16 -08:00
export const logEntryFields : INodeProperties [ ] = [
2022-08-17 08:50:24 -07:00
/* -------------------------------------------------------------------------- */
/* logEntry:get */
/* -------------------------------------------------------------------------- */
2020-04-05 18:06:23 -07:00
{
displayName : 'Log Entry ID' ,
name : 'logEntryId' ,
type : 'string' ,
required : true ,
default : '' ,
displayOptions : {
show : {
2022-08-17 08:50:24 -07:00
resource : [ 'logEntry' ] ,
operation : [ 'get' ] ,
2020-04-05 18:06:23 -07:00
} ,
} ,
2022-05-06 14:01:25 -07:00
description : 'Unique identifier for the log entry' ,
2020-04-05 18:06:23 -07:00
} ,
2022-08-17 08:50:24 -07:00
/* -------------------------------------------------------------------------- */
/* logEntry:getAll */
/* -------------------------------------------------------------------------- */
2020-04-05 18:06:23 -07:00
{
displayName : 'Return All' ,
name : 'returnAll' ,
type : 'boolean' ,
displayOptions : {
show : {
2022-08-17 08:50:24 -07:00
operation : [ 'getAll' ] ,
resource : [ 'logEntry' ] ,
2020-04-05 18:06:23 -07:00
} ,
} ,
default : false ,
2022-05-06 14:01:25 -07:00
description : 'Whether to return all results or only up to a given limit' ,
2020-04-05 18:06:23 -07:00
} ,
{
displayName : 'Limit' ,
name : 'limit' ,
type : 'number' ,
displayOptions : {
show : {
2022-08-17 08:50:24 -07:00
operation : [ 'getAll' ] ,
resource : [ 'logEntry' ] ,
returnAll : [ false ] ,
2020-04-05 18:06:23 -07:00
} ,
} ,
typeOptions : {
minValue : 1 ,
maxValue : 500 ,
} ,
default : 100 ,
2022-05-06 14:01:25 -07:00
description : 'Max number of results to return' ,
2020-04-05 18:06:23 -07:00
} ,
{
displayName : 'Options' ,
name : 'options' ,
type : 'collection' ,
placeholder : 'Add Field' ,
default : { } ,
displayOptions : {
show : {
2022-08-17 08:50:24 -07:00
resource : [ 'logEntry' ] ,
operation : [ 'getAll' ] ,
2020-04-05 18:06:23 -07:00
} ,
} ,
options : [
{
displayName : 'Include' ,
name : 'include' ,
type : 'multiOptions' ,
options : [
{
name : 'Channels' ,
value : 'channels' ,
} ,
{
name : 'Incidents' ,
value : 'incidents' ,
} ,
{
name : 'Services' ,
value : 'services' ,
} ,
{
name : 'Teams' ,
value : 'teams' ,
} ,
] ,
default : [ ] ,
2022-05-06 14:01:25 -07:00
description : 'Additional details to include' ,
2020-04-05 18:06:23 -07:00
} ,
{
displayName : 'Is Overview' ,
name : 'isOverview' ,
type : 'boolean' ,
default : false ,
2022-08-17 08:50:24 -07:00
description :
'Whether to return a subset of log entries that show only the most important changes to the incident' ,
2020-04-05 18:06:23 -07:00
} ,
{
displayName : 'Since' ,
name : 'since' ,
type : 'dateTime' ,
default : '' ,
2022-08-17 08:50:24 -07:00
description :
'The start of the date range over which you want to search. (the limit on date ranges is 6 months).' ,
2020-04-05 18:06:23 -07:00
} ,
{
2022-06-03 10:23:49 -07:00
displayName : 'Timezone Name or ID' ,
2020-04-05 18:06:23 -07:00
name : 'timeZone' ,
type : 'options' ,
typeOptions : {
loadOptionsMethod : 'getTimezones' ,
} ,
default : '' ,
2022-08-17 08:50:24 -07:00
description :
'Time zone in which dates in the result will be rendered. If not set dates will return UTC. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code-examples/expressions/">expression</a>.' ,
2020-04-05 18:06:23 -07:00
} ,
{
displayName : 'Until' ,
name : 'until' ,
type : 'dateTime' ,
default : '' ,
2022-08-17 08:50:24 -07:00
description :
'The end of the date range over which you want to search. (the limit on date ranges is 6 months).' ,
2020-04-05 18:06:23 -07:00
} ,
] ,
} ,
2021-12-03 00:44:16 -08:00
] ;