Class: OmniAuth::Strategies::TripIt

Inherits:
OAuth
  • Object
show all
Defined in:
lib/omniauth/strategies/oauth/trip_it.rb

Overview

Authenticate to TripIt via OAuth and retrieve an access token for API usage

Usage:

use OmniAuth::Strategies::TripIt, 'consumerkey', 'consumersecret'

Instance Attribute Summary

Attributes inherited from OAuth

#consumer_key, #consumer_options, #consumer_secret, #name

Instance Method Summary collapse

Methods inherited from OAuth

#auth_hash, #callback_phase, #consumer, #request_phase, #unique_id

Constructor Details

#initialize(app, consumer_key = nil, consumer_secret = nil, options = {}, &block) ⇒ TripIt

Returns a new instance of TripIt.



13
14
15
16
17
18
19
20
21
# File 'lib/omniauth/strategies/oauth/trip_it.rb', line 13

def initialize(app, consumer_key=nil, consumer_secret=nil, options={}, &block)
  client_options = {
    :access_token_path => '/oauth/access_token',
    :authorize_url => 'https://www.tripit.com/oauth/authorize',
    :request_token_path => '/oauth/request_token',
    :site => 'https://api.tripit.com',
  }
  super(app, :tripit, consumer_key, consumer_secret, client_options, options, &block)
end