Class: ApiConnectClient::User
- Defined in:
- lib/api_connect_client/user.rb
Instance Method Summary collapse
- #get_info ⇒ Object
-
#initialize(username, password) ⇒ User
constructor
A new instance of User.
- #list_organizations ⇒ Object
Constructor Details
#initialize(username, password) ⇒ User
Returns a new instance of User.
3 4 5 6 7 8 9 10 |
# File 'lib/api_connect_client/user.rb', line 3 def initialize(username, password) super() @headers = { 'X-IBM-APIManagement-Context': ApiConnectClient::Config.context } @username = username @password = password end |
Instance Method Details
#get_info ⇒ Object
12 13 14 |
# File 'lib/api_connect_client/user.rb', line 12 def get_info get("/me", @username, @password) end |
#list_organizations ⇒ Object
16 17 18 |
# File 'lib/api_connect_client/user.rb', line 16 def list_organizations get("/orgs", @username, @password) end |