Class: LunchMoney::Calls::Users

Inherits:
Base
  • Object
show all
Defined in:
lib/lunchmoney/calls/users.rb

Overview

Constant Summary

Constants inherited from Base

Base::BASE_URL

Instance Attribute Summary

Attributes inherited from Base

#api_key

Instance Method Summary collapse

Methods inherited from Base

#initialize

Constructor Details

This class inherits a constructor from LunchMoney::Calls::Base

Instance Method Details

#meObject



11
12
13
14
15
16
17
18
# File 'lib/lunchmoney/calls/users.rb', line 11

def me
  response = get("me")

  api_errors = errors(response)
  return api_errors if api_errors.present?

  LunchMoney::Objects::User.new(**response.body)
end