Class: Zavudev::Resources::Introspect

Inherits:
Object
  • Object
show all
Defined in:
lib/zavudev/resources/introspect.rb

Instance Method Summary collapse

Constructor Details

#initialize(client:) ⇒ Introspect

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

Parameters:



30
31
32
# File 'lib/zavudev/resources/introspect.rb', line 30

def initialize(client:)
  @client = client
end

Instance Method Details

#validate_phone(phone_number:, request_options: {}) ⇒ Zavudev::Models::IntrospectValidatePhoneResponse

Validate a phone number and check if a WhatsApp conversation window is open.

Parameters:

Returns:

See Also:



16
17
18
19
20
21
22
23
24
25
# File 'lib/zavudev/resources/introspect.rb', line 16

def validate_phone(params)
  parsed, options = Zavudev::IntrospectValidatePhoneParams.dump_request(params)
  @client.request(
    method: :post,
    path: "v1/introspect/phone",
    body: parsed,
    model: Zavudev::Models::IntrospectValidatePhoneResponse,
    options: options
  )
end