Class: Line::Bot::V2::Insight::GetNumberOfMessageDeliveriesResponse
- Inherits:
-
Object
- Object
- Line::Bot::V2::Insight::GetNumberOfMessageDeliveriesResponse
- Defined in:
- lib/line/bot/v2/insight/model/get_number_of_message_deliveries_response.rb
Overview
Get number of message deliveries
Instance Attribute Summary collapse
-
#api_broadcast ⇒ Integer?
Number of broadcast messages sent with the ‘Send broadcast message` Messaging API operation.
-
#api_multicast ⇒ Integer?
Number of multicast messages sent with the ‘Send multicast message` Messaging API operation.
-
#api_narrowcast ⇒ Integer?
Number of narrowcast messages sent with the ‘Send narrowcast message` Messaging API operation.
-
#api_push ⇒ Integer?
Number of push messages sent with the ‘Send push message` Messaging API operation.
-
#api_reply ⇒ Integer?
Number of replies sent with the ‘Send reply message` Messaging API operation.
-
#auto_response ⇒ Integer?
Number of auto-response messages sent.
-
#broadcast ⇒ Integer?
Number of messages sent to all of this LINE Official Account’s friends (broadcast messages).
-
#chat ⇒ Integer?
Number of messages sent from LINE Official Account Manager [Chat screen](www.linebiz.com/jp/manual/OfficialAccountManager/chats/) (only available in Japanese).
-
#status ⇒ String?
(‘ready’|‘unready’|‘out_of_service’) Status of the counting process.
-
#targeting ⇒ Integer?
Number of messages sent to some of this LINE Official Account’s friends, based on specific attributes (targeted messages).
-
#welcome_response ⇒ Integer?
Number of greeting messages sent.
Class Method Summary collapse
-
.create(args) ⇒ Line::Bot::V2::Insight::GetNumberOfMessageDeliveriesResponse
Create an instance of the class from a hash.
Instance Method Summary collapse
-
#==(other) ⇒ Boolean
True if the objects are equal, false otherwise.
-
#hash ⇒ Integer
Hash code of the object.
-
#initialize(status: nil, broadcast: nil, targeting: nil, auto_response: nil, welcome_response: nil, chat: nil, api_broadcast: nil, api_push: nil, api_multicast: nil, api_narrowcast: nil, api_reply: nil, **dynamic_attributes) ⇒ GetNumberOfMessageDeliveriesResponse
constructor
A new instance of GetNumberOfMessageDeliveriesResponse.
Constructor Details
#initialize(status: nil, broadcast: nil, targeting: nil, auto_response: nil, welcome_response: nil, chat: nil, api_broadcast: nil, api_push: nil, api_multicast: nil, api_narrowcast: nil, api_reply: nil, **dynamic_attributes) ⇒ GetNumberOfMessageDeliveriesResponse
Returns a new instance of GetNumberOfMessageDeliveriesResponse.
62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 |
# File 'lib/line/bot/v2/insight/model/get_number_of_message_deliveries_response.rb', line 62 def initialize( status: nil, broadcast: nil, targeting: nil, auto_response: nil, welcome_response: nil, chat: nil, api_broadcast: nil, api_push: nil, api_multicast: nil, api_narrowcast: nil, api_reply: nil, **dynamic_attributes ) @status = status @broadcast = broadcast @targeting = targeting @auto_response = auto_response @welcome_response = welcome_response @chat = chat @api_broadcast = api_broadcast @api_push = api_push @api_multicast = api_multicast @api_narrowcast = api_narrowcast @api_reply = api_reply dynamic_attributes.each do |key, value| self.class.attr_accessor key if value.is_a?(Hash) struct_klass = Struct.new(*value.keys.map(&:to_sym)) struct_values = value.map { |_k, v| v.is_a?(Hash) ? Line::Bot::V2::Utils.hash_to_struct(v) : v } instance_variable_set("@#{key}", struct_klass.new(*struct_values)) else instance_variable_set("@#{key}", value) end end end |
Instance Attribute Details
#api_broadcast ⇒ Integer?
Returns Number of broadcast messages sent with the ‘Send broadcast message` Messaging API operation.
37 38 39 |
# File 'lib/line/bot/v2/insight/model/get_number_of_message_deliveries_response.rb', line 37 def api_broadcast @api_broadcast end |
#api_multicast ⇒ Integer?
Returns Number of multicast messages sent with the ‘Send multicast message` Messaging API operation.
43 44 45 |
# File 'lib/line/bot/v2/insight/model/get_number_of_message_deliveries_response.rb', line 43 def api_multicast @api_multicast end |
#api_narrowcast ⇒ Integer?
Returns Number of narrowcast messages sent with the ‘Send narrowcast message` Messaging API operation.
46 47 48 |
# File 'lib/line/bot/v2/insight/model/get_number_of_message_deliveries_response.rb', line 46 def api_narrowcast @api_narrowcast end |
#api_push ⇒ Integer?
Returns Number of push messages sent with the ‘Send push message` Messaging API operation.
40 41 42 |
# File 'lib/line/bot/v2/insight/model/get_number_of_message_deliveries_response.rb', line 40 def api_push @api_push end |
#api_reply ⇒ Integer?
Returns Number of replies sent with the ‘Send reply message` Messaging API operation.
49 50 51 |
# File 'lib/line/bot/v2/insight/model/get_number_of_message_deliveries_response.rb', line 49 def api_reply @api_reply end |
#auto_response ⇒ Integer?
Returns Number of auto-response messages sent.
28 29 30 |
# File 'lib/line/bot/v2/insight/model/get_number_of_message_deliveries_response.rb', line 28 def auto_response @auto_response end |
#broadcast ⇒ Integer?
Returns Number of messages sent to all of this LINE Official Account’s friends (broadcast messages).
22 23 24 |
# File 'lib/line/bot/v2/insight/model/get_number_of_message_deliveries_response.rb', line 22 def broadcast @broadcast end |
#chat ⇒ Integer?
Returns Number of messages sent from LINE Official Account Manager [Chat screen](www.linebiz.com/jp/manual/OfficialAccountManager/chats/) (only available in Japanese).
34 35 36 |
# File 'lib/line/bot/v2/insight/model/get_number_of_message_deliveries_response.rb', line 34 def chat @chat end |
#status ⇒ String?
Returns (‘ready’|‘unready’|‘out_of_service’) Status of the counting process.
19 20 21 |
# File 'lib/line/bot/v2/insight/model/get_number_of_message_deliveries_response.rb', line 19 def status @status end |
#targeting ⇒ Integer?
Returns Number of messages sent to some of this LINE Official Account’s friends, based on specific attributes (targeted messages).
25 26 27 |
# File 'lib/line/bot/v2/insight/model/get_number_of_message_deliveries_response.rb', line 25 def targeting @targeting end |
#welcome_response ⇒ Integer?
Returns Number of greeting messages sent.
31 32 33 |
# File 'lib/line/bot/v2/insight/model/get_number_of_message_deliveries_response.rb', line 31 def welcome_response @welcome_response end |
Class Method Details
.create(args) ⇒ Line::Bot::V2::Insight::GetNumberOfMessageDeliveriesResponse
Create an instance of the class from a hash
105 106 107 108 |
# File 'lib/line/bot/v2/insight/model/get_number_of_message_deliveries_response.rb', line 105 def self.create(args) # steep:ignore symbolized_args = Line::Bot::V2::Utils.deep_symbolize(args) return new(**symbolized_args) # steep:ignore end |
Instance Method Details
#==(other) ⇒ Boolean
Returns true if the objects are equal, false otherwise.
112 113 114 115 116 117 118 |
# File 'lib/line/bot/v2/insight/model/get_number_of_message_deliveries_response.rb', line 112 def ==(other) return false unless self.class == other.class instance_variables.all? do |var| instance_variable_get(var) == other.instance_variable_get(var) end end |
#hash ⇒ Integer
Returns Hash code of the object.
121 122 123 |
# File 'lib/line/bot/v2/insight/model/get_number_of_message_deliveries_response.rb', line 121 def hash [self.class, *instance_variables.map { |var| instance_variable_get(var) }].hash end |