team-telnyx/telnyx-skills

telnyx-account-notifications-go

>- Configure notification channels and settings for account alerts and events. This skill provides Go SDK examples.

First seen Mar 7, 2026

Installation

$ npx skills add team-telnyx/telnyx-skills --skill telnyx-account-notifications-go

Similar popular skills

Related neighbors and high-traction skills in the same topics — useful to compare before installing.

Also in this package

Other skills from team-telnyx/telnyx-skills · top by installs.

npx skills add team-telnyx/telnyx-skills

Browse all from team-telnyx/telnyx-skills

More details

Agent compatibility

Declared targets from SKILL.md / docs. Unmarked agents are not listed — the skill may still install via the CLI.

Claude Code Not declared
Cursor Not declared
Codex Not declared
GitHub Copilot Not declared
Windsurf Not declared
Gemini CLI Not declared
Cline Not declared
OpenCode Not declared

Repository health

Stars 188
License LICENSE
Default branch main
Open issues 2
Status Active

Skill metadata

Parsed from SKILL.md frontmatter.

More metadata
author
telnyx
product
account-notifications
language
go
generated_by
telnyx-openapi-pipeline

Package contents

Files included with this skill beyond the listing page.

  • skill md SKILL.md 11,978 B
  • docs SUMMARY.md 151 B

History

  1. First seen on skills.sh
  2. First recorded snapshot · 13 installs

SKILL.md

<!-- Auto-generated from Telnyx OpenAPI specs. Do not edit. -->

Telnyx Account Notifications - Go

Installation

go get github.com/team-telnyx/telnyx-go

Setup

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.

Error Handling

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).

Important Notes

  • Pagination: Use ListAutoPaging() for automatic iteration: iter := client.Resource.ListAutoPaging(ctx, params); for iter.Next() { item := iter.Current() }.

List notification channels

List notification channels.

GET /notification_channels

	page, err := client.NotificationChannels.List(context.Background(), telnyx.NotificationChannelListParams{})
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("%+v\n", page)

Returns: channeldestination (string), channeltypeid (enum: sms, voice, email, webhook), createdat (date-time), id (string), notificationprofileid (string), updated_at (date-time)

Create a notification channel

Create a notification channel.

POST /notification_channels

Optional: channeldestination (string), channeltypeid (enum: sms, voice, email, webhook), createdat (date-time), id (string), notificationprofileid (string), updated_at (date-time)

	notificationChannel, err := client.NotificationChannels.New(context.Background(), telnyx.NotificationChannelNewParams{
		ChannelTypeID: "550e8400-e29b-41d4-a716-446655440000",
		ChannelDestination: "https://example.com/webhooks",
	})
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("%+v\n", notificationChannel.Data)

Returns: channeldestination (string), channeltypeid (enum: sms, voice, email, webhook), createdat (date-time), id (string), notificationprofileid (string), updated_at (date-time)

Get a notification channel

Get a notification channel.

GET /notification_channels/{id}

	notificationChannel, err := client.NotificationChannels.Get(context.Background(), "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e")
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("%+v\n", notificationChannel.Data)

Returns: channeldestination (string), channeltypeid (enum: sms, voice, email, webhook), createdat (date-time), id (string), notificationprofileid (string), updated_at (date-time)

Update a notification channel

Update a notification channel.

PATCH /notification_channels/{id}

Optional: channeldestination (string), channeltypeid (enum: sms, voice, email, webhook), createdat (date-time), id (string), notificationprofileid (string), updated_at (date-time)

	notificationChannel, err := client.NotificationChannels.Update(
		context.Background(),
		"182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
		telnyx.NotificationChannelUpdateParams{
			NotificationChannel: telnyx.NotificationChannelParam{},
		},
	)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("%+v\n", notificationChannel.Data)

Returns: channeldestination (string), channeltypeid (enum: sms, voice, email, webhook), createdat (date-time), id (string), notificationprofileid (string), updated_at (date-time)

Delete a notification channel

Delete a notification channel.

DELETE /notification_channels/{id}

	notificationChannel, err := client.NotificationChannels.Delete(context.Background(), "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e")
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("%+v\n", notificationChannel.Data)

Returns: channeldestination (string), channeltypeid (enum: sms, voice, email, webhook), createdat (date-time), id (string), notificationprofileid (string), updated_at (date-time)

List all Notifications Events Conditions

Returns a list of your notifications events conditions.

GET /notificationeventconditions

	page, err := client.NotificationEventConditions.List(context.Background(), telnyx.NotificationEventConditionListParams{})
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("%+v\n", page)

Returns: allowmultiplechannels (boolean), associatedrecordtype (enum: account, phonenumber), asynchronous (boolean), createdat (date-time), description (string), enabled (boolean), id (string), name (string), notificationeventid (string), parameters (array[object]), supportedchannels (array[string]), updatedat (date-time)

