Event service (gRPC)#

An Event is an annotated moment or time range. The Event Service is responsible for creating and retrieving events for a particular data source.

Endpoints#

Aggregate events#

gRPC /nominal.event.v2.EventService/AggregateEvents

Searches for events matching the given filter and aggregates them based on the requested functions.

Request: AggregateEventsRequest

query SearchQuery

​

Fields of SearchQuery
one of 41 fields

​

archived boolean

​

search_text string

Search text to perform fuzzy searching against.

exact_match string

Search text to perform exact matching against on the event name and description.

after Timestamp

Filters to events after this timestamp, exclusive.

Fields of Timestamp
seconds integer (int64)

​

nanos integer (int64)

​

before Timestamp

Filters to events before this timestamp, exclusive.

advanced_time_filter EventTimeFilter

​

Fields of EventTimeFilter
timestamp Timestamp

​

timestamp_condition EventTimeFilterCondition

​

Values of 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

​

asset string

​

assets AssetsFilter

​

Fields of AssetsFilter
operator SetOperator

​

Values of SetOperator
SET_OPERATOR_UNSPECIFIED

​

AND

​

OR

​

assets array of string

​

template string

​

workbook string

​

data_review string

​

data_reviews DataReviewsFilter

​

Fields of DataReviewsFilter
data_reviews array of string

​

origin_type SearchEventOriginType

​

Values of SearchEventOriginType
SEARCH_EVENT_ORIGIN_TYPE_UNSPECIFIED

​

WORKBOOK

​

TEMPLATE

​

API

​

DATA_REVIEW

​

PROCEDURE

​

STREAMING_CHECKLIST

​

origin_types OriginTypesFilter

​

Fields of OriginTypesFilter
operator SetOperator

​

origin_types array of SearchEventOriginType

​

data_review_check string

​

data_review_checks DataReviewChecksFilter

​

Fields of DataReviewChecksFilter
data_review_checks array of string

​

disposition_status EventDispositionStatus

​

Values of EventDispositionStatus
EVENT_DISPOSITION_STATUS_UNSPECIFIED

​

PENDING_REVIEW

​

CLOSED_IGNORED

​

CLOSED_REQUIRES_FURTHER_ACTION

​

NO_DISPOSITION

​

disposition_statuses EventDispositionStatusList

​

Fields of EventDispositionStatusList
values array of EventDispositionStatus

​

priority Priority

​

Values of Priority
PRIORITY_UNSPECIFIED

​

P0

​

P1

​

P2

​

P3

​

P4

​

priorities PriorityList

​

Fields of PriorityList
values array of Priority

​

assignee string

​

assignees AssigneesFilter

​

Fields of AssigneesFilter
operator SetOperator

​

assignees array of string

​

event_type EventType

​

Values of EventType
EVENT_TYPE_UNSPECIFIED

​

INFO

​

FLAG

​

ERROR

​

SUCCESS

​

event_types EventTypeList

​

Fields of EventTypeList
values array of EventType

​

created_by string

​

created_by_any_of UserRidList

​

Fields of UserRidList
values array of string

​

label string

​

labels LabelsFilter

​

Fields of LabelsFilter
operator SetOperator

​

labels array of string

​

property Property

​

Fields of Property
name string

​

value string

​

properties PropertiesFilter

​

Fields of PropertiesFilter
name string

​

values array of string

​

and SearchQueryList

​

Fields of SearchQueryList
queries array of SearchQuery

​

not SearchQuery

​

workspace string

​

procedure string

​

procedure_execution string

​

step_id string

​

streaming_checklist string

Filters to events created from a checklist executing in streaming.

streaming_check string

Filters to events created from the check of a checklist executing in streaming.

numeric_property NumericPropertyPredicate

Matches events using a numeric property comparison.

Fields of NumericPropertyPredicate
name string

​

value number

​

operator PropertyComparisonOperator

​

Values of PropertyComparisonOperator
PROPERTY_COMPARISON_OPERATOR_UNSPECIFIED

​

EQ

​

NEQ

​

GT

​

GTE

​

LT

​

LTE

​

numeric_property_range NumericPropertyRangePredicate

Matches events using an inclusive numeric property range.

Fields of NumericPropertyRangePredicate
name string

​

min number

​

max number

​

operator NumericPropertyRangeOperator

​

Values of NumericPropertyRangeOperator
NUMERIC_PROPERTY_RANGE_OPERATOR_UNSPECIFIED

​

BETWEEN

​

NOT_BETWEEN

​

aggregate_types array of AggregateType

​

Values of AggregateType
AGGREGATE_TYPE_UNSPECIFIED

​

TOTAL_DURATION

​

TOTAL_COUNT

​

Response: AggregateEventsResponse

values map of string to AggregateValue

Keyed by AggregateType enum value name (proto3 forbids enum map keys).

Fields of AggregateValue
one of duration, count

​

duration Duration

​

Fields of Duration
seconds integer (int64)

​

nanos integer (int64)

​

count integer

​

Request

import grpc
from nominal.protos.event.v2 import event_pb2, event_pb2_grpc

channel = grpc.secure_channel("api.gov.nominal.io:443", grpc.ssl_channel_credentials())
event_service = event_pb2_grpc.EventServiceStub(channel)
auth = [("authorization", "Bearer <api key>")]

request = event_pb2.AggregateEventsRequest(
    query={"archived": True},
    aggregate_types=["TOTAL_DURATION"],
)
response = event_service.AggregateEvents(request, metadata=auth)
print(response)
package main

import (
	"context"
	"crypto/tls"
	"fmt"
	"log"

	eventv2 "github.com/nominal-io/nominal-api-protos-go/nominal/protos/event/v2"
	"google.golang.org/grpc"
	"google.golang.org/grpc/credentials"
	"google.golang.org/grpc/metadata"
)

func main() {
	conn, err := grpc.NewClient("api.gov.nominal.io:443",
		grpc.WithTransportCredentials(credentials.NewTLS(&tls.Config{})))
	if err != nil {
		log.Fatal(err)
	}
	defer conn.Close()
	eventService := eventv2.NewEventServiceClient(conn)
	ctx := metadata.AppendToOutgoingContext(context.Background(), "authorization", "Bearer <api key>")

	request := &eventv2.AggregateEventsRequest{
		Query: &eventv2.SearchQuery{
			SearchQuery: &eventv2.SearchQuery_Archived{Archived: true},
		},
		AggregateTypes: []eventv2.AggregateType{
			eventv2.AggregateType_TOTAL_DURATION,
		},
	}
	response, err := eventService.AggregateEvents(ctx, request)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Println(response)
}

Response

{
  "values": {
    "<key>": {
      "duration": {
        "seconds": 1,
        "nanos": 1
      }
    }
  }
}

Archive event#

gRPC /nominal.event.v2.EventService/ArchiveEvent

Archives an event.

Request: ArchiveEventRequest

uuid string

​

Response: ArchiveEventResponse

A message with no fields.

Request

import grpc
from nominal.protos.event.v2 import event_pb2, event_pb2_grpc

channel = grpc.secure_channel("api.gov.nominal.io:443", grpc.ssl_channel_credentials())
event_service = event_pb2_grpc.EventServiceStub(channel)
auth = [("authorization", "Bearer <api key>")]

request = event_pb2.ArchiveEventRequest(uuid="<uuid>")
response = event_service.ArchiveEvent(request, metadata=auth)
print(response)
package main

import (
	"context"
	"crypto/tls"
	"fmt"
	"log"

	eventv2 "github.com/nominal-io/nominal-api-protos-go/nominal/protos/event/v2"
	"google.golang.org/grpc"
	"google.golang.org/grpc/credentials"
	"google.golang.org/grpc/metadata"
)

func main() {
	conn, err := grpc.NewClient("api.gov.nominal.io:443",
		grpc.WithTransportCredentials(credentials.NewTLS(&tls.Config{})))
	if err != nil {
		log.Fatal(err)
	}
	defer conn.Close()
	eventService := eventv2.NewEventServiceClient(conn)
	ctx := metadata.AppendToOutgoingContext(context.Background(), "authorization", "Bearer <api key>")

	request := &eventv2.ArchiveEventRequest{
		Uuid: "<uuid>",
	}
	response, err := eventService.ArchiveEvent(ctx, request)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Println(response)
}

Response

{}

Batch aggregate events#

gRPC /nominal.event.v2.EventService/BatchAggregateEvents

Aggregates each batched request and returns responses in the same order.

Request: BatchAggregateEventsRequest

requests array of AggregateEventsRequest

​

Fields of AggregateEventsRequest
query SearchQuery

​

Fields of SearchQuery
one of 41 fields

​

archived boolean

​

search_text string

Search text to perform fuzzy searching against.

exact_match string

Search text to perform exact matching against on the event name and description.

after Timestamp

Filters to events after this timestamp, exclusive.

Fields of Timestamp
seconds integer (int64)

​

nanos integer (int64)

​

before Timestamp

Filters to events before this timestamp, exclusive.

advanced_time_filter EventTimeFilter

​

Fields of EventTimeFilter
timestamp Timestamp

​

timestamp_condition EventTimeFilterCondition

​

Values of 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

​

asset string

​

assets AssetsFilter

​

Fields of AssetsFilter
operator SetOperator

​

Values of SetOperator
SET_OPERATOR_UNSPECIFIED

​

AND

​

OR

​

assets array of string

​

template string

​

workbook string

​

data_review string

​

data_reviews DataReviewsFilter

​

Fields of DataReviewsFilter
data_reviews array of string

​

origin_type SearchEventOriginType

​

Values of SearchEventOriginType
SEARCH_EVENT_ORIGIN_TYPE_UNSPECIFIED

​

WORKBOOK

​

TEMPLATE

​

API

​

DATA_REVIEW

​

PROCEDURE

​

STREAMING_CHECKLIST

​

origin_types OriginTypesFilter

​

Fields of OriginTypesFilter
operator SetOperator

​

origin_types array of SearchEventOriginType

​

data_review_check string

​

data_review_checks DataReviewChecksFilter

​

Fields of DataReviewChecksFilter
data_review_checks array of string

​

disposition_status EventDispositionStatus

​

Values of EventDispositionStatus
EVENT_DISPOSITION_STATUS_UNSPECIFIED

​

PENDING_REVIEW

​

CLOSED_IGNORED

​

CLOSED_REQUIRES_FURTHER_ACTION

​

NO_DISPOSITION

​

disposition_statuses EventDispositionStatusList

​

Fields of EventDispositionStatusList
values array of EventDispositionStatus

​

priority Priority

​

Values of Priority
PRIORITY_UNSPECIFIED

​

P0

​

P1

​

P2

​

P3

​

P4

​

priorities PriorityList

​

Fields of PriorityList
values array of Priority

​

assignee string

​

assignees AssigneesFilter

​

Fields of AssigneesFilter
operator SetOperator

​

assignees array of string

​

event_type EventType

​

Values of EventType
EVENT_TYPE_UNSPECIFIED

​

INFO

​

FLAG

​

ERROR

​

SUCCESS

​

event_types EventTypeList

​

Fields of EventTypeList
values array of EventType

​

created_by string

​

created_by_any_of UserRidList

​

Fields of UserRidList
values array of string

​

label string

​

labels LabelsFilter

​

Fields of LabelsFilter
operator SetOperator

​

labels array of string

​

property Property

​

Fields of Property
name string

​

value string

​

properties PropertiesFilter

​

Fields of PropertiesFilter
name string

​

values array of string

​

and SearchQueryList

​

Fields of SearchQueryList
queries array of SearchQuery

​

not SearchQuery

​

workspace string

​

procedure string

​

procedure_execution string

​

step_id string

​

streaming_checklist string

Filters to events created from a checklist executing in streaming.

streaming_check string

Filters to events created from the check of a checklist executing in streaming.

numeric_property NumericPropertyPredicate

Matches events using a numeric property comparison.

Fields of NumericPropertyPredicate
name string

​

value number

​

operator PropertyComparisonOperator

​

Values of PropertyComparisonOperator
PROPERTY_COMPARISON_OPERATOR_UNSPECIFIED

​

EQ

​

NEQ

​

GT

​

GTE

​

LT

​

LTE

​

numeric_property_range NumericPropertyRangePredicate

Matches events using an inclusive numeric property range.

Fields of NumericPropertyRangePredicate
name string

​

min number

​

max number

​

operator NumericPropertyRangeOperator

​

Values of NumericPropertyRangeOperator
NUMERIC_PROPERTY_RANGE_OPERATOR_UNSPECIFIED

​

BETWEEN

​

NOT_BETWEEN

​

aggregate_types array of AggregateType

​

Values of AggregateType
AGGREGATE_TYPE_UNSPECIFIED

​

TOTAL_DURATION

​

TOTAL_COUNT

​

Response: BatchAggregateEventsResponse

responses array of AggregateEventsResponse

​

Fields of AggregateEventsResponse
values map of string to AggregateValue

Keyed by AggregateType enum value name (proto3 forbids enum map keys).

Fields of AggregateValue
one of duration, count

​

duration Duration

​

Fields of Duration
seconds integer (int64)

​

nanos integer (int64)

​

count integer

​

Request

import grpc
from nominal.protos.event.v2 import event_pb2, event_pb2_grpc

channel = grpc.secure_channel("api.gov.nominal.io:443", grpc.ssl_channel_credentials())
event_service = event_pb2_grpc.EventServiceStub(channel)
auth = [("authorization", "Bearer <api key>")]

request = event_pb2.BatchAggregateEventsRequest(
    requests=[{"query": {"archived": True}, "aggregate_types": ["TOTAL_DURATION"]}],
)
response = event_service.BatchAggregateEvents(request, metadata=auth)
print(response)
package main

