2020-09-17 10:15:55 +08:00
|
|
|
syntax = "proto3";
|
|
|
|
|
option go_package = "./pb";
|
|
|
|
|
|
|
|
|
|
package pb;
|
|
|
|
|
|
2021-01-25 16:41:30 +08:00
|
|
|
import "models/rpc_messages.proto";
|
2020-09-17 10:15:55 +08:00
|
|
|
|
2022-06-25 19:22:19 +08:00
|
|
|
// 自定义页面服务
|
2020-09-17 10:15:55 +08:00
|
|
|
service HTTPPageService {
|
|
|
|
|
// 创建Page
|
|
|
|
|
rpc createHTTPPage (CreateHTTPPageRequest) returns (CreateHTTPPageResponse);
|
|
|
|
|
|
|
|
|
|
// 修改Page
|
2020-11-13 18:23:06 +08:00
|
|
|
rpc updateHTTPPage (UpdateHTTPPageRequest) returns (RPCSuccess);
|
2020-09-17 10:15:55 +08:00
|
|
|
|
|
|
|
|
// 查找单个Page配置
|
|
|
|
|
rpc findEnabledHTTPPageConfig (FindEnabledHTTPPageConfigRequest) returns (FindEnabledHTTPPageConfigResponse);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 创建Page
|
|
|
|
|
message CreateHTTPPageRequest {
|
|
|
|
|
repeated string statusList = 1;
|
2021-10-10 10:35:09 +08:00
|
|
|
string bodyType = 5;
|
2020-09-17 10:15:55 +08:00
|
|
|
string url = 2;
|
2021-10-10 10:35:09 +08:00
|
|
|
string body = 4;
|
2020-09-17 10:15:55 +08:00
|
|
|
int32 newStatus = 3;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
message CreateHTTPPageResponse {
|
2022-03-31 15:19:13 +08:00
|
|
|
int64 httpPageId = 1;
|
2020-09-17 10:15:55 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 修改Page
|
|
|
|
|
message UpdateHTTPPageRequest {
|
2022-03-31 15:19:13 +08:00
|
|
|
int64 httpPageId = 1;
|
2020-09-17 10:15:55 +08:00
|
|
|
repeated string statusList = 2;
|
2021-10-10 10:35:09 +08:00
|
|
|
string bodyType = 6;
|
2020-09-17 10:15:55 +08:00
|
|
|
string url = 3;
|
2021-10-10 10:35:09 +08:00
|
|
|
string body = 5;
|
2020-09-17 10:15:55 +08:00
|
|
|
int32 newStatus = 4;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// 查找单个Page配置
|
|
|
|
|
message FindEnabledHTTPPageConfigRequest {
|
2022-03-31 15:19:13 +08:00
|
|
|
int64 httpPageId = 1;
|
2020-09-17 10:15:55 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
message FindEnabledHTTPPageConfigResponse {
|
2020-09-21 19:52:10 +08:00
|
|
|
bytes pageJSON = 1;
|
2020-09-17 10:15:55 +08:00
|
|
|
}
|