openclaw

package
v0.3.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 9, 2026 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AnalyzeRequest

type AnalyzeRequest struct {
	StockCode string `json:"stockCode"` // 股票代码
	Query     string `json:"query"`     // 分析问题
}

AnalyzeRequest 分析请求

type AnalyzeResponse

type AnalyzeResponse struct {
	Success bool   `json:"success"`
	Summary string `json:"summary,omitempty"` // 最终总结
	Error   string `json:"error,omitempty"`   // 错误信息
}

AnalyzeResponse 分析响应

type Server

type Server struct {
	// contains filtered or unexported fields
}

Server OpenClaw HTTP 服务

func NewServer

func NewServer(ms *meeting.Service, ac *agent.Container, resolver func(string) *models.AIConfig, stockResolver StockResolver) *Server

NewServer 创建 OpenClaw 服务

func (*Server) GetPort

func (s *Server) GetPort() int

GetPort 获取当前端口

func (*Server) IsRunning

func (s *Server) IsRunning() bool

IsRunning 检查服务是否运行中

func (*Server) Restart

func (s *Server) Restart(port int, apiKey string) error

Restart 重启服务(端口或密钥变更时调用)

func (*Server) Start

func (s *Server) Start(port int, apiKey string) error

Start 启动服务

func (*Server) Stop

func (s *Server) Stop() error

Stop 停止服务

type StockResolver

type StockResolver func(code string) (*models.Stock, error)

StockResolver 根据股票代码获取实时数据

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL