Class: DocusignDtr::Profile

Inherits:
Object
  • Object
show all
Defined in:
lib/docusign_dtr/profile.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(client:) ⇒ Profile

Returns a new instance of Profile.



5
6
7
# File 'lib/docusign_dtr/profile.rb', line 5

def initialize(client:)
  @client = client
end

Instance Attribute Details

#clientObject

Returns the value of attribute client.



3
4
5
# File 'lib/docusign_dtr/profile.rb', line 3

def client
  @client
end

Instance Method Details

#find(user_id) ⇒ Object



9
10
11
12
13
14
# File 'lib/docusign_dtr/profile.rb', line 9

def find(user_id)
  profile_attrs = @client.get("/users/#{user_id}/profile")
  profile = DocusignDtr::Models::Profile.new(profile_attrs)
  profile.client = client
  profile
end