Quick StartThe ReportMagic MenuSchedulesBatch JobsReport StudioFilesProfileAdminAccount DetailsMeraki WebHooksGetting StartedAbout ReportMagicRegistering and Logging InSearching ReportMagicConnections and AgentsWriting ReportsStarting Out With Report StudioCreating Report TemplatesRMScriptMacro ShorthandReporting on Different Periods of TimeSetting Macro Parameter DefaultsStoring Input and Output FilesReport VariablesUsing Variable ParametersSpecifying How Graphs LookStep-by-Step LogicMonitor Graph ExamplesStep-by-Step Jira Graph ExamplesSpecifying How Tables LookChanging Fonts and ColorsUsing Macros in PowerPoint TemplatesRestricted MacrosGenerating Reports Using SchedulesUsing HTML Forms in SchedulesSeeing How Reports RanViewing ReportsCached ValuesUsing AggregationsAdvanced Report StudioAPI AccessREST APIREST API - FilesAdvancedRole-Based Access Control (RBAC)SecurityMiscellaneousBadgesCertificationsTips, Tricks and Shortcut KeysMacrosAgentAgent.ConnectionAgent.ExecuteAgent.MonitorMagicNodeListAgent.MonitorMagicNodeMeasurementListAgent.MonitorMagicNodeMeasurementSummaryAgent.MonitorMagicNodePropertyListAgent.MonitorMagicNodeTypeListAgent.PropertyAgent.SqlAnalysisAgent.SqlGraphAgent.SqlListAgent.SqlTableAgent.SqlValueAgent.SqlValuesAgent.WebQueryAlertMagicAlertMagic.MetricsGraphAlertMagic.MetricsListAutoTaskAutoTask.AccountListAutoTask.AccountPropertyAutoTask.ConnectionAutoTask.CountAutoTask.FieldListAutoTask.FieldPropertyAutoTask.ListAutoTask.PropertyAutoTask.SummaryValueAutoTask.TicketListAutoTask.TicketPropertyAzureAzure.ConnectionAzure.LogAnalyticsGraphAzure.LogAnalyticsQueryAzure.LogAnalyticsScalarAzure.LogAnalyticsTableAzure.ResourceGroupListAzure.ResourceListAzure.ResourcePropertiesAzure.SentinelAlertRuleListAzure.SentinelConnectorListAzure.SentinelIncidentListAzure.SentinelThreatIndicatorListAzure.SentinelThreatIndicatorMetricListAzure.SubscriptionListBloggerBlogger.BlogPropertyBlogger.ConnectionBlogger.PageBlogger.PageListBlogger.PagePropertyBlogger.PostBlogger.PostListBlogger.PostPropertyCacheCache.ExpiresCache.GetCache.IsSetCache.SetCache.UnsetCertifyCertify.ConnectionCertify.DepartmentListCertify.DepartmentPropertyCherwellCherwell.BusinessObjectDefinitionListCherwell.BusinessObjectListCherwell.BusinessObjectSchemaCherwell.BusinessObjectSummaryCherwell.ConnectionCiscoCisco.ConnectionCisco.FirmwareVersionPropertyCisco.SecurityAdvisoryListCisco.SerialNumberPropertyCisco.SoftwareSuggestionListCiscoDnaCenterCiscoDnaCenter.ConnectionCiscoDnaCenter.SiteListCiscoDnaCenter.SitePropertyCloudHealthCloudHealth.AssetDetailsCloudHealth.AssetListCloudHealth.AvailableReportDimensionsCloudHealth.AvailableReportOptionsCloudHealth.AvailableReportsListCloudHealth.AwsAccountDetailsCloudHealth.AwsAccountsListCloudHealth.ConnectionCloudHealth.CustomerDetailsCloudHealth.CustomerListCloudHealth.CustomerReportDetailsCloudHealth.CustomerStatementDetailsCloudHealth.OrganisationAccountsListCloudHealth.OrganisationListCloudHealth.QueryConnectWiseManageConnectWiseManage.ConnectionConnectWiseManage.CountConnectWiseManage.DictionaryConnectWiseManage.ListConnectWiseManage.PropertyCoreArrayArray.CountBreakBreakpointCalculateColorCommentContinueConvertDeleteDeleteRowDocumentBookmarkDocumentBreakDocumentInsertSectionDocumentSectionEmailEmailFileEmailReportExecuteForEachFormatTableCellFormatTableRowIfIgnoreIncInsertTableCellImageIsSetLinearRegressionLinkMapObjectRandomRegexRepeatRowSearchAndReplaceSectionSettingsSleepStopStopwatchStringStringIndexSubstringSwitchThrowExceptionUnsetWarningDatabaseDatabase.ConnectionDatabase.GraphDatabase.ListDatabase.TableDatabase.ValueDatabase.ValuesDataMagicDataMagic.SyncDictionaryDictionary.ItemDictionary.KeysDictionary.ValuesDocumentDocument.SetPropertiesFileFile.CopyFile.CopyOutputFilesFile.Csv.CellFile.Csv.RowFile.Csv.RowCountFile.Csv.TableFile.EmbedFile.ExecuteFile.ExistsFile.ImageFile.InsertFile.ListFile.LoadListFile.LoadObjectFile.LoadStringFile.LoadVariablesFile.Xlsx.CellFile.Xlsx.RowFile.Xlsx.RowCountFile.Xlsx.TableFunctionFunction.CallFunction.DefineGoogleGoogle.ConnectionGoogle.TableGraphGraph.AddDataGraph.DeleteDataGraph.RenameDataGraph.UpdateGravatarGravatar.ImageHighlightHighlight.BearerSummaryHighlight.BroadbandSummaryHighlight.CellularSummaryHighlight.ConnectionHighlight.FolderListHighlight.HttpServerPerformanceSummaryHighlight.IcmpTcpUdpPerformanceSummaryHighlight.MosPerformanceSummaryHighlight.PrecisionPerformanceSummaryHighlight.TunnelSummaryHighlight.WatchNodeListHighlight.WirelessAccessPointSummaryHubSpotHubSpot.ListJarrayJarray.TableJiraJira.AttachmentImageJira.AttachmentListJira.AttachmentPropertyJira.ConnectionJira.GraphJira.InsertMarkupJira.IssueAnalysisJira.IssueCommentListJira.IssueCommentPropertyJira.IssueLastCommentPropertyJira.IssueListJira.IssuePropertyJira.IssueResponseTimeJira.LastImageJira.StatusListJira.TableJira.TimeInStateJira.UserListJira.UserPropertyJsonJson.ItemJson.ListKrokiKroki.ImageListList.AddList.AnalysisList.ComplementList.CountList.DequeueList.DuplicatesList.FirstList.GraphList.GroupByList.IndicesOfList.IntersectionList.ItemList.RangeList.SelectList.SelectColumnsList.SortList.SummaryValueList.TableList.UnionList.WhereLogicMonitorLogicMonitor.AccountPropertyLogicMonitor.AlertAnalysisLogicMonitor.AlertCalendarLogicMonitor.AlertCountLogicMonitor.AlertListLogicMonitor.AlertMapLogicMonitor.AlertPropertyLogicMonitor.AlertRuleListLogicMonitor.AlertRulePropertyLogicMonitor.AlertStatusLogicMonitor.AlertTableLogicMonitor.AppliesToFunctionListLogicMonitor.AppliesToFunctionPropertyLogicMonitor.AppliesToListLogicMonitor.AuditEventAnalysisLogicMonitor.BigNumberWidgetValuesLogicMonitor.ClearCacheLogicMonitor.CollectorExecuteLogicMonitor.CollectorGroupListLogicMonitor.CollectorGroupPropertyLogicMonitor.CollectorListLogicMonitor.CollectorPropertyLogicMonitor.CollectorVersionListLogicMonitor.CollectorVersionPropertyLogicMonitor.ConfigCheckListLogicMonitor.ConfigCheckPropertyLogicMonitor.ConfigSourceGroupListLogicMonitor.ConfigSourceListLogicMonitor.ConfigSourcePropertyLogicMonitor.ConfigSourceXmlLogicMonitor.ConnectionLogicMonitor.ConnectionApiTokenLogicMonitor.ConvertToLiveWidgetLogicMonitor.DashboardLogicMonitor.DashboardGroupListLogicMonitor.DashboardGroupPropertyLogicMonitor.DashboardListLogicMonitor.DashboardPropertyLogicMonitor.DashboardWidgetListLogicMonitor.DatamartSyncLogicMonitor.DataPointListLogicMonitor.DataPointPropertyLogicMonitor.DataSourceGraphListLogicMonitor.DataSourceGraphPropertyLogicMonitor.DataSourceGroupListLogicMonitor.DataSourceListLogicMonitor.DataSourcePropertyLogicMonitor.DataSourceXmlLogicMonitor.DeviceConfigSourceFileLogicMonitor.DeviceConfigSourceInstanceListLogicMonitor.DeviceConfigSourceListLogicMonitor.DeviceConfigSourcePropertyLogicMonitor.DeviceCountLogicMonitor.DeviceDataSourceListLogicMonitor.DeviceDataSourcePropertyLogicMonitor.DeviceGroupListLogicMonitor.DeviceGroupPropertyLogicMonitor.DeviceListLogicMonitor.DevicePropertyLogicMonitor.DeviceSlaWidgetPropertyLogicMonitor.DeviceTableLogicMonitor.EscalationChainDestinationListLogicMonitor.EscalationChainDestinationPropertyLogicMonitor.EscalationChainListLogicMonitor.EscalationChainPropertyLogicMonitor.EventSourceFilterListLogicMonitor.EventSourceFilterPropertyLogicMonitor.EventSourceGroupListLogicMonitor.EventSourceListLogicMonitor.EventSourcePropertyLogicMonitor.EventSourceXmlLogicMonitor.FinancialInformationLogicMonitor.ForecastLogicMonitor.GraphLogicMonitor.HistoricSdtListLogicMonitor.ImageLogicMonitor.InstanceAnalysisLogicMonitor.InstanceCountLogicMonitor.InstanceDetailsTableLogicMonitor.InstanceGroupCountLogicMonitor.InstanceGroupListLogicMonitor.InstanceListLogicMonitor.InstancePropertyLogicMonitor.IntegrationListLogicMonitor.IntegrationPropertyLogicMonitor.JobMonitorListLogicMonitor.JobMonitorPropertyLogicMonitor.LastMeasurementLogicMonitor.LogAnalysisLogicMonitor.LogicModuleMetadataPropertyLogicMonitor.LogicModuleUpdateListLogicMonitor.LogicModuleUpdatePropertyLogicMonitor.LogItemListLogicMonitor.NetscanGroupListLogicMonitor.NetscanGroupPropertyLogicMonitor.NetscanListLogicMonitor.NetscanPropertyLogicMonitor.NewUserMessagePropertyLogicMonitor.PaymentInformationLogicMonitor.PercentageAvailabilityLogicMonitor.PortalVersionLogicMonitor.PropertySourceGroupListLogicMonitor.PropertySourceJsonLogicMonitor.PropertySourceListLogicMonitor.PropertySourcePropertyLogicMonitor.QueryLogicMonitor.RecipientGroupListLogicMonitor.RecipientGroupPropertyLogicMonitor.RecycleBinItemListLogicMonitor.RecycleBinItemPropertyLogicMonitor.ReportGroupListLogicMonitor.ReportGroupPropertyLogicMonitor.ReportListLogicMonitor.ReportPropertyLogicMonitor.ResourceAnalysisLogicMonitor.ResourceGroupAnalysisLogicMonitor.RoleListLogicMonitor.RolePropertyLogicMonitor.SdtListLogicMonitor.SdtPercentageLogicMonitor.SdtPropertyLogicMonitor.SingleSignOnPropertyLogicMonitor.SlaWidgetValuesLogicMonitor.SnmpSysOidMapListLogicMonitor.SnmpSysOidMapPropertyLogicMonitor.SummaryValueLogicMonitor.SummaryValueListLogicMonitor.ThresholdLogicMonitor.TrafficTableLogicMonitor.UnmonitoredDeviceListLogicMonitor.UnmonitoredDevicePropertyLogicMonitor.UserApiTokenListLogicMonitor.UserApiTokenPropertyLogicMonitor.UserListLogicMonitor.UserPropertyLogicMonitor.WebsiteCheckpointDataListLogicMonitor.WebsiteCountLogicMonitor.WebsiteGroupAnalysisLogicMonitor.WebsiteGroupCountLogicMonitor.WebsiteGroupListLogicMonitor.WebsiteGroupPropertyLogicMonitor.WebsiteListLogicMonitor.WebsitePropertyLogicMonitor.WidgetStatusMagicSuiteMagicSuite.SubscriptionListMerakiMeraki.CameraImageMeraki.ConfigurationChangeListMeraki.ConnectionMeraki.DevicePropertyMeraki.DeviceUplinkPropertyMeraki.EndOfLifeMeraki.NetworkClientListMeraki.NetworkDeviceListMeraki.NetworkEventListMeraki.NetworkListMeraki.NetworkPropertyMeraki.NetworkSwitchPortsListMeraki.NetworkSwitchStackListMeraki.OrganizationDeviceLicenseListMeraki.OrganizationDeviceLicensePropertyMeraki.OrganizationDeviceListMeraki.OrganizationDeviceListStatusPropertyMeraki.OrganizationInventoryListMeraki.OrganizationLicenseStatePropertyMeraki.OrganizationListMeraki.OrganizationPropertyMeraki.OrganizationUplinkUsageMeraki.WirelessNetworkClientConnectionStatsPropertyMeraki.WirelessNetworkClientLatencyListMeraki.WirelessNetworkClientsConnectionStatsListMeraki.WirelessNetworkClientsLatencyListMeraki.WirelessNetworkConnectionStatsPropertyMeraki.WirelessNetworkDeviceConnectionStatsPropertyMeraki.WirelessNetworkDeviceLatencyListMeraki.WirelessNetworkDevicesConnectionStatsListMeraki.WirelessNetworkDevicesLatencyListMeraki.WirelessNetworkLatencyListMicrosoftDataverseMicrosoftDataverse.ConnectionMicrosoftDataverse.CountMicrosoftDataverse.EntityDefinitionsListMicrosoftDataverse.EntityListMicrosoftDataverse.EntityPropertyListMicrosoftDataverse.ListMicrosoftDataverse.PropertyMicrosoftGraphMicrosoftGraph.ConnectionMicrosoftGraph.MicrosoftDataverseConnectionMicrosoftGraph.QueryObjectObject.ArrayCountObject.PropertyObject.TypeObject.UnpackObject.UnpackVariablesOpenAiOpenAi.AnswerOpenAi.CompleteOpenAi.ConnectionOpenAi.ImageQuickBooksQuickBooks.ConnectionQuickBooks.PropertyReportMagicReportMagic.ApplyBrandReportMagic.BadgeListReportMagic.ConnectionListReportMagic.ConnectionPropertyReportMagic.ConnectionStatusPropertyReportMagic.FeedbackListReportMagic.FeedbackPropertyReportMagic.MacroGroupListReportMagic.MacroHelpReportMagic.MacroListReportMagic.ReportBatchJobCountReportMagic.ReportBatchJobListReportMagic.ReportBatchJobPropertyReportMagic.ReportConnectionSummaryReportMagic.ReportJobCountReportMagic.ReportJobListReportMagic.ReportJobPropertyReportMagic.ReportMacroCountReportMagic.ReportPropertyReportMagic.ReportScheduleCountReportMagic.ReportScheduleListReportMagic.ReportSchedulePropertyReportMagic.SetReportPropertyReportMagic.SystemPropertyReportMagic.TenantImageReportMagic.TopicHelpReportMagic.VersionSalesforceSalesforce.ConnectionSalesforce.ListSalesforce.PropertyServiceNowServiceNow.ConnectionServiceNow.CountServiceNow.CreateServiceNow.DeleteServiceNow.DictionaryServiceNow.ListServiceNow.PropertyServiceNow.UpdateShapeShape.AddShape.CloneShape.DeleteShape.FormatShape.HideShape.SetPropertyShape.SetTextSlackSlack.ConnectionSlack.MessageSlideSlide.DeleteSlide.DeleteSectionSlide.LinkSlide.MoveToSlide.RepeatSmtpSmtp.ConnectionSnmpSnmp.EnterprisePropertySolarWindsSolarWinds.ConnectionSolarWinds.SqlListSolarWinds.SqlTableSqlSql.AnalysisTableTable.ColumnCountTable.DeleteTable.FormatTable.GraphTable.MergeCellsTable.RowCountTable.SaveTable.SortTable.WorldMapTimeCalendarCronHumanReadableCronRunDateDateRangeDateTimeDateTime.IsInWorkHoursDateTime.WorkHoursDurationTimeSpanTogglToggl.ClientListToggl.ClientPropertyToggl.ConnectionToggl.ProjectListToggl.ProjectPropertyToggl.ProjectReportPropertyToggl.TimeEntryListToggl.TimeEntryPropertyToggl.UserListToggl.UserPropertyToggl.WorkspaceListToggl.WorkspacePropertyTwilioTwilio.ConnectionTwilio.SmsUkParliamentUkParliament.PetitionCountUkParliament.PetitionListUkParliament.PetitionPropertyVariableVariable.ImageVariable.ListVariable.PropertyWebWeb.ConnectionWeb.HtmlWeb.ImageWeb.QueryWeb.ScreenshotWeb.TableWeb.TextXlsxXlsx.AddAnalysisXlsx.EmbedZendeskZendesk.ConnectionZendesk.ListZendesk.PropertyZoho.DeskZoho.Desk.ZohoListZoho.Desk.ZohoProperty

