MCPcopy Create free account
hub / github.com/astercloud/aster / NewRemoteClient

Function NewRemoteClient

pkg/sandbox/remote.go:24–38  ·  view source on GitHub ↗

NewRemoteClient 创建远程客户端

(config *RemoteClientConfig)

Source from the content-addressed store, hash-verified

22
23// NewRemoteClient 创建远程客户端
24func NewRemoteClient(config *RemoteClientConfig) *RemoteClient {
25 if config.Timeout == 0 {
26 config.Timeout = 30 * time.Second
27 }
28
29 return &RemoteClient{
30 baseURL: config.BaseURL,
31 apiKey: config.APIKey,
32 apiSecret: config.APISecret,
33 httpClient: &http.Client{
34 Timeout: config.Timeout,
35 },
36 headers: config.Headers,
37 }
38}
39
40// RemoteClientConfig 远程客户端配置
41type RemoteClientConfig struct {

Callers 1

NewRemoteSandboxFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected