zuck 0.1.0 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (36) hide show
  1. data/CHANGELOG.markdown +4 -0
  2. data/README.markdown +35 -0
  3. data/VERSION +1 -1
  4. data/lib/zuck/facebook/ad_account.rb +8 -5
  5. data/lib/zuck/facebook/ad_campaign.rb +0 -1
  6. data/lib/zuck/facebook/ad_creative.rb +11 -10
  7. data/lib/zuck/facebook/ad_group.rb +5 -7
  8. data/lib/zuck/fb_object/hash_delegator.rb +5 -1
  9. data/lib/zuck/fb_object/helpers.rb +1 -1
  10. data/lib/zuck/fb_object/read.rb +0 -35
  11. data/spec/fixtures/a_single_account.yml +32 -57
  12. data/spec/fixtures/a_single_campaign.yml +12 -12
  13. data/spec/fixtures/a_single_group.yml +48 -0
  14. data/spec/fixtures/ad_keyword_search_disney.yml +12 -12
  15. data/spec/fixtures/{ad_keyword_search_steve_carell.yml → ad_keyword_search_moviepilot.yml} +8 -9
  16. data/spec/fixtures/ad_keyword_search_nonexistant.yml +5 -5
  17. data/spec/fixtures/create_ad_campaign.yml +12 -15
  18. data/spec/fixtures/create_ad_group.yml +15 -14
  19. data/spec/fixtures/delete_ad_group.yml +11 -15
  20. data/spec/fixtures/find_a_single_group_and_update_it.yml +224 -0
  21. data/spec/fixtures/list_of_ad_accounts.yml +26 -23
  22. data/spec/fixtures/list_of_ad_campaigns.yml +23 -24
  23. data/spec/fixtures/list_of_ad_creatives.yml +13 -15
  24. data/spec/fixtures/list_of_ad_groups.yml +62 -31
  25. data/spec/fixtures/list_of_all_ad_creatives_of_account.yml +41 -34
  26. data/spec/fixtures/reach_for_invalid_keyword.yml +9 -56
  27. data/spec/fixtures/reach_for_valid_keywords.yml +11 -56
  28. data/spec/fixtures/reach_for_valid_keywords_male_young.yml +11 -56
  29. data/spec/lib/zuck/facebook/ad_keyword_spec.rb +3 -3
  30. data/spec/lib/zuck/facebook/targeting_spec_spec.rb +4 -4
  31. data/spec/lib/zuck/fb_object/helpers_spec.rb +3 -2
  32. data/spec/lib/zuck_spec.rb +17 -24
  33. data/spec/spec_helper.rb +3 -0
  34. data/zuck.gemspec +5 -4
  35. metadata +6 -5
  36. data/spec/fixtures/find_a_single_campaign_and_update_it.yml +0 -247
@@ -43,5 +43,8 @@ def expect_id_and_return(id, ret_val)
43
43
  lambda { |id| id.to_s.should == id.to_s; ret_val }
44
44
  end
45
45
 
46
+ def test_access_token
47
+ 'CAAEvJ5vzhl8BAH8aCPOx0Ft9uNB147TF8weJ8hK0g7YVDRWU4eEih7tEKdJgmfk0vABZClZACJbEzyhSMbiShL6RpsfkZASfX1C9nv1AlFvjJajflqkyYZAlpE2edT0FJHjdh4NFg0ZCt0sBgq0kZABtKsjuU18aMURLE7rjKHR4X8NkXBUafg1T4uZARRNqboZD'
48
+ end
46
49
 
47
50
  require File.expand_path("../../lib/zuck", __FILE__)
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = "zuck"
8
- s.version = "0.1.0"
8
+ s.version = "0.2.0"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Jannis Hermanns"]
12
- s.date = "2013-07-19"
12
+ s.date = "2013-09-13"
13
13
  s.description = "This gem allows to easily access facebook's ads api in ruby. See https://developers.facebook.com/docs/reference/ads-api/"
14
14
  s.email = "jannis@gmail.com"
