team-telnyx/ai

telnyx-import-retell

- Import Retell AI agents into Telnyx — both single-prompt and multi-prompt configurations.

소스 보기

사용 방법

  1. 설치 명령을 복사하고 자신의 에이전트 환경에 설치하기 전에 소스 패키지를 확인하세요.
  2. 필요한 도구, 인증 정보, 지원 환경은 원본 문서에서 확인하세요.
  3. 입력과 원하는 산출물을 설명하고 출처와 결과를 대조하세요.
npx skills add https://github.com/team-telnyx/ai --skill telnyx-import-retell

시작 전 확인

  • 설치에는 모델 구독, API 한도, 파일 접근 권한이 포함되지 않습니다.
  • 별점 수와 설치 수는 활동 지표이며 독립적인 품질·보안 검증이 아닙니다.
원본 Skill 문서

원본 저장소의 제목, 예시, 코드, 표, 링크, 이미지를 유지해 표시합니다.

Import Retell Agents into Telnyx

Migrate your Retell AI agents to Telnyx in minutes. The import API pulls agent configurations directly from Retell using your API key and recreates them as Telnyx AI Assistants. Both single-prompt and multi-prompt Retell agents are supported.

Interaction model: Collect the user's Telnyx API key and Retell API key, store the Retell key as a Telnyx integration secret, run the import, then verify. Do NOT skip the secret-creation step — the import endpoint requires a secret reference, not a raw key.

What Gets Imported

ComponentImported?Notes
InstructionsYesImported as-is (both single and multi-prompt)
Greeting / first messageYesMaps to assistant greeting
Voice configurationYesVoice provider and voice ID preserved
Dynamic variablesYesDefault values carried over
Tools (hangup, transfer, webhook)YesTool definitions and configurations
MCP Server integrationsYesServer URLs and tool mappings
Call analysis / insightsYesMapped to insight_settings
Data retention preferencesYesMapped to privacy_settings
Knowledge baseNoMust be manually added post-import
Secrets (API keys in tools)PartialPlaceholder secrets created — you must re-enter values in the Telnyx portal

Prerequisites

  1. Telnyx API key — get one at https://portal.telnyx.com/#/app/api-keys
  2. Retell API key — from your Retell dashboard
  3. Store the Retell API key as a Telnyx integration secret at https://portal.telnyx.com/#/app/integration-secrets

Step 1: Store Your Retell API Key as a Telnyx Secret

Before importing, store your Retell API key as an integration secret in Telnyx. Note the secret reference name (e.g., retell_api_key) — you'll use it in the import call.

You can create integration secrets via the Telnyx Portal under Integration Secrets, or via the API.

Step 2: Import All Retell Agents

Import every agent from your Retell account:

curl

bash
curl \
  -X POST \
  -H "Authorization: Bearer $TELNYX_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "provider": "retell",
  "api_key_ref": "retell_api_key"
}' \
  "https://api.telnyx.com/v2/ai/assistants/import"

Python

python
import os
from telnyx import Telnyx

client = Telnyx(api_key=os.environ.get("TELNYX_API_KEY"))

assistants = client.ai.assistants.imports(
    provider="retell",
    api_key_ref="retell_api_key",
)

for assistant in assistants.data:
    print(f"Imported: {assistant.name} (ID: {assistant.id})")

JavaScript

javascript
import Telnyx from 'telnyx';

const client = new Telnyx();

const assistants = await client.ai.assistants.imports({
  provider: 'retell',
  api_key_ref: 'retell_api_key',
});

for (const assistant of assistants.data) {
  console.log(`Imported: ${assistant.name} (ID: ${assistant.id})`);
}

Go

go
assistants, err := client.AI.Assistants.Imports(context.TODO(), telnyx.AIAssistantImportsParams{
    Provider:  telnyx.AIAssistantImportsParamsProviderRetell,
    APIKeyRef: "retell_api_key",
})
if err != nil {
    panic(err.Error())
}
for _, a := range assistants.Data {
    fmt.Printf("Imported: %s (ID: %s)\n", a.Name, a.ID)
}

Java

java
import com.telnyx.sdk.models.ai.assistants.AssistantImportsParams;
import com.telnyx.sdk.models.ai.assistants.AssistantsList;

AssistantImportsParams params = AssistantImportsParams.builder()
    .provider(AssistantImportsParams.Provider.RETELL)
    .apiKeyRef("retell_api_key")
    .build();
AssistantsList assistants = client.ai().assistants().imports(params);
assistants.getData().forEach(a ->
    System.out.printf("Imported: %s (ID: %s)%n", a.getName(), a.getId()));

Ruby

ruby
assistants = client.ai.assistants.imports(
  provider: :retell,
  api_key_ref: "retell_api_key"
)

assistants.data.each do |a|
  puts "Imported: #{a.name} (ID: #{a.id})"
end

Step 2 (Alternative): Import Specific Agents

To import only certain agents, pass their Retell agent IDs in import_ids:

curl

bash
curl \
  -X POST \
  -H "Authorization: Bearer $TELNYX_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "provider": "retell",
  "api_key_ref": "retell_api_key",
  "import_ids": ["retell-agent-id-1", "retell-agent-id-2"]
}' \
  "https://api.telnyx.com/v2/ai/assistants/import"

Python

python
assistants = client.ai.assistants.imports(
    provider="retell",
    api_key_ref="retell_api_key",
    import_ids=["retell-agent-id-1", "retell-agent-id-2"],
)

JavaScript

javascript
const assistants = await client.ai.assistants.imports({
  provider: 'retell',
  api_key_ref: 'retell_api_key',
  import_ids: ['retell-agent-id-1', 'retell-agent-id-2'],
});

Step 3: Verify the Import

List your Telnyx assistants to confirm the import succeeded:

curl

bash
curl -H "Authorization: Bearer $TELNYX_API_KEY" \
  "https://api.telnyx.com/v2/ai/assistants"

Python

python
assistants = client.ai.assistants.list()
for a in assistants.data:
    print(f"{a.name} — {a.id} — imported: {a.import_metadata}")

JavaScript

javascript
const assistants = await client.ai.assistants.list();
for (const a of assistants.data) {
  console.log(`${a.name} — ${a.id} — imported:`, a.import_metadata);
}

Step 4: Post-Import Checklist

After importing, complete these manual steps:

  1. Re-enter secrets — Any API keys referenced by tools were imported as placeholders. Go to https://portal.telnyx.com/#/app/integration-secrets and supply the actual values.
  2. Add knowledge bases — Knowledge base content is not imported. Upload files or add URLs in the assistant's Knowledge Base settings.
  3. Assign a phone number — Connect a Telnyx phone number to your imported assistant to start receiving calls.
  4. Test the assistant — Use the Telnyx assistant testing API or make a test call to verify behavior.

Re-importing

Running the import again for the same Retell agents will overwrite the existing Telnyx copies with the latest configuration from Retell. This is useful for syncing changes during a gradual migration.

API Reference

FieldTypeRequiredDescription
providerstringYesMust be "retell"
api_key_refstringYesName of the Telnyx integration secret containing your Retell API key
import_idsarray[string]NoSpecific Retell agent IDs to import. Omit to import all.

Endpoint: POST https://api.telnyx.com/v2/ai/assistants/import

Full API docs: https://developers.telnyx.com/api-reference/assistants/import-assistants-from-external-provider

관련 작업

같은 저장소의 Skills

더 많은 Skills

모든 Skills