peridot/peridot/proto/v1/search.proto
2022-07-07 22:13:21 +02:00

38 lines
771 B
Protocol Buffer

syntax = "proto3";
package resf.peridot.v1;
import "google/protobuf/any.proto";
import "google/protobuf/wrappers.proto";
import "peridot/proto/v1/package.proto";
import "peridot/proto/v1/project.proto";
import "google/api/annotations.proto";
option go_package = "peridot.resf.org/peridot/pb;peridotpb";
service SearchService {
rpc Search (SearchRequest) returns (stream SearchResponse) {
option (google.api.http) = {
post: "/v1/search"
body: "*"
};
}
}
message SearchRequest {
string query = 1;
google.protobuf.StringValue project_id = 2;
}
message SearchResponse {
repeated google.protobuf.Any hits = 1;
}
message SearchHitPackages {
repeated Package packages = 1;
}
message SearchHitProjects {
repeated Project projects = 1;
}