Related queries and mutations in Alerts and incidents. Each has its own section.
Queries
getAlert (query)
getAlert is a query in the Monte Carlo GraphQL API, in Alerts and incidents. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Returns an alert or a merged alert (which only contains data to inform which alert it was merged into).
Arguments
| Argument | Type | Description |
|---|---|---|
id | UUID! |
Returns
GenericAlert
Example
query GetAlert($id: UUID!) {
getAlert(id: $id)
}Types used only by getAlert
getAlertGenericAlert
GenericAlertUnion type.
One of: Alert, MergedAlert
Related types
getAlertAccessRequest (query)
getAlertAccessRequest is a query in the Monte Carlo GraphQL API, in Alerts and incidents. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Deprecated: Use getAccessRequest instead
DEPRECATED. Get the status of an alert access request for the current user
Arguments
| Argument | Type | Description |
|---|---|---|
alertId | UUID! | UUID of the alert |
Returns
Example
query GetAlertAccessRequest($alertId: UUID!) {
getAlertAccessRequest(alertId: $alertId) {
id
userId
alertId
status
createdTime
updatedTime
notifiedAdmins
}
}Related types
getAlertDescription (query)
getAlertDescription is a query in the Monte Carlo GraphQL API, in Alerts and incidents. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Get a textual representation of an alert's description
Arguments
| Argument | Type | Description |
|---|---|---|
id | UUID! | UUID of the alert |
Returns
AlertDescriptionOutput
Example
query GetAlertDescription($id: UUID!) {
getAlertDescription(id: $id) {
description
}
}Types used only by getAlertDescription
getAlertDescriptionAlertDescriptionOutput
AlertDescriptionOutputObject type.
| Field | Type | Description |
|---|---|---|
description | String |
Related types
getAlerts (query)
getAlerts is a query in the Monte Carlo GraphQL API, in Alerts and incidents. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Get alerts (i.e. a collection of related events) in my account within a 2 month time range. Excludes alerts that have been merged into another.
Arguments
| Argument | Type | Description |
|---|---|---|
onAgentReadTables | Boolean | True restricts alerts to known tables read by observed agents. The agents are those seen since the start of the time range, or in the last 3 hours if the range started more recently. The time range is createdTime, or updatedTime when createdTime is not supplied. The range end does not narrow the agents. Requires Assets and Lineage access in addition to Alerts access; a denied or failed dependency query raises an error. False or null applies no restriction. |
updatedTime | DateTimeRangeInput | Supply a time range within 2 months. Either this or createdTime or ids must be provided. |
createdTime | DateTimeRangeInput | Supply a time range within 2 months. Either this or updatedTime or ids must be provided. |
ids | [UUID!] | Either this or updated_time or createdTime must be provided. |
filter | AlertsFilterInput | Filter alerts. |
agentFilters | [AgentFilterInput!] | Filter alerts by agent. Returns alerts associated with monitors covering the specified agent trace tables. With workflow set, a filter returns only the alerts of monitors whose agent span filter pins that workflow. AgentFilterInput.workflow lists the values it refuses. |
offset | Int | |
before | String | |
after | String | |
first | Int | |
last | Int | |
orderBy | String | Order results by createdTime, updatedTime, sloBreachedTime, or triagePriority. Sorting by triagePriority always puts NOT_TRIAGED alerts at the bottom, regardless of asc/desc. |
Returns
AlertConnection
Example
query GetAlerts {
getAlerts {
totalCount
}
}Types used only by getAlerts
getAlertsAlertConnection
AlertConnectionObject type.
| Field | Type | Description |
|---|---|---|
pageInfo | PageInfo! | Pagination data for this connection. |
edges | [AlertEdge]! | Contains the nodes in this connection. |
totalCount | Int |
AlertEdge
AlertEdgeObject type. A Relay edge containing a Alert and its cursor.
| Field | Type | Description |
|---|---|---|
node | Alert | The item at the end of the edge |
cursor | String! | A cursor for use in pagination |
Related types
AgentFilterInput, Alert, AlertsFilterInput, DateTimeRangeInput, PageInfo, UUID
getAlertsCountByDate (query)
getAlertsCountByDate is a query in the Monte Carlo GraphQL API, in Alerts and incidents. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Get alert count by the updated_time date.
Arguments
| Argument | Type | Description |
|---|---|---|
updatedTime | DateTimeRangeInput! | Supply a time range within 2 months. |
filter | AlertsFilterInput | Filter alerts. |
before | String | |
after | String | |
first | Int | |
last | Int |
Returns
AlertsCountByDateConnection
Example
query GetAlertsCountByDate($updatedTime: DateTimeRangeInput!) {
getAlertsCountByDate(updatedTime: $updatedTime) {
pageInfo {
hasNextPage
hasPreviousPage
startCursor
endCursor
}
}
}Types used only by getAlertsCountByDate
getAlertsCountByDateAlertsCountByDate
AlertsCountByDateObject type.
| Field | Type | Description |
|---|---|---|
date | Date | Alert updated date |
count | Int | Count of alerts on the date |
AlertsCountByDateConnection
AlertsCountByDateConnectionObject type.
| Field | Type | Description |
|---|---|---|
pageInfo | PageInfo! | Pagination data for this connection. |
edges | [AlertsCountByDateEdge]! | Contains the nodes in this connection. |
AlertsCountByDateEdge
AlertsCountByDateEdgeObject type. A Relay edge containing a AlertsCountByDate and its cursor.
| Field | Type | Description |
|---|---|---|
node | AlertsCountByDate | The item at the end of the edge |
cursor | String! | A cursor for use in pagination |
Related types
AlertsFilterInput, Date, DateTimeRangeInput, PageInfo
getAlertsFilters (query)
getAlertsFilters is a query in the Monte Carlo GraphQL API, in Alerts and incidents. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Filters that can be applied when requesting for a list of alerts
Returns
[AlertsFilter]
Example
query GetAlertsFilters {
getAlertsFilters {
fieldName
displayName
queryParameterName
queryParameterAcceptsMultipleValues
facetable
facetSearchable
}
}Types used only by getAlertsFilters
getAlertsFiltersAlertsFilter
AlertsFilterObject type.
| Field | Type | Description |
|---|---|---|
fieldName | AlertsFilterFieldName! | |
displayName | String! | |
queryParameterName | String! | Associated getAlerts parameter used to filter alerts |
queryParameterAcceptsMultipleValues | Boolean! | Whether the associated getAlerts parameter accepts multiple values as input |
facetable | Boolean! | Whether the filter shows up as a facet on the alert feed page |
facetSearchable | Boolean! | Whether the filter values can be searched by their display name |
Related types
getAlertsFiltersData (query)
getAlertsFiltersData is a query in the Monte Carlo GraphQL API, in Alerts and incidents. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Filters that can be applied when requesting for a list of alerts
Arguments
| Argument | Type | Description |
|---|---|---|
request | [AlertsFilterDataRequestType]! |
Returns
[AlertsFilterData]
Example
query GetAlertsFiltersData($request: [AlertsFilterDataRequestType]!) {
getAlertsFiltersData(request: $request) {
fieldName
}
}Types used only by getAlertsFiltersData
getAlertsFiltersDataAlertsFilterData
AlertsFilterDataObject type.
| Field | Type | Description |
|---|---|---|
fieldName | AlertsFilterFieldName | |
values | [AlertsFilterDataValue] | List of possible values to filter alerts by |
pageInfo | NextPageInfo | Data for paginating values |
AlertsFilterDataFilterType
AlertsFilterDataFilterTypeInput object type.
| Field | Type | Description |
|---|---|---|
fieldName | AlertsFilterFieldName! | |
value | GenericScalar |
AlertsFilterDataRequestType
AlertsFilterDataRequestTypeInput object type.
| Field | Type | Description |
|---|---|---|
fieldName | AlertsFilterFieldName! | |
searchCriteria | AlertsFilterDataSearchCriteriaType! | |
first | Int | Number of results to return |
after | String | Cursor to paginate results |
searchValue | String | Respond with filter values which contain this text |
AlertsFilterDataSearchCriteriaType
AlertsFilterDataSearchCriteriaTypeInput object type.
| Field | Type | Description |
|---|---|---|
onAgentReadTables | Boolean | True restricts facet counts to known tables read by observed agents. The agents are those seen since the start of the time range, or in the last 3 hours if the range started more recently. The time range is createdTime, or updatedTime when createdTime is not supplied. The range end does not narrow the agents. Requires Assets and Lineage access in addition to Alerts access; a denied or failed dependency query raises an error. False or null applies no restriction. |
updatedTime | DateTimeRangeInput | Supply a time range to filter alerts by their updated time. Either this or createdTime must be supplied. |
createdTime | DateTimeRangeInput | Supply a time range to filter alerts by their created time. Either this or updatedTime must be supplied. |
filters | [AlertsFilterDataFilterType] | List of filters to apply to alerts |
fromAgentMonitor | Boolean | Scope the aggregated counts to alerts whose monitor was created by an agent (true) or not (false). Mirrors the getAlerts filter of the same name so the facet counts match the list. Omit for no constraint. |
AlertsFilterDataValue
AlertsFilterDataValueObject type.
| Field | Type | Description |
|---|---|---|
value | GenericScalar | |
displayName | String | |
count | Int | |
childValues | [AlertsFilterDataValue] | |
queryParameterName | String | If this has a value, it should override the value from AlertsFilter |
Related types
AlertsFilterFieldName, DateTimeRangeInput, GenericScalar, NextPageInfo
Mutations
mergeAlerts (mutation)
mergeAlerts is a mutation in the Monte Carlo GraphQL API, in Alerts and incidents. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Merge specified alerts into another alert
Arguments
| Argument | Type | Description |
|---|---|---|
fromAlertIds | [UUID!]! | UUID of the alert to merge from |
toAlert | MergeAlertsInput! | Merge alerts into specified alert |
Returns
MergeAlerts
Example
mutation MergeAlerts($fromAlertIds: [UUID!]!, $toAlert: MergeAlertsInput!) {
mergeAlerts(fromAlertIds: $fromAlertIds, toAlert: $toAlert) {
alert {
id
title
type
subTypes
severity
priority
triagePriority
triageState
tsaAnalysisThreadId
hasTsaInvestigation
status
monitorUuids
fromAgentMonitor
invalidRows
inTeammateDomain
commentCount
lastCommentText
createdTime
updatedTime
sloStatus
}
}
}Types used only by mergeAlerts
mergeAlertsMergeAlerts
MergeAlertsObject type. Merge alerts together
| Field | Type | Description |
|---|---|---|
alert | Alert | The updated alert |
MergeAlertsInput
MergeAlertsInputInput object type.
| Field | Type | Description |
|---|---|---|
id | UUID! | UUID of the alert to update |
severity | SeverityInput | By assigning a severity to the alert, the alert will be declared an incident |
status | AlertStatusInput | Status to assign to the alert. |
name | String! | Custom name for the alert. |
Related types
Alert, AlertStatusInput, SeverityInput, UUID
requestAlertAccess (mutation)
requestAlertAccess is a mutation in the Monte Carlo GraphQL API, in Alerts and incidents. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Deprecated: Use requestAccess instead
DEPRECATED. Request access to view an alert
Arguments
| Argument | Type | Description |
|---|---|---|
alertId | UUID! | UUID of the alert to request access for |
Returns
AlertAccessRequestOutput
Example
mutation RequestAlertAccess($alertId: UUID!) {
requestAlertAccess(alertId: $alertId) {
success
}
}Types used only by requestAlertAccess
requestAlertAccessAlertAccessRequestOutput
AlertAccessRequestOutputObject type.
| Field | Type | Description |
|---|---|---|
success | Boolean! | Whether the operation was successful |
accessRequest | AlertAccessRequest | The access request object |
Related types
updateAlertActionPermissionSettings (mutation)
updateAlertActionPermissionSettings is a mutation in the Monte Carlo GraphQL API, in Alerts and incidents. Send it to https://api.getmontecarlo.com/graphql with an API key; see API authentication.
Status: Experimental
Set whether the calling user's account requires a permitted Monte Carlo user to act on alerts from connected Slack and Microsoft Teams channels.
Arguments
| Argument | Type | Description |
|---|---|---|
enforcementEnabled | Boolean! | Whether acting on an alert from a connected Slack or Microsoft Teams channel requires a matching Monte Carlo user with sufficient permissions. When false, anyone in a connected channel can interact with and resolve alerts, even without a Monte Carlo account. Enabling this can block people who act on alerts today, because it requires the connected app to share their email and requires that email to match an invited Monte Carlo user. |
Returns
UpdateAlertActionPermissionSettings
Example
mutation UpdateAlertActionPermissionSettings($enforcementEnabled: Boolean!) {
updateAlertActionPermissionSettings(enforcementEnabled: $enforcementEnabled) {
alertActionPermissionSettings {
enforcementEnabled
}
}
}Types used only by updateAlertActionPermissionSettings
updateAlertActionPermissionSettingsAlertActionPermissionSettings
AlertActionPermissionSettingsObject type. Account-wide control over who may act on alerts from connected chat channels.
The value applies to every Slack and Microsoft Teams integration in the account.
| Field | Type | Description |
|---|---|---|
enforcementEnabled | Boolean! | Whether acting on an alert from a connected Slack or Microsoft Teams channel requires a matching Monte Carlo user with sufficient permissions. When false, anyone in a connected channel can interact with and resolve alerts, even without a Monte Carlo account. |
UpdateAlertActionPermissionSettings
UpdateAlertActionPermissionSettingsObject type. Set whether alert actions from connected chat channels require a permitted user.
| Field | Type | Description |
|---|---|---|
alertActionPermissionSettings | AlertActionPermissionSettings! | The updated settings. |
Source: The GraphQL API reference
This page is generated from the GraphQL schema on each release. Changes made in ReadMe are overwritten.