Using Aggregations in Macros

Various macros can use aggregations to summarise data, such as counting a list of values, averaging them, and so on. This can be useful in reports so you can see daily, weekly, or monthly values in charts and tables.

Which Macros Use Aggregations?

Some of the more common macros that allow you to use one or more aggregations include:

  • [List.GroupBy:]
  • [List.SummaryValue:]
  • [LogicMonitor.SummaryValue:]
  • [LogicMonitor.SummaryValueList:]

How?

In general, specify one or more aggregations using the "aggregations" parameter like this:

    aggregations=aggregation type 1;aggregation type 2;...

For example:

    [LogicMonitor.SummaryValue: aggregations=Min;Mean;Max;Count;Sum, ...]

What are the Aggregations?

The current list of aggregation is shown below although note that usage my differ slightly between macros. Also note that you should not specify the same aggregation twice in a macro:

Aggregation Description Notes / Usage
Mean The mean of the set of values.
Min The minimum of the set of values.
Max The maximum of the set of values.
First The first value in the set.
Last The last value in the set.
Count The count of the values.
All Adds all supported Aggregations. (Not supported in Legacy Mode) Example:
[List.SummaryValue: values=3;2;1, storeAs=a, aggregations=All]
{
"Mean": "2",
"Min": 1.0,
"Max": 3.0,
"First": "3",
"Last": "1",
"Sum": 6.0,
"Count": 3
}
PercentConditionMet() The percentage of the values where a condition was met Used like this:
  • aggregation=PercentConditionMet(value > 50.0)
  • aggregation=PercentConditionMet(value > 50.0) as P50
  • aggregation=PercentConditionMet(value > 50.0) as AnythingHere

