Monitor exceptions (GraphQL)

Related queries and mutations in Monitors. Each has its own section.

Queries

getExceptionActivityLogs (query)

getExceptionActivityLogs is a query in the Monte Carlo GraphQL API, in Monitors. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.

Status: Experimental

Get activity logs for an exception

Arguments

ArgumentTypeDescription
exceptionIdUUID!UUID of the exception to fetch activity logs for
offsetInt
beforeString
afterString
firstInt
lastInt
attributeNameString
actorEmailString
createdTime_GteDateTime
createdTime_LteDateTime
createdTime_GtDateTime
createdTime_LtDateTime
orderByStringOrdering

Returns

ExceptionActivityLogEntryConnection

Example

query GetExceptionActivityLogs($exceptionId: UUID!) {
  getExceptionActivityLogs(exceptionId: $exceptionId) {
    pageInfo {
      hasNextPage
      hasPreviousPage
      startCursor
      endCursor
    }
  }
}

Types used only by getExceptionActivityLogs

ExceptionActivityLogEntryConnection

Object type.

FieldTypeDescription
pageInfoPageInfo!Pagination data for this connection.
edges[ExceptionActivityLogEntryEdge]!Contains the nodes in this connection.
ExceptionActivityLogEntryEdge

Object type. A Relay edge containing a ExceptionActivityLogEntry and its cursor.

FieldTypeDescription
nodeExceptionActivityLogEntryThe item at the end of the edge
cursorString!A cursor for use in pagination

Related types

DateTime, ExceptionActivityLogEntry, PageInfo, UUID

getMonitorExceptions (query)

getMonitorExceptions is a query in the Monte Carlo GraphQL API, in Monitors. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.

Status: Experimental

Retrieves monitor exception records

Arguments

ArgumentTypeDescription
jobExecutionUuidUUID!JobExecution to fetch the output sample for

Returns

CustomSQLOutputSampleWithExceptions

Example

query GetMonitorExceptions($jobExecutionUuid: UUID!) {
  getMonitorExceptions(jobExecutionUuid: $jobExecutionUuid) {
    exceptionPrimaryKeyColumn
    samplingDisabled
  }
}

Types used only by getMonitorExceptions

ColumnConfig

Object type.

FieldTypeDescription
isUpdatableBoolean!Whether this column can be updated by users
typeColumnConfigType!Column type: predefined or custom
valueOptions[String!]Possible values for this column. Only set for custom columns.
ColumnConfigType

Enum type.

ValueDescription
PREDEFINED
CUSTOM
CustomSQLOutputSampleWithExceptions

Object type.

FieldTypeDescription
dataSampleDataSectionRead-only sample data from the custom SQL execution
metadataExceptionMetadataSectionUpdatable exception metadata for each row
exceptionPrimaryKeyColumnString!The primary key column name used to identify exceptions
samplingDisabledBoolean!Whether sampling is disabled for this job execution
DateTimeAttribute

Object type.

FieldTypeDescription
dateTimeValueDateTime!DateTime value
ExceptionMetadataRowValue

Union type.

One of: IntegerAttribute, DateTimeAttribute, UserAttribute, StringAttribute

ExceptionMetadataSection

Object type. Data associated to each sampled row. Columns and rows can be matched to SampleDataSection by index.

FieldTypeDescription
columns[String]Metadata column names
columnsConfig[ColumnConfig!]Configuration for each metadata column, matching the order of columns.
rows[[ExceptionMetadataRowValue]]Exception metadata rows, matching the order of data rows.
IntegerAttribute

Object type.

FieldTypeDescription
integerValueInt!Integer value
SampleDataSection

Object type. Sampled monitor breach data

FieldTypeDescription
columns[String]Column names from the sample data
rows[[String]]Sample data rows
StringAttribute

Object type.

FieldTypeDescription
stringValueString!String value

Related types

DateTime, UUID, UserAttribute

Mutations

bulkCreateCommentForExceptions (mutation)

bulkCreateCommentForExceptions is a mutation in the Monte Carlo GraphQL API, in Monitors. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.

Status: Experimental

Add a comment to all specified exceptions

Arguments

ArgumentTypeDescription
exceptionIds[UUID!]!List of exception UUIDs to add the comment to. All exceptions must belong to the same monitor.
textString!Comment text

Returns

BulkCreateCommentForExceptions

Example

mutation BulkCreateCommentForExceptions($exceptionIds: [UUID!]!, $text: String!) {
  bulkCreateCommentForExceptions(exceptionIds: $exceptionIds, text: $text) {
    success
  }
}

Types used only by bulkCreateCommentForExceptions

BulkCreateCommentForExceptions

Object type.

FieldTypeDescription
successBooleanWhether the bulk comment creation was successful

Related types

UUID

bulkUpdateMonitorExceptions (mutation)

bulkUpdateMonitorExceptions is a mutation in the Monte Carlo GraphQL API, in Monitors. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.

Status: Experimental

Bulk update exception attributes, such as assignee

Arguments

ArgumentTypeDescription
attributes[ExceptionAttributeInput!]!List of attribute updates with name and value
exceptionIds[UUID!]!List of exception UUIDs to update. All exceptions must belong to the same monitor.

Returns

BulkUpdateMonitorExceptions

Example

mutation BulkUpdateMonitorExceptions($attributes: [ExceptionAttributeInput!]!, $exceptionIds: [UUID!]!) {
  bulkUpdateMonitorExceptions(attributes: $attributes, exceptionIds: $exceptionIds) {
    success
  }
}

Types used only by bulkUpdateMonitorExceptions

BulkUpdateMonitorExceptions

Object type.

FieldTypeDescription
successBooleanWhether the bulk update was successful
ExceptionAttributeInput

Input object type. Input type for a single exception attribute update.

FieldTypeDescription
nameString!Name of the attribute to update (e.g., 'assignee')
valueStringValue for the attribute. If not provided, clears the attribute.

Related types

UUID

Source: The GraphQL API reference

This page is generated from the GraphQL schema on each release. Changes made in ReadMe are overwritten.