Related queries and mutations in Notifications. Each has its own section.
Queries
getNotificationAudienceCreators (query)
getNotificationAudienceCreators is a query in the Monte Carlo GraphQL API, in Notifications. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Retrieve users who created notification audiences. This may include null if there are audiences without a creator
Arguments
| Argument | Type | Description |
|---|---|---|
audienceId | UUID | Audience associated with the recipient |
search | String | Search text to filter the audiences list, returning those whose labels contain the specified text |
Returns
[User]
Example
query GetNotificationAudienceCreators {
getNotificationAudienceCreators {
id
cognitoUserId
email
firstName
lastName
displayName
state
createdOn
isSso
ssoGroups
ssoGroupsUpdatedAt
tokenId
isDeleted
deletedAt
deleteReason
invalidatedAt
persona
role
}
}Related types
getNotificationAudiences (query)
getNotificationAudiences is a query in the Monte Carlo GraphQL API, in Notifications. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Get notification audiences
Arguments
| Argument | Type | Description |
|---|---|---|
audienceId | UUID | Audience associated with the recipient |
search | String | Search text to filter the audiences list, returning those whose labels contain the specified text |
createdBy | [String] | Filter by creator using a list of user emails. It can include null to filter audiences without a creator |
orderBy | String | Field and direction to order audiences by |
limit | Int | Number of audiences to return |
offset | Int | From which audience to return the next results |
Returns
Example
query GetNotificationAudiences {
getNotificationAudiences {
uuid
accountUuid
label
defaultFailureAudience
routingRulesCount
customMonitorsCount
notificationServices
notificationSettingsCount
incidentCount
}
}Related types
getNotificationAudiencesCount (query)
getNotificationAudiencesCount is a query in the Monte Carlo GraphQL API, in Notifications. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
The number of audiences matching the filters
Arguments
| Argument | Type | Description |
|---|---|---|
audienceId | UUID | Audience associated with the recipient |
search | String | Search text to filter the audiences list, returning those whose labels contain the specified text |
createdBy | [String] | Filter by creator using a list of user emails. It can include null to filter audiences without a creator |
Returns
Int
Example
query GetNotificationAudiencesCount {
getNotificationAudiencesCount
}Related types
getNotificationCounts (query)
getNotificationCounts is a query in the Monte Carlo GraphQL API, in Notifications. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Get notification counts over the last 30 days
Returns
[NotificationRecordCount!]
Example
query GetNotificationCounts {
getNotificationCounts {
accountUuid
audienceUuid
incidentNotifications
digestNotifications
}
}Types used only by getNotificationCounts
getNotificationCountsNotificationRecordCount
NotificationRecordCountObject type.
Related types
getNotificationSettingsForAudiences (query)
getNotificationSettingsForAudiences is a query in the Monte Carlo GraphQL API, in Notifications. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
The notification settings that will be used for the given audiences
Arguments
| Argument | Type | Description |
|---|---|---|
labelNames | [String] | Label names. |
Returns
Example
query GetNotificationSettingsForAudiences {
getNotificationSettingsForAudiences {
uuid
createdTime
lastUpdateTime
name
isTemplateManaged
namespace
type
recipients
extra
notificationEnabled
integrationUuid
recipientsDisplayNames
customDisplayNames
incidentCount
integrationId
teamId
channelUrl
}
}Related types
getNotificationSettingsForOotb (query)
getNotificationSettingsForOotb is a query in the Monte Carlo GraphQL API, in Notifications. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Get OOTB notification settings for the given asset
Arguments
| Argument | Type | Description |
|---|---|---|
mcon | String! | Asset MCON |
anomalyType | IncidentSubType! | OOTB anomaly type |
Returns
Example
query GetNotificationSettingsForOotb($mcon: String!, $anomalyType: IncidentSubType!) {
getNotificationSettingsForOotb(mcon: $mcon, anomalyType: $anomalyType) {
uuid
createdTime
lastUpdateTime
name
isTemplateManaged
namespace
type
recipients
extra
notificationEnabled
integrationUuid
recipientsDisplayNames
customDisplayNames
incidentCount
integrationId
teamId
channelUrl
}
}Related types
IncidentSubType, NotificationSetting
Mutations
createOrUpdateAudience (mutation)
createOrUpdateAudience is a mutation in the Monte Carlo GraphQL API, in Notifications. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Create a notification audience
Arguments
| Argument | Type | Description |
|---|---|---|
label | String! | Label for the audience |
notificationSettings | [AudienceNotificationSettingInput]! | Notification settings for the audience |
uuid | UUID | For updating an audience |
Returns
CreateOrUpdateAudience
Example
mutation CreateOrUpdateAudience($label: String!, $notificationSettings: [AudienceNotificationSettingInput]!) {
createOrUpdateAudience(label: $label, notificationSettings: $notificationSettings) {
audience {
uuid
accountUuid
label
defaultFailureAudience
routingRulesCount
customMonitorsCount
notificationServices
notificationSettingsCount
incidentCount
}
}
}Types used only by createOrUpdateAudience
createOrUpdateAudienceAudienceNotificationSettingInput
AudienceNotificationSettingInputInput object type.
| Field | Type | Description |
|---|---|---|
recipients | [String]! | Destination to send notifications to |
customDisplayNames | [String] | Display names for the recipients. If this input parameter is provided, it should contain an entry for each recipient in the same order as the recipients list |
recipientsDisplayNames | [String] | Display names for the recipients. If this input parameter is provided, it should contain an entry for each recipient in the same order as the recipients list |
notificationType | String! | Specify the notification integration to use. Supported options include: email, opsgenie, pagerduty, slack, slack_v2, google_chat, webhook, msteams, msteams_v2, alation, servicenow, jira, webex, incidentio, datadog, azure_devops, firehydrant |
extra | NotificationExtra | Any extra values |
audienceId | UUID | Audience associated with the recipient |
integrationId | UUID | Integration ID for the recipient |
uuid | UUID | For updating a notification setting |
CreateOrUpdateAudience
CreateOrUpdateAudienceObject type. Create a notification audience
| Field | Type | Description |
|---|---|---|
audience | NotificationAudience |
Related types
NotificationAudience, NotificationExtra, UUID
createOrUpdateAudienceNotificationSetting (mutation)
createOrUpdateAudienceNotificationSetting is a mutation in the Monte Carlo GraphQL API, in Notifications. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Create or update an audience notification setting
Arguments
| Argument | Type | Description |
|---|---|---|
audienceId | UUID | Audience associated with the recipient |
customDisplayNames | [String] | Display names for the recipients. If this input parameter is provided, it should contain an entry for each recipient in the same order as the recipients list |
dry | Boolean | Test destination is reachable by sending a sample alert. Note - setting is not saved and rules are not evaluated. Default: false. |
extra | NotificationExtra | Any extra values |
integrationId | UUID | Integration ID for the recipient |
notificationType | String! | Specify the notification integration to use. Supported options include: email, opsgenie, pagerduty, slack, slack_v2, google_chat, webhook, msteams, msteams_v2, alation, servicenow, jira, webex, incidentio, datadog, azure_devops, firehydrant |
recipients | [String]! | Destination to send notifications to |
recipientsDisplayNames | [String] | Display names for the recipients. If this input parameter is provided, it should contain an entry for each recipient in the same order as the recipients list |
uuid | UUID | For updating a notification setting |
Returns
CreateOrUpdateAudienceNotificationSetting
Example
mutation CreateOrUpdateAudienceNotificationSetting($notificationType: String!, $recipients: [String]!) {
createOrUpdateAudienceNotificationSetting(notificationType: $notificationType, recipients: $recipients) {
notificationSetting {
uuid
createdTime
lastUpdateTime
name
isTemplateManaged
namespace
type
recipients
extra
notificationEnabled
integrationUuid
recipientsDisplayNames
customDisplayNames
incidentCount
integrationId
teamId
channelUrl
}
}
}Types used only by createOrUpdateAudienceNotificationSetting
createOrUpdateAudienceNotificationSettingCreateOrUpdateAudienceNotificationSetting
CreateOrUpdateAudienceNotificationSettingObject type. Create or update an audience notification setting
| Field | Type | Description |
|---|---|---|
notificationSetting | NotificationSetting | Setting that was created or updated |
Related types
NotificationExtra, NotificationSetting, UUID
createOrUpdateAudienceRoutingRule (mutation)
createOrUpdateAudienceRoutingRule is a mutation in the Monte Carlo GraphQL API, in Notifications. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Create or update an audience routing rule
Arguments
| Argument | Type | Description |
|---|---|---|
alertSubTypes | [AlertSubType] | Limit notifications to specific alert sub types (default=all). |
allTagKeyValues | [[NotificationTagPairs]] | |
anomalyTypes | [String] | Limit notifications to specific incident types (default=all). Supported options include: anomalies, schema_changes, json_schema_changes, deleted_tables, metric_anomalies, agent_metric_anomalies, agent_evaluation_anomalies, agent_anomalies, metric_comparison_anomalies, custom_rule_anomalies, performance_anomalies, dbt_errors, etl_errors, pseudo_integration_test, rule_run_execution_error, merged |
assetsMcons | [String] | Allowlist by asset mcons |
audienceId | UUID! | Audience associated with the rule |
customMessage | String | A custom message to be sent with triggered notification |
datasetIds | [UUID] | Allowlist by dataset identifiers |
digestSettings | NotificationDigestSettings | Deprecated. No longer supported for audience routing rules. |
domainIds | [UUID] | Allowlist by domain identifiers |
excludeAllTagKeyValues | [[NotificationTagPairs]] | |
excludeAssetsMcons | [String] | Denylist by asset mcons |
excludeDatasetIds | [UUID] | Denylist by dataset identifiers |
excludeFullTableIds | [String] | Denylist by full table identifiers |
excludeProjectMcons | [String] | Denylist by project mcons |
excludeProjectNames | [String] | Denylist by project names |
excludeTableMcons | [String] | Denylist by table mcon identifiers |
excludeTagKeyValues | [NotificationTagPairs] | Denylist by tag key/value pairs |
excludeTagKeys | [String] | Denylist by tag keys |
fullTableIds | [String] | Allowlist by full table identifiers |
incidentSubTypes | [IncidentSubType] | Limit notifications to specific incident sub types (default=all). Deprecated, use alertSubTypes instead. |
projectMcons | [String] | Allowlist by project mcons |
projectNames | [String] | Allowlist by project names |
tableMcons | [String] | Allowlist by table mcons |
tableRegex | String | For use in updating regex based rules |
tableStatsRules | TableStatsRules | Allowlist by table stats (importance_score, is_important). |
tagKeyValues | [NotificationTagPairs] | Allowlist by tag key/value pairs |
tagKeys | [String] | Allowlist by tag keys |
uuid | UUID | Rule ID to update a routing rule |
Returns
CreateOrUpdateAudienceRoutingRule
Example
mutation CreateOrUpdateAudienceRoutingRule($audienceId: UUID!) {
createOrUpdateAudienceRoutingRule(audienceId: $audienceId) {
routingRule {
uuid
tableRules
tagRules
sqlRules
tableStatsRules
domainRules
tableIdRules
assetRules
anomalyTypes
incidentSubTypes
customMessage
createdTime
updatedTime
incidentCount
alertSubTypes
assetDisplayNames
}
}
}Types used only by createOrUpdateAudienceRoutingRule
createOrUpdateAudienceRoutingRuleCreateOrUpdateAudienceRoutingRule
CreateOrUpdateAudienceRoutingRuleObject type. Create or update an audience routing rule
| Field | Type | Description |
|---|---|---|
routingRule | NotificationRoutingRule | Routing rule that was created or updated |
Related types
AlertSubType, IncidentSubType, NotificationDigestSettings, NotificationRoutingRule, NotificationTagPairs, TableStatsRules, UUID
deleteAudienceNotificationSetting (mutation)
deleteAudienceNotificationSetting is a mutation in the Monte Carlo GraphQL API, in Notifications. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Arguments
| Argument | Type | Description |
|---|---|---|
uuids | [UUID]! |
Returns
DeleteAudienceNotificationSetting
Example
mutation DeleteAudienceNotificationSetting($uuids: [UUID]!) {
deleteAudienceNotificationSetting(uuids: $uuids) {
deleted
}
}Types used only by deleteAudienceNotificationSetting
deleteAudienceNotificationSettingDeleteAudienceNotificationSetting
DeleteAudienceNotificationSettingObject type.
| Field | Type | Description |
|---|---|---|
deleted | Int |
Related types
deleteAudienceRoutingRule (mutation)
deleteAudienceRoutingRule is a mutation in the Monte Carlo GraphQL API, in Notifications. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Arguments
| Argument | Type | Description |
|---|---|---|
uuids | [UUID]! |
Returns
DeleteAudienceRoutingRule
Example
mutation DeleteAudienceRoutingRule($uuids: [UUID]!) {
deleteAudienceRoutingRule(uuids: $uuids) {
deleted
}
}Types used only by deleteAudienceRoutingRule
deleteAudienceRoutingRuleDeleteAudienceRoutingRule
DeleteAudienceRoutingRuleObject type.
| Field | Type | Description |
|---|---|---|
deleted | Int |
Related types
setDefaultFailureAudiences (mutation)
setDefaultFailureAudiences is a mutation in the Monte Carlo GraphQL API, in Notifications. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Set default failure audiences (labels) for the account
Arguments
| Argument | Type | Description |
|---|---|---|
audienceIds | [UUID!]! | Audience (labels) UUIDs to set as default for failure notifications |
Returns
SetDefaultFailureAudiences
Example
mutation SetDefaultFailureAudiences($audienceIds: [UUID!]!) {
setDefaultFailureAudiences(audienceIds: $audienceIds) {
success
}
}Types used only by setDefaultFailureAudiences
setDefaultFailureAudiencesSetDefaultFailureAudiences
SetDefaultFailureAudiencesObject type.
| Field | Type | Description |
|---|---|---|
success | Boolean |
Related types
Source: The GraphQL API reference
This page is generated from the GraphQL schema on each release. Changes made in ReadMe are overwritten.