The 'value' is a built-in term that is used as a placeholder for the value being used.
You can also set the 'outputDateTimes' parameter ONLY for this macro, to obtain a list of the matching DateTimes when the condition succeeded, rather than the percentage value.
PercentUpTime The percentage 'uptime' of a LogicMonitor Device (only applies to LogicMonitor.XXX macros in the list).
See the section below for more details of this aggregation.
MinDateTime The minimum DateTime in the set of data being considered. Only applies to LogicMonitor.XXX macros in the list).
MaxDateTime The maximum DateTime in the set of data being considered. Only applies to LogicMonitor.XXX macros in the list).
CountConditionMet() Similar to PercentConditionMet(), this is simply a count of values where a condition was met. Used like this:
  • aggregation=CountConditionMet(value > 50.0)
  • aggregation=CountConditionMet(value > 50.0) as C50
  • aggregation=CountConditionMet(value > 50.0) as AnythingHere

The 'value' is a built-in term that is used as a placeholder for the value being used.
Delta The difference between the first and last double-precision values in the data, i.e. (last double - first double).
DeltaPercent The percentage difference between the first and last double-precision values in the data, i.e. (last double - first double) / first double * 100.
Percentile() The N-th percentile of the data. Used like this:
  • aggregation=Percentile(95)
  • aggregation=Percentile(95) as Percentile95
  • aggregation=Percentile(95) as AnythingHere

