Skip to content

Commit

Permalink
Remove deprecated CreateSIPTrunk from SIP client (#543)
Browse files Browse the repository at this point in the history
  • Loading branch information
biglittlebigben authored Oct 14, 2024
1 parent 76007e6 commit b6c53e2
Showing 1 changed file with 0 additions and 15 deletions.
15 changes: 0 additions & 15 deletions sipclient.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,21 +42,6 @@ func NewSIPClient(url string, apiKey string, secretKey string, opts ...twirp.Cli
}
}

// CreateSIPTrunk creates a new SIP Trunk.
//
// Deprecated: Use CreateSIPInboundTrunk or CreateSIPOutboundTrunk
func (s *SIPClient) CreateSIPTrunk(ctx context.Context, in *livekit.CreateSIPTrunkRequest) (*livekit.SIPTrunkInfo, error) {
if in == nil {
return nil, ErrInvalidParameter
}

ctx, err := s.withAuth(ctx, withSIPGrant{Admin: true})
if err != nil {
return nil, err
}
return s.sipClient.CreateSIPTrunk(ctx, in)
}

// CreateSIPInboundTrunk creates a new SIP Trunk for accepting inbound calls to LiveKit.
func (s *SIPClient) CreateSIPInboundTrunk(ctx context.Context, in *livekit.CreateSIPInboundTrunkRequest) (*livekit.SIPInboundTrunkInfo, error) {
if in == nil || in.Trunk == nil || in.Trunk.SipTrunkId != "" {
Expand Down

0 comments on commit b6c53e2

Please sign in to comment.