import (
	"context"
	"crypto/tls"
	"fmt"
	"log"

	eventv2 "github.com/nominal-io/nominal-api-protos-go/nominal/protos/event/v2"
	"google.golang.org/grpc"
	"google.golang.org/grpc/credentials"
	"google.golang.org/grpc/metadata"
)

func main() {
	conn, err := grpc.NewClient("api.gov.nominal.io:443",
		grpc.WithTransportCredentials(credentials.NewTLS(&tls.Config{})))
	if err != nil {
		log.Fatal(err)
	}
	defer conn.Close()
	eventService := eventv2.NewEventServiceClient(conn)
	ctx := metadata.AppendToOutgoingContext(context.Background(), "authorization", "Bearer <api key>")

	request := &eventv2.BatchAggregateEventsRequest{
		Requests: []*eventv2.AggregateEventsRequest{
			{
				Query: &eventv2.SearchQuery{
					SearchQuery: &eventv2.SearchQuery_Archived{Archived: true},
				},
				AggregateTypes: []eventv2.AggregateType{
					eventv2.AggregateType_TOTAL_DURATION,
				},
			},
		},
	}
	response, err := eventService.BatchAggregateEvents(ctx, request)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Println(response)
}

Response

{
  "responses": [
    {
      "values": {
        "<key>": {
          "duration": {
            "seconds": 1,
            "nanos": 1
          }
        }
      }
    }
  ]
}

Batch archive event#

gRPC /nominal.event.v2.EventService/BatchArchiveEvent

Archives a set of events.

Request: BatchArchiveEventRequest

event_rids array of string

​

Response: BatchArchiveEventResponse

A message with no fields.

Request

import grpc
from nominal.protos.event.v2 import event_pb2, event_pb2_grpc

channel = grpc.secure_channel("api.gov.nominal.io:443", grpc.ssl_channel_credentials())
event_service = event_pb2_grpc.EventServiceStub(channel)
auth = [("authorization", "Bearer <api key>")]

request = event_pb2.BatchArchiveEventRequest(event_rids=["<event rids>"])
response = event_service.BatchArchiveEvent(request, metadata=auth)
print(response)
package main

import (
	"context"
	"crypto/tls"
	"fmt"
	"log"

	eventv2 "github.com/nominal-io/nominal-api-protos-go/nominal/protos/event/v2"
	"google.golang.org/grpc"
	"google.golang.org/grpc/credentials"
	"google.golang.org/grpc/metadata"
)

func main() {
	conn, err := grpc.NewClient("api.gov.nominal.io:443",
		grpc.WithTransportCredentials(credentials.NewTLS(&tls.Config{})))
	if err != nil {
		log.Fatal(err)
	}
	defer conn.Close()
	eventService := eventv2.NewEventServiceClient(conn)
	ctx := metadata.AppendToOutgoingContext(context.Background(), "authorization", "Bearer <api key>")

	request := &eventv2.BatchArchiveEventRequest{
		EventRids: []string{
			"<event rids>",
		},
	}
	response, err := eventService.BatchArchiveEvent(ctx, request)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Println(response)
}

Response

{}

Batch filter events#

gRPC /nominal.event.v2.EventService/BatchFilterEvents

Gets a filtered set of events by RID and search filters.

Request: BatchFilterEventsRequest

event_rids array of string

​

filter_query SearchQuery

​

Fields of SearchQuery
one of 41 fields

​

archived boolean

​

search_text string

Search text to perform fuzzy searching against.

exact_match string

Search text to perform exact matching against on the event name and description.

after Timestamp

Filters to events after this timestamp, exclusive.

Fields of Timestamp
seconds integer (int64)

​

nanos integer (int64)

​

before Timestamp

Filters to events before this timestamp, exclusive.

advanced_time_filter EventTimeFilter

​

Fields of EventTimeFilter
timestamp Timestamp

​

timestamp_condition EventTimeFilterCondition

​

Values of 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

​

asset string

​

assets AssetsFilter

​

Fields of AssetsFilter
operator SetOperator

​

Values of SetOperator
SET_OPERATOR_UNSPECIFIED

​

AND

​

OR

​

assets array of string

​

template string

​

workbook string

​

data_review string

​

data_reviews DataReviewsFilter

​

Fields of DataReviewsFilter
data_reviews array of string

​

origin_type SearchEventOriginType

​

Values of SearchEventOriginType
SEARCH_EVENT_ORIGIN_TYPE_UNSPECIFIED

​

WORKBOOK

​

TEMPLATE

​

API

​

DATA_REVIEW

​

PROCEDURE

​

STREAMING_CHECKLIST

​

origin_types OriginTypesFilter

​

Fields of OriginTypesFilter
operator SetOperator

​

origin_types array of SearchEventOriginType

​

data_review_check string

​

data_review_checks DataReviewChecksFilter

​

Fields of DataReviewChecksFilter
data_review_checks array of string

​

disposition_status EventDispositionStatus

​

Values of EventDispositionStatus
EVENT_DISPOSITION_STATUS_UNSPECIFIED

​

PENDING_REVIEW

​

CLOSED_IGNORED

​

CLOSED_REQUIRES_FURTHER_ACTION

​

NO_DISPOSITION

​

disposition_statuses EventDispositionStatusList

​

Fields of EventDispositionStatusList
values array of EventDispositionStatus

​

priority Priority

​

Values of Priority
PRIORITY_UNSPECIFIED

​

P0

​

P1

​

P2

​

P3

​

P4

​

priorities PriorityList

​

Fields of PriorityList
values array of Priority

​

assignee string

​

assignees AssigneesFilter

​

Fields of AssigneesFilter
operator SetOperator

​

assignees array of string

​

event_type EventType

​

Values of EventType
EVENT_TYPE_UNSPECIFIED

​

INFO

​

FLAG

​

ERROR

​

SUCCESS

​

event_types EventTypeList

​

Fields of EventTypeList
values array of EventType

​

created_by string

​

created_by_any_of UserRidList

​

Fields of UserRidList
values array of string

​

label string

​

labels LabelsFilter

​

Fields of LabelsFilter
operator SetOperator

​

labels array of string

​

property Property

​

Fields of Property
name string

​

value string

​

properties PropertiesFilter

​

Fields of PropertiesFilter
name string

​

values array of string

​

and SearchQueryList

​

Fields of SearchQueryList
queries array of SearchQuery

​

not SearchQuery

​

workspace string

​

procedure string

​

procedure_execution string

​

step_id string

​

streaming_checklist string

Filters to events created from a checklist executing in streaming.

streaming_check string

Filters to events created from the check of a checklist executing in streaming.

numeric_property NumericPropertyPredicate

Matches events using a numeric property comparison.

Fields of NumericPropertyPredicate
name string

​

value number

​

operator PropertyComparisonOperator

​

Values of PropertyComparisonOperator
PROPERTY_COMPARISON_OPERATOR_UNSPECIFIED

​

EQ

​

NEQ

​

GT

​

GTE

​

LT

​

LTE

​

numeric_property_range NumericPropertyRangePredicate

Matches events using an inclusive numeric property range.

Fields of NumericPropertyRangePredicate
name string

​

min number

​

max number

​

operator NumericPropertyRangeOperator

​

Values of NumericPropertyRangeOperator
NUMERIC_PROPERTY_RANGE_OPERATOR_UNSPECIFIED

​

BETWEEN

​

NOT_BETWEEN

​

Response: BatchFilterEventsResponse

events array of Event

​

Fields of Event
uuid string

​

rid string

​

asset_rids array of string

A set of asset rids associated with the event.

origins array of EventOrigin

A set of origins associated with the event.

Fields of EventOrigin
one of 6 fields

​

workbook WorkbookEventOrigin

This event was created in this workbook.

Fields of WorkbookEventOrigin
rid string

​

data array of WorkbookDataAssociation

Data visualizations to associate this event with.

Fields of WorkbookDataAssociation
time_series_channel TimeSeriesChannelAssociation

​

Fields of TimeSeriesChannelAssociation
variable_name string

​

tags map of string to string

If this variable is grouped, the tags within the groupings this event should associate with.

template TemplateEventOrigin

This event was created in this template.

Fields of TemplateEventOrigin
rid string

​

api ApiEventOrigin

This event was created programmatically via the API.

data_review DataReviewEventOrigin

This event was created automatically from a checklist execution.

Fields of DataReviewEventOrigin
data_review_rid string

​

check_metadata CheckOriginMetadata

Metadata about the check that created this event.

Fields of CheckOriginMetadata
check_evaluation_rid string

​

check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

procedure ProcedureEventOrigin

This event was created automatically from a procedure execution.

Fields of ProcedureEventOrigin
procedure_execution_rid string

​

procedure_rid string

​

step_id string

​

streaming_checklist StreamingChecklistEventOrigin

This event was created automatically from the execution of a streaming checklist.

Fields of StreamingChecklistEventOrigin
checklist_rid string

​

check_metadata StreamingCheckOriginMetadata

Metadata about the check that created this event.

Fields of StreamingCheckOriginMetadata
check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

timestamp Timestamp

​

Fields of Timestamp
seconds integer (int64)

​

nanos integer (int64)

​

duration Duration

​

Fields of Duration
seconds integer (int64)

​

nanos integer (int64)

​

name string

​

description string

​

type EventType

​

Values of EventType
EVENT_TYPE_UNSPECIFIED

​

INFO

​

FLAG

​

ERROR

​

SUCCESS

​

labels array of string

​

properties map of string to string deprecated

​

is_archived boolean

​

created_by string

The user who created the event. This field may be missing for legacy events.

disposition EventDisposition

​

Fields of EventDisposition
priority Priority

​

Values of Priority
PRIORITY_UNSPECIFIED

​

P0

​

P1

​

P2

​

P3

​

P4

​

state DispositionState

​

Fields of DispositionState
one of pending_review, closed_with_further_action, closed_with_ignore

​

pending_review PendingReviewDispositionState

​

Fields of PendingReviewDispositionState
opened_by string

​

closed_with_further_action ClosedWithFurtherActionDispositionState

​

Fields of ClosedWithFurtherActionDispositionState
closed_by string

​

closed_with_ignore ClosedWithIgnoreDispositionState

​

Fields of ClosedWithIgnoreDispositionState
closed_by string

​

assignees array of string

​

typed_properties map of string to TypedPropertyValue

​

Fields of TypedPropertyValue
one of string_value, numeric_value

​

string_value string

​

numeric_value number

​

Request

import grpc
from nominal.protos.event.v2 import event_pb2, event_pb2_grpc

channel = grpc.secure_channel("api.gov.nominal.io:443", grpc.ssl_channel_credentials())
event_service = event_pb2_grpc.EventServiceStub(channel)
auth = [("authorization", "Bearer <api key>")]

request = event_pb2.BatchFilterEventsRequest(
    event_rids=["<event rids>"],
    filter_query={"archived": True},
)
response = event_service.BatchFilterEvents(request, metadata=auth)
print(response)
package main

import (
	"context"
	"crypto/tls"
	"fmt"
	"log"

	eventv2 "github.com/nominal-io/nominal-api-protos-go/nominal/protos/event/v2"
	"google.golang.org/grpc"
	"google.golang.org/grpc/credentials"
	"google.golang.org/grpc/metadata"
)

func main() {
	conn, err := grpc.NewClient("api.gov.nominal.io:443",
		grpc.WithTransportCredentials(credentials.NewTLS(&tls.Config{})))
	if err != nil {
		log.Fatal(err)
	}
	defer conn.Close()
	eventService := eventv2.NewEventServiceClient(conn)
	ctx := metadata.AppendToOutgoingContext(context.Background(), "authorization", "Bearer <api key>")

	request := &eventv2.BatchFilterEventsRequest{
		EventRids: []string{
			"<event rids>",
		},
		FilterQuery: &eventv2.SearchQuery{
			SearchQuery: &eventv2.SearchQuery_Archived{Archived: true},
		},
	}
	response, err := eventService.BatchFilterEvents(ctx, request)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Println(response)
}

Response

