Class: Zavudev::Models::ConversationListParams

Inherits:
Internal::Type::BaseModel show all
Extended by:
Internal::Type::RequestParameters::Converter
Includes:
Internal::Type::RequestParameters
Defined in:
lib/zavudev/models/conversation_list_params.rb,
sig/zavudev/models/conversation_list_params.rbs

Overview

See Also:

  • Zavudev::Resources::Conversations#list

Defined Under Namespace

Modules: Channel

Instance Attribute Summary collapse

Attributes included from Internal::Type::RequestParameters

#request_options

Instance Method Summary collapse

Methods included from Internal::Type::RequestParameters::Converter

dump_request

Methods included from Internal::Type::RequestParameters

included

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(channel: nil, cursor: nil, limit: nil, search: nil, sender_id: nil, request_options: {}) ⇒ Object

Some parameter documentations has been truncated, see Zavudev::Models::ConversationListParams for more details.

Parameters:

  • channel (Symbol, Zavudev::Models::ConversationListParams::Channel) (defaults to: nil) —

    Keep only threads that have carried this channel.

  • cursor (String) (defaults to: nil) —

    Opaque cursor from a previous response's nextCursor. Do not construct it.

  • limit (Integer) (defaults to: nil)
  • search (String) (defaults to: nil) —

    Search threads by identity: phone number (any format — +1 (555) 123-4567 and `

  • sender_id (String) (defaults to: nil) —

    Keep only threads last handled by this sender.

  • request_options (Zavudev::RequestOptions, Hash{Symbol=>Object}) (defaults to: {})


# File 'lib/zavudev/models/conversation_list_params.rb', line 51

Instance Attribute Details

#channel ⇒ Symbol, ...

Keep only threads that have carried this channel.



14
# File 'lib/zavudev/models/conversation_list_params.rb', line 14

optional :channel, enum: -> { Zavudev::ConversationListParams::Channel }

#cursor ⇒ String?

Opaque cursor from a previous response's nextCursor. Do not construct it.

Parameters:

  • (String)

Returns:

  • (String, nil)


20
# File 'lib/zavudev/models/conversation_list_params.rb', line 20

optional :cursor, String

#limit ⇒ Integer?

Parameters:

  • (Integer)

Returns:

  • (Integer, nil)


25
# File 'lib/zavudev/models/conversation_list_params.rb', line 25

optional :limit, Integer

#search ⇒ String?

Search threads by identity: phone number (any format — +1 (555) 123-4567 and 15551234567 both match), email address (full or local part), WhatsApp group subject, WhatsApp username, or BSUID. Matching is by whole word, with prefix matching on the last term, so mar finds [email protected] and +1555 finds +15551234567; a fragment from the middle or end of a number (4567) does not match.

It does not search message bodies — only who the thread is with.

Results come back ranked by relevance rather than by recency, so the usual "most recently active first" ordering does not apply while q is set. senderId and channel still narrow the results, and cursor paginates them as usual. An empty or whitespace-only q returns no items rather than the full list.

Parameters:

  • (String)

Returns:

  • (String, nil)


43
# File 'lib/zavudev/models/conversation_list_params.rb', line 43

optional :search, String

#sender_id ⇒ String?

Keep only threads last handled by this sender.

Parameters:

  • (String)

Returns:

  • (String, nil)


49
# File 'lib/zavudev/models/conversation_list_params.rb', line 49

optional :sender_id, String

Instance Method Details

#to_hash ⇒ {

Returns:

  • ({)


48
# File 'sig/zavudev/models/conversation_list_params.rbs', line 48

def to_hash: -> {