syntax = "proto3"; package gnoi.sonic; //option (types.gnoi_version) = "0.1.0"; import "github.com/gogo/protobuf/gogoproto/gogo.proto"; option (gogoproto.marshaler_all) = true; option (gogoproto.unmarshaler_all) = true; service SonicService { rpc ShowTechsupport (TechsupportRequest) returns (TechsupportResponse) {} rpc ShowTechsupportCancel (TechsupportCancelRequest) returns (TechsupportCancelResponse) {} rpc Sum (SumRequest) returns (SumResponse) {} rpc ImageInstall(ImageInstallRequest) returns (ImageInstallResponse) {} rpc ImageRemove(ImageRemoveRequest) returns (ImageRemoveResponse) {} rpc ImageDefault(ImageDefaultRequest) returns (ImageDefaultResponse) {} rpc Authenticate(AuthenticateRequest) returns (AuthenticateResponse) {} rpc Refresh(RefreshRequest) returns (RefreshResponse) {} rpc ClearNeighbors(ClearNeighborsRequest) returns (ClearNeighborsResponse) {} rpc VlanReplace(VlanReplaceRequest) returns (VlanReplaceResponse) {} rpc GetAuditLog (GetAuditLogRequest) returns (GetAuditLogResponse) {} rpc ClearAuditLog (ClearAuditLogRequest) returns (ClearAuditLogResponse) {} rpc ShowSysLog(ShowSysLogRequest) returns (GetShowSysLogResponse) {} rpc GetEvents (GetEventsRequest) returns (GetEventsResponse) {} rpc GetAlarms (GetAlarmsRequest) returns (GetAlarmsResponse) {} rpc AckAlarms (AckAlarmsRequest) returns (AckAlarmsResponse) {} rpc UnackAlarms (UnackAlarmsRequest) returns (UnackAlarmsResponse) {} rpc GetEventProfile (GetEventProfileRequest) returns (GetEventProfileResponse) {} rpc SetEventProfile (SetEventProfileRequest) returns (SetEventProfileResponse) {} } message SonicOutput { int32 status = 1; string status_detail = 2 [(gogoproto.jsontag) = "status-detail", (gogoproto.moretags) = "xml:\",comment\""]; } message GetEventProfileRequest { } message GetEventProfileResponse { message Output { string file_name = 1 [(gogoproto.jsontag) = "file-name", (gogoproto.moretags) = "xml:\",comment\""]; repeated string file_list = 2 [(gogoproto.jsontag) = "file-list", (gogoproto.moretags) = "xml:\",comment\""]; } Output output = 1 [(gogoproto.jsontag) = "sonic-get-evprofile:output", (gogoproto.moretags) = "xml:\",comment\""]; } message SetEventProfileRequest { message Input { string filename =1 [(gogoproto.jsontag) = "file-name", (gogoproto.moretags) = "xml:\",comment\""]; } Input input =1 [(gogoproto.jsontag) = "sonic-evprofile:input", (gogoproto.moretags) = "xml:\",comment\""]; } message SetEventProfileResponse { SonicOutput output = 1 [(gogoproto.jsontag) = "sonic-set-evprofile:output", (gogoproto.moretags) = "xml:\",comment\""]; } message AckAlarmsRequest { message Input { repeated string id = 1; } Input input = 1 [(gogoproto.jsontag) = "sonic-alarm:input", (gogoproto.moretags) = "xml:\",comment\""]; } message AckAlarmsResponse { SonicOutput output = 1 [(gogoproto.jsontag) = "sonic-alarm:output", (gogoproto.moretags) = "xml:\",comment\""]; } message UnackAlarmsRequest { message Input { repeated string id = 1; } Input input = 1 [(gogoproto.jsontag) = "sonic-alarm:input", (gogoproto.moretags) = "xml:\",comment\""]; } message UnackAlarmsResponse { SonicOutput output = 1 [(gogoproto.jsontag) = "sonic-alarm:output", (gogoproto.moretags) = "xml:\",comment\""]; } message EventTimeFilter { string begin = 1; string end = 2; } message EventId { string begin = 1; string end = 2; } message EventsFilter { EventTimeFilter time = 1; string interval = 2; string severity = 3; EventId id = 4; } message GetEventsRequest { EventsFilter input = 1 [(gogoproto.jsontag) = "sonic-event:input", (gogoproto.moretags) = "xml:\",comment\""]; } message Event { string id = 1; string resource = 2; string text = 3; string time_created = 4 [(gogoproto.jsontag) = "time-created", (gogoproto.moretags) = "xml:\",comment\""]; string type_id = 5 [(gogoproto.jsontag) = "type-id", (gogoproto.moretags) = "xml:\",comment\""]; string severity = 6; string action = 7; } message Events { repeated Event EVENT_LIST = 1 [(gogoproto.jsontag) = "EVENT_LIST", (gogoproto.moretags) = "xml:\",comment\""]; } message EventsResponse { int32 status = 1; string status_detail = 2 [(gogoproto.jsontag) = "status-detail", (gogoproto.moretags) = "xml:\",comment\""]; Events EVENT =3; } message GetEventsResponse { EventsResponse output = 1 [(gogoproto.jsontag) = "sonic-event:output", (gogoproto.moretags) = "xml:\",comment\""]; } message Alarm { string id = 1; string resource = 2; string text = 3; string time_created = 4 [(gogoproto.jsontag) = "time-created", (gogoproto.moretags) = "xml:\",comment\""]; string type_id = 5 [(gogoproto.jsontag) = "type-id", (gogoproto.moretags) = "xml:\",comment\""]; string severity = 6; bool acknowledged = 7; string acknowledge_time = 8 [(gogoproto.jsontag) = "acknowledge-time", (gogoproto.moretags) = "xml:\",comment\""]; } message GetAlarmsRequest { EventsFilter input = 1 [(gogoproto.jsontag) = "sonic-alarm:input", (gogoproto.moretags) = "xml:\",comment\""]; } message Alarms { repeated Alarm ALARM_LIST = 1 [(gogoproto.jsontag) = "ALARM_LIST", (gogoproto.moretags) = "xml:\",comment\""]; } message AlarmsResponse { int32 status = 1; string status_detail = 2 [(gogoproto.jsontag) = "status-detail", (gogoproto.moretags) = "xml:\",comment\""]; Alarms ALARM =3; } message GetAlarmsResponse { AlarmsResponse output = 1 [(gogoproto.jsontag) = "sonic-alarm:output", (gogoproto.moretags) = "xml:\",comment\""]; } message TechsupportRequest { message Input { string date = 1; } Input input = 1 [(gogoproto.jsontag) = "openconfig-show-techsupport-private:input", (gogoproto.moretags) = "xml:\",comment\""]; } message TechsupportResponse { message Output { uint32 status = 1 [(gogoproto.jsontag) = "status", (gogoproto.moretags) = "xml:\",comment\""]; string status_detail = 2 [(gogoproto.jsontag) = "status-detail", (gogoproto.moretags) = "xml:\",comment\""]; string output_filename = 3 [(gogoproto.jsontag) = "output-filename", (gogoproto.moretags) = "xml:\",comment\""]; } Output output = 1 [(gogoproto.jsontag) = "openconfig-show-techsupport-private:output", (gogoproto.moretags) = "xml:\",comment\""]; } message TechsupportCancelRequest { } message TechsupportCancelResponse { message Output { uint32 status = 1 [(gogoproto.jsontag) = "status", (gogoproto.moretags) = "xml:\",comment\""]; string status_detail = 2 [(gogoproto.jsontag) = "status-detail", (gogoproto.moretags) = "xml:\",comment\""]; } Output output = 1 [(gogoproto.jsontag) = "openconfig-show-techsupport-private:output", (gogoproto.moretags) = "xml:\",comment\""]; } message ClearNeighborsRequest { message Input { bool force = 1; string family = 2; string ip = 3; string ifname = 4; } Input input = 1 [(gogoproto.jsontag) = "sonic-neighbor:input", (gogoproto.moretags) = "xml:\",comment\""]; } message ClearNeighborsResponse { message Output { string response = 1; } Output output = 1 [(gogoproto.jsontag) = "sonic-neighbor:output", (gogoproto.moretags) = "xml:\",comment\""]; } message VlanReplaceRequest { message Input { string ifname = 1; string vlanlist = 2; } Input input = 1 [(gogoproto.jsontag) = "openconfig-interfaces-private:input", (gogoproto.moretags) = "xml:\",comment\""]; } message VlanReplaceResponse { message Output { string response = 1; } Output output = 1 [(gogoproto.jsontag) = "openconfig-interfaces-private:output", (gogoproto.moretags) = "xml:\",comment\""]; } message SumRequest { message Input { int32 left = 1; int32 right = 2; } Input input = 1 [(gogoproto.jsontag) = "sonic-tests:input", (gogoproto.moretags) = "xml:\",comment\""]; } message SumResponse { message Output { int32 result = 1; } Output output = 1 [(gogoproto.jsontag) = "sonic-tests:output", (gogoproto.moretags) = "xml:\",comment\""]; } message ImageInstallRequest { message Input { string imagename = 1 [(gogoproto.jsontag) = "image-name", (gogoproto.moretags) = "xml:\",comment\""]; } Input input = 1 [(gogoproto.jsontag) = "openconfig-image-management:input", (gogoproto.moretags) = "xml:\",comment\""]; } message ImageInstallResponse { SonicOutput output = 1 [(gogoproto.jsontag) = "openconfig-image-management:output", (gogoproto.moretags) = "xml:\",comment\""]; } message ImageRemoveRequest { message Input { string imagename = 1 [(gogoproto.jsontag) = "image-name", (gogoproto.moretags) = "xml:\",comment\""]; } Input input = 1 [(gogoproto.jsontag) = "openconfig-image-management:input", (gogoproto.moretags) = "xml:\",comment\""]; } message ImageRemoveResponse { SonicOutput output = 1 [(gogoproto.jsontag) = "openconfig-image-management:output", (gogoproto.moretags) = "xml:\",comment\""]; } message ImageDefaultRequest { message Input { string imagename = 1 [(gogoproto.jsontag) = "image-name", (gogoproto.moretags) = "xml:\",comment\""]; } Input input = 1 [(gogoproto.jsontag) = "openconfig-image-management:input", (gogoproto.moretags) = "xml:\",comment\""]; } message ImageDefaultResponse { SonicOutput output = 1 [(gogoproto.jsontag) = "openconfig-image-management:output", (gogoproto.moretags) = "xml:\",comment\""]; } message GetAuditLogRequest { message Input { string content_type = 1 [(gogoproto.jsontag) = "content-type", (gogoproto.moretags) = "xml:\",comment\""]; } Input input = 1 [(gogoproto.jsontag) = "sonic-auditlog:input", (gogoproto.moretags) = "xml:\",comment\""]; } message GetAuditLogResponse { message AuditOutput { repeated string audit_content = 1 [(gogoproto.jsontag) = "audit-content", (gogoproto.moretags) = "xml:\",comment\""]; } AuditOutput output = 1 [(gogoproto.jsontag) = "sonic-get-auditlog:output", (gogoproto.moretags) = "xml:\",comment\""]; } message ClearAuditLogRequest { } message ClearAuditLogResponse { SonicOutput output = 1 [(gogoproto.jsontag) = "sonic-clear-auditlog:output", (gogoproto.moretags) = "xml:\",comment\""]; } message ShowSysLogRequest { message Input { int32 num_lines = 1 [(gogoproto.jsontag) = "num-lines", (gogoproto.moretags) = "xml:\",comment\""]; } Input input = 1 [(gogoproto.jsontag) = "openconfig-system-ext:input", (gogoproto.moretags) = "xml:\",comment\""]; } message ShowSysLogResponse { repeated string status_detail = 1 [(gogoproto.jsontag) = "status-detail", (gogoproto.moretags) = "xml:\",comment\""]; } message GetShowSysLogResponse { ShowSysLogResponse output = 1 [(gogoproto.jsontag) = "openconfig-system-ext:output", (gogoproto.moretags) = "xml:\",comment\""]; } message JwtToken { string access_token = 1; string type = 2; int64 expires_in = 3; } message AuthenticateRequest { string username = 1; string password = 2; } message AuthenticateResponse { JwtToken Token = 1; } message RefreshRequest { } message RefreshResponse { JwtToken Token = 1; }