Class: Telnyx::Resources::AI::Integrations

Inherits:
Object
  • Object
show all
Defined in:
lib/telnyx/resources/ai/integrations.rb,
lib/telnyx/resources/ai/integrations/connections.rb

Defined Under Namespace

Classes: Connections

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(client:) ⇒ Integrations

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Returns a new instance of Integrations.

Parameters:



51
52
53
54
# File 'lib/telnyx/resources/ai/integrations.rb', line 51

def initialize(client:)
  @client = client
  @connections = Telnyx::Resources::AI::Integrations::Connections.new(client: client)
end

Instance Attribute Details

#connectionsTelnyx::Resources::AI::Integrations::Connections (readonly)



8
9
10
# File 'lib/telnyx/resources/ai/integrations.rb', line 8

def connections
  @connections
end

Instance Method Details

#list(request_options: {}) ⇒ Telnyx::Models::AI::IntegrationListResponse

List all available integrations.

Parameters:

Returns:

See Also:



39
40
41
42
43
44
45
46
# File 'lib/telnyx/resources/ai/integrations.rb', line 39

def list(params = {})
  @client.request(
    method: :get,
    path: "ai/integrations",
    model: Telnyx::Models::AI::IntegrationListResponse,
    options: params[:request_options]
  )
end

#retrieve(integration_id, request_options: {}) ⇒ Telnyx::Models::AI::IntegrationRetrieveResponse

Retrieve integration details

Parameters:

  • integration_id (String)

    The integration id

  • request_options (Telnyx::RequestOptions, Hash{Symbol=>Object}, nil)

Returns:

See Also:



21
22
23
24
25
26
27
28
# File 'lib/telnyx/resources/ai/integrations.rb', line 21

def retrieve(integration_id, params = {})
  @client.request(
    method: :get,
    path: ["ai/integrations/%1$s", integration_id],
    model: Telnyx::Models::AI::IntegrationRetrieveResponse,
    options: params[:request_options]
  )
end