add generate server and swagger

This commit is contained in:
2024-05-18 05:34:55 +07:00
parent 5bba5821ab
commit 286048d068
11 changed files with 1220 additions and 15 deletions
+28
View File
@@ -0,0 +1,28 @@
syntax = "proto3";
package crabs.crm;
import "google/api/annotations.proto";
option go_package = "pkg/crm";
service CRM {
rpc GetCatalog(GetCatalogReq) returns (CatalogRsp) {
option (google.api.http) = {
get: "/catalog"
};
}
}
message GetCatalogReq {}
message CatalogRsp {
message Category {
int64 id = 1;
string name = 2;
string uri = 3;
repeated Category children = 4;
}
repeated Category categories = 1;
}