Documentation
¶
Index ¶
- type Attachment
- type AttachmentType
- type CompactionTokensUsed
- type ContextClass
- type ContextUnion
- type Data
- type ErrorClass
- type ErrorUnion
- type Metadata
- type QuotaSnapshot
- type Repository
- type Result
- type Role
- type SessionEvent
- type SessionEventType
- type SourceType
- type ToolRequest
- type ToolRequestType
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Attachment ¶
type Attachment struct {
DisplayName string `json:"displayName"`
Path string `json:"path"`
Type AttachmentType `json:"type"`
}
type AttachmentType ¶
type AttachmentType string
const ( Directory AttachmentType = "directory" File AttachmentType = "file" )
type CompactionTokensUsed ¶
type ContextClass ¶
type ContextUnion ¶
type ContextUnion struct {
ContextClass *ContextClass
String *string
}
func (*ContextUnion) MarshalJSON ¶
func (x *ContextUnion) MarshalJSON() ([]byte, error)
func (*ContextUnion) UnmarshalJSON ¶
func (x *ContextUnion) UnmarshalJSON(data []byte) error
type Data ¶
type Data struct {
Context *ContextUnion `json:"context"`
CopilotVersion *string `json:"copilotVersion,omitempty"`
Producer *string `json:"producer,omitempty"`
SelectedModel *string `json:"selectedModel,omitempty"`
SessionID *string `json:"sessionId,omitempty"`
StartTime *time.Time `json:"startTime,omitempty"`
Version *float64 `json:"version,omitempty"`
EventCount *float64 `json:"eventCount,omitempty"`
ResumeTime *time.Time `json:"resumeTime,omitempty"`
ErrorType *string `json:"errorType,omitempty"`
Message *string `json:"message,omitempty"`
Stack *string `json:"stack,omitempty"`
InfoType *string `json:"infoType,omitempty"`
NewModel *string `json:"newModel,omitempty"`
PreviousModel *string `json:"previousModel,omitempty"`
HandoffTime *time.Time `json:"handoffTime,omitempty"`
RemoteSessionID *string `json:"remoteSessionId,omitempty"`
Repository *Repository `json:"repository,omitempty"`
SourceType *SourceType `json:"sourceType,omitempty"`
Summary *string `json:"summary,omitempty"`
MessagesRemovedDuringTruncation *float64 `json:"messagesRemovedDuringTruncation,omitempty"`
PerformedBy *string `json:"performedBy,omitempty"`
PostTruncationMessagesLength *float64 `json:"postTruncationMessagesLength,omitempty"`
PostTruncationTokensInMessages *float64 `json:"postTruncationTokensInMessages,omitempty"`
PreTruncationMessagesLength *float64 `json:"preTruncationMessagesLength,omitempty"`
PreTruncationTokensInMessages *float64 `json:"preTruncationTokensInMessages,omitempty"`
TokenLimit *float64 `json:"tokenLimit,omitempty"`
TokensRemovedDuringTruncation *float64 `json:"tokensRemovedDuringTruncation,omitempty"`
CurrentTokens *float64 `json:"currentTokens,omitempty"`
MessagesLength *float64 `json:"messagesLength,omitempty"`
CompactionTokensUsed *CompactionTokensUsed `json:"compactionTokensUsed,omitempty"`
Error *ErrorUnion `json:"error"`
MessagesRemoved *float64 `json:"messagesRemoved,omitempty"`
PostCompactionTokens *float64 `json:"postCompactionTokens,omitempty"`
PreCompactionMessagesLength *float64 `json:"preCompactionMessagesLength,omitempty"`
PreCompactionTokens *float64 `json:"preCompactionTokens,omitempty"`
Success *bool `json:"success,omitempty"`
SummaryContent *string `json:"summaryContent,omitempty"`
TokensRemoved *float64 `json:"tokensRemoved,omitempty"`
Attachments []Attachment `json:"attachments,omitempty"`
Content *string `json:"content,omitempty"`
Source *string `json:"source,omitempty"`
TransformedContent *string `json:"transformedContent,omitempty"`
TurnID *string `json:"turnId,omitempty"`
Intent *string `json:"intent,omitempty"`
ReasoningID *string `json:"reasoningId,omitempty"`
DeltaContent *string `json:"deltaContent,omitempty"`
MessageID *string `json:"messageId,omitempty"`
ParentToolCallID *string `json:"parentToolCallId,omitempty"`
ToolRequests []ToolRequest `json:"toolRequests,omitempty"`
TotalResponseSizeBytes *float64 `json:"totalResponseSizeBytes,omitempty"`
APICallID *string `json:"apiCallId,omitempty"`
CacheReadTokens *float64 `json:"cacheReadTokens,omitempty"`
CacheWriteTokens *float64 `json:"cacheWriteTokens,omitempty"`
Cost *float64 `json:"cost,omitempty"`
Duration *float64 `json:"duration,omitempty"`
Initiator *string `json:"initiator,omitempty"`
InputTokens *float64 `json:"inputTokens,omitempty"`
Model *string `json:"model,omitempty"`
OutputTokens *float64 `json:"outputTokens,omitempty"`
ProviderCallID *string `json:"providerCallId,omitempty"`
QuotaSnapshots map[string]QuotaSnapshot `json:"quotaSnapshots,omitempty"`
Reason *string `json:"reason,omitempty"`
Arguments interface{} `json:"arguments"`
ToolCallID *string `json:"toolCallId,omitempty"`
ToolName *string `json:"toolName,omitempty"`
PartialOutput *string `json:"partialOutput,omitempty"`
IsUserRequested *bool `json:"isUserRequested,omitempty"`
Result *Result `json:"result,omitempty"`
ToolTelemetry map[string]interface{} `json:"toolTelemetry,omitempty"`
AgentDescription *string `json:"agentDescription,omitempty"`
AgentDisplayName *string `json:"agentDisplayName,omitempty"`
AgentName *string `json:"agentName,omitempty"`
Tools []string `json:"tools"`
HookInvocationID *string `json:"hookInvocationId,omitempty"`
HookType *string `json:"hookType,omitempty"`
Input interface{} `json:"input"`
Output interface{} `json:"output"`
Metadata *Metadata `json:"metadata,omitempty"`
Name *string `json:"name,omitempty"`
Role *Role `json:"role,omitempty"`
}
type ErrorClass ¶
type ErrorUnion ¶
type ErrorUnion struct {
ErrorClass *ErrorClass
String *string
}
func (*ErrorUnion) MarshalJSON ¶
func (x *ErrorUnion) MarshalJSON() ([]byte, error)
func (*ErrorUnion) UnmarshalJSON ¶
func (x *ErrorUnion) UnmarshalJSON(data []byte) error
type QuotaSnapshot ¶
type QuotaSnapshot struct {
EntitlementRequests float64 `json:"entitlementRequests"`
IsUnlimitedEntitlement bool `json:"isUnlimitedEntitlement"`
Overage float64 `json:"overage"`
OverageAllowedWithExhaustedQuota bool `json:"overageAllowedWithExhaustedQuota"`
RemainingPercentage float64 `json:"remainingPercentage"`
ResetDate *time.Time `json:"resetDate,omitempty"`
UsageAllowedWithExhaustedQuota bool `json:"usageAllowedWithExhaustedQuota"`
UsedRequests float64 `json:"usedRequests"`
}
type Repository ¶
type SessionEvent ¶
type SessionEvent struct {
Data Data `json:"data"`
Ephemeral *bool `json:"ephemeral,omitempty"`
ID string `json:"id"`
ParentID *string `json:"parentId"`
Timestamp time.Time `json:"timestamp"`
Type SessionEventType `json:"type"`
}
func UnmarshalSessionEvent ¶
func UnmarshalSessionEvent(data []byte) (SessionEvent, error)
func (*SessionEvent) Marshal ¶
func (r *SessionEvent) Marshal() ([]byte, error)
type SessionEventType ¶
type SessionEventType string
const ( Abort SessionEventType = "abort" AssistantIntent SessionEventType = "assistant.intent" AssistantMessage SessionEventType = "assistant.message" AssistantMessageDelta SessionEventType = "assistant.message_delta" AssistantReasoning SessionEventType = "assistant.reasoning" AssistantReasoningDelta SessionEventType = "assistant.reasoning_delta" AssistantTurnEnd SessionEventType = "assistant.turn_end" AssistantTurnStart SessionEventType = "assistant.turn_start" AssistantUsage SessionEventType = "assistant.usage" HookEnd SessionEventType = "hook.end" HookStart SessionEventType = "hook.start" PendingMessagesModified SessionEventType = "pending_messages.modified" SessionCompactionComplete SessionEventType = "session.compaction_complete" SessionCompactionStart SessionEventType = "session.compaction_start" SessionError SessionEventType = "session.error" SessionHandoff SessionEventType = "session.handoff" SessionIdle SessionEventType = "session.idle" SessionInfo SessionEventType = "session.info" SessionModelChange SessionEventType = "session.model_change" SessionResume SessionEventType = "session.resume" SessionStart SessionEventType = "session.start" SessionTruncation SessionEventType = "session.truncation" SessionUsageInfo SessionEventType = "session.usage_info" SubagentCompleted SessionEventType = "subagent.completed" SubagentFailed SessionEventType = "subagent.failed" SubagentSelected SessionEventType = "subagent.selected" SubagentStarted SessionEventType = "subagent.started" SystemMessage SessionEventType = "system.message" ToolExecutionComplete SessionEventType = "tool.execution_complete" ToolExecutionPartialResult SessionEventType = "tool.execution_partial_result" ToolExecutionStart SessionEventType = "tool.execution_start" ToolUserRequested SessionEventType = "tool.user_requested" UserMessage SessionEventType = "user.message" )
type SourceType ¶
type SourceType string
const ( Local SourceType = "local" Remote SourceType = "remote" )
type ToolRequest ¶
type ToolRequest struct {
Arguments interface{} `json:"arguments"`
Name string `json:"name"`
ToolCallID string `json:"toolCallId"`
Type *ToolRequestType `json:"type,omitempty"`
}
type ToolRequestType ¶
type ToolRequestType string
const ( Custom ToolRequestType = "custom" Function ToolRequestType = "function" )
Click to show internal directories.
Click to hide internal directories.