Class: PortaText::Command::Api::Me

Inherits:
Base
  • Object
show all
Defined in:
lib/portatext/command/api/me.rb

Overview

The me endpoint. github.com/PortaText/docs/wiki/REST-API#api_me

Author

Marcelo Gornstein ([email protected])

Copyright

Copyright © 2015 PortaText

License

Apache-2.0

Instance Attribute Summary

Attributes inherited from Base

#client

Instance Method Summary collapse

Methods inherited from Base

#accept_content_type, #body, #content_type, #delete, #get, #initialize, #patch, #post, #put, #set

Constructor Details

This class inherits a constructor from PortaText::Command::Base

Instance Method Details

#callback_url(callback_url) ⇒ Object



24
25
26
# File 'lib/portatext/command/api/me.rb', line 24

def callback_url(callback_url)
  set :callback_url, callback_url
end

#company(company) ⇒ Object



16
17
18
# File 'lib/portatext/command/api/me.rb', line 16

def company(company)
  set :company, company
end

#email(email) ⇒ Object



20
21
22
# File 'lib/portatext/command/api/me.rb', line 20

def email(email)
  set :email, email
end

#endpoint(_method) ⇒ Object



36
37
38
# File 'lib/portatext/command/api/me.rb', line 36

def endpoint(_method)
  'me'
end

#language(language) ⇒ Object



32
33
34
# File 'lib/portatext/command/api/me.rb', line 32

def language(language)
  set :language, language
end

#name(first, last) ⇒ Object



11
12
13
14
# File 'lib/portatext/command/api/me.rb', line 11

def name(first, last)
  set :first_name, first
  set :last_name, last
end

#timezone(timezone) ⇒ Object



28
29
30
# File 'lib/portatext/command/api/me.rb', line 28

def timezone(timezone)
  set :timezone, timezone
end