2024-05-12 14:12:38 +08:00

39 lines
654 B
Go

package proto
import "time"
type SearchResult struct {
Title string
Score float64
Brief string
Url string
}
type (
Args struct {
Keyword string `json:"keyword"`
}
Resp struct {
Title string `json:"title"`
ReqTime time.Time `json:"req_time"`
Values []SearchResult `json:"values"`
Keyword string `json:"keyword"`
N int `json:"n"`
Latency time.Duration `json:"latency"`
}
)
type Common struct {
Code int `json:"code"`
Msg string `json:"msg"`
}
type (
SubmitURLArgs struct {
URL string `json:"url"`
}
SubmitURLResp struct {
Common
}
)