Skip to content

gRPC Contract

The OpenWatchIt plugin contract is defined in three protobuf files in the repository under proto/.

FileContents
proto/ast.protoQueryAST, FilterNode, SignalType, FilterOperator
proto/result.protoResultRow, QueryWarning
proto/plugin.protoObservabilityPlugin service and all request/response messages
service ObservabilityPlugin {
rpc Capabilities(CapabilitiesRequest) returns (CapabilitiesResponse);
rpc Translate(TranslateRequest) returns (TranslateResponse);
rpc Query(QueryRequest) returns (stream QueryResult);
rpc HealthCheck(HealthRequest) returns (HealthResponse);
}

The structured representation of an OWL query passed to plugins via Translate and Query. Plugins receive this — never raw OWL text.

FieldTypeDescription
signal_typeSignalTypeThe signal type being queried
filtersrepeated FilterNodeAll filter triplets
time_windowTimeWindowResolved --last duration in seconds
limituint32Value of --limit (0 = no limit)
summarizeSummarizeExprValue of --summarize
FieldTypeDescription
fieldstringField name (e.g. level, service, duration)
operatorFilterOperatorOne of EQ, NE, GT, GE, LT, LE, CONTAINS
valuestringFilter value as string
FieldTypeDescription
timestampstringRFC 3339 timestamp
sourcestringBackend name from TOML config
servicestringService name (canonical)
levelstringLog level (canonical, logs only)
messagestringLog message body (canonical, logs only)
trace_idstringTrace identifier (canonical, when present)
span_idstringSpan identifier (canonical, when present)
passthroughmap<string, string>Vendor-specific fields, native names

Breaking changes to the protobuf schema require a major version bump. The package is versioned as openwatchit.v1. Plugin authors should pin to a major version.