siprealtime

package
v1.4.1 Latest Latest
Warning

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

Go to latest
Published: Jun 8, 2026 License: MIT Imports: 14 Imported by: 0

Documentation

Overview

Package siprealtime wires pkg/realtime agents into SIP RTP call legs.

Index

Constants

This section is empty.

Variables

View Source
var ErrNotConfigured = errors.New("siprealtime: REALTIME_CONFIG_JSON not set")

ErrNotConfigured means REALTIME_CONFIG_JSON is unset.

Functions

This section is empty.

Types

type Bridge

type Bridge struct {
	// contains filtered or unexported fields
}

Bridge connects caller RTP PCM ↔ realtime.Agent for one SIP leg.

func Attach

func Attach(cs *session.CallSession, cfg Config) (*Bridge, error)

Attach starts a realtime session on cs and registers media processors. Call before CallSession.StartOnACK / Start.

func (*Bridge) Close

func (b *Bridge) Close() error

Close tears down the realtime agent and output pacer.

type Config

type Config struct {
	Credential       map[string]any
	SystemPrompt     string
	Voice            string
	InputSampleRate  int
	OutputSampleRate int
}

Config holds realtime agent credentials and session options.

func ConfigFromEnv

func ConfigFromEnv() (Config, error)

ConfigFromEnv loads realtime settings from environment variables.

Jump to

Keyboard shortcuts

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