The 'value' is a built-in term that is used as a placeholder for the value being used.

The PercentUpTime Aggregation

The PercentUpTime aggregation is a special case that is designed to use LogicMonitor data to determine the percentage (between two dates) that a particular UNIX-based Device was 'up' for.

Note: When using this aggregation, you MUST set:

  • the 'dataSourceInstanceName' parameter to 'SNMP_Host_Uptime' 
  • the 'dataPoint' parameter to 'Uptime'

This aggregation counts:

  • Downtime: "No Data"s immediately preceding a value less than 300 (seconds)
  • Uptime: all other values
  • Percent Uptime: 100 * UpTimeCount / (UpTimeCount + DownTimeCount)

See the following diagram, where only xi and xi + 1 are considered downtime. All other periods are considered uptime.

Aggregations and Normal or Legacy Mode

You can use two modes in ReportMagic:

  • Legacy Mode (the default for Schedules)
  • Normal Mode (the default for Report Studio)

In Legacy Mode, variables you might store are treated as text (that is, not strongly typed objects), and the output is often concatenated by special separators (such as a semi-colon), which you can then parse in other macros to extract the values desired.

In Normal Mode (which was designed to make it easier to extract data and avoid issues with complicated text separators), variables are typically stored as objects (for example, a List of strings, or a JArray of integers), and the output will also differ accordingly.

