1 # = Configuration API Examples
3 # gem('twitter4r', '0.2.0')
6 # Here we setup configuration for all Twitter::Client instances
7 # This looks much like Rails' Initializer code that can be found
8 # in config/environment in Rails applications by design.
9 # Twitter::Client.configure do |conf|
10 # # We can set Twitter4R to use <tt>:ssl</tt> or <tt>:http</tt> to connect to the Twitter API.
11 # # Defaults to <tt>:ssl</tt>
12 # conf.protocol = :ssl
14 # # We can set Twitter4R to use another host name (perhaps for internal
15 # # testing purposes).
16 # # Defaults to 'twitter.com'
17 # conf.host = 'twitter.com'
19 # # We can set Twitter4R to use another port (also for internal
20 # # testing purposes).
24 # # We can set proxy information for Twitter4R
25 # # By default all following values are set to <tt>nil</tt>.
26 # conf.proxy_host = 'myproxy.host'
27 # conf.proxy_port = 8080
28 # conf.proxy_user = 'myuser'
29 # conf.proxy_pass = 'mypass'
31 # # We can also change the User-Agent and X-Twitter-Client* HTTP headers
32 # conf.user_agent = 'MyAppAgentName'
33 # conf.application_name = 'MyAppName'
34 # conf.application_version = 'v1.5.6'
35 # conf.application_url = 'http://myapp.url'
37 # # Twitter (not Twitter4R) will have to setup a source ID for your application to get it
38 # # recognized by the web interface according to your preferences.
39 # # To see more information how to go about doing this, please referen to the following thread:
40 # # http://groups.google.com/group/twitter4r-users/browse_thread/thread/c655457fdb127032
41 # conf.source = "your-source-id-that-twitter-recognizes"
43 # # OAuth settings for your application and the Twitter REST API URIs
44 # conf.oauth_consumer_token = "<YOUR APP'S CONSUMER TOKEN HERE>"
45 # conf.oauth_consumer_secret = "<YOUR APP'S CONSUMER SECRETE HERE>"
46 # # You shouldn't need to change the default URIs for the Twitter REST API unless Twitter changes them
47 # conf.oauth_request_token_path = "/oauth/request_token2"
48 # conf.oauth_access_token_path = "/oauth/access_token2"
49 # conf.oauth_authorize_path = "/oauth/authorize"