Method: ChatWork::Client::MessageMethods#find_message

Defined in:
lib/chatwork/client/message_methods.rb

#find_message(room_id:, message_id:) {|response_body, response_header| ... } ⇒ Hashie::Mash

Get information about the specified message

Examples:

response format

{
  "message_id": "5",
  "account": {
    "account_id": 123,
    "name": "Bob",
    "avatar_image_url": "https://example.com/ico_avatar.png"
  },
  "body": "Hello Chatwork!",
  "send_time": 1384242850,
  "update_time": 0
}

Parameters:

  • room_id (Integer)
  • message_id (String)

Yields:

  • (response_body, response_header)

    if block was given, return response body and response header through block arguments

Yield Parameters:

  • response_body (Hashie::Mash)

    response body

  • response_header (Hash<String, String>)

    response header (e.g. X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset)

Returns:

  • (Hashie::Mash)

See Also:



131
132
133
# File 'lib/chatwork/client/message_methods.rb', line 131

def find_message(room_id:, message_id:, &block)
  get("/rooms/#{room_id}/messages/#{message_id}", &block)
end