As an example, in Legacy Mode, this macro 

([LogicMonitor.SummaryValue: device=My Device, graphName=CPU, dataSourceInstanceName=NetSNMPCPU, dataPoint=UserPercent, aggregations=Min;Mean;Max, storeAs=Summary]) 

might output something like:

1.51;75.00;136.81

Whereas in Normal Mode, the output might be like this:

{
    "DeviceId": 123,
    "DeviceDisplayName": "My Device",
    "DataSourceName": "NetSNMPCPU",
    "DeviceDataSourceInstanceName": "NetSNMPCPU",
    "DeviceDataSourceInstanceId": 123,
    "DataPointName": "UserPercent",
    "Aggregations": {
      "Min": 1.51,
      "Mean": 75.00,
      "Max": 136.81
    }
  }

The entire result is output / stored as an 'object' (a JObject). You can then use further macros to extract the aggregations you want and store them into variables, for example:

[Object.Unpack: value=`{Summary}`, properties=Aggregations.Min;Aggregations.Mean;Aggregations.Max, storeAs=Min;Mean;Max]

The Object.Unpack macro takes in the previously-stored variable (Summary) and then based on the properties parameter, extracts the three aggregation values which it stores in the variables Min, Mean and Max.

Using Multiple Aggregations

Normal Mode