{
  "events": [
    {
      "uuid": "<uuid>",
      "rid": "<rid>",
      "asset_rids": [
        "<asset rids>"
      ],
      "origins": [
        {
          "workbook": {
            "rid": "<rid>",
            "data": [
              {
                "time_series_channel": {
                  "variable_name": "<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>"
      },
      "is_archived": true,
      "created_by": "<created by>",
      "disposition": {
        "priority": "P0",
        "state": {
          "pending_review": {
            "opened_by": "<opened by>"
          }
        },
        "assignees": [
          "<assignees>"
        ]
      },
      "typed_properties": {
        "<key>": {
          "string_value": "<string value>"
        }
      }
    }
  ]
}

Batch find events#

gRPC /nominal.event.v2.EventService/BatchFindEvents

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.

Request: BatchFindEventsRequest

query SearchQuery

The base query every batched find matches against, combined with each query’s asset and window constraints.

Fields of SearchQuery
one of 41 fields

​

archived boolean

​

search_text string

Search text to perform fuzzy searching against.

exact_match string

Search text to perform exact matching against on the event name and description.

after Timestamp

Filters to events after this timestamp, exclusive.

Fields of Timestamp
seconds integer (int64)

​

nanos integer (int64)

​

before Timestamp

Filters to events before this timestamp, exclusive.

advanced_time_filter EventTimeFilter

​

Fields of EventTimeFilter
timestamp Timestamp

​

timestamp_condition EventTimeFilterCondition

​

Values of 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

​

asset string

​

assets AssetsFilter

​

Fields of AssetsFilter
operator SetOperator

​

Values of SetOperator
SET_OPERATOR_UNSPECIFIED

​

AND

​

OR

​

assets array of string

​

template string

​

workbook string

​

data_review string

​

data_reviews DataReviewsFilter

​

Fields of DataReviewsFilter
data_reviews array of string

​

origin_type SearchEventOriginType

​

Values of SearchEventOriginType
SEARCH_EVENT_ORIGIN_TYPE_UNSPECIFIED

​

WORKBOOK

​

TEMPLATE

​

API

​

DATA_REVIEW

​

PROCEDURE

​

STREAMING_CHECKLIST

​

origin_types OriginTypesFilter

​

Fields of OriginTypesFilter
operator SetOperator

​

origin_types array of SearchEventOriginType

​

data_review_check string

​

data_review_checks DataReviewChecksFilter

​

Fields of DataReviewChecksFilter
data_review_checks array of string

​

disposition_status EventDispositionStatus

​

Values of EventDispositionStatus
EVENT_DISPOSITION_STATUS_UNSPECIFIED

​

PENDING_REVIEW

​

CLOSED_IGNORED

​

CLOSED_REQUIRES_FURTHER_ACTION

​

NO_DISPOSITION

​

disposition_statuses EventDispositionStatusList

​

Fields of EventDispositionStatusList
values array of EventDispositionStatus

​

priority Priority

​

Values of Priority
PRIORITY_UNSPECIFIED

​

P0

​

P1

​

P2

​

P3

​

P4

​

priorities PriorityList

​

Fields of PriorityList
values array of Priority

​

assignee string

​

assignees AssigneesFilter

​

Fields of AssigneesFilter
operator SetOperator

​

assignees array of string

​

event_type EventType

​

Values of EventType
EVENT_TYPE_UNSPECIFIED

​

INFO

​

FLAG

​

ERROR

​

SUCCESS

​

event_types EventTypeList

​

Fields of EventTypeList
values array of EventType

​

created_by string

​

created_by_any_of UserRidList

​

Fields of UserRidList
values array of string

​

label string

​

labels LabelsFilter

​

Fields of LabelsFilter
operator SetOperator

​

labels array of string

​

property Property

​

Fields of Property
name string

​

value string

​

properties PropertiesFilter

​

Fields of PropertiesFilter
name string

​

values array of string

​

and SearchQueryList

​

Fields of SearchQueryList
queries array of SearchQuery

​

not SearchQuery

​

workspace string

​

procedure string

​

procedure_execution string

​

step_id string

​

streaming_checklist string

Filters to events created from a checklist executing in streaming.

streaming_check string

Filters to events created from the check of a checklist executing in streaming.

numeric_property NumericPropertyPredicate

Matches events using a numeric property comparison.

Fields of NumericPropertyPredicate
name string

​

value number

​

operator PropertyComparisonOperator

​

Values of PropertyComparisonOperator
PROPERTY_COMPARISON_OPERATOR_UNSPECIFIED

​

EQ

​

NEQ

​

GT

​

GTE

​

LT

​

LTE

​

numeric_property_range NumericPropertyRangePredicate

Matches events using an inclusive numeric property range.

Fields of NumericPropertyRangePredicate
name string

​

min number

​

max number

​

operator NumericPropertyRangeOperator

​

Values of NumericPropertyRangeOperator
NUMERIC_PROPERTY_RANGE_OPERATOR_UNSPECIFIED

​

BETWEEN

​

NOT_BETWEEN

​

sort SortOptions

​

Fields of SortOptions
is_descending boolean

​

field SortField

​

Values of SortField
SORT_FIELD_UNSPECIFIED

​

START_TIME

​

END_TIME

​

DURATION

​

DISPOSITION_STATUS

​

PRIORITY

​

EVENT_NAME

​

queries array of FindEventsQuery

Rejects batches with more than 1k queries.

Fields of FindEventsQuery
asset_rids array of string

When non-empty, only events associated with at least one of these assets match. When empty, events match on the time window alone.

start_inclusive Timestamp

Half-open window [start_inclusive, end_exclusive) over event start times. An absent bound leaves that side of the window open.

end_exclusive Timestamp

​

index integer

Zero-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: BatchFindEventsResponse

results array of FindEventsResult

One result per request query, in the same order.

Fields of FindEventsResult
event Event

Absent when no event matches the query at the requested index.

Fields of Event
uuid string

​

rid string

​

asset_rids array of string

A set of asset rids associated with the event.

origins array of EventOrigin

A set of origins associated with the event.

Fields of EventOrigin
one of 6 fields

​

workbook WorkbookEventOrigin

This event was created in this workbook.

Fields of WorkbookEventOrigin
rid string

​

data array of WorkbookDataAssociation

Data visualizations to associate this event with.

Fields of WorkbookDataAssociation
time_series_channel TimeSeriesChannelAssociation

​

Fields of TimeSeriesChannelAssociation
variable_name string

​

tags map of string to string

If this variable is grouped, the tags within the groupings this event should associate with.

template TemplateEventOrigin

This event was created in this template.

Fields of TemplateEventOrigin
rid string

​

api ApiEventOrigin

This event was created programmatically via the API.

data_review DataReviewEventOrigin

This event was created automatically from a checklist execution.

Fields of DataReviewEventOrigin
data_review_rid string

​

check_metadata CheckOriginMetadata

Metadata about the check that created this event.

Fields of CheckOriginMetadata
check_evaluation_rid string

​

check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

procedure ProcedureEventOrigin

This event was created automatically from a procedure execution.

Fields of ProcedureEventOrigin
procedure_execution_rid string

​

procedure_rid string

​

step_id string

​

streaming_checklist StreamingChecklistEventOrigin

This event was created automatically from the execution of a streaming checklist.

Fields of StreamingChecklistEventOrigin
checklist_rid string

​

check_metadata StreamingCheckOriginMetadata

Metadata about the check that created this event.

Fields of StreamingCheckOriginMetadata
check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

timestamp Timestamp

​

Fields of Timestamp
seconds integer (int64)

​

nanos integer (int64)

​

duration Duration

​

Fields of Duration
seconds integer (int64)

​

nanos integer (int64)

​

name string

​

description string

​

type EventType

​

Values of EventType
EVENT_TYPE_UNSPECIFIED

​

INFO

​

FLAG

​

ERROR

​

SUCCESS

​

labels array of string

​

properties map of string to string deprecated

​

is_archived boolean

​

created_by string

The user who created the event. This field may be missing for legacy events.

disposition EventDisposition

​

Fields of EventDisposition
priority Priority

​

Values of Priority
PRIORITY_UNSPECIFIED

​

P0

​

P1

​

P2

​

P3

​

P4

​

state DispositionState

​

Fields of DispositionState
one of pending_review, closed_with_further_action, closed_with_ignore

​

pending_review PendingReviewDispositionState

​

Fields of PendingReviewDispositionState
opened_by string

​

closed_with_further_action ClosedWithFurtherActionDispositionState

​

Fields of ClosedWithFurtherActionDispositionState
closed_by string

​

closed_with_ignore ClosedWithIgnoreDispositionState

​

Fields of ClosedWithIgnoreDispositionState
closed_by string

​

assignees array of string

​

typed_properties map of string to TypedPropertyValue

​

Fields of TypedPropertyValue
one of string_value, numeric_value

​

string_value string

​

numeric_value number

​

Request

import grpc
from nominal.protos.event.v2 import event_pb2, event_pb2_grpc

channel = grpc.secure_channel("api.gov.nominal.io:443", grpc.ssl_channel_credentials())
event_service = event_pb2_grpc.EventServiceStub(channel)
auth = [("authorization", "Bearer <api key>")]

request = event_pb2.BatchFindEventsRequest(
    query={"archived": True},
    sort={"is_descending": True, "field": "START_TIME"},
    queries=[
        {
            "asset_rids": ["<asset rids>"],
            "start_inclusive": {"seconds": 1, "nanos": 1},
            "end_exclusive": {"seconds": 1, "nanos": 1},
            "index": 1,
        },
    ],
)
response = event_service.BatchFindEvents(request, metadata=auth)
print(response)
package main

import (
	"context"
	"crypto/tls"
	"fmt"
	"log"

	eventv2 "github.com/nominal-io/nominal-api-protos-go/nominal/protos/event/v2"
	typestime "github.com/nominal-io/nominal-api-protos-go/nominal/protos/types/time"
	"google.golang.org/grpc"
	"google.golang.org/grpc/credentials"
	"google.golang.org/grpc/metadata"
	"google.golang.org/protobuf/proto"
)

func main() {
	conn, err := grpc.NewClient("api.gov.nominal.io:443",
		grpc.WithTransportCredentials(credentials.NewTLS(&tls.Config{})))
	if err != nil {
		log.Fatal(err)
	}
	defer conn.Close()
	eventService := eventv2.NewEventServiceClient(conn)
	ctx := metadata.AppendToOutgoingContext(context.Background(), "authorization", "Bearer <api key>")

	request := &eventv2.BatchFindEventsRequest{
		Query: &eventv2.SearchQuery{
			SearchQuery: &eventv2.SearchQuery_Archived{Archived: true},
		},
		Sort: &eventv2.SortOptions{
			IsDescending: true,
			Field:        eventv2.SortField_START_TIME,
		},
		Queries: []*eventv2.FindEventsQuery{
			{
				AssetRids: []string{
					"<asset rids>",
				},
				StartInclusive: &typestime.Timestamp{
					Seconds: proto.Int64(1),
					Nanos:   proto.Int64(1),
				},
				EndExclusive: &typestime.Timestamp{
					Seconds: proto.Int64(1),
					Nanos:   proto.Int64(1),
				},
				Index: 1,
			},
		},
	}
	response, err := eventService.BatchFindEvents(ctx, request)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Println(response)
}

Response

{
  "results": [
    {
      "event": {
        "uuid": "<uuid>",
        "rid": "<rid>",
        "asset_rids": [
          "<asset rids>"
        ],
        "origins": [
          {
            "workbook": {
              "rid": "<rid>",
              "data": [
                {
                  "time_series_channel": {
                    "variable_name": "<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>"
        },
        "is_archived": true,
        "created_by": "<created by>",
        "disposition": {
          "priority": "P0",
          "state": {
            "pending_review": {
              "opened_by": "<opened by>"
            }
          },
          "assignees": [
            "<assignees>"
          ]
        },
        "typed_properties": {
          "<key>": {
            "string_value": "<string value>"
          }
        }
      }
    }
  ]
}

Batch get events#

gRPC /nominal.event.v2.EventService/BatchGetEvents

Gets a set of events by RID.

Request: BatchGetEventsRequest

event_rids array of string

​

Response: BatchGetEventsResponse

events array of Event

​

Fields of Event
uuid string

​

rid string

​

asset_rids array of string

A set of asset rids associated with the event.

origins array of EventOrigin

A set of origins associated with the event.

Fields of EventOrigin
one of 6 fields

​

workbook WorkbookEventOrigin

This event was created in this workbook.

Fields of WorkbookEventOrigin
rid string

​

data array of WorkbookDataAssociation

Data visualizations to associate this event with.

Fields of WorkbookDataAssociation
time_series_channel TimeSeriesChannelAssociation

​

Fields of TimeSeriesChannelAssociation
variable_name string

​

tags map of string to string

If this variable is grouped, the tags within the groupings this event should associate with.

template TemplateEventOrigin

This event was created in this template.

Fields of TemplateEventOrigin
rid string

​

api ApiEventOrigin

This event was created programmatically via the API.

data_review DataReviewEventOrigin

This event was created automatically from a checklist execution.

Fields of DataReviewEventOrigin
data_review_rid string

​

check_metadata CheckOriginMetadata

Metadata about the check that created this event.

Fields of CheckOriginMetadata
check_evaluation_rid string

​

check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

procedure ProcedureEventOrigin

This event was created automatically from a procedure execution.

Fields of ProcedureEventOrigin
procedure_execution_rid string

​

procedure_rid string

​

step_id string

​

streaming_checklist StreamingChecklistEventOrigin

This event was created automatically from the execution of a streaming checklist.

Fields of StreamingChecklistEventOrigin
checklist_rid string

​

check_metadata StreamingCheckOriginMetadata

Metadata about the check that created this event.

Fields of StreamingCheckOriginMetadata
check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

timestamp Timestamp

​

Fields of Timestamp
seconds integer (int64)

​

nanos integer (int64)

​

duration Duration

​

Fields of Duration
seconds integer (int64)

​

nanos integer (int64)

​

name string

​

description string

​

type EventType

​

Values of EventType
EVENT_TYPE_UNSPECIFIED

​

INFO

​

FLAG

​

ERROR

​

SUCCESS

​

labels array of string

​

properties map of string to string deprecated

​

is_archived boolean

​

created_by string

The user who created the event. This field may be missing for legacy events.

disposition EventDisposition

​

Fields of EventDisposition
priority Priority

​

Values of Priority
PRIORITY_UNSPECIFIED

​

P0

​

P1

​

P2

​

P3

​

P4

​

state DispositionState

​

Fields of DispositionState
one of pending_review, closed_with_further_action, closed_with_ignore

​

pending_review PendingReviewDispositionState

​

Fields of PendingReviewDispositionState
opened_by string

​

closed_with_further_action ClosedWithFurtherActionDispositionState

​

Fields of ClosedWithFurtherActionDispositionState
closed_by string

​

closed_with_ignore ClosedWithIgnoreDispositionState

​

Fields of ClosedWithIgnoreDispositionState
closed_by string

​

assignees array of string

​

typed_properties map of string to TypedPropertyValue

​

Fields of TypedPropertyValue
one of string_value, numeric_value

​

string_value string

​

numeric_value number

​

Request

import grpc
from nominal.protos.event.v2 import event_pb2, event_pb2_grpc

channel = grpc.secure_channel("api.gov.nominal.io:443", grpc.ssl_channel_credentials())
event_service = event_pb2_grpc.EventServiceStub(channel)
auth = [("authorization", "Bearer <api key>")]

request = event_pb2.BatchGetEventsRequest(event_rids=["<event rids>"])
response = event_service.BatchGetEvents(request, metadata=auth)
print(response)
package main

import (
	"context"
	"crypto/tls"
	"fmt"
	"log"

	eventv2 "github.com/nominal-io/nominal-api-protos-go/nominal/protos/event/v2"
	"google.golang.org/grpc"
	"google.golang.org/grpc/credentials"
	"google.golang.org/grpc/metadata"
)

func main() {
	conn, err := grpc.NewClient("api.gov.nominal.io:443",
		grpc.WithTransportCredentials(credentials.NewTLS(&tls.Config{})))
	if err != nil {
		log.Fatal(err)
	}
	defer conn.Close()
	eventService := eventv2.NewEventServiceClient(conn)
	ctx := metadata.AppendToOutgoingContext(context.Background(), "authorization", "Bearer <api key>")

	request := &eventv2.BatchGetEventsRequest{
		EventRids: []string{
			"<event rids>",
		},
	}
	response, err := eventService.BatchGetEvents(ctx, request)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Println(response)
}

Response

{
  "events": [
    {
      "uuid": "<uuid>",
      "rid": "<rid>",
      "asset_rids": [
        "<asset rids>"
      ],
      "origins": [
        {
          "workbook": {
            "rid": "<rid>",
            "data": [
              {
                "time_series_channel": {
                  "variable_name": "<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>"
      },
      "is_archived": true,
      "created_by": "<created by>",
      "disposition": {
        "priority": "P0",
        "state": {
          "pending_review": {
            "opened_by": "<opened by>"
          }
        },
        "assignees": [
          "<assignees>"
        ]
      },
      "typed_properties": {
        "<key>": {
          "string_value": "<string value>"
        }
      }
    }
  ]
}

Batch unarchive event#

gRPC /nominal.event.v2.EventService/BatchUnarchiveEvent

Unarchives a set of events.

Request: BatchUnarchiveEventRequest

event_rids array of string

​

Response: BatchUnarchiveEventResponse

A message with no fields.

Request

import grpc
from nominal.protos.event.v2 import event_pb2, event_pb2_grpc

channel = grpc.secure_channel("api.gov.nominal.io:443", grpc.ssl_channel_credentials())
event_service = event_pb2_grpc.EventServiceStub(channel)
auth = [("authorization", "Bearer <api key>")]

request = event_pb2.BatchUnarchiveEventRequest(event_rids=["<event rids>"])
response = event_service.BatchUnarchiveEvent(request, metadata=auth)
print(response)
package main

import (
	"context"
	"crypto/tls"
	"fmt"
	"log"

	eventv2 "github.com/nominal-io/nominal-api-protos-go/nominal/protos/event/v2"
	"google.golang.org/grpc"
	"google.golang.org/grpc/credentials"
	"google.golang.org/grpc/metadata"
)

func main() {
	conn, err := grpc.NewClient("api.gov.nominal.io:443",
		grpc.WithTransportCredentials(credentials.NewTLS(&tls.Config{})))
	if err != nil {
		log.Fatal(err)
	}
	defer conn.Close()
	eventService := eventv2.NewEventServiceClient(conn)
	ctx := metadata.AppendToOutgoingContext(context.Background(), "authorization", "Bearer <api key>")

	request := &eventv2.BatchUnarchiveEventRequest{
		EventRids: []string{
			"<event rids>",
		},
	}
	response, err := eventService.BatchUnarchiveEvent(ctx, request)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Println(response)
}

Response

{}

Batch update disposition#

gRPC /nominal.event.v2.EventService/BatchUpdateDisposition

Updates the disposition of a set of events.

Request: BatchUpdateDispositionRequest

requests array of UpdateDispositionRequest

​

Fields of UpdateDispositionRequest
rid string

​

disposition EventDisposition

The new disposition for the event. If empty, removes the disposition from the event.

Fields of EventDisposition
priority Priority

​

Values of Priority
PRIORITY_UNSPECIFIED

​

P0

​

P1

​

P2

​

P3

​

P4

​

state DispositionState

​

Fields of DispositionState
one of pending_review, closed_with_further_action, closed_with_ignore

​

pending_review PendingReviewDispositionState

​

Fields of PendingReviewDispositionState
opened_by string

​

closed_with_further_action ClosedWithFurtherActionDispositionState

​

Fields of ClosedWithFurtherActionDispositionState
closed_by string

​

closed_with_ignore ClosedWithIgnoreDispositionState

​

Fields of ClosedWithIgnoreDispositionState
closed_by string

​

assignees array of string

​

Response: BatchUpdateDispositionResponse

events array of Event

​

Fields of Event
uuid string

​

rid string

​

asset_rids array of string

A set of asset rids associated with the event.

origins array of EventOrigin

A set of origins associated with the event.

Fields of EventOrigin
one of 6 fields

​

workbook WorkbookEventOrigin

This event was created in this workbook.

Fields of WorkbookEventOrigin
rid string

​

data array of WorkbookDataAssociation

Data visualizations to associate this event with.

Fields of WorkbookDataAssociation
time_series_channel TimeSeriesChannelAssociation

​

Fields of TimeSeriesChannelAssociation
variable_name string

​

tags map of string to string

If this variable is grouped, the tags within the groupings this event should associate with.

template TemplateEventOrigin

This event was created in this template.

Fields of TemplateEventOrigin
rid string

​

api ApiEventOrigin

This event was created programmatically via the API.

data_review DataReviewEventOrigin

This event was created automatically from a checklist execution.

Fields of DataReviewEventOrigin
data_review_rid string

​

check_metadata CheckOriginMetadata

Metadata about the check that created this event.

Fields of CheckOriginMetadata
check_evaluation_rid string

​

check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

procedure ProcedureEventOrigin

This event was created automatically from a procedure execution.

Fields of ProcedureEventOrigin
procedure_execution_rid string

​

procedure_rid string

​

step_id string

​

streaming_checklist StreamingChecklistEventOrigin

This event was created automatically from the execution of a streaming checklist.

Fields of StreamingChecklistEventOrigin
checklist_rid string

​

check_metadata StreamingCheckOriginMetadata

Metadata about the check that created this event.

Fields of StreamingCheckOriginMetadata
check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

timestamp Timestamp

​

Fields of Timestamp
seconds integer (int64)

​

nanos integer (int64)

​

duration Duration

​

Fields of Duration
seconds integer (int64)

​

nanos integer (int64)

​

name string

​

description string

​

type EventType

​

Values of EventType
EVENT_TYPE_UNSPECIFIED

​

INFO

​

FLAG

​

ERROR

​

SUCCESS

​

labels array of string

​

properties map of string to string deprecated

​

is_archived boolean

​

created_by string

The user who created the event. This field may be missing for legacy events.

disposition EventDisposition

​

Fields of EventDisposition
priority Priority

​

Values of Priority
PRIORITY_UNSPECIFIED

​

P0

​

P1

​

P2

​

P3

​

P4

​

state DispositionState

​

Fields of DispositionState
one of pending_review, closed_with_further_action, closed_with_ignore

​

pending_review PendingReviewDispositionState

​

Fields of PendingReviewDispositionState
opened_by string

​

closed_with_further_action ClosedWithFurtherActionDispositionState

​

Fields of ClosedWithFurtherActionDispositionState
closed_by string

​

closed_with_ignore ClosedWithIgnoreDispositionState

​

Fields of ClosedWithIgnoreDispositionState
closed_by string

​

assignees array of string

​

typed_properties map of string to TypedPropertyValue

​

Fields of TypedPropertyValue
one of string_value, numeric_value

​

string_value string

​

numeric_value number

​

Request

import grpc
from nominal.protos.event.v2 import event_pb2, event_pb2_grpc

channel = grpc.secure_channel("api.gov.nominal.io:443", grpc.ssl_channel_credentials())
event_service = event_pb2_grpc.EventServiceStub(channel)
auth = [("authorization", "Bearer <api key>")]

request = event_pb2.BatchUpdateDispositionRequest(
    requests=[
        {
            "rid": "<rid>",
            "disposition": {
                "priority": "P0",
                "state": {"pending_review": {"opened_by": "<opened by>"}},
                "assignees": ["<assignees>"],
            },
        },
    ],
)
response = event_service.BatchUpdateDisposition(request, metadata=auth)
print(response)
package main

import (
	"context"
	"crypto/tls"
	"fmt"
	"log"

	eventv2 "github.com/nominal-io/nominal-api-protos-go/nominal/protos/event/v2"
	"google.golang.org/grpc"
	"google.golang.org/grpc/credentials"
	"google.golang.org/grpc/metadata"
)

func main() {
	conn, err := grpc.NewClient("api.gov.nominal.io:443",
		grpc.WithTransportCredentials(credentials.NewTLS(&tls.Config{})))
	if err != nil {
		log.Fatal(err)
	}
	defer conn.Close()
	eventService := eventv2.NewEventServiceClient(conn)
	ctx := metadata.AppendToOutgoingContext(context.Background(), "authorization", "Bearer <api key>")

	request := &eventv2.BatchUpdateDispositionRequest{
		Requests: []*eventv2.UpdateDispositionRequest{
			{
				Rid: "<rid>",
				Disposition: &eventv2.EventDisposition{
					Priority: eventv2.Priority_P0,
					State: &eventv2.DispositionState{
						DispositionState: &eventv2.DispositionState_PendingReview{PendingReview: &eventv2.PendingReviewDispositionState{
							OpenedBy: "<opened by>",
						}},
					},
					Assignees: []string{
						"<assignees>",
					},
				},
			},
		},
	}
	response, err := eventService.BatchUpdateDisposition(ctx, request)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Println(response)
}

Response

{
  "events": [
    {
      "uuid": "<uuid>",
      "rid": "<rid>",
      "asset_rids": [
        "<asset rids>"
      ],
      "origins": [
        {
          "workbook": {
            "rid": "<rid>",
            "data": [
              {
                "time_series_channel": {
                  "variable_name": "<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>"
      },
      "is_archived": true,
      "created_by": "<created by>",
      "disposition": {
        "priority": "P0",
        "state": {
          "pending_review": {
            "opened_by": "<opened by>"
          }
        },
        "assignees": [
          "<assignees>"
        ]
      },
      "typed_properties": {
        "<key>": {
          "string_value": "<string value>"
        }
      }
    }
  ]
}

Batch update event#

gRPC /nominal.event.v2.EventService/BatchUpdateEvent

Updates the fields of an event specified by each request in the batch. Empty fields are left unchanged.

Request: BatchUpdateEventRequest

updates array of EventUpdate

​

Fields of EventUpdate
rid string

​

asset_rids AssetRidSet

If provided, replaces the existing asset rids. If provided, must contain at least one asset rid.

Fields of AssetRidSet
asset_rids array of string

​

timestamp Timestamp

​

Fields of Timestamp
seconds integer (int64)

​

nanos integer (int64)

​

duration Duration

​

Fields of Duration
seconds integer (int64)

​

nanos integer (int64)

​

name string

​

description string

​

type EventType

​

Values of EventType
EVENT_TYPE_UNSPECIFIED

​

INFO

​

FLAG

​

ERROR

​

SUCCESS

​

labels LabelUpdateWrapper

​

Fields of LabelUpdateWrapper
labels array of string

​

properties PropertyUpdateWrapper deprecated

​

Fields of PropertyUpdateWrapper
properties map of string to string

​

typed_properties TypedPropertyUpdateWrapper

​

Fields of TypedPropertyUpdateWrapper
typed_properties map of string to TypedPropertyValue

​

Fields of TypedPropertyValue
one of string_value, numeric_value required

​

string_value string

​

numeric_value number

​

Response: BatchUpdateEventResponse

events array of Event

​

Fields of Event
uuid string

​

rid string

​

asset_rids array of string

A set of asset rids associated with the event.

origins array of EventOrigin

A set of origins associated with the event.

Fields of EventOrigin
one of 6 fields

​

workbook WorkbookEventOrigin

This event was created in this workbook.

Fields of WorkbookEventOrigin
rid string

​

data array of WorkbookDataAssociation

Data visualizations to associate this event with.

Fields of WorkbookDataAssociation
time_series_channel TimeSeriesChannelAssociation

​

Fields of TimeSeriesChannelAssociation
variable_name string

​

tags map of string to string

If this variable is grouped, the tags within the groupings this event should associate with.

template TemplateEventOrigin

This event was created in this template.

Fields of TemplateEventOrigin
rid string

​

api ApiEventOrigin

This event was created programmatically via the API.

data_review DataReviewEventOrigin

This event was created automatically from a checklist execution.

Fields of DataReviewEventOrigin
data_review_rid string

​

check_metadata CheckOriginMetadata

Metadata about the check that created this event.

Fields of CheckOriginMetadata
check_evaluation_rid string

​

check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

procedure ProcedureEventOrigin

This event was created automatically from a procedure execution.

Fields of ProcedureEventOrigin
procedure_execution_rid string

​

procedure_rid string

​

step_id string

​

streaming_checklist StreamingChecklistEventOrigin

This event was created automatically from the execution of a streaming checklist.

Fields of StreamingChecklistEventOrigin
checklist_rid string

​

check_metadata StreamingCheckOriginMetadata

Metadata about the check that created this event.

Fields of StreamingCheckOriginMetadata
check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

timestamp Timestamp

​

Fields of Timestamp
seconds integer (int64)

​

nanos integer (int64)

​

duration Duration

​

Fields of Duration
seconds integer (int64)

​

nanos integer (int64)

​

name string

​

description string

​

type EventType

​

Values of EventType
EVENT_TYPE_UNSPECIFIED

​

INFO

​

FLAG

​

ERROR

​

SUCCESS

​

labels array of string

​

properties map of string to string deprecated

​

is_archived boolean

​

created_by string

The user who created the event. This field may be missing for legacy events.

disposition EventDisposition

​

Fields of EventDisposition
priority Priority

​

Values of Priority
PRIORITY_UNSPECIFIED

​

P0

​

P1

​

P2

​

P3

​

P4

​

state DispositionState

​

Fields of DispositionState
one of pending_review, closed_with_further_action, closed_with_ignore

​

pending_review PendingReviewDispositionState

​

Fields of PendingReviewDispositionState
opened_by string

​

closed_with_further_action ClosedWithFurtherActionDispositionState

​

Fields of ClosedWithFurtherActionDispositionState
closed_by string

​

closed_with_ignore ClosedWithIgnoreDispositionState

​

Fields of ClosedWithIgnoreDispositionState
closed_by string

​

assignees array of string

​

typed_properties map of string to TypedPropertyValue

​

Fields of TypedPropertyValue
one of string_value, numeric_value

​

string_value string

​

numeric_value number

​

Request

import grpc
from nominal.protos.event.v2 import event_pb2, event_pb2_grpc

channel = grpc.secure_channel("api.gov.nominal.io:443", grpc.ssl_channel_credentials())
event_service = event_pb2_grpc.EventServiceStub(channel)
auth = [("authorization", "Bearer <api key>")]

request = event_pb2.BatchUpdateEventRequest(
    updates=[
        {
            "rid": "<rid>",
            "asset_rids": {"asset_rids": ["<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>"}},
            "typed_properties": {
                "typed_properties": {"<key>": {"string_value": "<string value>"}},
            },
        },
    ],
)
response = event_service.BatchUpdateEvent(request, metadata=auth)
print(response)
package main

import (
	"context"
	"crypto/tls"
	"fmt"
	"log"

	eventv2 "github.com/nominal-io/nominal-api-protos-go/nominal/protos/event/v2"
	"github.com/nominal-io/nominal-api-protos-go/nominal/protos/types"
	typestime "github.com/nominal-io/nominal-api-protos-go/nominal/protos/types/time"
	"google.golang.org/grpc"
	"google.golang.org/grpc/credentials"
	"google.golang.org/grpc/metadata"
	"google.golang.org/protobuf/proto"
)

func main() {
	conn, err := grpc.NewClient("api.gov.nominal.io:443",
		grpc.WithTransportCredentials(credentials.NewTLS(&tls.Config{})))
	if err != nil {
		log.Fatal(err)
	}
	defer conn.Close()
	eventService := eventv2.NewEventServiceClient(conn)
	ctx := metadata.AppendToOutgoingContext(context.Background(), "authorization", "Bearer <api key>")

	request := &eventv2.BatchUpdateEventRequest{
		Updates: []*eventv2.EventUpdate{
			{
				Rid: "<rid>",
				AssetRids: &eventv2.AssetRidSet{
					AssetRids: []string{
						"<asset rids>",
					},
				},
				Timestamp: &typestime.Timestamp{
					Seconds: proto.Int64(1),
					Nanos:   proto.Int64(1),
				},
				Duration: &types.Duration{
					Seconds: 1,
					Nanos:   1,
				},
				Name:        proto.String("<name>"),
				Description: proto.String("<description>"),
				Type:        eventv2.EventType_INFO.Enum(),
				Labels: &types.LabelUpdateWrapper{
					Labels: []string{
						"<labels>",
					},
				},
				Properties: &types.PropertyUpdateWrapper{
					Properties: map[string]string{
						"<key>": "<value>",
					},
				},
				TypedProperties: &types.TypedPropertyUpdateWrapper{
					TypedProperties: map[string]*types.TypedPropertyValue{
						"<key>": {
							TypedPropertyValue: &types.TypedPropertyValue_StringValue{StringValue: "<string value>"},
						},
					},
				},
			},
		},
	}
	response, err := eventService.BatchUpdateEvent(ctx, request)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Println(response)
}

Response

{
  "events": [
    {
      "uuid": "<uuid>",
      "rid": "<rid>",
      "asset_rids": [
        "<asset rids>"
      ],
      "origins": [
        {
          "workbook": {
            "rid": "<rid>",
            "data": [
              {
                "time_series_channel": {
                  "variable_name": "<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>"
      },
      "is_archived": true,
      "created_by": "<created by>",
      "disposition": {
        "priority": "P0",
        "state": {
          "pending_review": {
            "opened_by": "<opened by>"
          }
        },
        "assignees": [
          "<assignees>"
        ]
      },
      "typed_properties": {
        "<key>": {
          "string_value": "<string value>"
        }
      }
    }
  ]
}

Create event#

gRPC /nominal.event.v2.EventService/CreateEvent

Creates an event.

Request: CreateEventRequest

asset_rids array of string

Must contain at least one asset rid.

origins array of EventOrigin

If empty, defaults to a single API origin.

Fields of EventOrigin
one of 6 fields

​

workbook WorkbookEventOrigin

This event was created in this workbook.

Fields of WorkbookEventOrigin
rid string

​

data array of WorkbookDataAssociation

Data visualizations to associate this event with.

Fields of WorkbookDataAssociation
time_series_channel TimeSeriesChannelAssociation

​

Fields of TimeSeriesChannelAssociation
variable_name string

​

tags map of string to string

If this variable is grouped, the tags within the groupings this event should associate with.

template TemplateEventOrigin

This event was created in this template.

Fields of TemplateEventOrigin
rid string

​

api ApiEventOrigin

This event was created programmatically via the API.

data_review DataReviewEventOrigin

This event was created automatically from a checklist execution.

Fields of DataReviewEventOrigin
data_review_rid string

​

check_metadata CheckOriginMetadata

Metadata about the check that created this event.

Fields of CheckOriginMetadata
check_evaluation_rid string

​

check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

procedure ProcedureEventOrigin

This event was created automatically from a procedure execution.

Fields of ProcedureEventOrigin
procedure_execution_rid string

​

procedure_rid string

​

step_id string

​

streaming_checklist StreamingChecklistEventOrigin

This event was created automatically from the execution of a streaming checklist.

Fields of StreamingChecklistEventOrigin
checklist_rid string

​

check_metadata StreamingCheckOriginMetadata

Metadata about the check that created this event.

Fields of StreamingCheckOriginMetadata
check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

timestamp Timestamp

​

Fields of Timestamp
seconds integer (int64)

​

nanos integer (int64)

​

duration Duration

​

Fields of Duration
seconds integer (int64)

​

nanos integer (int64)

​

name string

​

description string

If not provided, defaults to an empty string.

type EventType

​

Values of EventType
EVENT_TYPE_UNSPECIFIED

​

INFO

​

FLAG

​

ERROR

​

SUCCESS

​

labels array of string

​

properties map of string to string deprecated

​

disposition EventDisposition

​

Fields of EventDisposition
priority Priority

​

Values of Priority
PRIORITY_UNSPECIFIED

​

P0

​

P1

​

P2

​

P3

​

P4

​

state DispositionState

​

Fields of DispositionState
one of pending_review, closed_with_further_action, closed_with_ignore

​

pending_review PendingReviewDispositionState

​

Fields of PendingReviewDispositionState
opened_by string

​

closed_with_further_action ClosedWithFurtherActionDispositionState

​

Fields of ClosedWithFurtherActionDispositionState
closed_by string

​

closed_with_ignore ClosedWithIgnoreDispositionState

​

Fields of ClosedWithIgnoreDispositionState
closed_by string

​

assignees array of string

​

typed_properties map of string to TypedPropertyValue

​

Fields of TypedPropertyValue
one of string_value, numeric_value required

​

string_value string

​

numeric_value number

​

Response: CreateEventResponse

event Event

​

Fields of Event
uuid string

​

rid string

​

asset_rids array of string

A set of asset rids associated with the event.

origins array of EventOrigin

A set of origins associated with the event.

Fields of EventOrigin
one of 6 fields

​

workbook WorkbookEventOrigin

This event was created in this workbook.

Fields of WorkbookEventOrigin
rid string

​

data array of WorkbookDataAssociation

Data visualizations to associate this event with.

Fields of WorkbookDataAssociation
time_series_channel TimeSeriesChannelAssociation

​

Fields of TimeSeriesChannelAssociation
variable_name string

​

tags map of string to string

If this variable is grouped, the tags within the groupings this event should associate with.

template TemplateEventOrigin

This event was created in this template.

Fields of TemplateEventOrigin
rid string

​

api ApiEventOrigin

This event was created programmatically via the API.

data_review DataReviewEventOrigin

This event was created automatically from a checklist execution.

Fields of DataReviewEventOrigin
data_review_rid string

​

check_metadata CheckOriginMetadata

Metadata about the check that created this event.

Fields of CheckOriginMetadata
check_evaluation_rid string

​

check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

procedure ProcedureEventOrigin

This event was created automatically from a procedure execution.

Fields of ProcedureEventOrigin
procedure_execution_rid string

​

procedure_rid string

​

step_id string

​

streaming_checklist StreamingChecklistEventOrigin

This event was created automatically from the execution of a streaming checklist.

Fields of StreamingChecklistEventOrigin
checklist_rid string

​

check_metadata StreamingCheckOriginMetadata

Metadata about the check that created this event.

Fields of StreamingCheckOriginMetadata
check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

timestamp Timestamp

​

Fields of Timestamp
seconds integer (int64)

​

nanos integer (int64)

​

duration Duration

​

Fields of Duration
seconds integer (int64)

​

nanos integer (int64)

​

name string

​

description string

​

type EventType

​

Values of EventType
EVENT_TYPE_UNSPECIFIED

​

INFO

​

FLAG

​

ERROR

​

SUCCESS

​

labels array of string

​

properties map of string to string deprecated

​

is_archived boolean

​

created_by string

The user who created the event. This field may be missing for legacy events.

disposition EventDisposition

​

Fields of EventDisposition
priority Priority

​

Values of Priority
PRIORITY_UNSPECIFIED

​

P0

​

P1

​

P2

​

P3

​

P4

​

state DispositionState

​

Fields of DispositionState
one of pending_review, closed_with_further_action, closed_with_ignore

​

pending_review PendingReviewDispositionState

​

Fields of PendingReviewDispositionState
opened_by string

​

closed_with_further_action ClosedWithFurtherActionDispositionState

​

Fields of ClosedWithFurtherActionDispositionState
closed_by string

​

closed_with_ignore ClosedWithIgnoreDispositionState

​

Fields of ClosedWithIgnoreDispositionState
closed_by string

​

assignees array of string

​

typed_properties map of string to TypedPropertyValue

​

Fields of TypedPropertyValue
one of string_value, numeric_value

​

string_value string

​

numeric_value number

​

Request

import grpc
from nominal.protos.event.v2 import event_pb2, event_pb2_grpc

channel = grpc.secure_channel("api.gov.nominal.io:443", grpc.ssl_channel_credentials())
event_service = event_pb2_grpc.EventServiceStub(channel)
auth = [("authorization", "Bearer <api key>")]

request = event_pb2.CreateEventRequest(
    asset_rids=["<asset rids>"],
    origins=[
        {
            "workbook": {
                "rid": "<rid>",
                "data": [
                    {
                        "time_series_channel": {
                            "variable_name": "<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": {"pending_review": {"opened_by": "<opened by>"}},
        "assignees": ["<assignees>"],
    },
    typed_properties={"<key>": {"string_value": "<string value>"}},
)
response = event_service.CreateEvent(request, metadata=auth)
print(response)
package main

import (
	"context"
	"crypto/tls"
	"fmt"
	"log"

	eventv2 "github.com/nominal-io/nominal-api-protos-go/nominal/protos/event/v2"
	"github.com/nominal-io/nominal-api-protos-go/nominal/protos/types"
	typestime "github.com/nominal-io/nominal-api-protos-go/nominal/protos/types/time"
	"google.golang.org/grpc"
	"google.golang.org/grpc/credentials"
	"google.golang.org/grpc/metadata"
	"google.golang.org/protobuf/proto"
)

func main() {
	conn, err := grpc.NewClient("api.gov.nominal.io:443",
		grpc.WithTransportCredentials(credentials.NewTLS(&tls.Config{})))
	if err != nil {
		log.Fatal(err)
	}
	defer conn.Close()
	eventService := eventv2.NewEventServiceClient(conn)
	ctx := metadata.AppendToOutgoingContext(context.Background(), "authorization", "Bearer <api key>")

	request := &eventv2.CreateEventRequest{
		AssetRids: []string{
			"<asset rids>",
		},
		Origins: []*eventv2.EventOrigin{
			{
				EventOrigin: &eventv2.EventOrigin_Workbook{Workbook: &eventv2.WorkbookEventOrigin{
					Rid: "<rid>",
					Data: []*eventv2.WorkbookDataAssociation{
						{
							WorkbookDataAssociation: &eventv2.WorkbookDataAssociation_TimeSeriesChannel{TimeSeriesChannel: &eventv2.TimeSeriesChannelAssociation{
								VariableName: "<variable name>",
								Tags: map[string]string{
									"<key>": "<value>",
								},
							}},
						},
					},
				}},
			},
		},
		Timestamp: &typestime.Timestamp{
			Seconds: proto.Int64(1),
			Nanos:   proto.Int64(1),
		},
		Duration: &types.Duration{
			Seconds: 1,
			Nanos:   1,
		},
		Name:        "<name>",
		Description: proto.String("<description>"),
		Type:        eventv2.EventType_INFO,
		Labels: []string{
			"<labels>",
		},
		Properties: map[string]string{
			"<key>": "<value>",
		},
		Disposition: &eventv2.EventDisposition{
			Priority: eventv2.Priority_P0,
			State: &eventv2.DispositionState{
				DispositionState: &eventv2.DispositionState_PendingReview{PendingReview: &eventv2.PendingReviewDispositionState{
					OpenedBy: "<opened by>",
				}},
			},
			Assignees: []string{
				"<assignees>",
			},
		},
		TypedProperties: map[string]*types.TypedPropertyValue{
			"<key>": {
				TypedPropertyValue: &types.TypedPropertyValue_StringValue{StringValue: "<string value>"},
			},
		},
	}
	response, err := eventService.CreateEvent(ctx, request)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Println(response)
}

Response

{
  "event": {
    "uuid": "<uuid>",
    "rid": "<rid>",
    "asset_rids": [
      "<asset rids>"
    ],
    "origins": [
      {
        "workbook": {
          "rid": "<rid>",
          "data": [
            {
              "time_series_channel": {
                "variable_name": "<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>"
    },
    "is_archived": true,
    "created_by": "<created by>",
    "disposition": {
      "priority": "P0",
      "state": {
        "pending_review": {
          "opened_by": "<opened by>"
        }
      },
      "assignees": [
        "<assignees>"
      ]
    },
    "typed_properties": {
      "<key>": {
        "string_value": "<string value>"
      }
    }
  }
}

Get events#

gRPC /nominal.event.v2.EventService/GetEvents

Gets a set of events by UUIDs.

Request: GetEventsRequest

uuids array of string

​

Response: GetEventsResponse

events array of Event

​

Fields of Event
uuid string

​

rid string

​

asset_rids array of string

A set of asset rids associated with the event.

origins array of EventOrigin

A set of origins associated with the event.

Fields of EventOrigin
one of 6 fields

​

workbook WorkbookEventOrigin

This event was created in this workbook.

Fields of WorkbookEventOrigin
rid string

​

data array of WorkbookDataAssociation

Data visualizations to associate this event with.

Fields of WorkbookDataAssociation
time_series_channel TimeSeriesChannelAssociation

​

Fields of TimeSeriesChannelAssociation
variable_name string

​

tags map of string to string

If this variable is grouped, the tags within the groupings this event should associate with.

template TemplateEventOrigin

This event was created in this template.

Fields of TemplateEventOrigin
rid string

​

api ApiEventOrigin

This event was created programmatically via the API.

data_review DataReviewEventOrigin

This event was created automatically from a checklist execution.

Fields of DataReviewEventOrigin
data_review_rid string

​

check_metadata CheckOriginMetadata

Metadata about the check that created this event.

Fields of CheckOriginMetadata
check_evaluation_rid string

​

check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

procedure ProcedureEventOrigin

This event was created automatically from a procedure execution.

Fields of ProcedureEventOrigin
procedure_execution_rid string

​

procedure_rid string

​

step_id string

​

streaming_checklist StreamingChecklistEventOrigin

This event was created automatically from the execution of a streaming checklist.

Fields of StreamingChecklistEventOrigin
checklist_rid string

​

check_metadata StreamingCheckOriginMetadata

Metadata about the check that created this event.

Fields of StreamingCheckOriginMetadata
check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

timestamp Timestamp

​

Fields of Timestamp
seconds integer (int64)

​

nanos integer (int64)

​

duration Duration

​

Fields of Duration
seconds integer (int64)

​

nanos integer (int64)

​

name string

​

description string

​

type EventType

​

Values of EventType
EVENT_TYPE_UNSPECIFIED

​

INFO

​

FLAG

​

ERROR

​

SUCCESS

​

labels array of string

​

properties map of string to string deprecated

​

is_archived boolean

​

created_by string

The user who created the event. This field may be missing for legacy events.

disposition EventDisposition

​

Fields of EventDisposition
priority Priority

​

Values of Priority
PRIORITY_UNSPECIFIED

​

P0

​

P1

​

P2

​

P3

​

P4

​

state DispositionState

​

Fields of DispositionState
one of pending_review, closed_with_further_action, closed_with_ignore

​

pending_review PendingReviewDispositionState

​

Fields of PendingReviewDispositionState
opened_by string

​

closed_with_further_action ClosedWithFurtherActionDispositionState

​

Fields of ClosedWithFurtherActionDispositionState
closed_by string

​

closed_with_ignore ClosedWithIgnoreDispositionState

​

Fields of ClosedWithIgnoreDispositionState
closed_by string

​

assignees array of string

​

typed_properties map of string to TypedPropertyValue

​

Fields of TypedPropertyValue
one of string_value, numeric_value

​

string_value string

​

numeric_value number

​

Request

import grpc
from nominal.protos.event.v2 import event_pb2, event_pb2_grpc

channel = grpc.secure_channel("api.gov.nominal.io:443", grpc.ssl_channel_credentials())
event_service = event_pb2_grpc.EventServiceStub(channel)
auth = [("authorization", "Bearer <api key>")]

request = event_pb2.GetEventsRequest(uuids=["<uuids>"])
response = event_service.GetEvents(request, metadata=auth)
print(response)
package main

import (
	"context"
	"crypto/tls"
	"fmt"
	"log"

	eventv2 "github.com/nominal-io/nominal-api-protos-go/nominal/protos/event/v2"
	"google.golang.org/grpc"
	"google.golang.org/grpc/credentials"
	"google.golang.org/grpc/metadata"
)

func main() {
	conn, err := grpc.NewClient("api.gov.nominal.io:443",
		grpc.WithTransportCredentials(credentials.NewTLS(&tls.Config{})))
	if err != nil {
		log.Fatal(err)
	}
	defer conn.Close()
	eventService := eventv2.NewEventServiceClient(conn)
	ctx := metadata.AppendToOutgoingContext(context.Background(), "authorization", "Bearer <api key>")

	request := &eventv2.GetEventsRequest{
		Uuids: []string{
			"<uuids>",
		},
	}
	response, err := eventService.GetEvents(ctx, request)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Println(response)
}

Response

{
  "events": [
    {
      "uuid": "<uuid>",
      "rid": "<rid>",
      "asset_rids": [
        "<asset rids>"
      ],
      "origins": [
        {
          "workbook": {
            "rid": "<rid>",
            "data": [
              {
                "time_series_channel": {
                  "variable_name": "<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>"
      },
      "is_archived": true,
      "created_by": "<created by>",
      "disposition": {
        "priority": "P0",
        "state": {
          "pending_review": {
            "opened_by": "<opened by>"
          }
        },
        "assignees": [
          "<assignees>"
        ]
      },
      "typed_properties": {
        "<key>": {
          "string_value": "<string value>"
        }
      }
    }
  ]
}

Get events histogram#

gRPC /nominal.event.v2.EventService/GetEventsHistogram

Gets a histogram of events that match the given filters.

Request: GetEventsHistogramRequest

start_inclusive Timestamp

​

Fields of Timestamp
seconds integer (int64)

​

nanos integer (int64)

​

end_exclusive Timestamp

​

filter_query HistogramFilterQuery

The query to filter the events included in the histogram.

Fields of HistogramFilterQuery
one of 21 fields

​

search_text string

​

asset string

​

template string

​

workbook string

​

data_review string

​

origin_type SearchEventOriginType

​

Values of SearchEventOriginType
SEARCH_EVENT_ORIGIN_TYPE_UNSPECIFIED

​

WORKBOOK

​

TEMPLATE

​

API

​

DATA_REVIEW

​

PROCEDURE

​

STREAMING_CHECKLIST

​

data_review_check string

​

disposition_status EventDispositionStatus

​

Values of EventDispositionStatus
EVENT_DISPOSITION_STATUS_UNSPECIFIED

​

PENDING_REVIEW

​

CLOSED_IGNORED

​

CLOSED_REQUIRES_FURTHER_ACTION

​

NO_DISPOSITION

​

priority Priority

​

Values of Priority
PRIORITY_UNSPECIFIED

​

P0

​

P1

​

P2

​

P3

​

P4

​

assignee string

​

event_type EventType

​

Values of EventType
EVENT_TYPE_UNSPECIFIED

​

INFO

​

FLAG

​

ERROR

​

SUCCESS

​

created_by string

​

label string

​

property Property

​

Fields of Property
name string

​

value string

​

and HistogramFilterQueryList

​

Fields of HistogramFilterQueryList
queries array of HistogramFilterQuery

​

workspace string

​

procedure string

​

procedure_execution string

​

step_id string

​

archived_statuses array of ArchivedStatus

If empty, defaults to NOT_ARCHIVED only.

Values of ArchivedStatus
ARCHIVED_STATUS_UNSPECIFIED

​

NOT_ARCHIVED

​

ARCHIVED

​

num_bins integer

Defaults to 100. Throws if larger than 1_000.

event_limit integer

Limits the number of events included in the histogram. Defaults to 10_000. Throws if larger than 10_000.

Response: GetEventsHistogramResponse

buckets array of EventsHistogramBucket

​

Fields of EventsHistogramBucket
start_inclusive Timestamp

​

Fields of Timestamp
seconds integer (int64)

​

nanos integer (int64)

​

end_exclusive Timestamp

​

count integer

​

Request

import grpc
from nominal.protos.event.v2 import event_pb2, event_pb2_grpc

channel = grpc.secure_channel("api.gov.nominal.io:443", grpc.ssl_channel_credentials())
event_service = event_pb2_grpc.EventServiceStub(channel)
auth = [("authorization", "Bearer <api key>")]

request = event_pb2.GetEventsHistogramRequest(
    start_inclusive={"seconds": 1, "nanos": 1},
    end_exclusive={"seconds": 1, "nanos": 1},
    filter_query={"search_text": "<search text>"},
    archived_statuses=["NOT_ARCHIVED"],
    num_bins=1,
    event_limit=1,
)
response = event_service.GetEventsHistogram(request, metadata=auth)
print(response)
package main

import (
	"context"
	"crypto/tls"
	"fmt"
	"log"

	eventv2 "github.com/nominal-io/nominal-api-protos-go/nominal/protos/event/v2"
	"github.com/nominal-io/nominal-api-protos-go/nominal/protos/types"
	typestime "github.com/nominal-io/nominal-api-protos-go/nominal/protos/types/time"
	"google.golang.org/grpc"
	"google.golang.org/grpc/credentials"
	"google.golang.org/grpc/metadata"
	"google.golang.org/protobuf/proto"
)

func main() {
	conn, err := grpc.NewClient("api.gov.nominal.io:443",
		grpc.WithTransportCredentials(credentials.NewTLS(&tls.Config{})))
	if err != nil {
		log.Fatal(err)
	}
	defer conn.Close()
	eventService := eventv2.NewEventServiceClient(conn)
	ctx := metadata.AppendToOutgoingContext(context.Background(), "authorization", "Bearer <api key>")

	request := &eventv2.GetEventsHistogramRequest{
		StartInclusive: &typestime.Timestamp{
			Seconds: proto.Int64(1),
			Nanos:   proto.Int64(1),
		},
		EndExclusive: &typestime.Timestamp{
			Seconds: proto.Int64(1),
			Nanos:   proto.Int64(1),
		},
		FilterQuery: &eventv2.HistogramFilterQuery{
			HistogramFilterQuery: &eventv2.HistogramFilterQuery_SearchText{SearchText: "<search text>"},
		},
		ArchivedStatuses: []types.ArchivedStatus{
			types.ArchivedStatus_NOT_ARCHIVED,
		},
		NumBins:    proto.Int32(1),
		EventLimit: proto.Int32(1),
	}
	response, err := eventService.GetEventsHistogram(ctx, request)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Println(response)
}

Response

{
  "buckets": [
    {
      "start_inclusive": {
        "seconds": 1,
        "nanos": 1
      },
      "end_exclusive": {
        "seconds": 1,
        "nanos": 1
      },
      "count": 1
    }
  ]
}

List properties and labels#

gRPC /nominal.event.v2.EventService/ListPropertiesAndLabels

Lists the properties and labels of active events in the provided workspaces.

Request: ListPropertiesAndLabelsRequest

workspace_rids array of string

If empty, results come from all workspaces the user belongs to.

Response: ListPropertiesAndLabelsResponse

properties map of string to PropertyValues deprecated

Deprecated: 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 PropertyValues
value array of string

​

labels array of string

​

Request

import grpc
from nominal.protos.event.v2 import event_pb2, event_pb2_grpc

channel = grpc.secure_channel("api.gov.nominal.io:443", grpc.ssl_channel_credentials())
event_service = event_pb2_grpc.EventServiceStub(channel)
auth = [("authorization", "Bearer <api key>")]

request = event_pb2.ListPropertiesAndLabelsRequest(workspace_rids=["<workspace rids>"])
response = event_service.ListPropertiesAndLabels(request, metadata=auth)
print(response)
package main

import (
	"context"
	"crypto/tls"
	"fmt"
	"log"

	eventv2 "github.com/nominal-io/nominal-api-protos-go/nominal/protos/event/v2"
	"google.golang.org/grpc"
	"google.golang.org/grpc/credentials"
	"google.golang.org/grpc/metadata"
)

func main() {
	conn, err := grpc.NewClient("api.gov.nominal.io:443",
		grpc.WithTransportCredentials(credentials.NewTLS(&tls.Config{})))
	if err != nil {
		log.Fatal(err)
	}
	defer conn.Close()
	eventService := eventv2.NewEventServiceClient(conn)
	ctx := metadata.AppendToOutgoingContext(context.Background(), "authorization", "Bearer <api key>")

	request := &eventv2.ListPropertiesAndLabelsRequest{
		WorkspaceRids: []string{
			"<workspace rids>",
		},
	}
	response, err := eventService.ListPropertiesAndLabels(ctx, request)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Println(response)
}

Response

{
  "properties": {
    "<key>": {
      "value": [
        "<value>"
      ]
    }
  },
  "labels": [
    "<labels>"
  ]
}

Search events#

gRPC /nominal.event.v2.EventService/SearchEvents

Searches for events that match the given filters.

Request: SearchEventsRequest

sort SortOptions

​

Fields of SortOptions
is_descending boolean

​

field SortField

​

Values of SortField
SORT_FIELD_UNSPECIFIED

​

START_TIME

​

END_TIME

​

DURATION

​

DISPOSITION_STATUS

​

PRIORITY

​

EVENT_NAME

​

page_size integer

Rejects page sizes greater than 10k.

next_page_token string

​

query SearchQuery

​

Fields of SearchQuery
one of 41 fields

​

archived boolean

​

search_text string

Search text to perform fuzzy searching against.

exact_match string

Search text to perform exact matching against on the event name and description.

after Timestamp

Filters to events after this timestamp, exclusive.

Fields of Timestamp
seconds integer (int64)

​

nanos integer (int64)

​

before Timestamp

Filters to events before this timestamp, exclusive.

advanced_time_filter EventTimeFilter

​

Fields of EventTimeFilter
timestamp Timestamp

​

timestamp_condition EventTimeFilterCondition

​

Values of 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

​

asset string

​

assets AssetsFilter

​

Fields of AssetsFilter
operator SetOperator

​

Values of SetOperator
SET_OPERATOR_UNSPECIFIED

​

AND

​

OR

​

assets array of string

​

template string

​

workbook string

​

data_review string

​

data_reviews DataReviewsFilter

​

Fields of DataReviewsFilter
data_reviews array of string

​

origin_type SearchEventOriginType

​

Values of SearchEventOriginType
SEARCH_EVENT_ORIGIN_TYPE_UNSPECIFIED

​

WORKBOOK

​

TEMPLATE

​

API

​

DATA_REVIEW

​

PROCEDURE

​

STREAMING_CHECKLIST

​

origin_types OriginTypesFilter

​

Fields of OriginTypesFilter
operator SetOperator

​

origin_types array of SearchEventOriginType

​

data_review_check string

​

data_review_checks DataReviewChecksFilter

​

Fields of DataReviewChecksFilter
data_review_checks array of string

​

disposition_status EventDispositionStatus

​

Values of EventDispositionStatus
EVENT_DISPOSITION_STATUS_UNSPECIFIED

​

PENDING_REVIEW

​

CLOSED_IGNORED

​

CLOSED_REQUIRES_FURTHER_ACTION

​

NO_DISPOSITION

​

disposition_statuses EventDispositionStatusList

​

Fields of EventDispositionStatusList
values array of EventDispositionStatus

​

priority Priority

​

Values of Priority
PRIORITY_UNSPECIFIED

​

P0

​

P1

​

P2

​

P3

​

P4

​

priorities PriorityList

​

Fields of PriorityList
values array of Priority

​

assignee string

​

assignees AssigneesFilter

​

Fields of AssigneesFilter
operator SetOperator

​

assignees array of string

​

event_type EventType

​

Values of EventType
EVENT_TYPE_UNSPECIFIED

​

INFO

​

FLAG

​

ERROR

​

SUCCESS

​

event_types EventTypeList

​

Fields of EventTypeList
values array of EventType

​

created_by string

​

created_by_any_of UserRidList

​

Fields of UserRidList
values array of string

​

label string

​

labels LabelsFilter

​

Fields of LabelsFilter
operator SetOperator

​

labels array of string

​

property Property

​

Fields of Property
name string

​

value string

​

properties PropertiesFilter

​

Fields of PropertiesFilter
name string

​

values array of string

​

and SearchQueryList

​

Fields of SearchQueryList
queries array of SearchQuery

​

not SearchQuery

​

workspace string

​

procedure string

​

procedure_execution string

​

step_id string

​

streaming_checklist string

Filters to events created from a checklist executing in streaming.

streaming_check string

Filters to events created from the check of a checklist executing in streaming.

numeric_property NumericPropertyPredicate

Matches events using a numeric property comparison.

Fields of NumericPropertyPredicate
name string

​

value number

​

operator PropertyComparisonOperator

​

Values of PropertyComparisonOperator
PROPERTY_COMPARISON_OPERATOR_UNSPECIFIED

​

EQ

​

NEQ

​

GT

​

GTE

​

LT

​

LTE

​

numeric_property_range NumericPropertyRangePredicate

Matches events using an inclusive numeric property range.

Fields of NumericPropertyRangePredicate
name string

​

min number

​

max number

​

operator NumericPropertyRangeOperator

​

Values of NumericPropertyRangeOperator
NUMERIC_PROPERTY_RANGE_OPERATOR_UNSPECIFIED

​

BETWEEN

​

NOT_BETWEEN

​

archived_statuses array of ArchivedStatus

If empty, defaults to NOT_ARCHIVED only. Allows including archived events in search.

Values of ArchivedStatus
ARCHIVED_STATUS_UNSPECIFIED

​

NOT_ARCHIVED

​

ARCHIVED

​

Response: SearchEventsResponse

results array of Event

​

Fields of Event
uuid string

​

rid string

​

asset_rids array of string

A set of asset rids associated with the event.

origins array of EventOrigin

A set of origins associated with the event.

Fields of EventOrigin
one of 6 fields

​

workbook WorkbookEventOrigin

This event was created in this workbook.

Fields of WorkbookEventOrigin
rid string

​

data array of WorkbookDataAssociation

Data visualizations to associate this event with.

Fields of WorkbookDataAssociation
time_series_channel TimeSeriesChannelAssociation

​

Fields of TimeSeriesChannelAssociation
variable_name string

​

tags map of string to string

If this variable is grouped, the tags within the groupings this event should associate with.

template TemplateEventOrigin

This event was created in this template.

Fields of TemplateEventOrigin
rid string

​

api ApiEventOrigin

This event was created programmatically via the API.

data_review DataReviewEventOrigin

This event was created automatically from a checklist execution.

Fields of DataReviewEventOrigin
data_review_rid string

​

check_metadata CheckOriginMetadata

Metadata about the check that created this event.

Fields of CheckOriginMetadata
check_evaluation_rid string

​

check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

procedure ProcedureEventOrigin

This event was created automatically from a procedure execution.

Fields of ProcedureEventOrigin
procedure_execution_rid string

​

procedure_rid string

​

step_id string

​

streaming_checklist StreamingChecklistEventOrigin

This event was created automatically from the execution of a streaming checklist.

Fields of StreamingChecklistEventOrigin
checklist_rid string

​

check_metadata StreamingCheckOriginMetadata

Metadata about the check that created this event.

Fields of StreamingCheckOriginMetadata
check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

timestamp Timestamp

​

Fields of Timestamp
seconds integer (int64)

​

nanos integer (int64)

​

duration Duration

​

Fields of Duration
seconds integer (int64)

​

nanos integer (int64)

​

name string

​

description string

​

type EventType

​

Values of EventType
EVENT_TYPE_UNSPECIFIED

​

INFO

​

FLAG

​

ERROR

​

SUCCESS

​

labels array of string

​

properties map of string to string deprecated

​

is_archived boolean

​

created_by string

The user who created the event. This field may be missing for legacy events.

disposition EventDisposition

​

Fields of EventDisposition
priority Priority

​

Values of Priority
PRIORITY_UNSPECIFIED

​

P0

​

P1

​

P2

​

P3

​

P4

​

state DispositionState

​

Fields of DispositionState
one of pending_review, closed_with_further_action, closed_with_ignore

​

pending_review PendingReviewDispositionState

​

Fields of PendingReviewDispositionState
opened_by string

​

closed_with_further_action ClosedWithFurtherActionDispositionState

​

Fields of ClosedWithFurtherActionDispositionState
closed_by string

​

closed_with_ignore ClosedWithIgnoreDispositionState

​

Fields of ClosedWithIgnoreDispositionState
closed_by string

​

assignees array of string

​

typed_properties map of string to TypedPropertyValue

​

Fields of TypedPropertyValue
one of string_value, numeric_value

​

string_value string

​

numeric_value number

​

next_page_token string

​

Request

import grpc
from nominal.protos.event.v2 import event_pb2, event_pb2_grpc

channel = grpc.secure_channel("api.gov.nominal.io:443", grpc.ssl_channel_credentials())
event_service = event_pb2_grpc.EventServiceStub(channel)
auth = [("authorization", "Bearer <api key>")]

request = event_pb2.SearchEventsRequest(
    sort={"is_descending": True, "field": "START_TIME"},
    page_size=1,
    next_page_token="<next page token>",
    query={"archived": True},
    archived_statuses=["NOT_ARCHIVED"],
)
response = event_service.SearchEvents(request, metadata=auth)
print(response)
package main

import (
	"context"
	"crypto/tls"
	"fmt"
	"log"

	eventv2 "github.com/nominal-io/nominal-api-protos-go/nominal/protos/event/v2"
	"github.com/nominal-io/nominal-api-protos-go/nominal/protos/types"
	"google.golang.org/grpc"
	"google.golang.org/grpc/credentials"
	"google.golang.org/grpc/metadata"
	"google.golang.org/protobuf/proto"
)

func main() {
	conn, err := grpc.NewClient("api.gov.nominal.io:443",
		grpc.WithTransportCredentials(credentials.NewTLS(&tls.Config{})))
	if err != nil {
		log.Fatal(err)
	}
	defer conn.Close()
	eventService := eventv2.NewEventServiceClient(conn)
	ctx := metadata.AppendToOutgoingContext(context.Background(), "authorization", "Bearer <api key>")

	request := &eventv2.SearchEventsRequest{
		Sort: &eventv2.SortOptions{
			IsDescending: true,
			Field:        eventv2.SortField_START_TIME,
		},
		PageSize:      1,
		NextPageToken: proto.String("<next page token>"),
		Query: &eventv2.SearchQuery{
			SearchQuery: &eventv2.SearchQuery_Archived{Archived: true},
		},
		ArchivedStatuses: []types.ArchivedStatus{
			types.ArchivedStatus_NOT_ARCHIVED,
		},
	}
	response, err := eventService.SearchEvents(ctx, request)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Println(response)
}

Response

{
  "results": [
    {
      "uuid": "<uuid>",
      "rid": "<rid>",
      "asset_rids": [
        "<asset rids>"
      ],
      "origins": [
        {
          "workbook": {
            "rid": "<rid>",
            "data": [
              {
                "time_series_channel": {
                  "variable_name": "<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>"
      },
      "is_archived": true,
      "created_by": "<created by>",
      "disposition": {
        "priority": "P0",
        "state": {
          "pending_review": {
            "opened_by": "<opened by>"
          }
        },
        "assignees": [
          "<assignees>"
        ]
      },
      "typed_properties": {
        "<key>": {
          "string_value": "<string value>"
        }
      }
    }
  ],
  "next_page_token": "<next page token>"
}

Update event#

gRPC /nominal.event.v2.EventService/UpdateEvent

Updates the fields of an event. Empty fields are left unchanged.

Request: UpdateEventRequest

uuid string

​

rid string

The unique identifier for the event. Required if the uuid field is not provided.

asset_rids AssetRidSet

If provided, replaces the existing asset rids. If provided, must contain at least one asset rid.

Fields of AssetRidSet
asset_rids array of string

​

timestamp Timestamp

​

Fields of Timestamp
seconds integer (int64)

​

nanos integer (int64)

​

duration Duration

​

Fields of Duration
seconds integer (int64)

​

nanos integer (int64)

​

name string

​

description string

​

type EventType

​

Values of EventType
EVENT_TYPE_UNSPECIFIED

​

INFO

​

FLAG

​

ERROR

​

SUCCESS

​

labels LabelUpdateWrapper

​

Fields of LabelUpdateWrapper
labels array of string

​

properties PropertyUpdateWrapper deprecated

​

Fields of PropertyUpdateWrapper
properties map of string to string

​

typed_properties TypedPropertyUpdateWrapper

​

Fields of TypedPropertyUpdateWrapper
typed_properties map of string to TypedPropertyValue

​

Fields of TypedPropertyValue
one of string_value, numeric_value required

​

string_value string

​

numeric_value number

​

Response: UpdateEventResponse

event Event

​

Fields of Event
uuid string

​

rid string

​

asset_rids array of string

A set of asset rids associated with the event.

origins array of EventOrigin

A set of origins associated with the event.

Fields of EventOrigin
one of 6 fields

​

workbook WorkbookEventOrigin

This event was created in this workbook.

Fields of WorkbookEventOrigin
rid string

​

data array of WorkbookDataAssociation

Data visualizations to associate this event with.

Fields of WorkbookDataAssociation
time_series_channel TimeSeriesChannelAssociation

​

Fields of TimeSeriesChannelAssociation
variable_name string

​

tags map of string to string

If this variable is grouped, the tags within the groupings this event should associate with.

template TemplateEventOrigin

This event was created in this template.

Fields of TemplateEventOrigin
rid string

​

api ApiEventOrigin

This event was created programmatically via the API.

data_review DataReviewEventOrigin

This event was created automatically from a checklist execution.

Fields of DataReviewEventOrigin
data_review_rid string

​

check_metadata CheckOriginMetadata

Metadata about the check that created this event.

Fields of CheckOriginMetadata
check_evaluation_rid string

​

check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

procedure ProcedureEventOrigin

This event was created automatically from a procedure execution.

Fields of ProcedureEventOrigin
procedure_execution_rid string

​

procedure_rid string

​

step_id string

​

streaming_checklist StreamingChecklistEventOrigin

This event was created automatically from the execution of a streaming checklist.

Fields of StreamingChecklistEventOrigin
checklist_rid string

​

check_metadata StreamingCheckOriginMetadata

Metadata about the check that created this event.

Fields of StreamingCheckOriginMetadata
check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

timestamp Timestamp

​

Fields of Timestamp
seconds integer (int64)

​

nanos integer (int64)

​

duration Duration

​

Fields of Duration
seconds integer (int64)

​

nanos integer (int64)

​

name string

​

description string

​

type EventType

​

Values of EventType
EVENT_TYPE_UNSPECIFIED

​

INFO

​

FLAG

​

ERROR

​

SUCCESS

​

labels array of string

​

properties map of string to string deprecated

​

is_archived boolean

​

created_by string

The user who created the event. This field may be missing for legacy events.

disposition EventDisposition

​

Fields of EventDisposition
priority Priority

​

Values of Priority
PRIORITY_UNSPECIFIED

​

P0

​

P1

​

P2

​

P3

​

P4

​

state DispositionState

​

Fields of DispositionState
one of pending_review, closed_with_further_action, closed_with_ignore

​

pending_review PendingReviewDispositionState

​

Fields of PendingReviewDispositionState
opened_by string

​

closed_with_further_action ClosedWithFurtherActionDispositionState

​

Fields of ClosedWithFurtherActionDispositionState
closed_by string

​

closed_with_ignore ClosedWithIgnoreDispositionState

​

Fields of ClosedWithIgnoreDispositionState
closed_by string

​

assignees array of string

​

typed_properties map of string to TypedPropertyValue

​

Fields of TypedPropertyValue
one of string_value, numeric_value

​

string_value string

​

numeric_value number

​

Request

import grpc
from nominal.protos.event.v2 import event_pb2, event_pb2_grpc

channel = grpc.secure_channel("api.gov.nominal.io:443", grpc.ssl_channel_credentials())
event_service = event_pb2_grpc.EventServiceStub(channel)
auth = [("authorization", "Bearer <api key>")]

request = event_pb2.UpdateEventRequest(
    uuid="<uuid>",
    rid="<rid>",
    asset_rids={"asset_rids": ["<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>"}},
    typed_properties={"typed_properties": {"<key>": {"string_value": "<string value>"}}},
)
response = event_service.UpdateEvent(request, metadata=auth)
print(response)
package main

import (
	"context"
	"crypto/tls"
	"fmt"
	"log"

	eventv2 "github.com/nominal-io/nominal-api-protos-go/nominal/protos/event/v2"
	"github.com/nominal-io/nominal-api-protos-go/nominal/protos/types"
	typestime "github.com/nominal-io/nominal-api-protos-go/nominal/protos/types/time"
	"google.golang.org/grpc"
	"google.golang.org/grpc/credentials"
	"google.golang.org/grpc/metadata"
	"google.golang.org/protobuf/proto"
)

func main() {
	conn, err := grpc.NewClient("api.gov.nominal.io:443",
		grpc.WithTransportCredentials(credentials.NewTLS(&tls.Config{})))
	if err != nil {
		log.Fatal(err)
	}
	defer conn.Close()
	eventService := eventv2.NewEventServiceClient(conn)
	ctx := metadata.AppendToOutgoingContext(context.Background(), "authorization", "Bearer <api key>")

	request := &eventv2.UpdateEventRequest{
		Uuid: "<uuid>",
		Rid:  proto.String("<rid>"),
		AssetRids: &eventv2.AssetRidSet{
			AssetRids: []string{
				"<asset rids>",
			},
		},
		Timestamp: &typestime.Timestamp{
			Seconds: proto.Int64(1),
			Nanos:   proto.Int64(1),
		},
		Duration: &types.Duration{
			Seconds: 1,
			Nanos:   1,
		},
		Name:        proto.String("<name>"),
		Description: proto.String("<description>"),
		Type:        eventv2.EventType_INFO.Enum(),
		Labels: &types.LabelUpdateWrapper{
			Labels: []string{
				"<labels>",
			},
		},
		Properties: &types.PropertyUpdateWrapper{
			Properties: map[string]string{
				"<key>": "<value>",
			},
		},
		TypedProperties: &types.TypedPropertyUpdateWrapper{
			TypedProperties: map[string]*types.TypedPropertyValue{
				"<key>": {
					TypedPropertyValue: &types.TypedPropertyValue_StringValue{StringValue: "<string value>"},
				},
			},
		},
	}
	response, err := eventService.UpdateEvent(ctx, request)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Println(response)
}

Response

{
  "event": {
    "uuid": "<uuid>",
    "rid": "<rid>",
    "asset_rids": [
      "<asset rids>"
    ],
    "origins": [
      {
        "workbook": {
          "rid": "<rid>",
          "data": [
            {
              "time_series_channel": {
                "variable_name": "<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>"
    },
    "is_archived": true,
    "created_by": "<created by>",
    "disposition": {
      "priority": "P0",
      "state": {
        "pending_review": {
          "opened_by": "<opened by>"
        }
      },
      "assignees": [
        "<assignees>"
      ]
    },
    "typed_properties": {
      "<key>": {
        "string_value": "<string value>"
      }
    }
  }
}

Errors#

Errors shows how these errors are sent.

Code

Reason

Message

INVALID_ARGUMENT

EVENT_ERROR_FIND_EVENTS_INDEX_INVALID

FindEventsIndexInvalid

INVALID_ARGUMENT

EVENT_ERROR_FIND_EVENTS_QUERY_COUNT_TOO_LARGE

FindEventsQueryCountTooLarge

INVALID_ARGUMENT

EVENT_ERROR_INVALID_EVENT_REQUEST

InvalidEventRequest

INVALID_ARGUMENT

EVENT_ERROR_SEARCH_QUERY_TOO_BROAD

EventSearchQueryTooBroad

Types#

AggregateEventsRequest#

query SearchQuery

​

aggregate_types array of AggregateType

​

AggregateEventsResponse#

values map of string to AggregateValue

Keyed 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

​

duration Duration

​

count integer

​

ApiEventOrigin#

A message with no fields.

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.

asset_rids array of string

​

AssetsFilter#

operator SetOperator

​

assets array of string

​

AssigneesFilter#

operator SetOperator

​

assignees array of string

​

CheckOriginMetadata#

check_evaluation_rid string

​

check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

ClosedWithFurtherActionDispositionState#

closed_by string

​

ClosedWithIgnoreDispositionState#

closed_by string

​

DataReviewChecksFilter#

data_review_checks array of string

​

DataReviewEventOrigin#

data_review_rid string

​

check_metadata CheckOriginMetadata

Metadata about the check that created this event.

DataReviewsFilter#

data_reviews array of string

​

DispositionState#

Set at most one of the fields below.

one of pending_review, closed_with_further_action, closed_with_ignore

​

pending_review PendingReviewDispositionState

​

closed_with_further_action ClosedWithFurtherActionDispositionState

​

closed_with_ignore ClosedWithIgnoreDispositionState

​

Duration#

seconds integer (int64)

​

nanos integer (int64)

​

Event#

uuid string

​

rid string

​

asset_rids array of string

A set of asset rids associated with the event.

origins array of EventOrigin

A set of origins associated with the event.

timestamp Timestamp

​

duration Duration

​

name string

​

description string

​

type EventType

​

labels array of string

​

properties map of string to string deprecated

​

is_archived boolean

​

created_by string

The user who created the event. This field may be missing for legacy events.

disposition EventDisposition

​

typed_properties map of string to TypedPropertyValue

​

EventDisposition#

Describes the review status for an event.

priority Priority

​

state DispositionState

​

assignees array of string

​

EventDispositionStatus#

EVENT_DISPOSITION_STATUS_UNSPECIFIED

​

PENDING_REVIEW

​

CLOSED_IGNORED

​

CLOSED_REQUIRES_FURTHER_ACTION

​

NO_DISPOSITION

​

EventDispositionStatusList#

values array of EventDispositionStatus

​

EventOrigin#

Describes where an event came from.

Set at most one of the fields below.

one of 6 fields

​

workbook WorkbookEventOrigin

This event was created in this workbook.

template TemplateEventOrigin

This event was created in this template.

api ApiEventOrigin

This event was created programmatically via the API.

data_review DataReviewEventOrigin

This event was created automatically from a checklist execution.

procedure ProcedureEventOrigin

This event was created automatically from a procedure execution.

streaming_checklist StreamingChecklistEventOrigin

This event was created automatically from the execution of a streaming checklist.

EventsHistogramBucket#

start_inclusive Timestamp

​

end_exclusive Timestamp

​

count integer

​

EventTimeFilter#

timestamp Timestamp

​

timestamp_condition EventTimeFilterCondition

​

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#

values array of EventType

​

EventUpdate#

rid string

​

asset_rids AssetRidSet

If provided, replaces the existing asset rids. If provided, must contain at least one asset rid.

timestamp Timestamp

​

duration Duration

​

name string

​

description string

​

type EventType

​

labels LabelUpdateWrapper

​

properties PropertyUpdateWrapper deprecated

​

typed_properties TypedPropertyUpdateWrapper

​

FindEventsQuery#

asset_rids array of string

When non-empty, only events associated with at least one of these assets match. When empty, events match on the time window alone.

start_inclusive Timestamp

Half-open window [start_inclusive, end_exclusive) over event start times. An absent bound leaves that side of the window open.

end_exclusive Timestamp

​

index integer

Zero-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#

event Event

Absent when no event matches the query at the requested index.

HistogramFilterQuery#

Set at most one of the fields below.

one of 21 fields

​

search_text string

​

asset string

​

template string

​

workbook string

​

data_review string

​

origin_type SearchEventOriginType

​

data_review_check string

​

disposition_status EventDispositionStatus

​

priority Priority

​

assignee string

​

event_type EventType

​

created_by string

​

label string

​

property Property

​

workspace string

​

procedure string

​

procedure_execution string

​

step_id string

​

HistogramFilterQueryList#

queries array of HistogramFilterQuery

​

LabelsFilter#

operator SetOperator

​

labels array of string

​

LabelUpdateWrapper#

Wrapper classes to allow for optional fields on update requests

labels array 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.

name string

​

value number

​

operator PropertyComparisonOperator

​

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.

name string

​

min number

​

max number

​

operator NumericPropertyRangeOperator

​

OriginTypesFilter#

operator SetOperator

​

origin_types array of SearchEventOriginType

​

PendingReviewDispositionState#

opened_by string

​

Priority#

PRIORITY_UNSPECIFIED

​

P0

​

P1

​

P2

​

P3

​

P4

​

PriorityList#

values array of Priority

​

ProcedureEventOrigin#

procedure_execution_rid string

​

procedure_rid string

​

step_id string

​

PropertiesFilter#

name string

​

values array of string

​

Property#

name string

​

value string

​

PropertyComparisonOperator#

PROPERTY_COMPARISON_OPERATOR_UNSPECIFIED

​

EQ

​

NEQ

​

GT

​

GTE

​

LT

​

LTE

​

PropertyUpdateWrapper#

properties map of string to string

​

PropertyValues#

value array 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

​

archived boolean

​

search_text string

Search text to perform fuzzy searching against.

exact_match string

Search text to perform exact matching against on the event name and description.

after Timestamp

Filters to events after this timestamp, exclusive.

before Timestamp

Filters to events before this timestamp, exclusive.

advanced_time_filter EventTimeFilter

​

asset string

​

assets AssetsFilter

​

template string

​

workbook string

​

data_review string

​

data_reviews DataReviewsFilter

​

origin_type SearchEventOriginType

​

origin_types OriginTypesFilter

​

data_review_check string

​

data_review_checks DataReviewChecksFilter

​

disposition_status EventDispositionStatus

​

disposition_statuses EventDispositionStatusList

​

priority Priority

​

priorities PriorityList

​

assignee string

​

assignees AssigneesFilter

​

event_type EventType

​

event_types EventTypeList

​

created_by string

​

created_by_any_of UserRidList

​

label string

​

labels LabelsFilter

​

property Property

​

properties PropertiesFilter

​

not SearchQuery

​

workspace string

​

procedure string

​

procedure_execution string

​

step_id string

​

streaming_checklist string

Filters to events created from a checklist executing in streaming.

streaming_check string

Filters to events created from the check of a checklist executing in streaming.

numeric_property NumericPropertyPredicate

Matches events using a numeric property comparison.

numeric_property_range NumericPropertyRangePredicate

Matches 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.

queries array of SearchQuery

​

SetOperator#

SET_OPERATOR_UNSPECIFIED

​

AND

​

OR

​

SortField#

SORT_FIELD_UNSPECIFIED

​

START_TIME

​

END_TIME

​

DURATION

​

DISPOSITION_STATUS

​

PRIORITY

​

EVENT_NAME

​

SortOptions#

is_descending boolean

​

field SortField

​

StreamingChecklistEventOrigin#

checklist_rid string

​

check_metadata StreamingCheckOriginMetadata

Metadata about the check that created this event.

StreamingCheckOriginMetadata#

check_rid string

​

check_lineage_rid string

​

implementation_index integer

​

TemplateEventOrigin#

rid string

​

TimeSeriesChannelAssociation#

A singular time series to associate the event with.

variable_name string

​

tags map of string to string

If 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.

seconds integer (int64)

​

nanos integer (int64)

​

TypedPropertyUpdateWrapper#

typed_properties map of string to TypedPropertyValue

​

TypedPropertyValue#

Set exactly one of the fields below.

one of string_value, numeric_value required

​

string_value string

​

numeric_value number

​

UpdateDispositionRequest#

rid string

​

disposition EventDisposition

The new disposition for the event. If empty, removes the disposition from the event.

UserRidList#

values array of string

​

WorkbookDataAssociation#

time_series_channel TimeSeriesChannelAssociation

​

WorkbookEventOrigin#

rid string

​

data array of WorkbookDataAssociation

Data visualizations to associate this event with.

Page design based on Scalar, MIT License.