Class: GetStream::Generated::Models::SendMessageResponse
- Defined in:
- lib/getstream_ruby/generated/models/send_message_response.rb
Instance Attribute Summary collapse
-
#channel_context ⇒ ChannelContextResponse
Slim channel object: identity plus creator.
-
#duration ⇒ String
Duration of the request in milliseconds.
-
#mentioned_members ⇒ Hash<String, Boolean>
Map of mentioned user ID to whether that user is currently an active channel member.
-
#message ⇒ MessageResponse
Represents any chat message.
-
#pending_message_metadata ⇒ Hash<String, String>
Pending message metadata.
-
#scheduled_message ⇒ ScheduledMessageResponse
A message scheduled to be sent later.
Class Method Summary collapse
-
.json_field_mappings ⇒ Object
Override field mappings for JSON serialization.
Instance Method Summary collapse
-
#initialize(attributes = {}) ⇒ SendMessageResponse
constructor
Initialize with attributes.
Methods inherited from BaseModel
#==, #inspect, omit_empty_fields, #to_h, #to_json
Constructor Details
#initialize(attributes = {}) ⇒ SendMessageResponse
Initialize with attributes
32 33 34 35 36 37 38 39 40 |
# File 'lib/getstream_ruby/generated/models/send_message_response.rb', line 32 def initialize(attributes = {}) super(attributes) @duration = attributes.fetch(:duration) { attributes.fetch('duration', nil) } = attributes.fetch(:message) { attributes.fetch('message', nil) } @channel_context = attributes.fetch(:channel_context) { attributes.fetch('channel_context', nil) } @mentioned_members = attributes.fetch(:mentioned_members) { attributes.fetch('mentioned_members', nil) } = attributes.fetch(:pending_message_metadata) { attributes.fetch('pending_message_metadata', nil) } = attributes.fetch(:scheduled_message) { attributes.fetch('scheduled_message', nil) } end |
Instance Attribute Details
#channel_context ⇒ ChannelContextResponse
Returns Slim channel object: identity plus creator.
20 21 22 |
# File 'lib/getstream_ruby/generated/models/send_message_response.rb', line 20 def channel_context @channel_context end |
#duration ⇒ String
Returns Duration of the request in milliseconds.
14 15 16 |
# File 'lib/getstream_ruby/generated/models/send_message_response.rb', line 14 def duration @duration end |
#mentioned_members ⇒ Hash<String, Boolean>
Returns Map of mentioned user ID to whether that user is currently an active channel member. Only set when include_mentioned_members was requested; omitted when the message has no mentions or the membership lookup failed.
23 24 25 |
# File 'lib/getstream_ruby/generated/models/send_message_response.rb', line 23 def mentioned_members @mentioned_members end |
#message ⇒ MessageResponse
Returns Represents any chat message.
17 18 19 |
# File 'lib/getstream_ruby/generated/models/send_message_response.rb', line 17 def end |
#pending_message_metadata ⇒ Hash<String, String>
Returns Pending message metadata.
26 27 28 |
# File 'lib/getstream_ruby/generated/models/send_message_response.rb', line 26 def end |
#scheduled_message ⇒ ScheduledMessageResponse
Returns A message scheduled to be sent later.
29 30 31 |
# File 'lib/getstream_ruby/generated/models/send_message_response.rb', line 29 def end |
Class Method Details
.json_field_mappings ⇒ Object
Override field mappings for JSON serialization
43 44 45 46 47 48 49 50 51 52 |
# File 'lib/getstream_ruby/generated/models/send_message_response.rb', line 43 def self.json_field_mappings { duration: 'duration', message: 'message', channel_context: 'channel_context', mentioned_members: 'mentioned_members', pending_message_metadata: 'pending_message_metadata', scheduled_message: 'scheduled_message' } end |