Documentation
¶
Index ¶
- type A2AArtifact
- type A2AContextRef
- type A2AMessage
- type A2AMessageSendParams
- type A2APushAuthenticationInfo
- type A2APushNotificationConfig
- type A2ASendConfiguration
- type A2ASendMessageResponse
- type A2AStreamResponse
- type A2ATask
- type A2ATaskArtifactUpdateEvent
- type A2ATaskListParams
- type A2ATaskListResponse
- type A2ATaskPushConfigList
- type A2ATaskPushConfigParams
- type A2ATaskPushNotificationConfig
- type A2ATaskQueryParams
- type A2ATaskStatus
- type A2ATaskStatusUpdateEvent
- type AgentCardProvider
- type BearerGRPCAuthenticator
- type CallAgentRequest
- type CallPolicyResponse
- type ChildRunResponse
- type CreateRuntimeTokenRequest
- type GRPCAuthInfo
- type GRPCAuthenticator
- type GRPCServer
- func (s *GRPCServer) CancelTask(ctx context.Context, req *a2apb.CancelTaskRequest) (*a2apb.Task, error)
- func (s *GRPCServer) CreateTaskPushNotificationConfig(ctx context.Context, req *a2apb.TaskPushNotificationConfig) (*a2apb.TaskPushNotificationConfig, error)
- func (s *GRPCServer) DeleteTaskPushNotificationConfig(ctx context.Context, req *a2apb.DeleteTaskPushNotificationConfigRequest) (*emptypb.Empty, error)
- func (s *GRPCServer) GetExtendedAgentCard(ctx context.Context, req *a2apb.GetExtendedAgentCardRequest) (*a2apb.AgentCard, error)
- func (s *GRPCServer) GetTask(ctx context.Context, req *a2apb.GetTaskRequest) (*a2apb.Task, error)
- func (s *GRPCServer) GetTaskPushNotificationConfig(ctx context.Context, req *a2apb.GetTaskPushNotificationConfigRequest) (*a2apb.TaskPushNotificationConfig, error)
- func (s *GRPCServer) ListTaskPushNotificationConfigs(ctx context.Context, req *a2apb.ListTaskPushNotificationConfigsRequest) (*a2apb.ListTaskPushNotificationConfigsResponse, error)
- func (s *GRPCServer) ListTasks(ctx context.Context, req *a2apb.ListTasksRequest) (*a2apb.ListTasksResponse, error)
- func (s *GRPCServer) SendMessage(ctx context.Context, req *a2apb.SendMessageRequest) (*a2apb.SendMessageResponse, error)
- func (s *GRPCServer) SendStreamingMessage(req *a2apb.SendMessageRequest, ...) error
- func (s *GRPCServer) SubscribeToTask(req *a2apb.SubscribeToTaskRequest, ...) error
- type Handler
- func (h *Handler) CallAgent(c echo.Context) error
- func (h *Handler) CancelTaskHTTP(c echo.Context) error
- func (h *Handler) CreateRuntimeToken(c echo.Context) error
- func (h *Handler) DeleteTaskPushNotificationHTTP(c echo.Context) error
- func (h *Handler) GetCallPolicy(c echo.Context) error
- func (h *Handler) GetExtendedAgentCardHTTP(c echo.Context) error
- func (h *Handler) GetPublicAgentCardHTTP(c echo.Context) error
- func (h *Handler) GetRuntimeWorkbench(c echo.Context) error
- func (h *Handler) GetTaskHTTP(c echo.Context) error
- func (h *Handler) GetTaskPushNotificationHTTP(c echo.Context) error
- func (h *Handler) JSONRPC(c echo.Context) error
- func (h *Handler) ListChildren(c echo.Context) error
- func (h *Handler) ListParentRuns(c echo.Context) error
- func (h *Handler) ListRuntimeTokens(c echo.Context) error
- func (h *Handler) ListTaskPushNotificationsHTTP(c echo.Context) error
- func (h *Handler) ListTasksHTTP(c echo.Context) error
- func (h *Handler) MessageHTTP(c echo.Context) error
- func (h *Handler) Register(api *echo.Group, jwtMiddleware, queryMiddleware echo.MiddlewareFunc)
- func (h *Handler) RevokeRuntimeToken(c echo.Context) error
- func (h *Handler) SendMessageHTTP(c echo.Context) error
- func (h *Handler) SetAgentCardProvider(provider AgentCardProvider)
- func (h *Handler) SetTaskPushNotificationHTTP(c echo.Context) error
- func (h *Handler) StreamMessageHTTP(c echo.Context) error
- func (h *Handler) SubscribeTaskHTTP(c echo.Context) error
- func (h *Handler) TaskActionHTTP(c echo.Context) error
- func (h *Handler) UpdateCallPolicy(c echo.Context) error
- type JSONRPCError
- type JSONRPCRequest
- type JSONRPCResponse
- type ParentRunListResponse
- type ParentRunSummary
- type RuntimeTokenResponse
- type RuntimeWorkbenchAgent
- type RuntimeWorkbenchDiagnostic
- type RuntimeWorkbenchResponse
- type RuntimeWorkbenchRun
- type RuntimeWorkbenchRuntime
- type Service
- func (s *Service) CallAgent(ctx context.Context, plaintextToken string, req *CallAgentRequest) (*runtime.RunResponse, error)
- func (s *Service) CancelProtocolTask(ctx context.Context, userID uuid.UUID, slug, taskID string) (*A2ATask, error)
- func (s *Service) CreateRuntimeToken(ctx context.Context, userID, agentID uuid.UUID, req *CreateRuntimeTokenRequest) (*RuntimeTokenResponse, error)
- func (s *Service) DeletePushNotificationConfig(ctx context.Context, userID uuid.UUID, slug string, ...) error
- func (s *Service) GetCallPolicy(ctx context.Context, userID, agentID uuid.UUID) (*CallPolicyResponse, error)
- func (s *Service) GetProtocolTask(ctx context.Context, userID uuid.UUID, slug, taskID string, historyLength *int) (*A2ATask, error)
- func (s *Service) GetPushNotificationConfig(ctx context.Context, userID uuid.UUID, slug string, ...) (*A2ATaskPushNotificationConfig, error)
- func (s *Service) GetRuntimeWorkbench(ctx context.Context, userID, agentID uuid.UUID) (*RuntimeWorkbenchResponse, error)
- func (s *Service) ListChildren(ctx context.Context, userID, parentRunID uuid.UUID) ([]ChildRunResponse, error)
- func (s *Service) ListParentRuns(ctx context.Context, userID uuid.UUID, page, size int32, search string) (*ParentRunListResponse, error)
- func (s *Service) ListProtocolTaskEvents(ctx context.Context, userID uuid.UUID, slug, taskID string, ...) ([]interface{}, bool, int32, error)
- func (s *Service) ListProtocolTasks(ctx context.Context, userID uuid.UUID, slug string, params *A2ATaskListParams) (*A2ATaskListResponse, error)
- func (s *Service) ListPushNotificationConfigs(ctx context.Context, userID uuid.UUID, slug string, ...) (*A2ATaskPushConfigList, error)
- func (s *Service) ListRuntimeTokens(ctx context.Context, userID, agentID uuid.UUID) ([]RuntimeTokenResponse, error)
- func (s *Service) RevokeRuntimeToken(ctx context.Context, userID, tokenID uuid.UUID) error
- func (s *Service) SendProtocolMessage(ctx context.Context, userID uuid.UUID, slug string, ...) (*A2ATask, error)
- func (s *Service) SetDelegationLimits(maxDepth, maxRunning int)
- func (s *Service) SetPushNotificationConfig(ctx context.Context, userID uuid.UUID, slug string, ...) (*A2ATaskPushNotificationConfig, error)
- func (s *Service) SetTaskCallbackManager(manager taskCallbackManager)
- func (s *Service) StartProtocolMessage(ctx context.Context, userID uuid.UUID, slug string, ...) (*A2ATask, error)
- func (s *Service) UpdateCallPolicy(ctx context.Context, userID, agentID uuid.UUID, req *UpdateCallPolicyRequest) (*CallPolicyResponse, error)
- type SkillRef
- type UpdateCallPolicyRequest
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type A2AArtifact ¶
type A2AContextRef ¶
type A2AContextRef struct {
ProtocolContextID string `json:"protocol_context_id,omitempty"`
ProtocolTaskID string `json:"protocol_task_id,omitempty"`
RootContextID string `json:"root_context_id,omitempty"`
ParentContextID string `json:"parent_context_id,omitempty"`
ParentTaskID string `json:"parent_task_id,omitempty"`
TraceID string `json:"trace_id,omitempty"`
ReferenceTaskIDs []string `json:"reference_task_ids,omitempty"`
Source string `json:"source,omitempty"`
}
type A2AMessage ¶
type A2AMessage struct {
Kind string `json:"kind,omitempty"`
MessageID string `json:"messageId,omitempty"`
ContextID string `json:"contextId,omitempty"`
TaskID string `json:"taskId,omitempty"`
ReferenceTaskIDs []string `json:"referenceTaskIds,omitempty"`
Extensions []string `json:"extensions,omitempty"`
Role string `json:"role,omitempty"`
Parts []map[string]interface{} `json:"parts,omitempty"`
Metadata map[string]interface{} `json:"metadata,omitempty"`
}
type A2AMessageSendParams ¶
type A2AMessageSendParams struct {
Message A2AMessage `json:"message"`
Configuration *A2ASendConfiguration `json:"configuration,omitempty"`
Metadata map[string]interface{} `json:"metadata,omitempty"`
}
A2AMessageSendParams maps the A2A message/send params onto an OpenLinker run.
type A2APushNotificationConfig ¶
type A2APushNotificationConfig struct {
ID string `json:"id,omitempty"`
URL string `json:"url,omitempty"`
Token string `json:"token,omitempty"`
Secret string `json:"secret,omitempty"`
Authentication *A2APushAuthenticationInfo `json:"authentication,omitempty"`
Metadata map[string]interface{} `json:"metadata,omitempty"`
EventTypes []string `json:"eventTypes,omitempty"`
EventTypesAlias []string `json:"event_types,omitempty"`
}
type A2ASendConfiguration ¶
type A2ASendConfiguration struct {
AcceptedOutputModes []string `json:"acceptedOutputModes,omitempty"`
Blocking *bool `json:"blocking,omitempty"`
ReturnImmediately *bool `json:"returnImmediately,omitempty"`
PushNotificationConfig *A2APushNotificationConfig `json:"pushNotificationConfig,omitempty"`
TaskPushNotificationConfig *A2ATaskPushNotificationConfig `json:"taskPushNotificationConfig,omitempty"`
HistoryLength *int `json:"historyLength,omitempty"`
}
type A2ASendMessageResponse ¶
type A2ASendMessageResponse struct {
Task *A2ATask `json:"task,omitempty"`
Message *A2AMessage `json:"message,omitempty"`
}
type A2AStreamResponse ¶
type A2AStreamResponse struct {
Task *A2ATask `json:"task,omitempty"`
Message *A2AMessage `json:"message,omitempty"`
StatusUpdate *A2ATaskStatusUpdateEvent `json:"statusUpdate,omitempty"`
ArtifactUpdate *A2ATaskArtifactUpdateEvent `json:"artifactUpdate,omitempty"`
}
type A2ATask ¶
type A2ATask struct {
Kind string `json:"kind"`
ID string `json:"id"`
ContextID string `json:"contextId,omitempty"`
Status A2ATaskStatus `json:"status"`
Artifacts []A2AArtifact `json:"artifacts,omitempty"`
History []A2AMessage `json:"history,omitempty"`
Metadata map[string]interface{} `json:"metadata,omitempty"`
ResponseMessage *A2AMessage `json:"-"`
}
type A2ATaskArtifactUpdateEvent ¶
type A2ATaskArtifactUpdateEvent struct {
Kind string `json:"kind"`
TaskID string `json:"taskId"`
ContextID string `json:"contextId"`
Artifact A2AArtifact `json:"artifact"`
Append bool `json:"append,omitempty"`
LastChunk bool `json:"lastChunk,omitempty"`
Metadata map[string]interface{} `json:"metadata,omitempty"`
}
type A2ATaskListParams ¶
type A2ATaskListParams struct {
ContextID string `json:"contextId,omitempty"`
Status string `json:"status,omitempty"`
PageSize *int `json:"pageSize,omitempty"`
PageToken string `json:"pageToken,omitempty"`
HistoryLength *int `json:"historyLength,omitempty"`
StatusTimestampAfter string `json:"statusTimestampAfter,omitempty"`
IncludeArtifacts *bool `json:"includeArtifacts,omitempty"`
}
type A2ATaskListResponse ¶
type A2ATaskPushConfigList ¶
type A2ATaskPushConfigList struct {
Configs []A2ATaskPushNotificationConfig `json:"configs,omitempty"`
NextPageToken string `json:"nextPageToken,omitempty"`
Items []A2ATaskPushNotificationConfig `json:"items,omitempty"`
}
type A2ATaskPushConfigParams ¶
type A2ATaskPushConfigParams struct {
ID string `json:"id,omitempty"`
TaskID string `json:"taskId,omitempty"`
TaskIDAlias string `json:"task_id,omitempty"`
PushNotificationConfigID string `json:"pushNotificationConfigId,omitempty"`
PushNotificationConfigIDAlias string `json:"push_notification_config_id,omitempty"`
PushNotificationConfig A2APushNotificationConfig `json:"pushNotificationConfig,omitempty"`
URL string `json:"url,omitempty"`
Token string `json:"token,omitempty"`
Secret string `json:"secret,omitempty"`
Authentication *A2APushAuthenticationInfo `json:"authentication,omitempty"`
Metadata map[string]interface{} `json:"metadata,omitempty"`
EventTypes []string `json:"eventTypes,omitempty"`
EventTypesAlias []string `json:"event_types,omitempty"`
PageSize *int `json:"pageSize,omitempty"`
PageToken string `json:"pageToken,omitempty"`
}
type A2ATaskPushNotificationConfig ¶
type A2ATaskPushNotificationConfig struct {
Tenant string `json:"tenant,omitempty"`
ID string `json:"id,omitempty"`
TaskID string `json:"taskId,omitempty"`
TaskIDAlias string `json:"task_id,omitempty"`
URL string `json:"url,omitempty"`
Token string `json:"token,omitempty"`
Secret string `json:"secret,omitempty"`
Authentication *A2APushAuthenticationInfo `json:"authentication,omitempty"`
Metadata map[string]interface{} `json:"metadata,omitempty"`
EventTypes []string `json:"eventTypes,omitempty"`
EventTypesAlias []string `json:"event_types,omitempty"`
PushNotificationConfig A2APushNotificationConfig `json:"pushNotificationConfig,omitempty"`
}
type A2ATaskQueryParams ¶
type A2ATaskStatus ¶
type A2ATaskStatus struct {
State string `json:"state"`
Timestamp string `json:"timestamp,omitempty"`
Message *A2AMessage `json:"message,omitempty"`
}
type AgentCardProvider ¶
type BearerGRPCAuthenticator ¶
type BearerGRPCAuthenticator struct {
// contains filtered or unexported fields
}
func NewBearerGRPCAuthenticator ¶
func NewBearerGRPCAuthenticator(jwtSecret string, verifier auth.ApiKeyVerifier) *BearerGRPCAuthenticator
func (*BearerGRPCAuthenticator) AuthenticateA2AGRPC ¶
func (a *BearerGRPCAuthenticator) AuthenticateA2AGRPC(ctx context.Context) (*GRPCAuthInfo, error)
type CallAgentRequest ¶
type CallAgentRequest struct {
ParentRunID string `json:"parent_run_id,omitempty" validate:"omitempty,uuid"`
CurrentRunID string `json:"current_run_id,omitempty" validate:"omitempty,uuid"`
TargetAgentID string `json:"target_agent_id" validate:"required,uuid"`
Reason string `json:"reason" validate:"max=500"`
Input map[string]interface{} `json:"input" validate:"required"`
Metadata map[string]interface{} `json:"metadata,omitempty"`
ContextID string `json:"context_id,omitempty"`
ContextIDAlias string `json:"contextId,omitempty"`
TraceID string `json:"trace_id,omitempty"`
TraceIDAlias string `json:"traceId,omitempty"`
ReferenceTaskIDs []string `json:"reference_task_ids,omitempty"`
ReferenceTaskIDsAlias []string `json:"referenceTaskIds,omitempty"`
TaskCallback *A2APushNotificationConfig `json:"task_callback,omitempty"`
PushNotification *A2APushNotificationConfig `json:"push_notification,omitempty"`
PushNotificationAlias *A2APushNotificationConfig `json:"pushNotification,omitempty"`
PushNotificationConfig *A2APushNotificationConfig `json:"pushNotificationConfig,omitempty"`
}
CallAgentRequest is sent by Agent A using its runtime token.
type CallPolicyResponse ¶
type ChildRunResponse ¶
type ChildRunResponse struct {
ChildRunID string `json:"child_run_id"`
ParentRunID string `json:"parent_run_id"`
CallerAgentID string `json:"caller_agent_id"`
CallerAgentSlug string `json:"caller_agent_slug"`
CallerAgentName string `json:"caller_agent_name"`
CallerAgentTags []string `json:"caller_agent_tags"`
CallerSkills []SkillRef `json:"caller_skills"`
TargetAgentID string `json:"target_agent_id"`
TargetAgentSlug string `json:"target_agent_slug"`
TargetAgentName string `json:"target_agent_name"`
TargetAgentTags []string `json:"target_agent_tags"`
TargetSkills []SkillRef `json:"target_skills"`
Reason string `json:"reason"`
Status string `json:"status"`
CostCents int32 `json:"cost_cents"`
DurationMs *int32 `json:"duration_ms,omitempty"`
StartedAt string `json:"started_at"`
FinishedAt *string `json:"finished_at,omitempty"`
Source string `json:"source"`
BillingMode string `json:"billing_mode"`
A2AContext *A2AContextRef `json:"a2a_context,omitempty"`
Children []ChildRunResponse `json:"children,omitempty"`
}
type CreateRuntimeTokenRequest ¶
type CreateRuntimeTokenRequest struct {
Name string `json:"name" validate:"required,min=1,max=80"`
}
CreateRuntimeTokenRequest creates a credential bound to one calling Agent.
type GRPCAuthenticator ¶
type GRPCAuthenticator interface {
AuthenticateA2AGRPC(ctx context.Context) (*GRPCAuthInfo, error)
}
type GRPCServer ¶
type GRPCServer struct {
a2apb.UnimplementedA2AServiceServer
// contains filtered or unexported fields
}
func NewGRPCServer ¶
func NewGRPCServer(svc service, cardProvider AgentCardProvider, auth GRPCAuthenticator) *GRPCServer
func (*GRPCServer) CancelTask ¶
func (s *GRPCServer) CancelTask(ctx context.Context, req *a2apb.CancelTaskRequest) (*a2apb.Task, error)
func (*GRPCServer) CreateTaskPushNotificationConfig ¶
func (s *GRPCServer) CreateTaskPushNotificationConfig(ctx context.Context, req *a2apb.TaskPushNotificationConfig) (*a2apb.TaskPushNotificationConfig, error)
func (*GRPCServer) DeleteTaskPushNotificationConfig ¶
func (s *GRPCServer) DeleteTaskPushNotificationConfig(ctx context.Context, req *a2apb.DeleteTaskPushNotificationConfigRequest) (*emptypb.Empty, error)
func (*GRPCServer) GetExtendedAgentCard ¶
func (s *GRPCServer) GetExtendedAgentCard(ctx context.Context, req *a2apb.GetExtendedAgentCardRequest) (*a2apb.AgentCard, error)
func (*GRPCServer) GetTask ¶
func (s *GRPCServer) GetTask(ctx context.Context, req *a2apb.GetTaskRequest) (*a2apb.Task, error)
func (*GRPCServer) GetTaskPushNotificationConfig ¶
func (s *GRPCServer) GetTaskPushNotificationConfig(ctx context.Context, req *a2apb.GetTaskPushNotificationConfigRequest) (*a2apb.TaskPushNotificationConfig, error)
func (*GRPCServer) ListTaskPushNotificationConfigs ¶
func (s *GRPCServer) ListTaskPushNotificationConfigs(ctx context.Context, req *a2apb.ListTaskPushNotificationConfigsRequest) (*a2apb.ListTaskPushNotificationConfigsResponse, error)
func (*GRPCServer) ListTasks ¶
func (s *GRPCServer) ListTasks(ctx context.Context, req *a2apb.ListTasksRequest) (*a2apb.ListTasksResponse, error)
func (*GRPCServer) SendMessage ¶
func (s *GRPCServer) SendMessage(ctx context.Context, req *a2apb.SendMessageRequest) (*a2apb.SendMessageResponse, error)
func (*GRPCServer) SendStreamingMessage ¶
func (s *GRPCServer) SendStreamingMessage(req *a2apb.SendMessageRequest, stream a2apb.A2AService_SendStreamingMessageServer) error
func (*GRPCServer) SubscribeToTask ¶
func (s *GRPCServer) SubscribeToTask(req *a2apb.SubscribeToTaskRequest, stream a2apb.A2AService_SubscribeToTaskServer) error
type Handler ¶
type Handler struct {
// contains filtered or unexported fields
}
func NewHandler ¶
func NewHandler(svc service) *Handler
func (*Handler) CancelTaskHTTP ¶
CancelTaskHTTP handles the A2A HTTP+JSON alias POST /tasks/:taskID:cancel.
func (*Handler) DeleteTaskPushNotificationHTTP ¶
func (*Handler) GetExtendedAgentCardHTTP ¶
func (*Handler) GetPublicAgentCardHTTP ¶
GetPublicAgentCardHTTP exposes the A2A well-known Agent Card beneath the agent's protocol base URL while keeping the existing marketplace card URL.
func (*Handler) GetTaskHTTP ¶
GetTaskHTTP handles the A2A HTTP+JSON alias GET /tasks/:taskID.
func (*Handler) GetTaskPushNotificationHTTP ¶
func (*Handler) ListTaskPushNotificationsHTTP ¶
func (*Handler) MessageHTTP ¶
MessageHTTP dispatches literal A2A colon actions such as /message:send and /message:stream.
func (*Handler) Register ¶
func (h *Handler) Register(api *echo.Group, jwtMiddleware, queryMiddleware echo.MiddlewareFunc)
Register mounts creator controls, runtime-token invocation and user-visible trace lookup.
func (*Handler) SendMessageHTTP ¶
SendMessageHTTP handles the A2A HTTP+JSON alias POST /message:send.
func (*Handler) SetAgentCardProvider ¶
func (h *Handler) SetAgentCardProvider(provider AgentCardProvider)
func (*Handler) SetTaskPushNotificationHTTP ¶
func (*Handler) StreamMessageHTTP ¶
StreamMessageHTTP handles the A2A HTTP+JSON alias POST /message:stream.
func (*Handler) SubscribeTaskHTTP ¶
SubscribeTaskHTTP handles the A2A HTTP+JSON task subscription alias.
func (*Handler) TaskActionHTTP ¶
TaskActionHTTP dispatches literal A2A task colon actions such as /tasks/{id}:subscribe and /tasks/{id}:cancel.
type JSONRPCError ¶
type JSONRPCRequest ¶
type JSONRPCRequest struct {
JSONRPC string `json:"jsonrpc"`
ID json.RawMessage `json:"id"`
Method string `json:"method"`
Params json.RawMessage `json:"params,omitempty"`
}
JSONRPCRequest is the minimal JSON-RPC envelope used by the A2A adapter.
type JSONRPCResponse ¶
type JSONRPCResponse struct {
JSONRPC string `json:"jsonrpc"`
ID json.RawMessage `json:"id"`
Result interface{} `json:"result,omitempty"`
Error *JSONRPCError `json:"error,omitempty"`
}
type ParentRunListResponse ¶
type ParentRunListResponse struct {
Items []ParentRunSummary `json:"items"`
Total int32 `json:"total"`
Page int32 `json:"page"`
Size int32 `json:"size"`
}
ParentRunListResponse is the user's A2A entry directory.
type ParentRunSummary ¶
type ParentRunSummary struct {
ParentRunID string `json:"parent_run_id"`
CallerAgentID string `json:"caller_agent_id"`
CallerAgentSlug string `json:"caller_agent_slug"`
CallerAgentName string `json:"caller_agent_name"`
CallerAgentTags []string `json:"caller_agent_tags"`
CallerSkills []SkillRef `json:"caller_skills"`
Source string `json:"source"`
Status string `json:"status"`
DurationMs *int32 `json:"duration_ms,omitempty"`
StartedAt string `json:"started_at"`
FinishedAt *string `json:"finished_at,omitempty"`
ChildCount int32 `json:"child_count"`
SuccessfulChildCount int32 `json:"successful_child_count"`
RunningChildCount int32 `json:"running_child_count"`
ActiveAgentTokenCount int32 `json:"active_agent_token_count"`
LastAgentTokenUsedAt *string `json:"last_agent_token_used_at,omitempty"`
A2AContext *A2AContextRef `json:"a2a_context,omitempty"`
}
ParentRunSummary identifies one user-owned run that delegated work to child Agents.
type RuntimeTokenResponse ¶
type RuntimeTokenResponse struct {
ID string `json:"id"`
AgentID string `json:"agent_id"`
Name string `json:"name"`
Prefix string `json:"prefix"`
Scopes []string `json:"scopes"`
PlaintextToken string `json:"plaintext_token,omitempty"`
LastUsedAt *string `json:"last_used_at,omitempty"`
RevokedAt *string `json:"revoked_at,omitempty"`
CreatedAt string `json:"created_at"`
}
RuntimeTokenResponse returns token metadata. PlaintextToken is only populated once on creation.
type RuntimeWorkbenchAgent ¶
type RuntimeWorkbenchAgent struct {
ID string `json:"id"`
Slug string `json:"slug"`
Name string `json:"name"`
ConnectionMode string `json:"connection_mode"`
LifecycleStatus string `json:"lifecycle_status"`
Visibility string `json:"visibility"`
CertificationStatus string `json:"certification_status"`
ReadinessCallable bool `json:"readiness_callable"`
AvailabilityStatus string `json:"availability_status"`
}
type RuntimeWorkbenchResponse ¶
type RuntimeWorkbenchResponse struct {
Agent RuntimeWorkbenchAgent `json:"agent"`
Runtime RuntimeWorkbenchRuntime `json:"runtime"`
Tokens []RuntimeTokenResponse `json:"tokens"`
RecentRuns []RuntimeWorkbenchRun `json:"recent_runs"`
Diagnostics []RuntimeWorkbenchDiagnostic `json:"diagnostics"`
}
type RuntimeWorkbenchRun ¶
type RuntimeWorkbenchRun struct {
RunID string `json:"run_id"`
Status string `json:"status"`
Source string `json:"source"`
StartedAt string `json:"started_at"`
ClaimedAt *string `json:"claimed_at,omitempty"`
FinishedAt *string `json:"finished_at,omitempty"`
ErrorCode *string `json:"error_code,omitempty"`
ErrorMessage *string `json:"error_message,omitempty"`
DetailURL string `json:"detail_url"`
}
type RuntimeWorkbenchRuntime ¶
type RuntimeWorkbenchRuntime struct {
ActiveTokenCount int32 `json:"active_token_count"`
PendingRunCount int32 `json:"pending_run_count"`
ClaimNow bool `json:"claim_now"`
LastRuntimeActivityAt *string `json:"last_runtime_activity_at,omitempty"`
LastClaimedAt *string `json:"last_claimed_at,omitempty"`
LastResultAt *string `json:"last_result_at,omitempty"`
RecommendedHeartbeatAfterSeconds int32 `json:"recommended_heartbeat_after_seconds"`
MaxClaimWaitSeconds int32 `json:"max_claim_wait_seconds"`
}
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func (*Service) CallAgent ¶
func (s *Service) CallAgent(ctx context.Context, plaintextToken string, req *CallAgentRequest) (*runtime.RunResponse, error)
func (*Service) CancelProtocolTask ¶
func (s *Service) CancelProtocolTask(ctx context.Context, userID uuid.UUID, slug, taskID string) (*A2ATask, error)
CancelProtocolTask maps A2A tasks/cancel onto a real OpenLinker run cancellation.
func (*Service) CreateRuntimeToken ¶
func (s *Service) CreateRuntimeToken(ctx context.Context, userID, agentID uuid.UUID, req *CreateRuntimeTokenRequest) (*RuntimeTokenResponse, error)
func (*Service) DeletePushNotificationConfig ¶
func (*Service) GetCallPolicy ¶
func (*Service) GetProtocolTask ¶
func (s *Service) GetProtocolTask(ctx context.Context, userID uuid.UUID, slug, taskID string, historyLength *int) (*A2ATask, error)
GetProtocolTask maps an owner-readable OpenLinker run back to the A2A Task shape.
func (*Service) GetPushNotificationConfig ¶
func (s *Service) GetPushNotificationConfig(ctx context.Context, userID uuid.UUID, slug string, params *A2ATaskPushConfigParams) (*A2ATaskPushNotificationConfig, error)
func (*Service) GetRuntimeWorkbench ¶
func (*Service) ListChildren ¶
func (*Service) ListParentRuns ¶
func (*Service) ListProtocolTaskEvents ¶
func (*Service) ListProtocolTasks ¶
func (s *Service) ListProtocolTasks(ctx context.Context, userID uuid.UUID, slug string, params *A2ATaskListParams) (*A2ATaskListResponse, error)
func (*Service) ListPushNotificationConfigs ¶
func (s *Service) ListPushNotificationConfigs(ctx context.Context, userID uuid.UUID, slug string, params *A2ATaskPushConfigParams) (*A2ATaskPushConfigList, error)
func (*Service) ListRuntimeTokens ¶
func (*Service) RevokeRuntimeToken ¶
func (*Service) SendProtocolMessage ¶
func (s *Service) SendProtocolMessage(ctx context.Context, userID uuid.UUID, slug string, params *A2AMessageSendParams) (*A2ATask, error)
SendProtocolMessage accepts an external A2A message/send request and runs the target Agent.
func (*Service) SetDelegationLimits ¶
func (*Service) SetPushNotificationConfig ¶
func (s *Service) SetPushNotificationConfig(ctx context.Context, userID uuid.UUID, slug string, params *A2ATaskPushConfigParams) (*A2ATaskPushNotificationConfig, error)
func (*Service) SetTaskCallbackManager ¶
func (s *Service) SetTaskCallbackManager(manager taskCallbackManager)
func (*Service) StartProtocolMessage ¶
func (s *Service) StartProtocolMessage(ctx context.Context, userID uuid.UUID, slug string, params *A2AMessageSendParams) (*A2ATask, error)
StartProtocolMessage starts an A2A message/stream request and returns the initial Task.
func (*Service) UpdateCallPolicy ¶
func (s *Service) UpdateCallPolicy(ctx context.Context, userID, agentID uuid.UUID, req *UpdateCallPolicyRequest) (*CallPolicyResponse, error)
type UpdateCallPolicyRequest ¶
type UpdateCallPolicyRequest struct {
CallableBy string `json:"callable_by" validate:"required,oneof=public same_creator private"`
}
UpdateCallPolicyRequest configures which Agents may call the target through OpenLinker.