You can use multiple different aggregations in a macro like in the following:

[List.SummaryValue: values=10;9;8;7;6;5;4;3;2;1, aggregations=Percentile(25);PercentConditionMet(value>25);CountConditionMet(value>75);Count;Mean;Min;Max;First;Last;Sum]

But if you want to find out, for example multiple different sets of PercentConditionMet() aggregations, you can now specify it like:

[LogicMonitor.SummaryValueList: matchAppliesToQuery=`isWindows() && displayName != "dev.panoramicdata.com"`, dataPointSpecs=WinCPU^-1^CPUBusyPercent, aggregations=PercentConditionMet(value>5) as Percent5;PercentConditionMet(value>10) as Percent10;PercentConditionMet(value>20) as Percent20]

It is set out in the following way: Aggregation as newname.

This applies to all of the aggregations in the above table and you can specify more than one Aggregation as per macro:

[LogicMonitor.SummaryValue: device=pdl-dr-prod-01, graphName=CPU, dataSourceInstanceName=NetSNMPCPU, dataPoint=UserPercent, aggregations= Percentile(25) as Percentile1;Percentile(75) as Percentile2;PercentConditionMet(value>25) as PercentConditionMet1;PercentConditionMet(value>75) as PercentConditionMet2;CountConditionMet(value>25) as CountConditionMet1;CountConditionMet(value>75) as CountConditionMet2;Count as Count1;Count as Count2;Mean as Mean1;Min as Minimum;Max as Maximum;First as First1;Last as Last1;Sum as Sum1]

Legacy Mode

In Legacy mode, multiple aggregations (even of the same type) do not cause an issue, and just output in the normal way e.g. a semi-colon or caret-delimited list such as:

100.00^200.00^...etc
An unhandled error has occurred. Reload 🗙