socialyzer 0.0.7 → 0.0.8
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/socialyzer/engine.rb +3 -1
- data/lib/socialyzer/version.rb +1 -1
- data/lib/socialyzer.rb +7 -2
- metadata +3 -3
data/lib/socialyzer/engine.rb
CHANGED
@@ -7,7 +7,9 @@ module Socialyzer
|
|
7
7
|
initializer "setup" do |app|
|
8
8
|
config_file = File.join(app.root,"config","socialyzer.yml")
|
9
9
|
if File.exist?(config_file)
|
10
|
-
|
10
|
+
config = YAML.load_file(config_file)
|
11
|
+
Socialyzer::API_KEY = config["api_key"] if config["api_key"]
|
12
|
+
Socialyzer::BASE_URL = config["api_url"] || "http://api.socialyzerhq.com"
|
11
13
|
end
|
12
14
|
end
|
13
15
|
|
data/lib/socialyzer/version.rb
CHANGED
data/lib/socialyzer.rb
CHANGED
@@ -37,6 +37,12 @@ module Socialyzer
|
|
37
37
|
api_request(:bitly_links, :user => screen_name)
|
38
38
|
end
|
39
39
|
|
40
|
+
# Not really supported yet
|
41
|
+
#
|
42
|
+
def self.bulk_add_twitter_account(options={})
|
43
|
+
api_request(:bulk_add_twitter_account, options)
|
44
|
+
end
|
45
|
+
|
40
46
|
def self.api_request(action, options={})
|
41
47
|
env = options.delete(:env) || :production
|
42
48
|
options.merge!(:key => API_KEY)
|
@@ -45,8 +51,7 @@ module Socialyzer
|
|
45
51
|
end
|
46
52
|
|
47
53
|
def self.api_action(action, env=:production)
|
48
|
-
|
49
|
-
"http://#{subdomain}.socialyzerhq.com/api/#{action}.json"
|
54
|
+
"#{Socialyzer::BASE_URL}/#{action}.json"
|
50
55
|
end
|
51
56
|
|
52
57
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: socialyzer
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.8
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2012-12-30 00:00:00.
|
12
|
+
date: 2012-12-30 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rest-client
|
@@ -72,7 +72,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
72
72
|
version: '0'
|
73
73
|
requirements: []
|
74
74
|
rubyforge_project:
|
75
|
-
rubygems_version: 1.8.
|
75
|
+
rubygems_version: 1.8.23
|
76
76
|
signing_key:
|
77
77
|
specification_version: 3
|
78
78
|
summary: A ruby library for dealing with the Socialyzer API
|