Skip to content

Latest commit

 

History

History
70 lines (47 loc) · 1.85 KB

File metadata and controls

70 lines (47 loc) · 1.85 KB
sidebar_position 1
title Installation
description Install the Agora Conversational AI Go SDK and configure your project.

Installation

Prerequisites

  • Go 1.21 or later

Install

go get github.com/AgoraIO/agora-agents-go/v2@v2.0.0

Import Paths

The SDK is organized into several packages. Import the ones you need:

// Root package — type definitions, pointer helpers (Agora.String(), Agora.Bool(), etc.), environments
Agora "github.com/AgoraIO/agora-agents-go/v2"

// Fern-generated client — low-level API access
"github.com/AgoraIO/agora-agents-go/v2/client"

// Request options — authentication, base URL, retries, HTTP client
"github.com/AgoraIO/agora-agents-go/v2/option"

// Wrapper layer — Agent builder with functional options, session lifecycle
"github.com/AgoraIO/agora-agents-go/v2/agentkit"

// Vendor constructors — LLM, TTS, STT, MLLM, and Avatar vendors
"github.com/AgoraIO/agora-agents-go/v2/agentkit/vendors"

Verify Installation

package main

import (
    "fmt"

    Agora "github.com/AgoraIO/agora-agents-go/v2"
)

func main() {
    fmt.Println("Default API endpoint:", Agora.Environments.Default)
}
go run main.go
# Output: Default API endpoint: https://api.agora.io/api/conversational-ai-agent

Next Steps

Migrating from a previous module path

In v2.0.0, the repository remains AgoraIO/agora-agents-go, and the Go module path is github.com/AgoraIO/agora-agents-go/v2. Replace github.com/AgoraIO-Conversational-AI/agent-server-sdk-go in go.mod and in all import paths, then run go mod tidy.

For the full change list, see changelog — v2.0.0.