mirror of
https://github.com/APIParkLab/APIPark.git
synced 2026-06-14 20:41:15 +08:00
15 lines
463 B
Go
15 lines
463 B
Go
package core
|
|
|
|
import (
|
|
"net/http"
|
|
|
|
"github.com/eolinker/go-common/pm3"
|
|
)
|
|
|
|
func (p *plugin) upstreamApis() []pm3.Api {
|
|
return []pm3.Api{
|
|
pm3.CreateApiWidthDoc(http.MethodGet, "/api/v1/service/upstream", []string{"context", "query:service"}, []string{"upstream"}, p.upstreamController.Get),
|
|
pm3.CreateApiWidthDoc(http.MethodPut, "/api/v1/service/upstream", []string{"context", "query:service", "body"}, []string{"upstream"}, p.upstreamController.Save),
|
|
}
|
|
}
|