Sha256: 9bb15ab14bbe353cc681b1ce8e892049120da4d0bbce94b1c05fffbf3461094a

Contents?: true

Size: 1.44 KB

Versions: 10

Compression:

Stored size: 1.44 KB

Contents

module ChatWork
  module Me
    # Get your account information
    #
    # @see http://developer.chatwork.com/ja/endpoint_me.html#GET-me
    # @see http://download.chatwork.com/ChatWork_API_Documentation.pdf
    #
    # @yield [response_body, response_header] if block was given, return response body and response header through block arguments
    # @yieldparam response_body [Hashie::Mash] response body
    # @yieldparam response_header [Hash<String, String>] response header (e.g. X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset)
    #
    # @return [Hashie::Mash]
    #
    # @example response format
    #   {
    #     "account_id": 123,
    #     "room_id": 322,
    #     "name": "John Smith",
    #     "chatwork_id": "tarochatworkid",
    #     "organization_id": 101,
    #     "organization_name": "Hello Company",
    #     "department": "Marketing",
    #     "title": "CMO",
    #     "url": "http://mycompany.example.com",
    #     "introduction": "Self Introduction",
    #     "mail": "taro@example.com",
    #     "tel_organization": "XXX-XXXX-XXXX",
    #     "tel_extension": "YYY-YYYY-YYYY",
    #     "tel_mobile": "ZZZ-ZZZZ-ZZZZ",
    #     "skype": "myskype_id",
    #     "facebook": "myfacebook_id",
    #     "twitter": "mytwitter_id",
    #     "avatar_image_url": "https://example.com/abc.png",
    #     "login_mail": "account@example.com"
    #   }
    def self.get(&block)
      ChatWork.client.get_me(&block)
    end
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
chatwork-1.0.1 lib/chatwork/me.rb
chatwork-1.0.0 lib/chatwork/me.rb
chatwork-0.12.3 lib/chatwork/me.rb
chatwork-0.12.2 lib/chatwork/me.rb
chatwork-0.12.1 lib/chatwork/me.rb
chatwork-0.12.0 lib/chatwork/me.rb
chatwork-0.11.0 lib/chatwork/me.rb
chatwork-0.10.0 lib/chatwork/me.rb
chatwork-0.9.0 lib/chatwork/me.rb
chatwork-0.8.0 lib/chatwork/me.rb