mirror of
https://github.com/yusing/godoxy.git
synced 2025-05-20 20:52:33 +02:00
14 lines
373 B
Go
14 lines
373 B
Go
package v1
|
|
|
|
import (
|
|
"net/http"
|
|
"time"
|
|
|
|
"github.com/yusing/go-proxy/agent/pkg/agent"
|
|
config "github.com/yusing/go-proxy/internal/config/types"
|
|
"github.com/yusing/go-proxy/internal/net/gphttp/gpwebsocket"
|
|
)
|
|
|
|
func ListAgents(cfg config.ConfigInstance, w http.ResponseWriter, r *http.Request) {
|
|
gpwebsocket.DynamicJSONHandler(w, r, agent.Agents.Slice, 10*time.Second)
|
|
}
|