List all Notifications Events

Returns a list of your notifications events.

GET /notification_events

	page, err := client.NotificationEvents.List(context.Background(), telnyx.NotificationEventListParams{})
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("%+v\n", page)

Returns: createdat (date-time), enabled (boolean), id (string), name (string), notificationcategory (string), updated_at (date-time)

List all Notifications Profiles

Returns a list of your notifications profiles.

GET /notification_profiles

	page, err := client.NotificationProfiles.List(context.Background(), telnyx.NotificationProfileListParams{})
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("%+v\n", page)

Returns: createdat (date-time), id (string), name (string), updatedat (date-time)

Create a notification profile

Create a notification profile.

POST /notification_profiles

Optional: createdat (date-time), id (string), name (string), updatedat (date-time)

	notificationProfile, err := client.NotificationProfiles.New(context.Background(), telnyx.NotificationProfileNewParams{
		Name: "My Notification Profile",
	})
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("%+v\n", notificationProfile.Data)

Returns: createdat (date-time), id (string), name (string), updatedat (date-time)

Get a notification profile

Get a notification profile.

GET /notification_profiles/{id}

	notificationProfile, err := client.NotificationProfiles.Get(context.Background(), "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e")
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("%+v\n", notificationProfile.Data)

Returns: createdat (date-time), id (string), name (string), updatedat (date-time)

Update a notification profile

Update a notification profile.

PATCH /notification_profiles/{id}

Optional: createdat (date-time), id (string), name (string), updatedat (date-time)

	notificationProfile, err := client.NotificationProfiles.Update(
		context.Background(),
		"182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",
		telnyx.NotificationProfileUpdateParams{
			NotificationProfile: telnyx.NotificationProfileParam{},
		},
	)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("%+v\n", notificationProfile.Data)

Returns: createdat (date-time), id (string), name (string), updatedat (date-time)

Delete a notification profile

Delete a notification profile.

DELETE /notification_profiles/{id}

	notificationProfile, err := client.NotificationProfiles.Delete(context.Background(), "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e")
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("%+v\n", notificationProfile.Data)

Returns: createdat (date-time), id (string), name (string), updatedat (date-time)

List notification settings

List notification settings.

GET /notification_settings

	page, err := client.NotificationSettings.List(context.Background(), telnyx.NotificationSettingListParams{})
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("%+v\n", page)

Returns: associatedrecordtype (string), associatedrecordtypevalue (string), createdat (date-time), id (string), notificationchannelid (string), notificationeventconditionid (string), notificationprofileid (string), parameters (array[object]), status (enum: enabled, enable-received, enable-pending, enable-submitted, delete-received, delete-pending, delete-submitted, deleted), updatedat (date-time)

Add a Notification Setting

Add a notification setting.

POST /notification_settings

Optional: associatedrecordtype (string), associatedrecordtypevalue (string), createdat (date-time), id (string), notificationchannelid (string), notificationeventconditionid (string), notificationprofileid (string), parameters (array[object]), status (enum: enabled, enable-received, enable-pending, enable-submitted, delete-received, delete-pending, delete-submitted, deleted), updatedat (date-time)

	notificationSetting, err := client.NotificationSettings.New(context.Background(), telnyx.NotificationSettingNewParams{})
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("%+v\n", notificationSetting.Data)

Returns: associatedrecordtype (string), associatedrecordtypevalue (string), createdat (date-time), id (string), notificationchannelid (string), notificationeventconditionid (string), notificationprofileid (string), parameters (array[object]), status (enum: enabled, enable-received, enable-pending, enable-submitted, delete-received, delete-pending, delete-submitted, deleted), updatedat (date-time)

Get a notification setting

Get a notification setting.

GET /notification_settings/{id}

	notificationSetting, err := client.NotificationSettings.Get(context.Background(), "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e")
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("%+v\n", notificationSetting.Data)

Returns: associatedrecordtype (string), associatedrecordtypevalue (string), createdat (date-time), id (string), notificationchannelid (string), notificationeventconditionid (string), notificationprofileid (string), parameters (array[object]), status (enum: enabled, enable-received, enable-pending, enable-submitted, delete-received, delete-pending, delete-submitted, deleted), updatedat (date-time)

Delete a notification setting

Delete a notification setting.

DELETE /notification_settings/{id}

	notificationSetting, err := client.NotificationSettings.Delete(context.Background(), "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e")
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("%+v\n", notificationSetting.Data)

Returns: associatedrecordtype (string), associatedrecordtypevalue (string), createdat (date-time), id (string), notificationchannelid (string), notificationeventconditionid (string), notificationprofileid (string), parameters (array[object]), status (enum: enabled, enable-received, enable-pending, enable-submitted, delete-received, delete-pending, delete-submitted, deleted), updatedat (date-time)