Documentation
¶
Index ¶
Constants ¶
View Source
const ( CodeSuccess = 0 CodeInvalidParams = 40001 CodeNotFound = 40401 CodeInternalError = 50001 CodeValidationError = 40002 )
错误码常量
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ArtifactPayload ¶
type ArtifactPayload = events.ArtifactPayload
type BaseResponse ¶
BaseResponse 基础响应格式
type CreateDigitalAssistantResponse ¶
type CreateDigitalAssistantResponse struct {
Code int `json:"code"`
Message string `json:"message"`
Data *contract.DigitalAssistant `json:"data"`
}
CreateDigitalAssistantResponse 创建数字助手响应
func NewCreateDigitalAssistantResponse ¶
func NewCreateDigitalAssistantResponse(data *contract.DigitalAssistant) *CreateDigitalAssistantResponse
NewCreateDigitalAssistantResponse 创建成功响应
type ErrorResponse ¶
type ErrorResponse struct {
BaseResponse `json:",inline"`
Details string `json:"details,omitempty"`
}
ErrorResponse 错误响应格式
func ErrorWithDetails ¶
func ErrorWithDetails(code int, message string, details string) *ErrorResponse
ErrorWithDetails 带详情的错误响应
type MessageDeltaPayload ¶
type MessageDeltaPayload = events.MessageDeltaPayload
type Response ¶
type Response struct {
BaseResponse `json:",inline"`
Data interface{} `json:"data,omitempty"`
}
Response 统一响应格式
type RunStatusPayload ¶
type RuntimeTodoItemPayload ¶
type RuntimeTodoItemPayload = events.RuntimeTodoItem
type SessionEvent ¶
type ToolCallDeltaPayload ¶
type ToolCallDeltaPayload = events.ToolCallPayload
type ToolCallResultPayload ¶
Click to show internal directories.
Click to hide internal directories.