15
15
  s.extra_rdoc_files = [
@@ -48,13 +48,14 @@ Gem::Specification.new do |s|
48
48
  "lib/zuck/koala/koala_methods.rb",
49
49
  "spec/fixtures/a_single_account.yml",
50
50
  "spec/fixtures/a_single_campaign.yml",
51
+ "spec/fixtures/a_single_group.yml",
51
52
  "spec/fixtures/ad_keyword_search_disney.yml",
53
+ "spec/fixtures/ad_keyword_search_moviepilot.yml",
52
54
  "spec/fixtures/ad_keyword_search_nonexistant.yml",
53
- "spec/fixtures/ad_keyword_search_steve_carell.yml",
54
55
  "spec/fixtures/create_ad_campaign.yml",
55
56
  "spec/fixtures/create_ad_group.yml",
56
57
  "spec/fixtures/delete_ad_group.yml",
57
- "spec/fixtures/find_a_single_campaign_and_update_it.yml",
58
+ "spec/fixtures/find_a_single_group_and_update_it.yml",
58
59
  "spec/fixtures/list_of_ad_accounts.yml",
59
60
  "spec/fixtures/list_of_ad_campaigns.yml",
60
61
  "spec/fixtures/list_of_ad_creatives.yml",
metadata CHANGED
@@ -2,14 +2,14 @@
2
2
  name: zuck
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.1.0
5
+ version: 0.2.0
6
6
  platform: ruby
7
7
  authors:
8
8
  - Jannis Hermanns
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-07-19 00:00:00.000000000 Z
12
+ date: 2013-09-13 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rvm
@@ -338,13 +338,14 @@ files:
338
338
  - lib/zuck/koala/koala_methods.rb
339
339
  - spec/fixtures/a_single_account.yml
340
340
  - spec/fixtures/a_single_campaign.yml
341
+ - spec/fixtures/a_single_group.yml
341
342
  - spec/fixtures/ad_keyword_search_disney.yml
343
+ - spec/fixtures/ad_keyword_search_moviepilot.yml
342
344
  - spec/fixtures/ad_keyword_search_nonexistant.yml
343
- - spec/fixtures/ad_keyword_search_steve_carell.yml
344
345
  - spec/fixtures/create_ad_campaign.yml
345
346
  - spec/fixtures/create_ad_group.yml
346
347
  - spec/fixtures/delete_ad_group.yml
347
- - spec/fixtures/find_a_single_campaign_and_update_it.yml
348
+ - spec/fixtures/find_a_single_group_and_update_it.yml
348
349
  - spec/fixtures/list_of_ad_accounts.yml
349
350
  - spec/fixtures/list_of_ad_campaigns.yml
350
351
  - spec/fixtures/list_of_ad_creatives.yml
@@ -377,7 +378,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
377
378
  - !ruby/object:Gem::Version
378
379
  segments:
379
380
  - 0
380
- hash: 1542161049211835241
381
+ hash: 2263188203156526454
381
382
  version: '0'
382
383
  none: false
383
384
  required_rubygems_version: !ruby/object:Gem::Requirement
@@ -1,247 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: get
5
- uri: https://graph.facebook.com/6005859287551?access_token=AAAEvJ5vzhl8BABhTSazJZB2D0B4N0l242VX22Hg9J2WZA7fptcAztfXxfAZB9mhZB6W1nl5dz5tXMlb9DJk9ibs6RqtP7PtO6a3XCiHWVwZDZD
6
- body:
7
- encoding: US-ASCII
8
- string: ''
9
- headers:
10
- Accept-Encoding:
11
- - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
12
- Accept:
13
- - ! '*/*'
14
- User-Agent:
15
- - Ruby
16
- response:
17
- status:
18
- code: 200
19
- message: OK
20
- headers:
21
- Access-Control-Allow-Origin:
22
- - ! '*'
23
- Cache-Control:
24
- - private, no-cache, no-store, must-revalidate
25
- Content-Type:
26
- - text/javascript; charset=UTF-8
27
- Etag:
28
- - ! '"b7741a9194bcc0d32abecf0bc48c03ac9bad136a"'
29
- Expires:
30
- - Sat, 01 Jan 2000 00:00:00 GMT
31
- Pragma:
32
- - no-cache
33
- X-Fb-Rev:
34
- - '612565'
35
- X-Fb-Debug:
36
- - O+UUy1fJDylkydwqIDHF56Yp3PS77xj3eExqEBxiQ9M=
37
- Date:
38
- - Tue, 21 Aug 2012 14:20:27 GMT
39
- Connection:
40
- - keep-alive
41
- Content-Length:
42
- - '786'
43
- body:
44
- encoding: US-ASCII
45
- string: ! '{"adgroup_id":6005859287551,"ad_id":6005859287551,"campaign_id":6005851032951,"name":"My
46
- new name","adgroup_status":3,"bid_type":1,"max_bid":"1","bid_info":{"1":"1"},"ad_status":3,"locations":[3],"impression_control_map":[{"location":3,"control":{"impression_control_type":2,"user_impression_limit":6,"user_impression_limit_period":24,"user_impression_limit_period_unit":0}}],"account_id":"10150585630710217","id":"6005859287551","creative_ids":[6005851371551],"targeting":{"countries":["US"],"friends_of_connections":[{"id":"6005851366351","name":null}]},"conversion_specs":[{"action.type":"like","post":"10150420410887685"}],"last_updated_by_app_id":333322143368799,"start_time":null,"end_time":null,"updated_time":"2012-08-21T14:17:51+0000","created_time":"2012-08-03T08:03:57+0000"}'
47
- http_version:
48
- recorded_at: Tue, 21 Aug 2012 14:20:28 GMT
49
- - request:
50
- method: post
51
- uri: https://graph.facebook.com/6005859287551
52
- body:
53
- encoding: US-ASCII
54
- string: ! "-------------RubyMultipartPost\r\nContent-Disposition: form-data;
55
- name=\"adgroup_id\"\r\n\r\n6005859287551\r\n-------------RubyMultipartPost\r\nContent-Disposition:
56
- form-data; name=\"ad_id\"\r\n\r\n6005859287551\r\n-------------RubyMultipartPost\r\nContent-Disposition:
57
- form-data; name=\"campaign_id\"\r\n\r\n6005851032951\r\n-------------RubyMultipartPost\r\nContent-Disposition:
58
- form-data; name=\"name\"\r\n\r\nMy old name\r\n-------------RubyMultipartPost\r\nContent-Disposition:
59
- form-data; name=\"adgroup_status\"\r\n\r\n3\r\n-------------RubyMultipartPost\r\nContent-Disposition:
60
- form-data; name=\"bid_type\"\r\n\r\n1\r\n-------------RubyMultipartPost\r\nContent-Disposition:
61
- form-data; name=\"max_bid\"\r\n\r\n1\r\n-------------RubyMultipartPost\r\nContent-Disposition:
62
- form-data; name=\"bid_info%5B1%5D\"\r\n\r\n1\r\n-------------RubyMultipartPost\r\nContent-Disposition:
63
- form-data; name=\"ad_status\"\r\n\r\n3\r\n-------------RubyMultipartPost\r\nContent-Disposition:
64
- form-data; name=\"locations%5B%5D\"\r\n\r\n3\r\n-------------RubyMultipartPost\r\nContent-Disposition:
65
- form-data; name=\"impression_control_map%5B%5D%5Blocation%5D\"\r\n\r\n3\r\n-------------RubyMultipartPost\r\nContent-Disposition:
66
- form-data; name=\"impression_control_map%5B%5D%5Bcontrol%5D%5Bimpression_control_type%5D\"\r\n\r\n2\r\n-------------RubyMultipartPost\r\nContent-Disposition:
67
- form-data; name=\"impression_control_map%5B%5D%5Bcontrol%5D%5Buser_impression_limit%5D\"\r\n\r\n6\r\n-------------RubyMultipartPost\r\nContent-Disposition:
68
- form-data; name=\"impression_control_map%5B%5D%5Bcontrol%5D%5Buser_impression_limit_period%5D\"\r\n\r\n24\r\n-------------RubyMultipartPost\r\nContent-Disposition:
69
- form-data; name=\"impression_control_map%5B%5D%5Bcontrol%5D%5Buser_impression_limit_period_unit%5D\"\r\n\r\n0\r\n-------------RubyMultipartPost\r\nContent-Disposition:
70
- form-data; name=\"account_id\"\r\n\r\n10150585630710217\r\n-------------RubyMultipartPost\r\nContent-Disposition:
71
- form-data; name=\"creative_ids%5B%5D\"\r\n\r\n6005851371551\r\n-------------RubyMultipartPost\r\nContent-Disposition:
72
- form-data; name=\"targeting%5Bcountries%5D%5B%5D\"\r\n\r\nUS\r\n-------------RubyMultipartPost\r\nContent-Disposition:
73
- form-data; name=\"targeting%5Bfriends_of_connections%5D%5B%5D%5Bid%5D\"\r\n\r\n6005851366351\r\n-------------RubyMultipartPost\r\nContent-Disposition:
74
- form-data; name=\"targeting%5Bfriends_of_connections%5D%5B%5D%5Bname%5D\"\r\n\r\n\r\n-------------RubyMultipartPost\r\nContent-Disposition:
75
- form-data; name=\"conversion_specs%5B%5D%5Baction.type%5D\"\r\n\r\nlike\r\n-------------RubyMultipartPost\r\nContent-Disposition:
76
- form-data; name=\"conversion_specs%5B%5D%5Bpost%5D\"\r\n\r\n10150420410887685\r\n-------------RubyMultipartPost\r\nContent-Disposition:
77
- form-data; name=\"last_updated_by_app_id\"\r\n\r\n333322143368799\r\n-------------RubyMultipartPost\r\nContent-Disposition:
78
- form-data; name=\"start_time\"\r\n\r\n\r\n-------------RubyMultipartPost\r\nContent-Disposition:
79
- form-data; name=\"end_time\"\r\n\r\n\r\n-------------RubyMultipartPost\r\nContent-Disposition:
80
- form-data; name=\"updated_time\"\r\n\r\n2012-08-21T14:17:51+0000\r\n-------------RubyMultipartPost\r\nContent-Disposition:
81
- form-data; name=\"created_time\"\r\n\r\n2012-08-03T08:03:57+0000\r\n-------------RubyMultipartPost\r\nContent-Disposition:
82
- form-data; name=\"redownload\"\r\n\r\n1\r\n-------------RubyMultipartPost\r\nContent-Disposition:
83
- form-data; name=\"access_token\"\r\n\r\nAAAEvJ5vzhl8BABhTSazJZB2D0B4N0l242VX22Hg9J2WZA7fptcAztfXxfAZB9mhZB6W1nl5dz5tXMlb9DJk9ibs6RqtP7PtO6a3XCiHWVwZDZD\r\n-------------RubyMultipartPost--\r\n\r\n"
84
- headers:
85
- Content-Type:
86
- - multipart/form-data;boundary=-----------RubyMultipartPost
87
- Content-Length:
88
- - '3324'
89
- Accept:
90
- - ! '*/*'
91
- User-Agent:
92
- - Ruby
93
- response:
94
- status:
95
- code: 200
96
- message: OK
97
- headers:
98
- Access-Control-Allow-Origin:
99
- - ! '*'
100
- Cache-Control:
101
- - private, no-cache, no-store, must-revalidate
102
- Content-Type:
103
- - text/javascript; charset=UTF-8
104
- Expires:
105
- - Sat, 01 Jan 2000 00:00:00 GMT
106
- Pragma:
107
- - no-cache
108
- X-Fb-Rev:
109
- - '612565'
110
- X-Fb-Debug:
111
- - 0ksL16mYUlHtzQAmoW2c+LNaOu4aKdx+5xVfkdS51mk=
112
- Date:
113
- - Tue, 21 Aug 2012 14:20:29 GMT
114
- Connection:
115
- - keep-alive
116
- Content-Length:
117
- - '1188'
118
- body:
119
- encoding: US-ASCII
120
- string: ! '{"result":true,"data":{"adgroups":{"6005859287551":{"adgroup_id":6005859287551,"ad_id":6005859287551,"campaign_id":6005851032951,"name":"My
121
- old name","adgroup_status":3,"bid_type":1,"max_bid":"1","bid_info":{"1":"1"},"ad_status":3,"locations":[3],"impression_control_map":[{"location":3,"control":{"impression_control_type":2,"user_impression_limit":6,"user_impression_limit_period":24,"user_impression_limit_period_unit":0}}],"account_id":"10150585630710217","id":"6005859287551","creative_ids":[6005851371551],"targeting":{"countries":["US"],"friends_of_connections":[{"id":"6005851366351","name":null}]},"conversion_specs":[{"action.type":"like","post":"10150420410887685"}],"last_updated_by_app_id":333322143368799,"start_time":null,"end_time":null,"updated_time":1345558829,"created_time":1343981037}},"creatives":{"6005851371551":{"type":25,"action_spec":{"action.type":"like","post":"10150420410887685"},"related_fan_page":1,"cluster_id":6005851366351,"name":"Sponsored
122
- story #6005851371551","run_status":1,"preview_url":"http:\/\/www.facebook.com\/ads\/api\/creative_preview.php?cid=6005851371551","count_current_adgroups":11,"id":"6005851371551","creative_id":"6005851371551"}}}}'
123
- http_version:
124
- recorded_at: Tue, 21 Aug 2012 14:20:30 GMT
125
- - request:
126
- method: post
127
- uri: https://graph.facebook.com/6005859287551
128
- body:
129
- encoding: US-ASCII
130
- string: ! "-------------RubyMultipartPost\r\nContent-Disposition: form-data;
131
- name=\"adgroup_id\"\r\n\r\n6005859287551\r\n-------------RubyMultipartPost\r\nContent-Disposition:
132
- form-data; name=\"ad_id\"\r\n\r\n6005859287551\r\n-------------RubyMultipartPost\r\nContent-Disposition:
133
- form-data; name=\"campaign_id\"\r\n\r\n6005851032951\r\n-------------RubyMultipartPost\r\nContent-Disposition:
134
- form-data; name=\"name\"\r\n\r\nMy new name\r\n-------------RubyMultipartPost\r\nContent-Disposition:
135
- form-data; name=\"adgroup_status\"\r\n\r\n3\r\n-------------RubyMultipartPost\r\nContent-Disposition:
136
- form-data; name=\"bid_type\"\r\n\r\n1\r\n-------------RubyMultipartPost\r\nContent-Disposition:
137
- form-data; name=\"max_bid\"\r\n\r\n1\r\n-------------RubyMultipartPost\r\nContent-Disposition:
138
- form-data; name=\"bid_info%5B1%5D\"\r\n\r\n1\r\n-------------RubyMultipartPost\r\nContent-Disposition:
139
- form-data; name=\"ad_status\"\r\n\r\n3\r\n-------------RubyMultipartPost\r\nContent-Disposition:
140
- form-data; name=\"locations%5B%5D\"\r\n\r\n3\r\n-------------RubyMultipartPost\r\nContent-Disposition:
141
- form-data; name=\"impression_control_map%5B%5D%5Blocation%5D\"\r\n\r\n3\r\n-------------RubyMultipartPost\r\nContent-Disposition:
142
- form-data; name=\"impression_control_map%5B%5D%5Bcontrol%5D%5Bimpression_control_type%5D\"\r\n\r\n2\r\n-------------RubyMultipartPost\r\nContent-Disposition:
143
- form-data; name=\"impression_control_map%5B%5D%5Bcontrol%5D%5Buser_impression_limit%5D\"\r\n\r\n6\r\n-------------RubyMultipartPost\r\nContent-Disposition:
144
- form-data; name=\"impression_control_map%5B%5D%5Bcontrol%5D%5Buser_impression_limit_period%5D\"\r\n\r\n24\r\n-------------RubyMultipartPost\r\nContent-Disposition:
145
- form-data; name=\"impression_control_map%5B%5D%5Bcontrol%5D%5Buser_impression_limit_period_unit%5D\"\r\n\r\n0\r\n-------------RubyMultipartPost\r\nContent-Disposition:
146
- form-data; name=\"account_id\"\r\n\r\n10150585630710217\r\n-------------RubyMultipartPost\r\nContent-Disposition:
147
- form-data; name=\"creative_ids%5B%5D\"\r\n\r\n6005851371551\r\n-------------RubyMultipartPost\r\nContent-Disposition:
148
- form-data; name=\"targeting%5Bcountries%5D%5B%5D\"\r\n\r\nUS\r\n-------------RubyMultipartPost\r\nContent-Disposition:
149
- form-data; name=\"targeting%5Bfriends_of_connections%5D%5B%5D%5Bid%5D\"\r\n\r\n6005851366351\r\n-------------RubyMultipartPost\r\nContent-Disposition:
150
- form-data; name=\"targeting%5Bfriends_of_connections%5D%5B%5D%5Bname%5D\"\r\n\r\n\r\n-------------RubyMultipartPost\r\nContent-Disposition:
151
- form-data; name=\"conversion_specs%5B%5D%5Baction.type%5D\"\r\n\r\nlike\r\n-------------RubyMultipartPost\r\nContent-Disposition:
152
- form-data; name=\"conversion_specs%5B%5D%5Bpost%5D\"\r\n\r\n10150420410887685\r\n-------------RubyMultipartPost\r\nContent-Disposition:
153
- form-data; name=\"last_updated_by_app_id\"\r\n\r\n333322143368799\r\n-------------RubyMultipartPost\r\nContent-Disposition:
154
- form-data; name=\"start_time\"\r\n\r\n\r\n-------------RubyMultipartPost\r\nContent-Disposition:
155
- form-data; name=\"end_time\"\r\n\r\n\r\n-------------RubyMultipartPost\r\nContent-Disposition:
156
- form-data; name=\"updated_time\"\r\n\r\n1345558829\r\n-------------RubyMultipartPost\r\nContent-Disposition:
157
- form-data; name=\"created_time\"\r\n\r\n1343981037\r\n-------------RubyMultipartPost\r\nContent-Disposition:
158
- form-data; name=\"redownload\"\r\n\r\n1\r\n-------------RubyMultipartPost\r\nContent-Disposition:
159
- form-data; name=\"access_token\"\r\n\r\nAAAEvJ5vzhl8BABhTSazJZB2D0B4N0l242VX22Hg9J2WZA7fptcAztfXxfAZB9mhZB6W1nl5dz5tXMlb9DJk9ibs6RqtP7PtO6a3XCiHWVwZDZD\r\n-------------RubyMultipartPost--\r\n\r\n"
160
- headers:
161
- Content-Type:
162
- - multipart/form-data;boundary=-----------RubyMultipartPost
163
- Content-Length:
164
- - '3296'
165
- Accept:
166
- - ! '*/*'
167
- User-Agent:
168
- - Ruby
169
- response:
170
- status:
171
- code: 200
172
- message: OK
173
- headers:
174
- Access-Control-Allow-Origin:
175
- - ! '*'
176
- Cache-Control:
177
- - private, no-cache, no-store, must-revalidate
178
- Content-Type:
179
- - text/javascript; charset=UTF-8
180
- Expires:
181
- - Sat, 01 Jan 2000 00:00:00 GMT
182
- Pragma:
183
- - no-cache
184
- X-Fb-Rev:
185
- - '612565'
186
- X-Fb-Debug:
187
- - aybsAvoevphfkbHd0RJfT8BZ7KQ7h60SElY0ms5y0A8=
188
- Date:
189
- - Tue, 21 Aug 2012 14:20:31 GMT
190
- Connection:
191
- - keep-alive
192
- Content-Length:
193
- - '1188'
194
- body:
195
- encoding: US-ASCII
196
- string: ! '{"result":true,"data":{"adgroups":{"6005859287551":{"adgroup_id":6005859287551,"ad_id":6005859287551,"campaign_id":6005851032951,"name":"My
197
- new name","adgroup_status":3,"bid_type":1,"max_bid":"1","bid_info":{"1":"1"},"ad_status":3,"locations":[3],"impression_control_map":[{"location":3,"control":{"impression_control_type":2,"user_impression_limit":6,"user_impression_limit_period":24,"user_impression_limit_period_unit":0}}],"account_id":"10150585630710217","id":"6005859287551","creative_ids":[6005851371551],"targeting":{"countries":["US"],"friends_of_connections":[{"id":"6005851366351","name":null}]},"conversion_specs":[{"action.type":"like","post":"10150420410887685"}],"last_updated_by_app_id":333322143368799,"start_time":null,"end_time":null,"updated_time":1345558830,"created_time":1343981037}},"creatives":{"6005851371551":{"type":25,"action_spec":{"action.type":"like","post":"10150420410887685"},"related_fan_page":1,"cluster_id":6005851366351,"name":"Sponsored
198
- story #6005851371551","run_status":1,"preview_url":"http:\/\/www.facebook.com\/ads\/api\/creative_preview.php?cid=6005851371551","count_current_adgroups":11,"id":"6005851371551","creative_id":"6005851371551"}}}}'
199
- http_version:
200
- recorded_at: Tue, 21 Aug 2012 14:20:31 GMT
201
- - request:
202
- method: get
203
- uri: https://graph.facebook.com/6005859287551?access_token=AAAEvJ5vzhl8BABhTSazJZB2D0B4N0l242VX22Hg9J2WZA7fptcAztfXxfAZB9mhZB6W1nl5dz5tXMlb9DJk9ibs6RqtP7PtO6a3XCiHWVwZDZD
204
- body:
205
- encoding: US-ASCII
206
- string: ''
207
- headers:
208
- Accept-Encoding:
209
- - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
210
- Accept:
211
- - ! '*/*'
212
- User-Agent:
213
- - Ruby
214
- response:
215
- status:
216
- code: 200
217
- message: OK
218
- headers:
219
- Access-Control-Allow-Origin:
220
- - ! '*'
221
- Cache-Control:
222
- - private, no-cache, no-store, must-revalidate
223
- Content-Type:
224
- - text/javascript; charset=UTF-8
225
- Etag:
226
- - ! '"1652cd0dfcd195031ef0ebde9d52ba22bca9edbf"'
227
- Expires:
228
- - Sat, 01 Jan 2000 00:00:00 GMT
229
- Pragma:
230
- - no-cache
231
- X-Fb-Rev:
232
- - '612565'
233
- X-Fb-Debug:
234
- - C6USh72V9vXHwkVPbaLd8637mADobNQkZJBlAhQGArg=
235
- Date:
236
- - Tue, 21 Aug 2012 14:20:31 GMT
237
- Connection:
238
- - keep-alive
239
- Content-Length:
240
- - '786'
241
- body:
242
- encoding: US-ASCII
243
- string: ! '{"adgroup_id":6005859287551,"ad_id":6005859287551,"campaign_id":6005851032951,"name":"My
244
- new name","adgroup_status":3,"bid_type":1,"max_bid":"1","bid_info":{"1":"1"},"ad_status":3,"locations":[3],"impression_control_map":[{"location":3,"control":{"impression_control_type":2,"user_impression_limit":6,"user_impression_limit_period":24,"user_impression_limit_period_unit":0}}],"account_id":"10150585630710217","id":"6005859287551","creative_ids":[6005851371551],"targeting":{"countries":["US"],"friends_of_connections":[{"id":"6005851366351","name":null}]},"conversion_specs":[{"action.type":"like","post":"10150420410887685"}],"last_updated_by_app_id":333322143368799,"start_time":null,"end_time":null,"updated_time":"2012-08-21T14:20:30+0000","created_time":"2012-08-03T08:03:57+0000"}'
245
- http_version:
246
- recorded_at: Tue, 21 Aug 2012 14:20:32 GMT
247
- recorded_with: VCR 2.2.4