Changeset 0.28.6 (#192)
This commit is contained in:
@@ -13,24 +13,33 @@ type GitCredential struct {
|
||||
AuthType string `json:"auth_type" db:"auth_type"` // https_pat, https_basic, ssh_key
|
||||
EncryptedData []byte `json:"-" db:"encrypted_data"` // never expose
|
||||
Nonce []byte `json:"-" db:"nonce"` // never expose
|
||||
PublicKey string `json:"public_key,omitempty" db:"public_key"`
|
||||
Fingerprint string `json:"fingerprint,omitempty" db:"fingerprint"`
|
||||
PersonaID *string `json:"persona_id,omitempty" db:"persona_id"`
|
||||
CreatedAt time.Time `json:"created_at" db:"created_at"`
|
||||
}
|
||||
|
||||
// GitCredentialSummary is the safe-to-expose version (no encrypted data).
|
||||
type GitCredentialSummary struct {
|
||||
ID string `json:"id"`
|
||||
Name string `json:"name"`
|
||||
AuthType string `json:"auth_type"`
|
||||
CreatedAt time.Time `json:"created_at"`
|
||||
ID string `json:"id"`
|
||||
Name string `json:"name"`
|
||||
AuthType string `json:"auth_type"`
|
||||
PublicKey string `json:"public_key,omitempty"`
|
||||
Fingerprint string `json:"fingerprint,omitempty"`
|
||||
PersonaID *string `json:"persona_id,omitempty"`
|
||||
CreatedAt time.Time `json:"created_at"`
|
||||
}
|
||||
|
||||
// Summary returns a safe version without encrypted fields.
|
||||
func (c *GitCredential) Summary() GitCredentialSummary {
|
||||
return GitCredentialSummary{
|
||||
ID: c.ID,
|
||||
Name: c.Name,
|
||||
AuthType: c.AuthType,
|
||||
CreatedAt: c.CreatedAt,
|
||||
ID: c.ID,
|
||||
Name: c.Name,
|
||||
AuthType: c.AuthType,
|
||||
PublicKey: c.PublicKey,
|
||||
Fingerprint: c.Fingerprint,
|
||||
PersonaID: c.PersonaID,
|
||||
CreatedAt: c.CreatedAt,
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -34,6 +34,7 @@ const (
|
||||
NotifTypeTaskCompleted = "task.completed"
|
||||
NotifTypeTaskFailed = "task.failed"
|
||||
NotifTypeTaskBudget = "task.budget_exceeded"
|
||||
NotifTypeAnnouncement = "system.announcement"
|
||||
)
|
||||
|
||||
// Resource type constants for click-to-navigate.
|
||||
|
||||
@@ -7,7 +7,8 @@ import (
|
||||
|
||||
// Task is a scheduled, one-shot, or webhook-triggered job that creates a
|
||||
// service channel and runs a completion (prompt task), instantiates a
|
||||
// workflow, or relays a payload without LLM involvement (action task).
|
||||
// workflow, relays a payload without LLM involvement (action task), or
|
||||
// executes a built-in Go function (system task).
|
||||
type Task struct {
|
||||
ID string `json:"id" db:"id"`
|
||||
OwnerID string `json:"owner_id" db:"owner_id"`
|
||||
@@ -17,7 +18,8 @@ type Task struct {
|
||||
Scope string `json:"scope" db:"scope"` // personal | team | global
|
||||
|
||||
// What to run
|
||||
TaskType string `json:"task_type" db:"task_type"` // prompt | workflow | action
|
||||
TaskType string `json:"task_type" db:"task_type"` // prompt | workflow | action | system
|
||||
SystemFunction string `json:"system_function,omitempty" db:"system_function"`
|
||||
PersonaID *string `json:"persona_id,omitempty" db:"persona_id"`
|
||||
ModelID string `json:"model_id" db:"model_id"`
|
||||
SystemPrompt string `json:"system_prompt" db:"system_prompt"`
|
||||
|
||||
Reference in New Issue
Block a user