|
@@ -137,21 +137,16 @@ func RegisterHandlers(server *rest.Server, serverCtx *svc.ServiceContext) {
|
|
|
)
|
|
|
|
|
|
server.AddRoutes(
|
|
|
- []rest.Route{
|
|
|
- {
|
|
|
- Method: http.MethodPost,
|
|
|
- Path: "/agent/data/upload",
|
|
|
- Handler: agent.UploadAgentDataHandler(serverCtx),
|
|
|
- },
|
|
|
- },
|
|
|
- )
|
|
|
-
|
|
|
- server.AddRoutes(
|
|
|
rest.WithMiddlewares(
|
|
|
[]rest.Middleware{serverCtx.Authority},
|
|
|
[]rest.Route{
|
|
|
{
|
|
|
Method: http.MethodPost,
|
|
|
+ Path: "/agent/data/upload",
|
|
|
+ Handler: agent.UploadAgentDataHandler(serverCtx),
|
|
|
+ },
|
|
|
+ {
|
|
|
+ Method: http.MethodPost,
|
|
|
Path: "/agent/create",
|
|
|
Handler: agent.CreateAgentHandler(serverCtx),
|
|
|
},
|