Event service#
An Event is an annotated moment or time range. The Event Service is responsible for creating and retrieving events for a particular data source.
OpenAPI file: nominal.event.v2.json
Endpoints#
Create event#
POST /event/v2/events
Creates an event.
Body
assetRidsarray of stringMust contain at least one asset rid.
originsarray ofEventOriginIf empty, defaults to a single API origin.
Fields of
EventOrigin- one of 6 fields
workbookWorkbookEventOriginThis event was created in this workbook.
Fields of
WorkbookEventOriginridstring
dataarray ofWorkbookDataAssociationData visualizations to associate this event with.
Fields of
WorkbookDataAssociationtimeSeriesChannelTimeSeriesChannelAssociation
Fields of
TimeSeriesChannelAssociationvariableNamestring
tagsmap of string to stringIf this variable is grouped, the tags within the groupings this event should associate with.
templateTemplateEventOriginThis event was created in this template.
Fields of
TemplateEventOriginridstring
apiApiEventOriginThis event was created programmatically via the API.
dataReviewDataReviewEventOriginThis event was created automatically from a checklist execution.
Fields of
DataReviewEventOrigindataReviewRidstring
checkMetadataCheckOriginMetadataMetadata about the check that created this event.
Fields of
CheckOriginMetadatacheckEvaluationRidstring
checkRidstring
checkLineageRidstring
implementationIndexinteger
procedureProcedureEventOriginThis event was created automatically from a procedure execution.
Fields of
ProcedureEventOriginprocedureExecutionRidstring
procedureRidstring
stepIdstring
streamingChecklistStreamingChecklistEventOriginThis event was created automatically from the execution of a streaming checklist.
Fields of
StreamingChecklistEventOriginchecklistRidstring
checkMetadataStreamingCheckOriginMetadataMetadata about the check that created this event.
Fields of
StreamingCheckOriginMetadatacheckRidstring
checkLineageRidstring
implementationIndexinteger
timestampTimestamp
Fields of
Timestampsecondsstring (int64)
nanosstring (int64)
durationDuration
Fields of
Durationsecondsstring (int64)
nanosstring (int64)
namestring
descriptionstringIf not provided, defaults to an empty string.
typeEventType
Values of
EventTypeEVENT_TYPE_UNSPECIFIED
INFO
FLAG
ERROR
SUCCESS
labelsarray of string
propertiesmap of string to string deprecated
dispositionEventDisposition
Fields of
EventDispositionpriorityPriority
Values of
PriorityPRIORITY_UNSPECIFIED
P0
P1
P2
P3
P4
stateDispositionState
Fields of
DispositionState- one of
pendingReview,closedWithFurtherAction,closedWithIgnore
pendingReviewPendingReviewDispositionState
Fields of
PendingReviewDispositionStateopenedBystring
closedWithFurtherActionClosedWithFurtherActionDispositionState
Fields of
ClosedWithFurtherActionDispositionStateclosedBystring
closedWithIgnoreClosedWithIgnoreDispositionState
Fields of
ClosedWithIgnoreDispositionStateclosedBystring
- one of
assigneesarray of string
typedPropertiesmap of string toTypedPropertyValue
Fields of
TypedPropertyValue- one of
stringValue,numericValuerequired
stringValuestring
numericValuenumber
- one of
Response
eventEvent
Fields of
Eventuuidstring
ridstring
assetRidsarray of stringA set of asset rids associated with the event.
originsarray ofEventOriginA set of origins associated with the event.
Fields of
EventOrigin- one of 6 fields
workbookWorkbookEventOriginThis event was created in this workbook.
Fields of
WorkbookEventOriginridstring
dataarray ofWorkbookDataAssociationData visualizations to associate this event with.
Fields of
WorkbookDataAssociationtimeSeriesChannelTimeSeriesChannelAssociation
Fields of
TimeSeriesChannelAssociationvariableNamestring
tagsmap of string to stringIf this variable is grouped, the tags within the groupings this event should associate with.
templateTemplateEventOriginThis event was created in this template.
Fields of
TemplateEventOriginridstring
apiApiEventOriginThis event was created programmatically via the API.
dataReviewDataReviewEventOriginThis event was created automatically from a checklist execution.
Fields of
DataReviewEventOrigindataReviewRidstring
checkMetadataCheckOriginMetadataMetadata about the check that created this event.
Fields of
CheckOriginMetadatacheckEvaluationRidstring
checkRidstring
checkLineageRidstring
implementationIndexinteger
procedureProcedureEventOriginThis event was created automatically from a procedure execution.
Fields of
ProcedureEventOriginprocedureExecutionRidstring
procedureRidstring
stepIdstring
streamingChecklistStreamingChecklistEventOriginThis event was created automatically from the execution of a streaming checklist.
Fields of
StreamingChecklistEventOriginchecklistRidstring
checkMetadataStreamingCheckOriginMetadataMetadata about the check that created this event.
Fields of
StreamingCheckOriginMetadatacheckRidstring
checkLineageRidstring
implementationIndexinteger
timestampTimestamp
Fields of
Timestampsecondsstring (int64)
nanosstring (int64)
durationDuration
Fields of
Durationsecondsstring (int64)
nanosstring (int64)
namestring
descriptionstring
typeEventType
Values of
EventTypeEVENT_TYPE_UNSPECIFIED
INFO
FLAG
ERROR
SUCCESS
labelsarray of string
propertiesmap of string to string deprecated
isArchivedboolean
createdBystringThe user who created the event. This field may be missing for legacy events.
dispositionEventDisposition
Fields of
EventDispositionpriorityPriority
Values of
PriorityPRIORITY_UNSPECIFIED
P0
P1
P2
P3
P4
stateDispositionState
Fields of
DispositionState- one of
pendingReview,closedWithFurtherAction,closedWithIgnore
pendingReviewPendingReviewDispositionState
Fields of
PendingReviewDispositionStateopenedBystring
closedWithFurtherActionClosedWithFurtherActionDispositionState
Fields of
ClosedWithFurtherActionDispositionStateclosedBystring
closedWithIgnoreClosedWithIgnoreDispositionState
Fields of
ClosedWithIgnoreDispositionStateclosedBystring
- one of
assigneesarray of string
typedPropertiesmap of string toTypedPropertyValue
Fields of
TypedPropertyValue- one of
stringValue,numericValue
stringValuestring
numericValuenumber
- one of
Request
curl -X POST "https://api.gov.nominal.io/api/event/v2/events" \
-H "Authorization: Bearer <api key>" \
-H "Content-Type: application/json" \
--data '{
"assetRids": [
"<asset rids>"
],
"origins": [
{
"workbook": {
"rid": "<rid>",
"data": [
{
"timeSeriesChannel": {
"variableName": "<variable name>",
"tags": {
"<key>": "<value>"
}
}
}
]
}
}
],
"timestamp": {
"seconds": "1",
"nanos": "1"
},
"duration": {
"seconds": "1",
"nanos": "1"
},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": [
"<labels>"
],
"properties": {
"<key>": "<value>"
},
"disposition": {
"priority": "P0",
"state": {
"pendingReview": {
"openedBy": "<opened by>"
}
},
"assignees": [
"<assignees>"
]
},
"typedProperties": {
"<key>": {
"stringValue": "<string value>"
}
}
}'
import requests
response = requests.post(
"https://api.gov.nominal.io/api/event/v2/events",
headers={"Authorization": "Bearer <api key>"},
json={
"assetRids": ["<asset rids>"],
"origins": [
{
"workbook": {
"rid": "<rid>",
"data": [
{
"timeSeriesChannel": {
"variableName": "<variable name>",
"tags": {"<key>": "<value>"},
},
},
],
},
},
],
"timestamp": {"seconds": "1", "nanos": "1"},
"duration": {"seconds": "1", "nanos": "1"},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": ["<labels>"],
"properties": {"<key>": "<value>"},
"disposition": {
"priority": "P0",
"state": {"pendingReview": {"openedBy": "<opened by>"}},
"assignees": ["<assignees>"],
},
"typedProperties": {"<key>": {"stringValue": "<string value>"}},
},
)
response.raise_for_status()
print(response.json())
import httpx
response = httpx.post(
"https://api.gov.nominal.io/api/event/v2/events",
headers={"Authorization": "Bearer <api key>"},
json={
"assetRids": ["<asset rids>"],
"origins": [
{
"workbook": {
"rid": "<rid>",
"data": [
{
"timeSeriesChannel": {
"variableName": "<variable name>",
"tags": {"<key>": "<value>"},
},
},
],
},
},
],
"timestamp": {"seconds": "1", "nanos": "1"},
"duration": {"seconds": "1", "nanos": "1"},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": ["<labels>"],
"properties": {"<key>": "<value>"},
"disposition": {
"priority": "P0",
"state": {"pendingReview": {"openedBy": "<opened by>"}},
"assignees": ["<assignees>"],
},
"typedProperties": {"<key>": {"stringValue": "<string value>"}},
},
)
response.raise_for_status()
print(response.json())
import asyncio
import aiohttp
async def main() -> None:
async with aiohttp.ClientSession() as session:
async with session.post(
"https://api.gov.nominal.io/api/event/v2/events",
headers={"Authorization": "Bearer <api key>"},
json={
"assetRids": ["<asset rids>"],
"origins": [
{
"workbook": {
"rid": "<rid>",
"data": [
{
"timeSeriesChannel": {
"variableName": "<variable name>",
"tags": {"<key>": "<value>"},
},
},
],
},
},
],
"timestamp": {"seconds": "1", "nanos": "1"},
"duration": {"seconds": "1", "nanos": "1"},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": ["<labels>"],
"properties": {"<key>": "<value>"},
"disposition": {
"priority": "P0",
"state": {"pendingReview": {"openedBy": "<opened by>"}},
"assignees": ["<assignees>"],
},
"typedProperties": {"<key>": {"stringValue": "<string value>"}},
},
) as response:
response.raise_for_status()
print(await response.json())
asyncio.run(main())
Response: 200
{
"event": {
"uuid": "<uuid>",
"rid": "<rid>",
"assetRids": [
"<asset rids>"
],
"origins": [
{
"workbook": {
"rid": "<rid>",
"data": [
{
"timeSeriesChannel": {
"variableName": "<variable name>",
"tags": {
"<key>": "<value>"
}
}
}
]
}
}
],
"timestamp": {
"seconds": "1",
"nanos": "1"
},
"duration": {
"seconds": "1",
"nanos": "1"
},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": [
"<labels>"
],
"properties": {
"<key>": "<value>"
},
"isArchived": true,
"createdBy": "<created by>",
"disposition": {
"priority": "P0",
"state": {
"pendingReview": {
"openedBy": "<opened by>"
}
},
"assignees": [
"<assignees>"
]
},
"typedProperties": {
"<key>": {
"stringValue": "<string value>"
}
}
}
}
Aggregate events#
POST /event/v2/events/aggregate
Searches for events matching the given filter and aggregates them based on the requested functions.
Body
querySearchQuery
Fields of
SearchQuery- one of 41 fields
archivedboolean
searchTextstringSearch text to perform fuzzy searching against.
exactMatchstringSearch text to perform exact matching against on the event name and description.
afterTimestampFilters to events after this timestamp, exclusive.
Fields of
Timestampsecondsstring (int64)
nanosstring (int64)
beforeTimestampFilters to events before this timestamp, exclusive.
advancedTimeFilterEventTimeFilter
Fields of
EventTimeFiltertimestampTimestamp
timestampConditionEventTimeFilterCondition
Values of
EventTimeFilterConditionEVENT_TIME_FILTER_CONDITION_UNSPECIFIED
START_TIME_BEFORE_INCLUSIVE
START_TIME_BEFORE_EXCLUSIVE
START_TIME_AFTER_INCLUSIVE
START_TIME_AFTER_EXCLUSIVE
END_TIME_BEFORE_INCLUSIVE
END_TIME_BEFORE_EXCLUSIVE
END_TIME_AFTER_INCLUSIVE
END_TIME_AFTER_EXCLUSIVE
assetstring
assetsAssetsFilter
Fields of
AssetsFilteroperatorSetOperator
Values of
SetOperatorSET_OPERATOR_UNSPECIFIED
AND
OR
assetsarray of string
templatestring
workbookstring
dataReviewstring
dataReviewsDataReviewsFilter
Fields of
DataReviewsFilterdataReviewsarray of string
originTypeSearchEventOriginType
Values of
SearchEventOriginTypeSEARCH_EVENT_ORIGIN_TYPE_UNSPECIFIED
WORKBOOK
TEMPLATE
API
DATA_REVIEW
PROCEDURE
STREAMING_CHECKLIST
originTypesOriginTypesFilter
Fields of
OriginTypesFilteroperatorSetOperator
originTypesarray ofSearchEventOriginType
dataReviewCheckstring
dataReviewChecksDataReviewChecksFilter
Fields of
DataReviewChecksFilterdataReviewChecksarray of string
dispositionStatusEventDispositionStatus
Values of
EventDispositionStatusEVENT_DISPOSITION_STATUS_UNSPECIFIED
PENDING_REVIEW
CLOSED_IGNORED
CLOSED_REQUIRES_FURTHER_ACTION
NO_DISPOSITION
dispositionStatusesEventDispositionStatusList
Fields of
EventDispositionStatusListvaluesarray ofEventDispositionStatus
priorityPriority
Values of
PriorityPRIORITY_UNSPECIFIED
P0
P1
P2
P3
P4
prioritiesPriorityList
Fields of
PriorityListvaluesarray ofPriority
assigneestring
assigneesAssigneesFilter
Fields of
AssigneesFilteroperatorSetOperator
assigneesarray of string
eventTypeEventType
Values of
EventTypeEVENT_TYPE_UNSPECIFIED
INFO
FLAG
ERROR
SUCCESS
eventTypesEventTypeList
Fields of
EventTypeListvaluesarray ofEventType
createdBystring
createdByAnyOfUserRidList
Fields of
UserRidListvaluesarray of string
labelstring
labelsLabelsFilter
Fields of
LabelsFilteroperatorSetOperator
labelsarray of string
propertyProperty
Fields of
Propertynamestring
valuestring
propertiesPropertiesFilter
Fields of
PropertiesFilternamestring
valuesarray of string
andSearchQueryList
Fields of
SearchQueryListqueriesarray ofSearchQuery
orSearchQueryList
notSearchQuery
workspacestring
procedurestring
procedureExecutionstring
stepIdstring
streamingCheckliststringFilters to events created from a checklist executing in streaming.
streamingCheckstringFilters to events created from the check of a checklist executing in streaming.
numericPropertyNumericPropertyPredicateMatches events using a numeric property comparison.
Fields of
NumericPropertyPredicatenamestring
valuenumber
operatorPropertyComparisonOperator
Values of
PropertyComparisonOperatorPROPERTY_COMPARISON_OPERATOR_UNSPECIFIED
EQ
NEQ
GT
GTE
LT
LTE
numericPropertyRangeNumericPropertyRangePredicateMatches events using an inclusive numeric property range.
Fields of
NumericPropertyRangePredicatenamestring
minnumber
maxnumber
operatorNumericPropertyRangeOperator
Values of
NumericPropertyRangeOperatorNUMERIC_PROPERTY_RANGE_OPERATOR_UNSPECIFIED
BETWEEN
NOT_BETWEEN
aggregateTypesarray ofAggregateType
Values of
AggregateTypeAGGREGATE_TYPE_UNSPECIFIED
TOTAL_DURATION
TOTAL_COUNT
Response
valuesmap of string toAggregateValueKeyed by AggregateType enum value name (proto3 forbids enum map keys).
Fields of
AggregateValue- one of
duration,count
durationDuration
Fields of
Durationsecondsstring (int64)
nanosstring (int64)
countinteger
- one of
Request
curl -X POST "https://api.gov.nominal.io/api/event/v2/events/aggregate" \
-H "Authorization: Bearer <api key>" \
-H "Content-Type: application/json" \
--data '{
"query": {
"archived": true
},
"aggregateTypes": [
"TOTAL_DURATION"
]
}'
import requests
response = requests.post(
"https://api.gov.nominal.io/api/event/v2/events/aggregate",
headers={"Authorization": "Bearer <api key>"},
json={"query": {"archived": True}, "aggregateTypes": ["TOTAL_DURATION"]},
)
response.raise_for_status()
print(response.json())
import httpx
response = httpx.post(
"https://api.gov.nominal.io/api/event/v2/events/aggregate",
headers={"Authorization": "Bearer <api key>"},
json={"query": {"archived": True}, "aggregateTypes": ["TOTAL_DURATION"]},
)
response.raise_for_status()
print(response.json())
import asyncio
import aiohttp
async def main() -> None:
async with aiohttp.ClientSession() as session:
async with session.post(
"https://api.gov.nominal.io/api/event/v2/events/aggregate",
headers={"Authorization": "Bearer <api key>"},
json={"query": {"archived": True}, "aggregateTypes": ["TOTAL_DURATION"]},
) as response:
response.raise_for_status()
print(await response.json())
asyncio.run(main())
Response: 200
{
"values": {
"<key>": {
"duration": {
"seconds": "1",
"nanos": "1"
}
}
}
}
Archive event#
POST /event/v2/events/archive
Archives an event.
Body
uuidstring
Response
An empty JSON object, {}.
Request
curl -X POST "https://api.gov.nominal.io/api/event/v2/events/archive" \
-H "Authorization: Bearer <api key>" \
-H "Content-Type: application/json" \
--data '{
"uuid": "<uuid>"
}'
import requests
response = requests.post(
"https://api.gov.nominal.io/api/event/v2/events/archive",
headers={"Authorization": "Bearer <api key>"},
json={"uuid": "<uuid>"},
)
response.raise_for_status()
print(response.json())
import httpx
response = httpx.post(
"https://api.gov.nominal.io/api/event/v2/events/archive",
headers={"Authorization": "Bearer <api key>"},
json={"uuid": "<uuid>"},
)
response.raise_for_status()
print(response.json())
import asyncio
import aiohttp
async def main() -> None:
async with aiohttp.ClientSession() as session:
async with session.post(
"https://api.gov.nominal.io/api/event/v2/events/archive",
headers={"Authorization": "Bearer <api key>"},
json={"uuid": "<uuid>"},
) as response:
response.raise_for_status()
print(await response.json())
asyncio.run(main())
Response: 200
{}
Batch aggregate events#
POST /event/v2/events/batch-aggregate
Aggregates each batched request and returns responses in the same order.
Body
requestsarray ofAggregateEventsRequest
Fields of
AggregateEventsRequestquerySearchQuery
Fields of
SearchQuery- one of 41 fields
archivedboolean
searchTextstringSearch text to perform fuzzy searching against.
exactMatchstringSearch text to perform exact matching against on the event name and description.
afterTimestampFilters to events after this timestamp, exclusive.
Fields of
Timestampsecondsstring (int64)
nanosstring (int64)
beforeTimestampFilters to events before this timestamp, exclusive.
advancedTimeFilterEventTimeFilter
Fields of
EventTimeFiltertimestampTimestamp
timestampConditionEventTimeFilterCondition
Values of
EventTimeFilterConditionEVENT_TIME_FILTER_CONDITION_UNSPECIFIED
START_TIME_BEFORE_INCLUSIVE
START_TIME_BEFORE_EXCLUSIVE
START_TIME_AFTER_INCLUSIVE
START_TIME_AFTER_EXCLUSIVE
END_TIME_BEFORE_INCLUSIVE
END_TIME_BEFORE_EXCLUSIVE
END_TIME_AFTER_INCLUSIVE
END_TIME_AFTER_EXCLUSIVE
assetstring
assetsAssetsFilter
Fields of
AssetsFilteroperatorSetOperator
Values of
SetOperatorSET_OPERATOR_UNSPECIFIED
AND
OR
assetsarray of string
templatestring
workbookstring
dataReviewstring
dataReviewsDataReviewsFilter
Fields of
DataReviewsFilterdataReviewsarray of string
originTypeSearchEventOriginType
Values of
SearchEventOriginTypeSEARCH_EVENT_ORIGIN_TYPE_UNSPECIFIED
WORKBOOK
TEMPLATE
API
DATA_REVIEW
PROCEDURE
STREAMING_CHECKLIST
originTypesOriginTypesFilter
Fields of
OriginTypesFilteroperatorSetOperator
originTypesarray ofSearchEventOriginType
dataReviewCheckstring
dataReviewChecksDataReviewChecksFilter
Fields of
DataReviewChecksFilterdataReviewChecksarray of string
dispositionStatusEventDispositionStatus
Values of
EventDispositionStatusEVENT_DISPOSITION_STATUS_UNSPECIFIED
PENDING_REVIEW
CLOSED_IGNORED
CLOSED_REQUIRES_FURTHER_ACTION
NO_DISPOSITION
dispositionStatusesEventDispositionStatusList
Fields of
EventDispositionStatusListvaluesarray ofEventDispositionStatus
priorityPriority
Values of
PriorityPRIORITY_UNSPECIFIED
P0
P1
P2
P3
P4
prioritiesPriorityList
Fields of
PriorityListvaluesarray ofPriority
assigneestring
assigneesAssigneesFilter
Fields of
AssigneesFilteroperatorSetOperator
assigneesarray of string
eventTypeEventType
Values of
EventTypeEVENT_TYPE_UNSPECIFIED
INFO
FLAG
ERROR
SUCCESS
eventTypesEventTypeList
Fields of
EventTypeListvaluesarray ofEventType
createdBystring
createdByAnyOfUserRidList
Fields of
UserRidListvaluesarray of string
labelstring
labelsLabelsFilter
Fields of
LabelsFilteroperatorSetOperator
labelsarray of string
propertyProperty
Fields of
Propertynamestring
valuestring
propertiesPropertiesFilter
Fields of
PropertiesFilternamestring
valuesarray of string
andSearchQueryList
Fields of
SearchQueryListqueriesarray ofSearchQuery
orSearchQueryList
notSearchQuery
workspacestring
procedurestring
procedureExecutionstring
stepIdstring
streamingCheckliststringFilters to events created from a checklist executing in streaming.
streamingCheckstringFilters to events created from the check of a checklist executing in streaming.
numericPropertyNumericPropertyPredicateMatches events using a numeric property comparison.
Fields of
NumericPropertyPredicatenamestring
valuenumber
operatorPropertyComparisonOperator
Values of
PropertyComparisonOperatorPROPERTY_COMPARISON_OPERATOR_UNSPECIFIED
EQ
NEQ
GT
GTE
LT
LTE
numericPropertyRangeNumericPropertyRangePredicateMatches events using an inclusive numeric property range.
Fields of
NumericPropertyRangePredicatenamestring
minnumber
maxnumber
operatorNumericPropertyRangeOperator
Values of
NumericPropertyRangeOperatorNUMERIC_PROPERTY_RANGE_OPERATOR_UNSPECIFIED
BETWEEN
NOT_BETWEEN
aggregateTypesarray ofAggregateType
Values of
AggregateTypeAGGREGATE_TYPE_UNSPECIFIED
TOTAL_DURATION
TOTAL_COUNT
Response
responsesarray ofAggregateEventsResponse
Fields of
AggregateEventsResponsevaluesmap of string toAggregateValueKeyed by AggregateType enum value name (proto3 forbids enum map keys).
Fields of
AggregateValue- one of
duration,count
durationDuration
Fields of
Durationsecondsstring (int64)
nanosstring (int64)
countinteger
- one of
Request
curl -X POST "https://api.gov.nominal.io/api/event/v2/events/batch-aggregate" \
-H "Authorization: Bearer <api key>" \
-H "Content-Type: application/json" \
--data '{
"requests": [
{
"query": {
"archived": true
},
"aggregateTypes": [
"TOTAL_DURATION"
]
}
]
}'
import requests
response = requests.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-aggregate",
headers={"Authorization": "Bearer <api key>"},
json={
"requests": [
{"query": {"archived": True}, "aggregateTypes": ["TOTAL_DURATION"]},
],
},
)
response.raise_for_status()
print(response.json())
import httpx
response = httpx.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-aggregate",
headers={"Authorization": "Bearer <api key>"},
json={
"requests": [
{"query": {"archived": True}, "aggregateTypes": ["TOTAL_DURATION"]},
],
},
)
response.raise_for_status()
print(response.json())
import asyncio
import aiohttp
async def main() -> None:
async with aiohttp.ClientSession() as session:
async with session.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-aggregate",
headers={"Authorization": "Bearer <api key>"},
json={
"requests": [
{"query": {"archived": True}, "aggregateTypes": ["TOTAL_DURATION"]},
],
},
) as response:
response.raise_for_status()
print(await response.json())
asyncio.run(main())
Response: 200
{
"responses": [
{
"values": {
"<key>": {
"duration": {
"seconds": "1",
"nanos": "1"
}
}
}
}
]
}
Batch archive event#
POST /event/v2/events/batch-archive
Archives a set of events.
Body
eventRidsarray of string
Response
An empty JSON object, {}.
Request
curl -X POST "https://api.gov.nominal.io/api/event/v2/events/batch-archive" \
-H "Authorization: Bearer <api key>" \
-H "Content-Type: application/json" \
--data '{
"eventRids": [
"<event rids>"
]
}'
import requests
response = requests.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-archive",
headers={"Authorization": "Bearer <api key>"},
json={"eventRids": ["<event rids>"]},
)
response.raise_for_status()
print(response.json())
import httpx
response = httpx.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-archive",
headers={"Authorization": "Bearer <api key>"},
json={"eventRids": ["<event rids>"]},
)
response.raise_for_status()
print(response.json())
import asyncio
import aiohttp
async def main() -> None:
async with aiohttp.ClientSession() as session:
async with session.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-archive",
headers={"Authorization": "Bearer <api key>"},
json={"eventRids": ["<event rids>"]},
) as response:
response.raise_for_status()
print(await response.json())
asyncio.run(main())
Response: 200
{}
Batch filter events#
POST /event/v2/events/batch-filter-get
Gets a filtered set of events by RID and search filters.
Body
eventRidsarray of string
filterQuerySearchQuery
Fields of
SearchQuery- one of 41 fields
archivedboolean
searchTextstringSearch text to perform fuzzy searching against.
exactMatchstringSearch text to perform exact matching against on the event name and description.
afterTimestampFilters to events after this timestamp, exclusive.
Fields of
Timestampsecondsstring (int64)
nanosstring (int64)
beforeTimestampFilters to events before this timestamp, exclusive.
advancedTimeFilterEventTimeFilter
Fields of
EventTimeFiltertimestampTimestamp
timestampConditionEventTimeFilterCondition
Values of
EventTimeFilterConditionEVENT_TIME_FILTER_CONDITION_UNSPECIFIED
START_TIME_BEFORE_INCLUSIVE
START_TIME_BEFORE_EXCLUSIVE
START_TIME_AFTER_INCLUSIVE
START_TIME_AFTER_EXCLUSIVE
END_TIME_BEFORE_INCLUSIVE
END_TIME_BEFORE_EXCLUSIVE
END_TIME_AFTER_INCLUSIVE
END_TIME_AFTER_EXCLUSIVE
assetstring
assetsAssetsFilter
Fields of
AssetsFilteroperatorSetOperator
Values of
SetOperatorSET_OPERATOR_UNSPECIFIED
AND
OR
assetsarray of string
templatestring
workbookstring
dataReviewstring
dataReviewsDataReviewsFilter
Fields of
DataReviewsFilterdataReviewsarray of string
originTypeSearchEventOriginType
Values of
SearchEventOriginTypeSEARCH_EVENT_ORIGIN_TYPE_UNSPECIFIED
WORKBOOK
TEMPLATE
API
DATA_REVIEW
PROCEDURE
STREAMING_CHECKLIST
originTypesOriginTypesFilter
Fields of
OriginTypesFilteroperatorSetOperator
originTypesarray ofSearchEventOriginType
dataReviewCheckstring
dataReviewChecksDataReviewChecksFilter
Fields of
DataReviewChecksFilterdataReviewChecksarray of string
dispositionStatusEventDispositionStatus
Values of
EventDispositionStatusEVENT_DISPOSITION_STATUS_UNSPECIFIED
PENDING_REVIEW
CLOSED_IGNORED
CLOSED_REQUIRES_FURTHER_ACTION
NO_DISPOSITION
dispositionStatusesEventDispositionStatusList
Fields of
EventDispositionStatusListvaluesarray ofEventDispositionStatus
priorityPriority
Values of
PriorityPRIORITY_UNSPECIFIED
P0
P1
P2
P3
P4
prioritiesPriorityList
Fields of
PriorityListvaluesarray ofPriority
assigneestring
assigneesAssigneesFilter
Fields of
AssigneesFilteroperatorSetOperator
assigneesarray of string
eventTypeEventType
Values of
EventTypeEVENT_TYPE_UNSPECIFIED
INFO
FLAG
ERROR
SUCCESS
eventTypesEventTypeList
Fields of
EventTypeListvaluesarray ofEventType
createdBystring
createdByAnyOfUserRidList
Fields of
UserRidListvaluesarray of string
labelstring
labelsLabelsFilter
Fields of
LabelsFilteroperatorSetOperator
labelsarray of string
propertyProperty
Fields of
Propertynamestring
valuestring
propertiesPropertiesFilter
Fields of
PropertiesFilternamestring
valuesarray of string
andSearchQueryList
Fields of
SearchQueryListqueriesarray ofSearchQuery
orSearchQueryList
notSearchQuery
workspacestring
procedurestring
procedureExecutionstring
stepIdstring
streamingCheckliststringFilters to events created from a checklist executing in streaming.
streamingCheckstringFilters to events created from the check of a checklist executing in streaming.
numericPropertyNumericPropertyPredicateMatches events using a numeric property comparison.
Fields of
NumericPropertyPredicatenamestring
valuenumber
operatorPropertyComparisonOperator
Values of
PropertyComparisonOperatorPROPERTY_COMPARISON_OPERATOR_UNSPECIFIED
EQ
NEQ
GT
GTE
LT
LTE
numericPropertyRangeNumericPropertyRangePredicateMatches events using an inclusive numeric property range.
Fields of
NumericPropertyRangePredicatenamestring
minnumber
maxnumber
operatorNumericPropertyRangeOperator
Values of
NumericPropertyRangeOperatorNUMERIC_PROPERTY_RANGE_OPERATOR_UNSPECIFIED
BETWEEN
NOT_BETWEEN
Response
eventsarray ofEvent
Fields of
Eventuuidstring
ridstring
assetRidsarray of stringA set of asset rids associated with the event.
originsarray ofEventOriginA set of origins associated with the event.
Fields of
EventOrigin- one of 6 fields
workbookWorkbookEventOriginThis event was created in this workbook.
Fields of
WorkbookEventOriginridstring
dataarray ofWorkbookDataAssociationData visualizations to associate this event with.
Fields of
WorkbookDataAssociationtimeSeriesChannelTimeSeriesChannelAssociation
Fields of
TimeSeriesChannelAssociationvariableNamestring
tagsmap of string to stringIf this variable is grouped, the tags within the groupings this event should associate with.
templateTemplateEventOriginThis event was created in this template.
Fields of
TemplateEventOriginridstring
apiApiEventOriginThis event was created programmatically via the API.
dataReviewDataReviewEventOriginThis event was created automatically from a checklist execution.
Fields of
DataReviewEventOrigindataReviewRidstring
checkMetadataCheckOriginMetadataMetadata about the check that created this event.
Fields of
CheckOriginMetadatacheckEvaluationRidstring
checkRidstring
checkLineageRidstring
implementationIndexinteger
procedureProcedureEventOriginThis event was created automatically from a procedure execution.
Fields of
ProcedureEventOriginprocedureExecutionRidstring
procedureRidstring
stepIdstring
streamingChecklistStreamingChecklistEventOriginThis event was created automatically from the execution of a streaming checklist.
Fields of
StreamingChecklistEventOriginchecklistRidstring
checkMetadataStreamingCheckOriginMetadataMetadata about the check that created this event.
Fields of
StreamingCheckOriginMetadatacheckRidstring
checkLineageRidstring
implementationIndexinteger
timestampTimestamp
Fields of
Timestampsecondsstring (int64)
nanosstring (int64)
durationDuration
Fields of
Durationsecondsstring (int64)
nanosstring (int64)
namestring
descriptionstring
typeEventType
Values of
EventTypeEVENT_TYPE_UNSPECIFIED
INFO
FLAG
ERROR
SUCCESS
labelsarray of string
propertiesmap of string to string deprecated
isArchivedboolean
createdBystringThe user who created the event. This field may be missing for legacy events.
dispositionEventDisposition
Fields of
EventDispositionpriorityPriority
Values of
PriorityPRIORITY_UNSPECIFIED
P0
P1
P2
P3
P4
stateDispositionState
Fields of
DispositionState- one of
pendingReview,closedWithFurtherAction,closedWithIgnore
pendingReviewPendingReviewDispositionState
Fields of
PendingReviewDispositionStateopenedBystring
closedWithFurtherActionClosedWithFurtherActionDispositionState
Fields of
ClosedWithFurtherActionDispositionStateclosedBystring
closedWithIgnoreClosedWithIgnoreDispositionState
Fields of
ClosedWithIgnoreDispositionStateclosedBystring
- one of
assigneesarray of string
typedPropertiesmap of string toTypedPropertyValue
Fields of
TypedPropertyValue- one of
stringValue,numericValue
stringValuestring
numericValuenumber
- one of
Request
curl -X POST "https://api.gov.nominal.io/api/event/v2/events/batch-filter-get" \
-H "Authorization: Bearer <api key>" \
-H "Content-Type: application/json" \
--data '{
"eventRids": [
"<event rids>"
],
"filterQuery": {
"archived": true
}
}'
import requests
response = requests.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-filter-get",
headers={"Authorization": "Bearer <api key>"},
json={"eventRids": ["<event rids>"], "filterQuery": {"archived": True}},
)
response.raise_for_status()
print(response.json())
import httpx
response = httpx.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-filter-get",
headers={"Authorization": "Bearer <api key>"},
json={"eventRids": ["<event rids>"], "filterQuery": {"archived": True}},
)
response.raise_for_status()
print(response.json())
import asyncio
import aiohttp
async def main() -> None:
async with aiohttp.ClientSession() as session:
async with session.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-filter-get",
headers={"Authorization": "Bearer <api key>"},
json={"eventRids": ["<event rids>"], "filterQuery": {"archived": True}},
) as response:
response.raise_for_status()
print(await response.json())
asyncio.run(main())
Response: 200
{
"events": [
{
"uuid": "<uuid>",
"rid": "<rid>",
"assetRids": [
"<asset rids>"
],
"origins": [
{
"workbook": {
"rid": "<rid>",
"data": [
{
"timeSeriesChannel": {
"variableName": "<variable name>",
"tags": {
"<key>": "<value>"
}
}
}
]
}
}
],
"timestamp": {
"seconds": "1",
"nanos": "1"
},
"duration": {
"seconds": "1",
"nanos": "1"
},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": [
"<labels>"
],
"properties": {
"<key>": "<value>"
},
"isArchived": true,
"createdBy": "<created by>",
"disposition": {
"priority": "P0",
"state": {
"pendingReview": {
"openedBy": "<opened by>"
}
},
"assignees": [
"<assignees>"
]
},
"typedProperties": {
"<key>": {
"stringValue": "<string value>"
}
}
}
]
}
Batch find events#
POST /event/v2/events/batch-find
Finds, for each batched query, the single event at the query’s index among events matching the shared base query within the query’s asset and time-window constraints. Returns one result per query in the same order.
Best-effort under permission filtering: each query fetches index + 1 candidate rows and then removes events the caller cannot view, so when hidden events fall inside those candidates a query may report no event even though a later visible match exists.
Body
querySearchQueryThe base query every batched find matches against, combined with each query’s asset and window constraints.
Fields of
SearchQuery- one of 41 fields
archivedboolean
searchTextstringSearch text to perform fuzzy searching against.
exactMatchstringSearch text to perform exact matching against on the event name and description.
afterTimestampFilters to events after this timestamp, exclusive.
Fields of
Timestampsecondsstring (int64)
nanosstring (int64)
beforeTimestampFilters to events before this timestamp, exclusive.
advancedTimeFilterEventTimeFilter
Fields of
EventTimeFiltertimestampTimestamp
timestampConditionEventTimeFilterCondition
Values of
EventTimeFilterConditionEVENT_TIME_FILTER_CONDITION_UNSPECIFIED
START_TIME_BEFORE_INCLUSIVE
START_TIME_BEFORE_EXCLUSIVE
START_TIME_AFTER_INCLUSIVE
START_TIME_AFTER_EXCLUSIVE
END_TIME_BEFORE_INCLUSIVE
END_TIME_BEFORE_EXCLUSIVE
END_TIME_AFTER_INCLUSIVE
END_TIME_AFTER_EXCLUSIVE
assetstring
assetsAssetsFilter
Fields of
AssetsFilteroperatorSetOperator
Values of
SetOperatorSET_OPERATOR_UNSPECIFIED
AND
OR
assetsarray of string
templatestring
workbookstring
dataReviewstring
dataReviewsDataReviewsFilter
Fields of
DataReviewsFilterdataReviewsarray of string
originTypeSearchEventOriginType
Values of
SearchEventOriginTypeSEARCH_EVENT_ORIGIN_TYPE_UNSPECIFIED
WORKBOOK
TEMPLATE
API
DATA_REVIEW
PROCEDURE
STREAMING_CHECKLIST
originTypesOriginTypesFilter
Fields of
OriginTypesFilteroperatorSetOperator
originTypesarray ofSearchEventOriginType
dataReviewCheckstring
dataReviewChecksDataReviewChecksFilter
Fields of
DataReviewChecksFilterdataReviewChecksarray of string
dispositionStatusEventDispositionStatus
Values of
EventDispositionStatusEVENT_DISPOSITION_STATUS_UNSPECIFIED
PENDING_REVIEW
CLOSED_IGNORED
CLOSED_REQUIRES_FURTHER_ACTION
NO_DISPOSITION
dispositionStatusesEventDispositionStatusList
Fields of
EventDispositionStatusListvaluesarray ofEventDispositionStatus
priorityPriority
Values of
PriorityPRIORITY_UNSPECIFIED
P0
P1
P2
P3
P4
prioritiesPriorityList
Fields of
PriorityListvaluesarray ofPriority
assigneestring
assigneesAssigneesFilter
Fields of
AssigneesFilteroperatorSetOperator
assigneesarray of string
eventTypeEventType
Values of
EventTypeEVENT_TYPE_UNSPECIFIED
INFO
FLAG
ERROR
SUCCESS
eventTypesEventTypeList
Fields of
EventTypeListvaluesarray ofEventType
createdBystring
createdByAnyOfUserRidList
Fields of
UserRidListvaluesarray of string
labelstring
labelsLabelsFilter
Fields of
LabelsFilteroperatorSetOperator
labelsarray of string
propertyProperty
Fields of
Propertynamestring
valuestring
propertiesPropertiesFilter
Fields of
PropertiesFilternamestring
valuesarray of string
andSearchQueryList
Fields of
SearchQueryListqueriesarray ofSearchQuery
orSearchQueryList
notSearchQuery
workspacestring
procedurestring
procedureExecutionstring
stepIdstring
streamingCheckliststringFilters to events created from a checklist executing in streaming.
streamingCheckstringFilters to events created from the check of a checklist executing in streaming.
numericPropertyNumericPropertyPredicateMatches events using a numeric property comparison.
Fields of
NumericPropertyPredicatenamestring
valuenumber
operatorPropertyComparisonOperator
Values of
PropertyComparisonOperatorPROPERTY_COMPARISON_OPERATOR_UNSPECIFIED
EQ
NEQ
GT
GTE
LT
LTE
numericPropertyRangeNumericPropertyRangePredicateMatches events using an inclusive numeric property range.
Fields of
NumericPropertyRangePredicatenamestring
minnumber
maxnumber
operatorNumericPropertyRangeOperator
Values of
NumericPropertyRangeOperatorNUMERIC_PROPERTY_RANGE_OPERATOR_UNSPECIFIED
BETWEEN
NOT_BETWEEN
sortSortOptions
Fields of
SortOptionsisDescendingboolean
fieldSortField
Values of
SortFieldSORT_FIELD_UNSPECIFIED
START_TIME
END_TIME
DURATION
DISPOSITION_STATUS
PRIORITY
EVENT_NAME
queriesarray ofFindEventsQueryRejects batches with more than 1k queries.
Fields of
FindEventsQueryassetRidsarray of stringWhen non-empty, only events associated with at least one of these assets match. When empty, events match on the time window alone.
startInclusiveTimestampHalf-open window [start_inclusive, end_exclusive) over event start times. An absent bound leaves that side of the window open.
endExclusiveTimestamp
indexintegerZero-based rank of the event to return after applying the request sort and permission filtering. Must be non-negative. When permission filtering hides events within the first index matches, the result may be absent even though later matches exist.
Response
resultsarray ofFindEventsResultOne result per request query, in the same order.
Fields of
FindEventsResulteventEventAbsent when no event matches the query at the requested index.
Fields of
Eventuuidstring
ridstring
assetRidsarray of stringA set of asset rids associated with the event.
originsarray ofEventOriginA set of origins associated with the event.
Fields of
EventOrigin- one of 6 fields
workbookWorkbookEventOriginThis event was created in this workbook.
Fields of
WorkbookEventOriginridstring
dataarray ofWorkbookDataAssociationData visualizations to associate this event with.
Fields of
WorkbookDataAssociationtimeSeriesChannelTimeSeriesChannelAssociation
Fields of
TimeSeriesChannelAssociationvariableNamestring
tagsmap of string to stringIf this variable is grouped, the tags within the groupings this event should associate with.
templateTemplateEventOriginThis event was created in this template.
Fields of
TemplateEventOriginridstring
apiApiEventOriginThis event was created programmatically via the API.
dataReviewDataReviewEventOriginThis event was created automatically from a checklist execution.
Fields of
DataReviewEventOrigindataReviewRidstring
checkMetadataCheckOriginMetadataMetadata about the check that created this event.
Fields of
CheckOriginMetadatacheckEvaluationRidstring
checkRidstring
checkLineageRidstring
implementationIndexinteger
procedureProcedureEventOriginThis event was created automatically from a procedure execution.
Fields of
ProcedureEventOriginprocedureExecutionRidstring
procedureRidstring
stepIdstring
streamingChecklistStreamingChecklistEventOriginThis event was created automatically from the execution of a streaming checklist.
Fields of
StreamingChecklistEventOriginchecklistRidstring
checkMetadataStreamingCheckOriginMetadataMetadata about the check that created this event.
Fields of
StreamingCheckOriginMetadatacheckRidstring
checkLineageRidstring
implementationIndexinteger
timestampTimestamp
Fields of
Timestampsecondsstring (int64)
nanosstring (int64)
durationDuration
Fields of
Durationsecondsstring (int64)
nanosstring (int64)
namestring
descriptionstring
typeEventType
Values of
EventTypeEVENT_TYPE_UNSPECIFIED
INFO
FLAG
ERROR
SUCCESS
labelsarray of string
propertiesmap of string to string deprecated
isArchivedboolean
createdBystringThe user who created the event. This field may be missing for legacy events.
dispositionEventDisposition
Fields of
EventDispositionpriorityPriority
Values of
PriorityPRIORITY_UNSPECIFIED
P0
P1
P2
P3
P4
stateDispositionState
Fields of
DispositionState- one of
pendingReview,closedWithFurtherAction,closedWithIgnore
pendingReviewPendingReviewDispositionState
Fields of
PendingReviewDispositionStateopenedBystring
closedWithFurtherActionClosedWithFurtherActionDispositionState
Fields of
ClosedWithFurtherActionDispositionStateclosedBystring
closedWithIgnoreClosedWithIgnoreDispositionState
Fields of
ClosedWithIgnoreDispositionStateclosedBystring
- one of
assigneesarray of string
typedPropertiesmap of string toTypedPropertyValue
Fields of
TypedPropertyValue- one of
stringValue,numericValue
stringValuestring
numericValuenumber
- one of
Request
curl -X POST "https://api.gov.nominal.io/api/event/v2/events/batch-find" \
-H "Authorization: Bearer <api key>" \
-H "Content-Type: application/json" \
--data '{
"query": {
"archived": true
},
"sort": {
"isDescending": true,
"field": "START_TIME"
},
"queries": [
{
"assetRids": [
"<asset rids>"
],
"startInclusive": {
"seconds": "1",
"nanos": "1"
},
"endExclusive": {
"seconds": "1",
"nanos": "1"
},
"index": 1
}
]
}'
import requests
response = requests.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-find",
headers={"Authorization": "Bearer <api key>"},
json={
"query": {"archived": True},
"sort": {"isDescending": True, "field": "START_TIME"},
"queries": [
{
"assetRids": ["<asset rids>"],
"startInclusive": {"seconds": "1", "nanos": "1"},
"endExclusive": {"seconds": "1", "nanos": "1"},
"index": 1,
},
],
},
)
response.raise_for_status()
print(response.json())
import httpx
response = httpx.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-find",
headers={"Authorization": "Bearer <api key>"},
json={
"query": {"archived": True},
"sort": {"isDescending": True, "field": "START_TIME"},
"queries": [
{
"assetRids": ["<asset rids>"],
"startInclusive": {"seconds": "1", "nanos": "1"},
"endExclusive": {"seconds": "1", "nanos": "1"},
"index": 1,
},
],
},
)
response.raise_for_status()
print(response.json())
import asyncio
import aiohttp
async def main() -> None:
async with aiohttp.ClientSession() as session:
async with session.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-find",
headers={"Authorization": "Bearer <api key>"},
json={
"query": {"archived": True},
"sort": {"isDescending": True, "field": "START_TIME"},
"queries": [
{
"assetRids": ["<asset rids>"],
"startInclusive": {"seconds": "1", "nanos": "1"},
"endExclusive": {"seconds": "1", "nanos": "1"},
"index": 1,
},
],
},
) as response:
response.raise_for_status()
print(await response.json())
asyncio.run(main())
Response: 200
{
"results": [
{
"event": {
"uuid": "<uuid>",
"rid": "<rid>",
"assetRids": [
"<asset rids>"
],
"origins": [
{
"workbook": {
"rid": "<rid>",
"data": [
{
"timeSeriesChannel": {
"variableName": "<variable name>",
"tags": {
"<key>": "<value>"
}
}
}
]
}
}
],
"timestamp": {
"seconds": "1",
"nanos": "1"
},
"duration": {
"seconds": "1",
"nanos": "1"
},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": [
"<labels>"
],
"properties": {
"<key>": "<value>"
},
"isArchived": true,
"createdBy": "<created by>",
"disposition": {
"priority": "P0",
"state": {
"pendingReview": {
"openedBy": "<opened by>"
}
},
"assignees": [
"<assignees>"
]
},
"typedProperties": {
"<key>": {
"stringValue": "<string value>"
}
}
}
}
]
}
Batch get events#
POST /event/v2/events/batch-get
Gets a set of events by RID.
Body
eventRidsarray of string
Response
eventsarray ofEvent
Fields of
Eventuuidstring
ridstring
assetRidsarray of stringA set of asset rids associated with the event.
originsarray ofEventOriginA set of origins associated with the event.
Fields of
EventOrigin- one of 6 fields
workbookWorkbookEventOriginThis event was created in this workbook.
Fields of
WorkbookEventOriginridstring
dataarray ofWorkbookDataAssociationData visualizations to associate this event with.
Fields of
WorkbookDataAssociationtimeSeriesChannelTimeSeriesChannelAssociation
Fields of
TimeSeriesChannelAssociationvariableNamestring
tagsmap of string to stringIf this variable is grouped, the tags within the groupings this event should associate with.
templateTemplateEventOriginThis event was created in this template.
Fields of
TemplateEventOriginridstring
apiApiEventOriginThis event was created programmatically via the API.
dataReviewDataReviewEventOriginThis event was created automatically from a checklist execution.
Fields of
DataReviewEventOrigindataReviewRidstring
checkMetadataCheckOriginMetadataMetadata about the check that created this event.
Fields of
CheckOriginMetadatacheckEvaluationRidstring
checkRidstring
checkLineageRidstring
implementationIndexinteger
procedureProcedureEventOriginThis event was created automatically from a procedure execution.
Fields of
ProcedureEventOriginprocedureExecutionRidstring
procedureRidstring
stepIdstring
streamingChecklistStreamingChecklistEventOriginThis event was created automatically from the execution of a streaming checklist.
Fields of
StreamingChecklistEventOriginchecklistRidstring
checkMetadataStreamingCheckOriginMetadataMetadata about the check that created this event.
Fields of
StreamingCheckOriginMetadatacheckRidstring
checkLineageRidstring
implementationIndexinteger
timestampTimestamp
Fields of
Timestampsecondsstring (int64)
nanosstring (int64)
durationDuration
Fields of
Durationsecondsstring (int64)
nanosstring (int64)
namestring
descriptionstring
typeEventType
Values of
EventTypeEVENT_TYPE_UNSPECIFIED
INFO
FLAG
ERROR
SUCCESS
labelsarray of string
propertiesmap of string to string deprecated
isArchivedboolean
createdBystringThe user who created the event. This field may be missing for legacy events.
dispositionEventDisposition
Fields of
EventDispositionpriorityPriority
Values of
PriorityPRIORITY_UNSPECIFIED
P0
P1
P2
P3
P4
stateDispositionState
Fields of
DispositionState- one of
pendingReview,closedWithFurtherAction,closedWithIgnore
pendingReviewPendingReviewDispositionState
Fields of
PendingReviewDispositionStateopenedBystring
closedWithFurtherActionClosedWithFurtherActionDispositionState
Fields of
ClosedWithFurtherActionDispositionStateclosedBystring
closedWithIgnoreClosedWithIgnoreDispositionState
Fields of
ClosedWithIgnoreDispositionStateclosedBystring
- one of
assigneesarray of string
typedPropertiesmap of string toTypedPropertyValue
Fields of
TypedPropertyValue- one of
stringValue,numericValue
stringValuestring
numericValuenumber
- one of
Request
curl -X POST "https://api.gov.nominal.io/api/event/v2/events/batch-get" \
-H "Authorization: Bearer <api key>" \
-H "Content-Type: application/json" \
--data '{
"eventRids": [
"<event rids>"
]
}'
import requests
response = requests.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-get",
headers={"Authorization": "Bearer <api key>"},
json={"eventRids": ["<event rids>"]},
)
response.raise_for_status()
print(response.json())
import httpx
response = httpx.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-get",
headers={"Authorization": "Bearer <api key>"},
json={"eventRids": ["<event rids>"]},
)
response.raise_for_status()
print(response.json())
import asyncio
import aiohttp
async def main() -> None:
async with aiohttp.ClientSession() as session:
async with session.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-get",
headers={"Authorization": "Bearer <api key>"},
json={"eventRids": ["<event rids>"]},
) as response:
response.raise_for_status()
print(await response.json())
asyncio.run(main())
Response: 200
{
"events": [
{
"uuid": "<uuid>",
"rid": "<rid>",
"assetRids": [
"<asset rids>"
],
"origins": [
{
"workbook": {
"rid": "<rid>",
"data": [
{
"timeSeriesChannel": {
"variableName": "<variable name>",
"tags": {
"<key>": "<value>"
}
}
}
]
}
}
],
"timestamp": {
"seconds": "1",
"nanos": "1"
},
"duration": {
"seconds": "1",
"nanos": "1"
},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": [
"<labels>"
],
"properties": {
"<key>": "<value>"
},
"isArchived": true,
"createdBy": "<created by>",
"disposition": {
"priority": "P0",
"state": {
"pendingReview": {
"openedBy": "<opened by>"
}
},
"assignees": [
"<assignees>"
]
},
"typedProperties": {
"<key>": {
"stringValue": "<string value>"
}
}
}
]
}
Batch unarchive event#
POST /event/v2/events/batch-unarchive
Unarchives a set of events.
Body
eventRidsarray of string
Response
An empty JSON object, {}.
Request
curl -X POST "https://api.gov.nominal.io/api/event/v2/events/batch-unarchive" \
-H "Authorization: Bearer <api key>" \
-H "Content-Type: application/json" \
--data '{
"eventRids": [
"<event rids>"
]
}'
import requests
response = requests.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-unarchive",
headers={"Authorization": "Bearer <api key>"},
json={"eventRids": ["<event rids>"]},
)
response.raise_for_status()
print(response.json())
import httpx
response = httpx.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-unarchive",
headers={"Authorization": "Bearer <api key>"},
json={"eventRids": ["<event rids>"]},
)
response.raise_for_status()
print(response.json())
import asyncio
import aiohttp
async def main() -> None:
async with aiohttp.ClientSession() as session:
async with session.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-unarchive",
headers={"Authorization": "Bearer <api key>"},
json={"eventRids": ["<event rids>"]},
) as response:
response.raise_for_status()
print(await response.json())
asyncio.run(main())
Response: 200
{}
Batch update event#
POST /event/v2/events/batch-update
Updates the fields of an event specified by each request in the batch. Empty fields are left unchanged.
Body
updatesarray ofEventUpdate
Fields of
EventUpdateridstring
assetRidsAssetRidSetIf provided, replaces the existing asset rids. If provided, must contain at least one asset rid.
Fields of
AssetRidSetassetRidsarray of string
timestampTimestamp
Fields of
Timestampsecondsstring (int64)
nanosstring (int64)
durationDuration
Fields of
Durationsecondsstring (int64)
nanosstring (int64)
namestring
descriptionstring
typeEventType
Values of
EventTypeEVENT_TYPE_UNSPECIFIED
INFO
FLAG
ERROR
SUCCESS
labelsLabelUpdateWrapper
Fields of
LabelUpdateWrapperlabelsarray of string
propertiesPropertyUpdateWrapperdeprecated
Fields of
PropertyUpdateWrapperpropertiesmap of string to string
typedPropertiesTypedPropertyUpdateWrapper
Fields of
TypedPropertyUpdateWrappertypedPropertiesmap of string toTypedPropertyValue
Fields of
TypedPropertyValue- one of
stringValue,numericValuerequired
stringValuestring
numericValuenumber
- one of
Response
eventsarray ofEvent
Fields of
Eventuuidstring
ridstring
assetRidsarray of stringA set of asset rids associated with the event.
originsarray ofEventOriginA set of origins associated with the event.
Fields of
EventOrigin- one of 6 fields
workbookWorkbookEventOriginThis event was created in this workbook.
Fields of
WorkbookEventOriginridstring
dataarray ofWorkbookDataAssociationData visualizations to associate this event with.
Fields of
WorkbookDataAssociationtimeSeriesChannelTimeSeriesChannelAssociation
Fields of
TimeSeriesChannelAssociationvariableNamestring
tagsmap of string to stringIf this variable is grouped, the tags within the groupings this event should associate with.
templateTemplateEventOriginThis event was created in this template.
Fields of
TemplateEventOriginridstring
apiApiEventOriginThis event was created programmatically via the API.
dataReviewDataReviewEventOriginThis event was created automatically from a checklist execution.
Fields of
DataReviewEventOrigindataReviewRidstring
checkMetadataCheckOriginMetadataMetadata about the check that created this event.
Fields of
CheckOriginMetadatacheckEvaluationRidstring
checkRidstring
checkLineageRidstring
implementationIndexinteger
procedureProcedureEventOriginThis event was created automatically from a procedure execution.
Fields of
ProcedureEventOriginprocedureExecutionRidstring
procedureRidstring
stepIdstring
streamingChecklistStreamingChecklistEventOriginThis event was created automatically from the execution of a streaming checklist.
Fields of
StreamingChecklistEventOriginchecklistRidstring
checkMetadataStreamingCheckOriginMetadataMetadata about the check that created this event.
Fields of
StreamingCheckOriginMetadatacheckRidstring
checkLineageRidstring
implementationIndexinteger
timestampTimestamp
Fields of
Timestampsecondsstring (int64)
nanosstring (int64)
durationDuration
Fields of
Durationsecondsstring (int64)
nanosstring (int64)
namestring
descriptionstring
typeEventType
Values of
EventTypeEVENT_TYPE_UNSPECIFIED
INFO
FLAG
ERROR
SUCCESS
labelsarray of string
propertiesmap of string to string deprecated
isArchivedboolean
createdBystringThe user who created the event. This field may be missing for legacy events.
dispositionEventDisposition
Fields of
EventDispositionpriorityPriority
Values of
PriorityPRIORITY_UNSPECIFIED
P0
P1
P2
P3
P4
stateDispositionState
Fields of
DispositionState- one of
pendingReview,closedWithFurtherAction,closedWithIgnore
pendingReviewPendingReviewDispositionState
Fields of
PendingReviewDispositionStateopenedBystring
closedWithFurtherActionClosedWithFurtherActionDispositionState
Fields of
ClosedWithFurtherActionDispositionStateclosedBystring
closedWithIgnoreClosedWithIgnoreDispositionState
Fields of
ClosedWithIgnoreDispositionStateclosedBystring
- one of
assigneesarray of string
typedPropertiesmap of string toTypedPropertyValue
Fields of
TypedPropertyValue- one of
stringValue,numericValue
stringValuestring
numericValuenumber
- one of
Request
curl -X POST "https://api.gov.nominal.io/api/event/v2/events/batch-update" \
-H "Authorization: Bearer <api key>" \
-H "Content-Type: application/json" \
--data '{
"updates": [
{
"rid": "<rid>",
"assetRids": {
"assetRids": [
"<asset rids>"
]
},
"timestamp": {
"seconds": "1",
"nanos": "1"
},
"duration": {
"seconds": "1",
"nanos": "1"
},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": {
"labels": [
"<labels>"
]
},
"properties": {
"properties": {
"<key>": "<value>"
}
},
"typedProperties": {
"typedProperties": {
"<key>": {
"stringValue": "<string value>"
}
}
}
}
]
}'
import requests
response = requests.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-update",
headers={"Authorization": "Bearer <api key>"},
json={
"updates": [
{
"rid": "<rid>",
"assetRids": {"assetRids": ["<asset rids>"]},
"timestamp": {"seconds": "1", "nanos": "1"},
"duration": {"seconds": "1", "nanos": "1"},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": {"labels": ["<labels>"]},
"properties": {"properties": {"<key>": "<value>"}},
"typedProperties": {
"typedProperties": {"<key>": {"stringValue": "<string value>"}},
},
},
],
},
)
response.raise_for_status()
print(response.json())
import httpx
response = httpx.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-update",
headers={"Authorization": "Bearer <api key>"},
json={
"updates": [
{
"rid": "<rid>",
"assetRids": {"assetRids": ["<asset rids>"]},
"timestamp": {"seconds": "1", "nanos": "1"},
"duration": {"seconds": "1", "nanos": "1"},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": {"labels": ["<labels>"]},
"properties": {"properties": {"<key>": "<value>"}},
"typedProperties": {
"typedProperties": {"<key>": {"stringValue": "<string value>"}},
},
},
],
},
)
response.raise_for_status()
print(response.json())
import asyncio
import aiohttp
async def main() -> None:
async with aiohttp.ClientSession() as session:
async with session.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-update",
headers={"Authorization": "Bearer <api key>"},
json={
"updates": [
{
"rid": "<rid>",
"assetRids": {"assetRids": ["<asset rids>"]},
"timestamp": {"seconds": "1", "nanos": "1"},
"duration": {"seconds": "1", "nanos": "1"},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": {"labels": ["<labels>"]},
"properties": {"properties": {"<key>": "<value>"}},
"typedProperties": {
"typedProperties": {
"<key>": {"stringValue": "<string value>"},
},
},
},
],
},
) as response:
response.raise_for_status()
print(await response.json())
asyncio.run(main())
Response: 200
{
"events": [
{
"uuid": "<uuid>",
"rid": "<rid>",
"assetRids": [
"<asset rids>"
],
"origins": [
{
"workbook": {
"rid": "<rid>",
"data": [
{
"timeSeriesChannel": {
"variableName": "<variable name>",
"tags": {
"<key>": "<value>"
}
}
}
]
}
}
],
"timestamp": {
"seconds": "1",
"nanos": "1"
},
"duration": {
"seconds": "1",
"nanos": "1"
},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": [
"<labels>"
],
"properties": {
"<key>": "<value>"
},
"isArchived": true,
"createdBy": "<created by>",
"disposition": {
"priority": "P0",
"state": {
"pendingReview": {
"openedBy": "<opened by>"
}
},
"assignees": [
"<assignees>"
]
},
"typedProperties": {
"<key>": {
"stringValue": "<string value>"
}
}
}
]
}
Batch update disposition#
POST /event/v2/events/batch-update-disposition
Updates the disposition of a set of events.
Body
requestsarray ofUpdateDispositionRequest
Fields of
UpdateDispositionRequestridstring
dispositionEventDispositionThe new disposition for the event. If empty, removes the disposition from the event.
Fields of
EventDispositionpriorityPriority
Values of
PriorityPRIORITY_UNSPECIFIED
P0
P1
P2
P3
P4
stateDispositionState
Fields of
DispositionState- one of
pendingReview,closedWithFurtherAction,closedWithIgnore
pendingReviewPendingReviewDispositionState
Fields of
PendingReviewDispositionStateopenedBystring
closedWithFurtherActionClosedWithFurtherActionDispositionState
Fields of
ClosedWithFurtherActionDispositionStateclosedBystring
closedWithIgnoreClosedWithIgnoreDispositionState
Fields of
ClosedWithIgnoreDispositionStateclosedBystring
- one of
assigneesarray of string
Response
eventsarray ofEvent
Fields of
Eventuuidstring
ridstring
assetRidsarray of stringA set of asset rids associated with the event.
originsarray ofEventOriginA set of origins associated with the event.
Fields of
EventOrigin- one of 6 fields
workbookWorkbookEventOriginThis event was created in this workbook.
Fields of
WorkbookEventOriginridstring
dataarray ofWorkbookDataAssociationData visualizations to associate this event with.
Fields of
WorkbookDataAssociationtimeSeriesChannelTimeSeriesChannelAssociation
Fields of
TimeSeriesChannelAssociationvariableNamestring
tagsmap of string to stringIf this variable is grouped, the tags within the groupings this event should associate with.
templateTemplateEventOriginThis event was created in this template.
Fields of
TemplateEventOriginridstring
apiApiEventOriginThis event was created programmatically via the API.
dataReviewDataReviewEventOriginThis event was created automatically from a checklist execution.
Fields of
DataReviewEventOrigindataReviewRidstring
checkMetadataCheckOriginMetadataMetadata about the check that created this event.
Fields of
CheckOriginMetadatacheckEvaluationRidstring
checkRidstring
checkLineageRidstring
implementationIndexinteger
procedureProcedureEventOriginThis event was created automatically from a procedure execution.
Fields of
ProcedureEventOriginprocedureExecutionRidstring
procedureRidstring
stepIdstring
streamingChecklistStreamingChecklistEventOriginThis event was created automatically from the execution of a streaming checklist.
Fields of
StreamingChecklistEventOriginchecklistRidstring
checkMetadataStreamingCheckOriginMetadataMetadata about the check that created this event.
Fields of
StreamingCheckOriginMetadatacheckRidstring
checkLineageRidstring
implementationIndexinteger
timestampTimestamp
Fields of
Timestampsecondsstring (int64)
nanosstring (int64)
durationDuration
Fields of
Durationsecondsstring (int64)
nanosstring (int64)
namestring
descriptionstring
typeEventType
Values of
EventTypeEVENT_TYPE_UNSPECIFIED
INFO
FLAG
ERROR
SUCCESS
labelsarray of string
propertiesmap of string to string deprecated
isArchivedboolean
createdBystringThe user who created the event. This field may be missing for legacy events.
dispositionEventDisposition
Fields of
EventDispositionpriorityPriority
Values of
PriorityPRIORITY_UNSPECIFIED
P0
P1
P2
P3
P4
stateDispositionState
Fields of
DispositionState- one of
pendingReview,closedWithFurtherAction,closedWithIgnore
pendingReviewPendingReviewDispositionState
Fields of
PendingReviewDispositionStateopenedBystring
closedWithFurtherActionClosedWithFurtherActionDispositionState
Fields of
ClosedWithFurtherActionDispositionStateclosedBystring
closedWithIgnoreClosedWithIgnoreDispositionState
Fields of
ClosedWithIgnoreDispositionStateclosedBystring
- one of
assigneesarray of string
typedPropertiesmap of string toTypedPropertyValue
Fields of
TypedPropertyValue- one of
stringValue,numericValue
stringValuestring
numericValuenumber
- one of
Request
curl -X POST "https://api.gov.nominal.io/api/event/v2/events/batch-update-disposition" \
-H "Authorization: Bearer <api key>" \
-H "Content-Type: application/json" \
--data '{
"requests": [
{
"rid": "<rid>",
"disposition": {
"priority": "P0",
"state": {
"pendingReview": {
"openedBy": "<opened by>"
}
},
"assignees": [
"<assignees>"
]
}
}
]
}'
import requests
response = requests.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-update-disposition",
headers={"Authorization": "Bearer <api key>"},
json={
"requests": [
{
"rid": "<rid>",
"disposition": {
"priority": "P0",
"state": {"pendingReview": {"openedBy": "<opened by>"}},
"assignees": ["<assignees>"],
},
},
],
},
)
response.raise_for_status()
print(response.json())
import httpx
response = httpx.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-update-disposition",
headers={"Authorization": "Bearer <api key>"},
json={
"requests": [
{
"rid": "<rid>",
"disposition": {
"priority": "P0",
"state": {"pendingReview": {"openedBy": "<opened by>"}},
"assignees": ["<assignees>"],
},
},
],
},
)
response.raise_for_status()
print(response.json())
import asyncio
import aiohttp
async def main() -> None:
async with aiohttp.ClientSession() as session:
async with session.post(
"https://api.gov.nominal.io/api/event/v2/events/batch-update-disposition",
headers={"Authorization": "Bearer <api key>"},
json={
"requests": [
{
"rid": "<rid>",
"disposition": {
"priority": "P0",
"state": {"pendingReview": {"openedBy": "<opened by>"}},
"assignees": ["<assignees>"],
},
},
],
},
) as response:
response.raise_for_status()
print(await response.json())
asyncio.run(main())
Response: 200
{
"events": [
{
"uuid": "<uuid>",
"rid": "<rid>",
"assetRids": [
"<asset rids>"
],
"origins": [
{
"workbook": {
"rid": "<rid>",
"data": [
{
"timeSeriesChannel": {
"variableName": "<variable name>",
"tags": {
"<key>": "<value>"
}
}
}
]
}
}
],
"timestamp": {
"seconds": "1",
"nanos": "1"
},
"duration": {
"seconds": "1",
"nanos": "1"
},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": [
"<labels>"
],
"properties": {
"<key>": "<value>"
},
"isArchived": true,
"createdBy": "<created by>",
"disposition": {
"priority": "P0",
"state": {
"pendingReview": {
"openedBy": "<opened by>"
}
},
"assignees": [
"<assignees>"
]
},
"typedProperties": {
"<key>": {
"stringValue": "<string value>"
}
}
}
]
}
Get events#
POST /event/v2/events/get-by-uuids
Gets a set of events by UUIDs.
Body
uuidsarray of string
Response
eventsarray ofEvent
Fields of
Eventuuidstring
ridstring
assetRidsarray of stringA set of asset rids associated with the event.
originsarray ofEventOriginA set of origins associated with the event.
Fields of
EventOrigin- one of 6 fields
workbookWorkbookEventOriginThis event was created in this workbook.
Fields of
WorkbookEventOriginridstring
dataarray ofWorkbookDataAssociationData visualizations to associate this event with.
Fields of
WorkbookDataAssociationtimeSeriesChannelTimeSeriesChannelAssociation
Fields of
TimeSeriesChannelAssociationvariableNamestring
tagsmap of string to stringIf this variable is grouped, the tags within the groupings this event should associate with.
templateTemplateEventOriginThis event was created in this template.
Fields of
TemplateEventOriginridstring
apiApiEventOriginThis event was created programmatically via the API.
dataReviewDataReviewEventOriginThis event was created automatically from a checklist execution.
Fields of
DataReviewEventOrigindataReviewRidstring
checkMetadataCheckOriginMetadataMetadata about the check that created this event.
Fields of
CheckOriginMetadatacheckEvaluationRidstring
checkRidstring
checkLineageRidstring
implementationIndexinteger
procedureProcedureEventOriginThis event was created automatically from a procedure execution.
Fields of
ProcedureEventOriginprocedureExecutionRidstring
procedureRidstring
stepIdstring
streamingChecklistStreamingChecklistEventOriginThis event was created automatically from the execution of a streaming checklist.
Fields of
StreamingChecklistEventOriginchecklistRidstring
checkMetadataStreamingCheckOriginMetadataMetadata about the check that created this event.
Fields of
StreamingCheckOriginMetadatacheckRidstring
checkLineageRidstring
implementationIndexinteger
timestampTimestamp
Fields of
Timestampsecondsstring (int64)
nanosstring (int64)
durationDuration
Fields of
Durationsecondsstring (int64)
nanosstring (int64)
namestring
descriptionstring
typeEventType
Values of
EventTypeEVENT_TYPE_UNSPECIFIED
INFO
FLAG
ERROR
SUCCESS
labelsarray of string
propertiesmap of string to string deprecated
isArchivedboolean
createdBystringThe user who created the event. This field may be missing for legacy events.
dispositionEventDisposition
Fields of
EventDispositionpriorityPriority
Values of
PriorityPRIORITY_UNSPECIFIED
P0
P1
P2
P3
P4
stateDispositionState
Fields of
DispositionState- one of
pendingReview,closedWithFurtherAction,closedWithIgnore
pendingReviewPendingReviewDispositionState
Fields of
PendingReviewDispositionStateopenedBystring
closedWithFurtherActionClosedWithFurtherActionDispositionState
Fields of
ClosedWithFurtherActionDispositionStateclosedBystring
closedWithIgnoreClosedWithIgnoreDispositionState
Fields of
ClosedWithIgnoreDispositionStateclosedBystring
- one of
assigneesarray of string
typedPropertiesmap of string toTypedPropertyValue
Fields of
TypedPropertyValue- one of
stringValue,numericValue
stringValuestring
numericValuenumber
- one of
Request
curl -X POST "https://api.gov.nominal.io/api/event/v2/events/get-by-uuids" \
-H "Authorization: Bearer <api key>" \
-H "Content-Type: application/json" \
--data '{
"uuids": [
"<uuids>"
]
}'
import requests
response = requests.post(
"https://api.gov.nominal.io/api/event/v2/events/get-by-uuids",
headers={"Authorization": "Bearer <api key>"},
json={"uuids": ["<uuids>"]},
)
response.raise_for_status()
print(response.json())
import httpx
response = httpx.post(
"https://api.gov.nominal.io/api/event/v2/events/get-by-uuids",
headers={"Authorization": "Bearer <api key>"},
json={"uuids": ["<uuids>"]},
)
response.raise_for_status()
print(response.json())
import asyncio
import aiohttp
async def main() -> None:
async with aiohttp.ClientSession() as session:
async with session.post(
"https://api.gov.nominal.io/api/event/v2/events/get-by-uuids",
headers={"Authorization": "Bearer <api key>"},
json={"uuids": ["<uuids>"]},
) as response:
response.raise_for_status()
print(await response.json())
asyncio.run(main())
Response: 200
{
"events": [
{
"uuid": "<uuid>",
"rid": "<rid>",
"assetRids": [
"<asset rids>"
],
"origins": [
{
"workbook": {
"rid": "<rid>",
"data": [
{
"timeSeriesChannel": {
"variableName": "<variable name>",
"tags": {
"<key>": "<value>"
}
}
}
]
}
}
],
"timestamp": {
"seconds": "1",
"nanos": "1"
},
"duration": {
"seconds": "1",
"nanos": "1"
},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": [
"<labels>"
],
"properties": {
"<key>": "<value>"
},
"isArchived": true,
"createdBy": "<created by>",
"disposition": {
"priority": "P0",
"state": {
"pendingReview": {
"openedBy": "<opened by>"
}
},
"assignees": [
"<assignees>"
]
},
"typedProperties": {
"<key>": {
"stringValue": "<string value>"
}
}
}
]
}
Get events histogram#
POST /event/v2/events/histogram
Gets a histogram of events that match the given filters.
Body
startInclusiveTimestamp
Fields of
Timestampsecondsstring (int64)
nanosstring (int64)
endExclusiveTimestamp
filterQueryHistogramFilterQueryThe query to filter the events included in the histogram.
Fields of
HistogramFilterQuery- one of 21 fields
searchTextstring
assetstring
templatestring
workbookstring
dataReviewstring
originTypeSearchEventOriginType
Values of
SearchEventOriginTypeSEARCH_EVENT_ORIGIN_TYPE_UNSPECIFIED
WORKBOOK
TEMPLATE
API
DATA_REVIEW
PROCEDURE
STREAMING_CHECKLIST
dataReviewCheckstring
dispositionStatusEventDispositionStatus
Values of
EventDispositionStatusEVENT_DISPOSITION_STATUS_UNSPECIFIED
PENDING_REVIEW
CLOSED_IGNORED
CLOSED_REQUIRES_FURTHER_ACTION
NO_DISPOSITION
priorityPriority
Values of
PriorityPRIORITY_UNSPECIFIED
P0
P1
P2
P3
P4
assigneestring
eventTypeEventType
Values of
EventTypeEVENT_TYPE_UNSPECIFIED
INFO
FLAG
ERROR
SUCCESS
createdBystring
labelstring
propertyProperty
Fields of
Propertynamestring
valuestring
andHistogramFilterQueryList
Fields of
HistogramFilterQueryListqueriesarray ofHistogramFilterQuery
notHistogramFilterQuery
workspacestring
procedurestring
procedureExecutionstring
stepIdstring
archivedStatusesarray ofArchivedStatusIf empty, defaults to NOT_ARCHIVED only.
Values of
ArchivedStatusARCHIVED_STATUS_UNSPECIFIED
NOT_ARCHIVED
ARCHIVED
numBinsintegerDefaults to 100. Throws if larger than 1_000.
eventLimitintegerLimits the number of events included in the histogram. Defaults to 10_000. Throws if larger than 10_000.
Response
bucketsarray ofEventsHistogramBucket
Request
curl -X POST "https://api.gov.nominal.io/api/event/v2/events/histogram" \
-H "Authorization: Bearer <api key>" \
-H "Content-Type: application/json" \
--data '{
"startInclusive": {
"seconds": "1",
"nanos": "1"
},
"endExclusive": {
"seconds": "1",
"nanos": "1"
},
"filterQuery": {
"searchText": "<search text>"
},
"archivedStatuses": [
"NOT_ARCHIVED"
],
"numBins": 1,
"eventLimit": 1
}'
import requests
response = requests.post(
"https://api.gov.nominal.io/api/event/v2/events/histogram",
headers={"Authorization": "Bearer <api key>"},
json={
"startInclusive": {"seconds": "1", "nanos": "1"},
"endExclusive": {"seconds": "1", "nanos": "1"},
"filterQuery": {"searchText": "<search text>"},
"archivedStatuses": ["NOT_ARCHIVED"],
"numBins": 1,
"eventLimit": 1,
},
)
response.raise_for_status()
print(response.json())
import httpx
response = httpx.post(
"https://api.gov.nominal.io/api/event/v2/events/histogram",
headers={"Authorization": "Bearer <api key>"},
json={
"startInclusive": {"seconds": "1", "nanos": "1"},
"endExclusive": {"seconds": "1", "nanos": "1"},
"filterQuery": {"searchText": "<search text>"},
"archivedStatuses": ["NOT_ARCHIVED"],
"numBins": 1,
"eventLimit": 1,
},
)
response.raise_for_status()
print(response.json())
import asyncio
import aiohttp
async def main() -> None:
async with aiohttp.ClientSession() as session:
async with session.post(
"https://api.gov.nominal.io/api/event/v2/events/histogram",
headers={"Authorization": "Bearer <api key>"},
json={
"startInclusive": {"seconds": "1", "nanos": "1"},
"endExclusive": {"seconds": "1", "nanos": "1"},
"filterQuery": {"searchText": "<search text>"},
"archivedStatuses": ["NOT_ARCHIVED"],
"numBins": 1,
"eventLimit": 1,
},
) as response:
response.raise_for_status()
print(await response.json())
asyncio.run(main())
Response: 200
{
"buckets": [
{
"startInclusive": {
"seconds": "1",
"nanos": "1"
},
"endExclusive": {
"seconds": "1",
"nanos": "1"
},
"count": 1
}
]
}
Search events#
POST /event/v2/events/search
Searches for events that match the given filters.
Body
sortSortOptions
Fields of
SortOptionsisDescendingboolean
fieldSortField
Values of
SortFieldSORT_FIELD_UNSPECIFIED
START_TIME
END_TIME
DURATION
DISPOSITION_STATUS
PRIORITY
EVENT_NAME
pageSizeintegerRejects page sizes greater than 10k.
nextPageTokenstring
querySearchQuery
Fields of
SearchQuery- one of 41 fields
archivedboolean
searchTextstringSearch text to perform fuzzy searching against.
exactMatchstringSearch text to perform exact matching against on the event name and description.
afterTimestampFilters to events after this timestamp, exclusive.
Fields of
Timestampsecondsstring (int64)
nanosstring (int64)
beforeTimestampFilters to events before this timestamp, exclusive.
advancedTimeFilterEventTimeFilter
Fields of
EventTimeFiltertimestampTimestamp
timestampConditionEventTimeFilterCondition
Values of
EventTimeFilterConditionEVENT_TIME_FILTER_CONDITION_UNSPECIFIED
START_TIME_BEFORE_INCLUSIVE
START_TIME_BEFORE_EXCLUSIVE
START_TIME_AFTER_INCLUSIVE
START_TIME_AFTER_EXCLUSIVE
END_TIME_BEFORE_INCLUSIVE
END_TIME_BEFORE_EXCLUSIVE
END_TIME_AFTER_INCLUSIVE
END_TIME_AFTER_EXCLUSIVE
assetstring
assetsAssetsFilter
Fields of
AssetsFilteroperatorSetOperator
Values of
SetOperatorSET_OPERATOR_UNSPECIFIED
AND
OR
assetsarray of string
templatestring
workbookstring
dataReviewstring
dataReviewsDataReviewsFilter
Fields of
DataReviewsFilterdataReviewsarray of string
originTypeSearchEventOriginType
Values of
SearchEventOriginTypeSEARCH_EVENT_ORIGIN_TYPE_UNSPECIFIED
WORKBOOK
TEMPLATE
API
DATA_REVIEW
PROCEDURE
STREAMING_CHECKLIST
originTypesOriginTypesFilter
Fields of
OriginTypesFilteroperatorSetOperator
originTypesarray ofSearchEventOriginType
dataReviewCheckstring
dataReviewChecksDataReviewChecksFilter
Fields of
DataReviewChecksFilterdataReviewChecksarray of string
dispositionStatusEventDispositionStatus
Values of
EventDispositionStatusEVENT_DISPOSITION_STATUS_UNSPECIFIED
PENDING_REVIEW
CLOSED_IGNORED
CLOSED_REQUIRES_FURTHER_ACTION
NO_DISPOSITION
dispositionStatusesEventDispositionStatusList
Fields of
EventDispositionStatusListvaluesarray ofEventDispositionStatus
priorityPriority
Values of
PriorityPRIORITY_UNSPECIFIED
P0
P1
P2
P3
P4
prioritiesPriorityList
Fields of
PriorityListvaluesarray ofPriority
assigneestring
assigneesAssigneesFilter
Fields of
AssigneesFilteroperatorSetOperator
assigneesarray of string
eventTypeEventType
Values of
EventTypeEVENT_TYPE_UNSPECIFIED
INFO
FLAG
ERROR
SUCCESS
eventTypesEventTypeList
Fields of
EventTypeListvaluesarray ofEventType
createdBystring
createdByAnyOfUserRidList
Fields of
UserRidListvaluesarray of string
labelstring
labelsLabelsFilter
Fields of
LabelsFilteroperatorSetOperator
labelsarray of string
propertyProperty
Fields of
Propertynamestring
valuestring
propertiesPropertiesFilter
Fields of
PropertiesFilternamestring
valuesarray of string
andSearchQueryList
Fields of
SearchQueryListqueriesarray ofSearchQuery
orSearchQueryList
notSearchQuery
workspacestring
procedurestring
procedureExecutionstring
stepIdstring
streamingCheckliststringFilters to events created from a checklist executing in streaming.
streamingCheckstringFilters to events created from the check of a checklist executing in streaming.
numericPropertyNumericPropertyPredicateMatches events using a numeric property comparison.
Fields of
NumericPropertyPredicatenamestring
valuenumber
operatorPropertyComparisonOperator
Values of
PropertyComparisonOperatorPROPERTY_COMPARISON_OPERATOR_UNSPECIFIED
EQ
NEQ
GT
GTE
LT
LTE
numericPropertyRangeNumericPropertyRangePredicateMatches events using an inclusive numeric property range.
Fields of
NumericPropertyRangePredicatenamestring
minnumber
maxnumber
operatorNumericPropertyRangeOperator
Values of
NumericPropertyRangeOperatorNUMERIC_PROPERTY_RANGE_OPERATOR_UNSPECIFIED
BETWEEN
NOT_BETWEEN
archivedStatusesarray ofArchivedStatusIf empty, defaults to NOT_ARCHIVED only. Allows including archived events in search.
Values of
ArchivedStatusARCHIVED_STATUS_UNSPECIFIED
NOT_ARCHIVED
ARCHIVED
Response
resultsarray ofEvent
Fields of
Eventuuidstring
ridstring
assetRidsarray of stringA set of asset rids associated with the event.
originsarray ofEventOriginA set of origins associated with the event.
Fields of
EventOrigin- one of 6 fields
workbookWorkbookEventOriginThis event was created in this workbook.
Fields of
WorkbookEventOriginridstring
dataarray ofWorkbookDataAssociationData visualizations to associate this event with.
Fields of
WorkbookDataAssociationtimeSeriesChannelTimeSeriesChannelAssociation
Fields of
TimeSeriesChannelAssociationvariableNamestring
tagsmap of string to stringIf this variable is grouped, the tags within the groupings this event should associate with.
templateTemplateEventOriginThis event was created in this template.
Fields of
TemplateEventOriginridstring
apiApiEventOriginThis event was created programmatically via the API.
dataReviewDataReviewEventOriginThis event was created automatically from a checklist execution.
Fields of
DataReviewEventOrigindataReviewRidstring
checkMetadataCheckOriginMetadataMetadata about the check that created this event.
Fields of
CheckOriginMetadatacheckEvaluationRidstring
checkRidstring
checkLineageRidstring
implementationIndexinteger
procedureProcedureEventOriginThis event was created automatically from a procedure execution.
Fields of
ProcedureEventOriginprocedureExecutionRidstring
procedureRidstring
stepIdstring
streamingChecklistStreamingChecklistEventOriginThis event was created automatically from the execution of a streaming checklist.
Fields of
StreamingChecklistEventOriginchecklistRidstring
checkMetadataStreamingCheckOriginMetadataMetadata about the check that created this event.
Fields of
StreamingCheckOriginMetadatacheckRidstring
checkLineageRidstring
implementationIndexinteger
timestampTimestamp
Fields of
Timestampsecondsstring (int64)
nanosstring (int64)
durationDuration
Fields of
Durationsecondsstring (int64)
nanosstring (int64)
namestring
descriptionstring
typeEventType
Values of
EventTypeEVENT_TYPE_UNSPECIFIED
INFO
FLAG
ERROR
SUCCESS
labelsarray of string
propertiesmap of string to string deprecated
isArchivedboolean
createdBystringThe user who created the event. This field may be missing for legacy events.
dispositionEventDisposition
Fields of
EventDispositionpriorityPriority
Values of
PriorityPRIORITY_UNSPECIFIED
P0
P1
P2
P3
P4
stateDispositionState
Fields of
DispositionState- one of
pendingReview,closedWithFurtherAction,closedWithIgnore
pendingReviewPendingReviewDispositionState
Fields of
PendingReviewDispositionStateopenedBystring
closedWithFurtherActionClosedWithFurtherActionDispositionState
Fields of
ClosedWithFurtherActionDispositionStateclosedBystring
closedWithIgnoreClosedWithIgnoreDispositionState
Fields of
ClosedWithIgnoreDispositionStateclosedBystring
- one of
assigneesarray of string
typedPropertiesmap of string toTypedPropertyValue
Fields of
TypedPropertyValue- one of
stringValue,numericValue
stringValuestring
numericValuenumber
- one of
nextPageTokenstring
Request
curl -X POST "https://api.gov.nominal.io/api/event/v2/events/search" \
-H "Authorization: Bearer <api key>" \
-H "Content-Type: application/json" \
--data '{
"sort": {
"isDescending": true,
"field": "START_TIME"
},
"pageSize": 1,
"nextPageToken": "<next page token>",
"query": {
"archived": true
},
"archivedStatuses": [
"NOT_ARCHIVED"
]
}'
import requests
response = requests.post(
"https://api.gov.nominal.io/api/event/v2/events/search",
headers={"Authorization": "Bearer <api key>"},
json={
"sort": {"isDescending": True, "field": "START_TIME"},
"pageSize": 1,
"nextPageToken": "<next page token>",
"query": {"archived": True},
"archivedStatuses": ["NOT_ARCHIVED"],
},
)
response.raise_for_status()
print(response.json())
import httpx
response = httpx.post(
"https://api.gov.nominal.io/api/event/v2/events/search",
headers={"Authorization": "Bearer <api key>"},
json={
"sort": {"isDescending": True, "field": "START_TIME"},
"pageSize": 1,
"nextPageToken": "<next page token>",
"query": {"archived": True},
"archivedStatuses": ["NOT_ARCHIVED"],
},
)
response.raise_for_status()
print(response.json())
import asyncio
import aiohttp
async def main() -> None:
async with aiohttp.ClientSession() as session:
async with session.post(
"https://api.gov.nominal.io/api/event/v2/events/search",
headers={"Authorization": "Bearer <api key>"},
json={
"sort": {"isDescending": True, "field": "START_TIME"},
"pageSize": 1,
"nextPageToken": "<next page token>",
"query": {"archived": True},
"archivedStatuses": ["NOT_ARCHIVED"],
},
) as response:
response.raise_for_status()
print(await response.json())
asyncio.run(main())
Response: 200
{
"results": [
{
"uuid": "<uuid>",
"rid": "<rid>",
"assetRids": [
"<asset rids>"
],
"origins": [
{
"workbook": {
"rid": "<rid>",
"data": [
{
"timeSeriesChannel": {
"variableName": "<variable name>",
"tags": {
"<key>": "<value>"
}
}
}
]
}
}
],
"timestamp": {
"seconds": "1",
"nanos": "1"
},
"duration": {
"seconds": "1",
"nanos": "1"
},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": [
"<labels>"
],
"properties": {
"<key>": "<value>"
},
"isArchived": true,
"createdBy": "<created by>",
"disposition": {
"priority": "P0",
"state": {
"pendingReview": {
"openedBy": "<opened by>"
}
},
"assignees": [
"<assignees>"
]
},
"typedProperties": {
"<key>": {
"stringValue": "<string value>"
}
}
}
],
"nextPageToken": "<next page token>"
}
Update event#
POST /event/v2/events/update
Updates the fields of an event. Empty fields are left unchanged.
Body
uuidstring
ridstringThe unique identifier for the event. Required if the uuid field is not provided.
assetRidsAssetRidSetIf provided, replaces the existing asset rids. If provided, must contain at least one asset rid.
Fields of
AssetRidSetassetRidsarray of string
timestampTimestamp
Fields of
Timestampsecondsstring (int64)
nanosstring (int64)
durationDuration
Fields of
Durationsecondsstring (int64)
nanosstring (int64)
namestring
descriptionstring
typeEventType
Values of
EventTypeEVENT_TYPE_UNSPECIFIED
INFO
FLAG
ERROR
SUCCESS
labelsLabelUpdateWrapper
Fields of
LabelUpdateWrapperlabelsarray of string
propertiesPropertyUpdateWrapperdeprecated
Fields of
PropertyUpdateWrapperpropertiesmap of string to string
typedPropertiesTypedPropertyUpdateWrapper
Fields of
TypedPropertyUpdateWrappertypedPropertiesmap of string toTypedPropertyValue
Fields of
TypedPropertyValue- one of
stringValue,numericValuerequired
stringValuestring
numericValuenumber
- one of
Response
eventEvent
Fields of
Eventuuidstring
ridstring
assetRidsarray of stringA set of asset rids associated with the event.
originsarray ofEventOriginA set of origins associated with the event.
Fields of
EventOrigin- one of 6 fields
workbookWorkbookEventOriginThis event was created in this workbook.
Fields of
WorkbookEventOriginridstring
dataarray ofWorkbookDataAssociationData visualizations to associate this event with.
Fields of
WorkbookDataAssociationtimeSeriesChannelTimeSeriesChannelAssociation
Fields of
TimeSeriesChannelAssociationvariableNamestring
tagsmap of string to stringIf this variable is grouped, the tags within the groupings this event should associate with.
templateTemplateEventOriginThis event was created in this template.
Fields of
TemplateEventOriginridstring
apiApiEventOriginThis event was created programmatically via the API.
dataReviewDataReviewEventOriginThis event was created automatically from a checklist execution.
Fields of
DataReviewEventOrigindataReviewRidstring
checkMetadataCheckOriginMetadataMetadata about the check that created this event.
Fields of
CheckOriginMetadatacheckEvaluationRidstring
checkRidstring
checkLineageRidstring
implementationIndexinteger
procedureProcedureEventOriginThis event was created automatically from a procedure execution.
Fields of
ProcedureEventOriginprocedureExecutionRidstring
procedureRidstring
stepIdstring
streamingChecklistStreamingChecklistEventOriginThis event was created automatically from the execution of a streaming checklist.
Fields of
StreamingChecklistEventOriginchecklistRidstring
checkMetadataStreamingCheckOriginMetadataMetadata about the check that created this event.
Fields of
StreamingCheckOriginMetadatacheckRidstring
checkLineageRidstring
implementationIndexinteger
timestampTimestamp
Fields of
Timestampsecondsstring (int64)
nanosstring (int64)
durationDuration
Fields of
Durationsecondsstring (int64)
nanosstring (int64)
namestring
descriptionstring
typeEventType
Values of
EventTypeEVENT_TYPE_UNSPECIFIED
INFO
FLAG
ERROR
SUCCESS
labelsarray of string
propertiesmap of string to string deprecated
isArchivedboolean
createdBystringThe user who created the event. This field may be missing for legacy events.
dispositionEventDisposition
Fields of
EventDispositionpriorityPriority
Values of
PriorityPRIORITY_UNSPECIFIED
P0
P1
P2
P3
P4
stateDispositionState
Fields of
DispositionState- one of
pendingReview,closedWithFurtherAction,closedWithIgnore
pendingReviewPendingReviewDispositionState
Fields of
PendingReviewDispositionStateopenedBystring
closedWithFurtherActionClosedWithFurtherActionDispositionState
Fields of
ClosedWithFurtherActionDispositionStateclosedBystring
closedWithIgnoreClosedWithIgnoreDispositionState
Fields of
ClosedWithIgnoreDispositionStateclosedBystring
- one of
assigneesarray of string
typedPropertiesmap of string toTypedPropertyValue
Fields of
TypedPropertyValue- one of
stringValue,numericValue
stringValuestring
numericValuenumber
- one of
Request
curl -X POST "https://api.gov.nominal.io/api/event/v2/events/update" \
-H "Authorization: Bearer <api key>" \
-H "Content-Type: application/json" \
--data '{
"uuid": "<uuid>",
"rid": "<rid>",
"assetRids": {
"assetRids": [
"<asset rids>"
]
},
"timestamp": {
"seconds": "1",
"nanos": "1"
},
"duration": {
"seconds": "1",
"nanos": "1"
},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": {
"labels": [
"<labels>"
]
},
"properties": {
"properties": {
"<key>": "<value>"
}
},
"typedProperties": {
"typedProperties": {
"<key>": {
"stringValue": "<string value>"
}
}
}
}'
import requests
response = requests.post(
"https://api.gov.nominal.io/api/event/v2/events/update",
headers={"Authorization": "Bearer <api key>"},
json={
"uuid": "<uuid>",
"rid": "<rid>",
"assetRids": {"assetRids": ["<asset rids>"]},
"timestamp": {"seconds": "1", "nanos": "1"},
"duration": {"seconds": "1", "nanos": "1"},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": {"labels": ["<labels>"]},
"properties": {"properties": {"<key>": "<value>"}},
"typedProperties": {
"typedProperties": {"<key>": {"stringValue": "<string value>"}},
},
},
)
response.raise_for_status()
print(response.json())
import httpx
response = httpx.post(
"https://api.gov.nominal.io/api/event/v2/events/update",
headers={"Authorization": "Bearer <api key>"},
json={
"uuid": "<uuid>",
"rid": "<rid>",
"assetRids": {"assetRids": ["<asset rids>"]},
"timestamp": {"seconds": "1", "nanos": "1"},
"duration": {"seconds": "1", "nanos": "1"},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": {"labels": ["<labels>"]},
"properties": {"properties": {"<key>": "<value>"}},
"typedProperties": {
"typedProperties": {"<key>": {"stringValue": "<string value>"}},
},
},
)
response.raise_for_status()
print(response.json())
import asyncio
import aiohttp
async def main() -> None:
async with aiohttp.ClientSession() as session:
async with session.post(
"https://api.gov.nominal.io/api/event/v2/events/update",
headers={"Authorization": "Bearer <api key>"},
json={
"uuid": "<uuid>",
"rid": "<rid>",
"assetRids": {"assetRids": ["<asset rids>"]},
"timestamp": {"seconds": "1", "nanos": "1"},
"duration": {"seconds": "1", "nanos": "1"},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": {"labels": ["<labels>"]},
"properties": {"properties": {"<key>": "<value>"}},
"typedProperties": {
"typedProperties": {"<key>": {"stringValue": "<string value>"}},
},
},
) as response:
response.raise_for_status()
print(await response.json())
asyncio.run(main())
Response: 200
{
"event": {
"uuid": "<uuid>",
"rid": "<rid>",
"assetRids": [
"<asset rids>"
],
"origins": [
{
"workbook": {
"rid": "<rid>",
"data": [
{
"timeSeriesChannel": {
"variableName": "<variable name>",
"tags": {
"<key>": "<value>"
}
}
}
]
}
}
],
"timestamp": {
"seconds": "1",
"nanos": "1"
},
"duration": {
"seconds": "1",
"nanos": "1"
},
"name": "<name>",
"description": "<description>",
"type": "INFO",
"labels": [
"<labels>"
],
"properties": {
"<key>": "<value>"
},
"isArchived": true,
"createdBy": "<created by>",
"disposition": {
"priority": "P0",
"state": {
"pendingReview": {
"openedBy": "<opened by>"
}
},
"assignees": [
"<assignees>"
]
},
"typedProperties": {
"<key>": {
"stringValue": "<string value>"
}
}
}
}
List properties and labels#
POST /event/v2/list-properties-labels
Lists the properties and labels of active events in the provided workspaces.
Body
workspaceRidsarray of stringIf empty, results come from all workspaces the user belongs to.
Response
propertiesmap of string toPropertyValuesdeprecatedDeprecated: use the paginated SearchPropertyKeys and SearchPropertyValues methods instead. Legacy string-only property values. proto3 forbids a repeated map value, so the property values are wrapped.
Fields of
PropertyValuesvaluearray of string
labelsarray of string
Request
curl -X POST "https://api.gov.nominal.io/api/event/v2/list-properties-labels" \
-H "Authorization: Bearer <api key>" \
-H "Content-Type: application/json" \
--data '{
"workspaceRids": [
"<workspace rids>"
]
}'
import requests
response = requests.post(
"https://api.gov.nominal.io/api/event/v2/list-properties-labels",
headers={"Authorization": "Bearer <api key>"},
json={"workspaceRids": ["<workspace rids>"]},
)
response.raise_for_status()
print(response.json())
import httpx
response = httpx.post(
"https://api.gov.nominal.io/api/event/v2/list-properties-labels",
headers={"Authorization": "Bearer <api key>"},
json={"workspaceRids": ["<workspace rids>"]},
)
response.raise_for_status()
print(response.json())
import asyncio
import aiohttp
async def main() -> None:
async with aiohttp.ClientSession() as session:
async with session.post(
"https://api.gov.nominal.io/api/event/v2/list-properties-labels",
headers={"Authorization": "Bearer <api key>"},
json={"workspaceRids": ["<workspace rids>"]},
) as response:
response.raise_for_status()
print(await response.json())
asyncio.run(main())
Response: 200
{
"properties": {
"<key>": {
"value": [
"<value>"
]
}
},
"labels": [
"<labels>"
]
}
Errors#
Errors shows how these errors are sent.
Each error’s errorName is NominalEventV2: followed by its name below.
Status |
Name |
Notes |
|---|---|---|
400 |
|
FindEventsIndexInvalid |
400 |
|
FindEventsQueryCountTooLarge |
400 |
|
InvalidEventRequest |
400 |
|
EventSearchQueryTooBroad |
Types#
AggregateEventsRequest#
querySearchQuery
aggregateTypesarray ofAggregateType
AggregateEventsResponse#
valuesmap of string toAggregateValueKeyed by AggregateType enum value name (proto3 forbids enum map keys).
AggregateType#
AGGREGATE_TYPE_UNSPECIFIED
TOTAL_DURATION
TOTAL_COUNT
AggregateValue#
Set at most one of the fields below.
- one of
duration,count
durationDuration
countinteger
ApiEventOrigin#
An empty JSON object, {}.
ArchivedStatus#
ARCHIVED_STATUS_UNSPECIFIED
NOT_ARCHIVED
ARCHIVED
AssetRidSet#
Optional collection presence: an absent wrapper leaves the field untouched, a present (even empty) wrapper replaces it — matching the classic REST optional<set>/optional<map> update semantics.
assetRidsarray of string
AssetsFilter#
operatorSetOperator
assetsarray of string
AssigneesFilter#
operatorSetOperator
assigneesarray of string
CheckOriginMetadata#
checkEvaluationRidstring
checkRidstring
checkLineageRidstring
implementationIndexinteger
ClosedWithFurtherActionDispositionState#
closedBystring
ClosedWithIgnoreDispositionState#
closedBystring
DataReviewChecksFilter#
dataReviewChecksarray of string
DataReviewEventOrigin#
dataReviewRidstring
checkMetadataCheckOriginMetadataMetadata about the check that created this event.
DataReviewsFilter#
dataReviewsarray of string
DispositionState#
Set at most one of the fields below.
- one of
pendingReview,closedWithFurtherAction,closedWithIgnore
pendingReviewPendingReviewDispositionState
closedWithFurtherActionClosedWithFurtherActionDispositionState
closedWithIgnoreClosedWithIgnoreDispositionState
Duration#
secondsstring (int64)
nanosstring (int64)
Event#
uuidstring
ridstring
assetRidsarray of stringA set of asset rids associated with the event.
originsarray ofEventOriginA set of origins associated with the event.
timestampTimestamp
durationDuration
namestring
descriptionstring
typeEventType
labelsarray of string
propertiesmap of string to string deprecated
isArchivedboolean
createdBystringThe user who created the event. This field may be missing for legacy events.
dispositionEventDisposition
typedPropertiesmap of string toTypedPropertyValue
EventDisposition#
Describes the review status for an event.
priorityPriority
stateDispositionState
assigneesarray of string
EventDispositionStatus#
EVENT_DISPOSITION_STATUS_UNSPECIFIED
PENDING_REVIEW
CLOSED_IGNORED
CLOSED_REQUIRES_FURTHER_ACTION
NO_DISPOSITION
EventDispositionStatusList#
valuesarray ofEventDispositionStatus
EventOrigin#
Describes where an event came from.
Set at most one of the fields below.
- one of 6 fields
workbookWorkbookEventOriginThis event was created in this workbook.
templateTemplateEventOriginThis event was created in this template.
apiApiEventOriginThis event was created programmatically via the API.
dataReviewDataReviewEventOriginThis event was created automatically from a checklist execution.
procedureProcedureEventOriginThis event was created automatically from a procedure execution.
streamingChecklistStreamingChecklistEventOriginThis event was created automatically from the execution of a streaming checklist.
EventsHistogramBucket#
EventTimeFilter#
timestampTimestamp
timestampConditionEventTimeFilterCondition
EventTimeFilterCondition#
EVENT_TIME_FILTER_CONDITION_UNSPECIFIED
START_TIME_BEFORE_INCLUSIVE
START_TIME_BEFORE_EXCLUSIVE
START_TIME_AFTER_INCLUSIVE
START_TIME_AFTER_EXCLUSIVE
END_TIME_BEFORE_INCLUSIVE
END_TIME_BEFORE_EXCLUSIVE
END_TIME_AFTER_INCLUSIVE
END_TIME_AFTER_EXCLUSIVE
EventType#
EVENT_TYPE_UNSPECIFIED
INFO
FLAG
ERROR
SUCCESS
EventTypeList#
valuesarray ofEventType
EventUpdate#
ridstring
assetRidsAssetRidSetIf provided, replaces the existing asset rids. If provided, must contain at least one asset rid.
timestampTimestamp
durationDuration
namestring
descriptionstring
typeEventType
labelsLabelUpdateWrapper
propertiesPropertyUpdateWrapperdeprecated
typedPropertiesTypedPropertyUpdateWrapper
FindEventsQuery#
assetRidsarray of stringWhen non-empty, only events associated with at least one of these assets match. When empty, events match on the time window alone.
startInclusiveTimestampHalf-open window [start_inclusive, end_exclusive) over event start times. An absent bound leaves that side of the window open.
endExclusiveTimestamp
indexintegerZero-based rank of the event to return after applying the request sort and permission filtering. Must be non-negative. When permission filtering hides events within the first index matches, the result may be absent even though later matches exist.
FindEventsResult#
eventEventAbsent when no event matches the query at the requested index.
HistogramFilterQuery#
Set at most one of the fields below.
- one of 21 fields
searchTextstring
assetstring
templatestring
workbookstring
dataReviewstring
originTypeSearchEventOriginType
dataReviewCheckstring
dispositionStatusEventDispositionStatus
priorityPriority
assigneestring
eventTypeEventType
createdBystring
labelstring
propertyProperty
notHistogramFilterQuery
workspacestring
procedurestring
procedureExecutionstring
stepIdstring
HistogramFilterQueryList#
queriesarray ofHistogramFilterQuery
LabelsFilter#
operatorSetOperator
labelsarray of string
LabelUpdateWrapper#
Wrapper classes to allow for optional fields on update requests
labelsarray of string
NumericPropertyPredicate#
Matches resources that have a numeric value for the named property and whose value satisfies the operator. NEQ excludes resources that lack the property or store a string value under the same name.
namestring
valuenumber
operatorPropertyComparisonOperator
NumericPropertyRangeOperator#
NUMERIC_PROPERTY_RANGE_OPERATOR_UNSPECIFIED
BETWEEN
NOT_BETWEEN
NumericPropertyRangePredicate#
Inclusive range on a numeric property. At least one bound is required. BETWEEN: min <= x <= max. An absent bound is unbounded on that side. NOT_BETWEEN: x < min OR x > max. An absent bound drops that side. Both operators require a numeric value for name. Missing properties and string values never match. Bounds are closed [min, max] to match the number chip (is between / is not between), not half-open.
namestring
minnumber
maxnumber
operatorNumericPropertyRangeOperator
OriginTypesFilter#
operatorSetOperator
originTypesarray ofSearchEventOriginType
PendingReviewDispositionState#
openedBystring
Priority#
PRIORITY_UNSPECIFIED
P0
P1
P2
P3
P4
PriorityList#
valuesarray ofPriority
ProcedureEventOrigin#
procedureExecutionRidstring
procedureRidstring
stepIdstring
PropertiesFilter#
namestring
valuesarray of string
Property#
namestring
valuestring
PropertyComparisonOperator#
PROPERTY_COMPARISON_OPERATOR_UNSPECIFIED
EQ
NEQ
GT
GTE
LT
LTE
PropertyUpdateWrapper#
propertiesmap of string to string
PropertyValues#
valuearray of string
SearchEventOriginType#
SEARCH_EVENT_ORIGIN_TYPE_UNSPECIFIED
WORKBOOK
TEMPLATE
API
DATA_REVIEW
PROCEDURE
STREAMING_CHECKLIST
SearchQuery#
Set at most one of the fields below.
- one of 41 fields
archivedboolean
searchTextstringSearch text to perform fuzzy searching against.
exactMatchstringSearch text to perform exact matching against on the event name and description.
afterTimestampFilters to events after this timestamp, exclusive.
beforeTimestampFilters to events before this timestamp, exclusive.
advancedTimeFilterEventTimeFilter
assetstring
assetsAssetsFilter
templatestring
workbookstring
dataReviewstring
dataReviewsDataReviewsFilter
originTypeSearchEventOriginType
originTypesOriginTypesFilter
dataReviewCheckstring
dataReviewChecksDataReviewChecksFilter
dispositionStatusEventDispositionStatus
dispositionStatusesEventDispositionStatusList
priorityPriority
prioritiesPriorityList
assigneestring
assigneesAssigneesFilter
eventTypeEventType
eventTypesEventTypeList
createdBystring
createdByAnyOfUserRidList
labelstring
labelsLabelsFilter
propertyProperty
propertiesPropertiesFilter
andSearchQueryList
orSearchQueryList
notSearchQuery
workspacestring
procedurestring
procedureExecutionstring
stepIdstring
streamingCheckliststringFilters to events created from a checklist executing in streaming.
streamingCheckstringFilters to events created from the check of a checklist executing in streaming.
numericPropertyNumericPropertyPredicateMatches events using a numeric property comparison.
numericPropertyRangeNumericPropertyRangePredicateMatches events using an inclusive numeric property range.
SearchQueryList#
Repeated-value arms of the SearchQuery / HistogramFilterQuery oneofs are message-wrapped: proto3 oneof arms cannot be repeated directly.
queriesarray ofSearchQuery
SetOperator#
SET_OPERATOR_UNSPECIFIED
AND
OR
SortField#
SORT_FIELD_UNSPECIFIED
START_TIME
END_TIME
DURATION
DISPOSITION_STATUS
PRIORITY
EVENT_NAME
SortOptions#
isDescendingboolean
fieldSortField
StreamingChecklistEventOrigin#
checklistRidstring
checkMetadataStreamingCheckOriginMetadataMetadata about the check that created this event.
StreamingCheckOriginMetadata#
checkRidstring
checkLineageRidstring
implementationIndexinteger
TemplateEventOrigin#
ridstring
TimeSeriesChannelAssociation#
A singular time series to associate the event with.
variableNamestring
tagsmap of string to stringIf this variable is grouped, the tags within the groupings this event should associate with.
Timestamp#
Deprecated for new APIs. Use google.protobuf.Timestamp for absolute instants.
This legacy nanosecond-precision timestamp is represented by an epoch time in seconds and a nanosecond offset. The nanosecond offset is from the start of the epoch second, so must be less than 1 billion.
secondsstring (int64)
nanosstring (int64)
TypedPropertyUpdateWrapper#
typedPropertiesmap of string toTypedPropertyValue
TypedPropertyValue#
Set exactly one of the fields below.
- one of
stringValue,numericValuerequired
stringValuestring
numericValuenumber
UpdateDispositionRequest#
ridstring
dispositionEventDispositionThe new disposition for the event. If empty, removes the disposition from the event.
UserRidList#
valuesarray of string
WorkbookDataAssociation#
timeSeriesChannelTimeSeriesChannelAssociation
WorkbookEventOrigin#
ridstring
dataarray ofWorkbookDataAssociationData visualizations to associate this event with.
Page design based on Scalar, MIT License.