Module: Brio::API
- Included in:
- Client
- Defined in:
- lib/brio/api.rb
Constant Summary collapse
- CLIENT_ID =
'9JnCd6aS5VGNjd7p5Cx6EA7qd6Xz7eEs'
- DEFAULT_OAUTH_HOST =
'alpha.app.net'
- DEFAULT_API_HOST =
'alpha-api.app.net'
- DEFAULT_PROTOCOL =
'https'
- REDIRECT_URI =
'https://brioapp.herokuapp.com/auth/callback/'
- SCOPE =
'stream,email,write_post,follow,messages,update_profile,export'
- RESPONSE_TYPE =
'token'
Instance Method Summary collapse
Instance Method Details
#oauth_url ⇒ Object
17 18 19 |
# File 'lib/brio/api.rb', line 17 def oauth_url "#{protocol}://#{oauth_host}/oauth/authenticate?client_id=#{CLIENT_ID}&response_type=#{RESPONSE_TYPE}&scope=#{SCOPE}&redirect_uri=#{REDIRECT_URI}" end |
#posts_url(id = "") ⇒ Object
POSTS
22 23 24 25 |
# File 'lib/brio/api.rb', line 22 def posts_url(id ="") id = "/#{id}" unless id.empty? "/stream/0/posts#{id}" end |
#users_url(id = "me") ⇒ Object
USERS
28 29 30 |
# File 'lib/brio/api.rb', line 28 def users_url( id = "me") "/stream/0/users/#{id}" end |