notify

package
v0.98.0 Latest Latest
Warning

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

Go to latest
Published: Jul 21, 2026 License: GPL-3.0 Imports: 8 Imported by: 0

Documentation

Overview

Package notify provides the chatagent tool for Gateway notification pushes.

Index

Constants

View Source
const (
	// SendToolName is the agent tool name for sending a gateway notification.
	SendToolName = "send_notification"
)

Variables

This section is empty.

Functions

func ActiveToolNames

func ActiveToolNames() []string

ActiveToolNames returns the default notify tool names.

func Register

func Register(registry *tool.Registry, uid types.Uid) error

Register registers send_notification on the given registry.

Types

type SendTool

type SendTool struct {
	// UID is the notification owner recorded with the send.
	UID types.Uid
}

SendTool sends a notification via the notification gateway defaults.

func (SendTool) Description

func (SendTool) Description() string

Description explains the tool to the model.

func (SendTool) Execute

func (t SendTool) Execute(ctx context.Context, id string, args map[string]any, _ tool.UpdateHandler) (msg.ToolResultMessage, error)

Execute sends the notification using global default channel and template.

func (SendTool) Name

func (SendTool) Name() string

Name returns the tool identifier.

func (SendTool) Parameters

func (SendTool) Parameters() map[string]any

Parameters returns the JSON schema for tool arguments.

Jump to

Keyboard shortcuts

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