telnyx-ai-assistants-c…
AI voice assistants with custom instructions, knowledge bases, and tool integrations.
Manage call recordings, media storage, Dialogflow integration, and external connections for SIP trunking. This skill provides Go SDK examples.
$ npx -y skills add team-telnyx/ai --skill telnyx-sip-integrations-go --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/telnyx-sip-integrations-goContext preview
The summary Claude sees to decide when to auto-load this skill.
Manage call recordings, media storage, Dialogflow integration, and external connections for SIP trunking. This skill provides Go SDK examples.
name: telnyx-sip-integrations-go description: >- Manage call recordings, media storage, Dialogflow integration, and external connections for SIP trunking. This skill provides Go SDK examples. metadata: author: telnyx product: sip-integrations language: go generated_by: telnyx-openapi-pipeline
<!-- Auto-generated from Telnyx OpenAPI specs. Do not edit. -->
go get github.com/team-telnyx/telnyx-go
import (
"context"
"fmt"
"os"
"github.com/team-telnyx/telnyx-go"
"github.com/team-telnyx/telnyx-go/option"
)
client := telnyx.NewClient(
option.WithAPIKey(os.Getenv("TELNYX_API_KEY")),
)All examples below assume `client` is already initialized as shown above.
All API calls can fail with network errors, rate limits (429), validation errors (422), or authentication errors (401). Always handle errors in production code:
import "errors"
result, err := client.Messages.Send(ctx, params)
if err != nil {
var apiErr *telnyx.Error
if errors.As(err, &apiErr) {
switch apiErr.StatusCode {
case 422:
fmt.Println("Validation error — check required fields and formats")
case 429:
// Rate limited — wait and retry with exponential backoff
fmt.Println("Rate limited, retrying...")
default:
fmt.Printf("API error %d: %s\n", apiErr.StatusCode, apiErr.Error())
}
} else {
fmt.Println("Network error — check connectivity and retry")
}
}Common error codes: `401` invalid API key, `403` insufficient permissions, `404` resource not found, `422` validation error (check field formats), `429` rate limited (retry with exponential backoff).
Returns the information about custom storage credentials.
`GET /custom_storage_credentials/{connection_id}`
customStorageCredential, err := client.CustomStorageCredentials.Get(context.Background(), "connection_id")
if err != nil {
log.Fatal(err)
}
fmt.Printf("%+v\n", customStorageCredential.ConnectionID)Returns: `backend` (enum: gcs, s3, azure), `configuration` (object)
Creates a custom storage credentials configuration.
`POST /custom_storage_credentials/{connection_id}`
customStorageCredential, err := client.CustomStorageCredentials.New(
context.Background(),
"connection_id",
telnyx.CustomStorageCredentialNewParams{
CustomStorageConfiguration: telnyx.CustomStorageConfigurationParam{
Backend: telnyx.CustomStorageConfigurationBackendGcs,
Configuration: telnyx.CustomStorageConfigurationConfigurationUnionParam{
OfGcs: &telnyx.GcsConfigurationDataParam{
Backend: telnyx.GcsConfigurationDataBackendGcs,
},
},
},
},
)
if err != nil {
log.Fatal(err)
}
fmt.Printf("%+v\n", customStorageCredential.ConnectionID)Returns: `backend` (enum: gcs, s3, azure), `configuration` (object)
Updates a stored custom credentials configuration.
`PUT /custom_storage_credentials/{connection_id}`
customStorageCredential, err := client.CustomStorageCredentials.Update(
context.Background(),
"connection_id",
telnyx.CustomStorageCredentialUpdateParams{
CustomStorageConfiguration: telnyx.CustomStorageConfigurationParam{
Backend: telnyx.CustomStorageConfigurationBackendGcs,
Configuration: telnyx.CustomStorageConfigurationConfigurationUnionParam{
OfGcs: &telnyx.GcsConfigurationDataParam{
Backend: telnyx.GcsConfigurationDataBackendGcs,
},
},
},
},
)
if err != nil {
log.Fatal(err)
}
fmt.Printf("%+v\n", customStorageCredential.ConnectionID)Returns: `backend` (enum: gcs, s3, azure), `configuration` (object)
Deletes a stored custom credentials configuration.
`DELETE /custom_storage_credentials/{connection_id}`
err := client.CustomStorageCredentials.Delete(context.Background(), "connection_id")
if err != nil {
log.Fatal(err)
}Return details of the Dialogflow connection associated with the given CallControl connection.
`GET /dialogflow_connections/{connection_id}`
dialogflowConnection, err := client.DialogflowConnections.Get(context.Background(), "connection_id")
if err != nil {
log.Fatal(err)
}
fmt.Printf("%+v\n", dialogflowConnection.Data)Returns: `connection_id` (string), `conversation_profile_id` (string), `environment` (string), `record_type` (string), `service_account` (string)
Save Dialogflow Credentiails to Telnyx, so it can be used with other Telnyx services.
`POST /dialogflow_connections/{connection_id}`
dialogflowConnection, err := client.DialogflowConnections.New(
context.Background(),
"connection_id",
telnyx.DialogflowConnectionNewParams{
ServiceAccount: map[string]any{
"type": "bar",
"project_id": "bar",
"private_key_id": "bar",
"private_key": "bar",
"client_email": "bar",
"client_id": "bar",
"auth_uri": "bar",
"token_uri": "bar",
"auth_provider_x509_cert_url": "bar",
"client_x509_cert_url": "bar",
},
},
)
if err != nil {
log.Fatal(err)
}
fmt.Printf("%+v\n", dialogflowConnection.Data)Returns: `connection_id` (string), `conversation_profile_id` (string), `environment` (string), `record_type` (string), `service_account` (string)
Updates a stored Dialogflow Connection.
`PUT /dialogflow_connections/{connection_id}`
dialogflowConnection, err := client.DialogflowConnections.Update( conte
This repo is the one-stop shop for AI Agents and AI-first developers building with Telnyx — everything an agent needs to build production-grade applications and manage its account, from signup to funding.
Repo: team-telnyx/ai
AI voice assistants with custom instructions, knowledge bases, and tool integrations.
AI voice assistants with custom instructions, knowledge bases, and tool integrations.
AI voice assistants with custom instructions, knowledge bases, and tool integrations.
AI voice assistants with custom instructions, knowledge bases, and tool integrations.
AI voice assistants with custom instructions, knowledge bases, and tool integrations.
AI voice assistants with custom instructions, knowledge bases, and tool integrations.