Class: Telnyx::Models::AI::WebhookTool::Webhook

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/telnyx/models/ai/webhook_tool.rb

Overview

See Also:

Defined Under Namespace

Modules: Method Classes: BodyParameters, Header, PathParameters, QueryParameters

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(name: nil, value: nil) ⇒ Object

Some parameter documentations has been truncated, see Header for more details.

Parameters:

  • name (String) (defaults to: nil)
  • value (String) (defaults to: nil)

    The value of the header. Note that we support mustache templating for the value.



# File 'lib/telnyx/models/ai/webhook_tool.rb', line 95

Instance Attribute Details

#body_parametersTelnyx::Models::AI::WebhookTool::Webhook::BodyParameters?

The body parameters the webhook tool accepts, described as a JSON Schema object. These parameters will be passed to the webhook as the body of the request. See the [JSON Schema reference](json-schema.org/understanding-json-schema) for documentation about the format



61
# File 'lib/telnyx/models/ai/webhook_tool.rb', line 61

optional :body_parameters, -> { Telnyx::AI::WebhookTool::Webhook::BodyParameters }

#descriptionString

The description of the tool.

Returns:

  • (String)


37
# File 'lib/telnyx/models/ai/webhook_tool.rb', line 37

required :description, String

#headersArray<Telnyx::Models::AI::WebhookTool::Webhook::Header>?

The headers to be sent to the external tool.



67
# File 'lib/telnyx/models/ai/webhook_tool.rb', line 67

optional :headers, -> { Telnyx::Internal::Type::ArrayOf[Telnyx::AI::WebhookTool::Webhook::Header] }

#http_methodSymbol, ...

The HTTP method to be used when calling the external tool.



73
# File 'lib/telnyx/models/ai/webhook_tool.rb', line 73

optional :http_method, enum: -> { Telnyx::AI::WebhookTool::Webhook::Method }, api_name: :method

#nameString

The name of the tool.

Returns:

  • (String)


43
# File 'lib/telnyx/models/ai/webhook_tool.rb', line 43

required :name, String

#path_parametersTelnyx::Models::AI::WebhookTool::Webhook::PathParameters?

The path parameters the webhook tool accepts, described as a JSON Schema object. These parameters will be passed to the webhook as the path of the request if the URL contains a placeholder for a value. See the [JSON Schema reference](json-schema.org/understanding-json-schema) for documentation about the format



83
# File 'lib/telnyx/models/ai/webhook_tool.rb', line 83

optional :path_parameters, -> { Telnyx::AI::WebhookTool::Webhook::PathParameters }

#query_parametersTelnyx::Models::AI::WebhookTool::Webhook::QueryParameters?

The query parameters the webhook tool accepts, described as a JSON Schema object. These parameters will be passed to the webhook as the query of the request. See the [JSON Schema reference](json-schema.org/understanding-json-schema) for documentation about the format



93
# File 'lib/telnyx/models/ai/webhook_tool.rb', line 93

optional :query_parameters, -> { Telnyx::AI::WebhookTool::Webhook::QueryParameters }

#urlString

The URL of the external tool to be called. This URL is going to be used by the assistant. The URL can be templated like: ‘example.com/api/v1/id`, where `id` is a placeholder for a value that will be provided by the assistant if `path_parameters` are provided with the `id` attribute.

Returns:

  • (String)


52
# File 'lib/telnyx/models/ai/webhook_tool.rb', line 52

required :url, String

Class Method Details

.valuesArray<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/telnyx/models/ai/webhook_tool.rb', line 152