constantcontact 1.1.2 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (33) hide show
  1. data/README.md +2 -2
  2. data/constantcontact.gemspec +1 -1
  3. data/lib/constantcontact.rb +15 -2
  4. data/lib/constantcontact/api.rb +164 -21
  5. data/lib/constantcontact/components/event_spot/contact.rb +5 -5
  6. data/lib/constantcontact/components/event_spot/event.rb +28 -22
  7. data/lib/constantcontact/components/event_spot/event_address.rb +29 -0
  8. data/lib/constantcontact/components/event_spot/{fee.rb → event_fee.rb} +7 -7
  9. data/lib/constantcontact/components/event_spot/event_item.rb +36 -0
  10. data/lib/constantcontact/components/event_spot/event_item_attribute.rb +26 -0
  11. data/lib/constantcontact/components/event_spot/event_track.rb +6 -3
  12. data/lib/constantcontact/components/event_spot/guest.rb +6 -6
  13. data/lib/constantcontact/components/event_spot/guest_section.rb +34 -0
  14. data/lib/constantcontact/components/event_spot/notification_option.rb +2 -2
  15. data/lib/constantcontact/components/event_spot/online_meeting.rb +28 -0
  16. data/lib/constantcontact/components/event_spot/payment_address.rb +29 -0
  17. data/lib/constantcontact/components/event_spot/payment_summary.rb +33 -0
  18. data/lib/constantcontact/components/event_spot/promocode.rb +25 -0
  19. data/lib/constantcontact/components/event_spot/registrant.rb +19 -21
  20. data/lib/constantcontact/components/event_spot/registrant_fee.rb +29 -0
  21. data/lib/constantcontact/components/event_spot/registrant_order.rb +39 -0
  22. data/lib/constantcontact/components/event_spot/registrant_promo_code.rb +31 -0
  23. data/lib/constantcontact/components/event_spot/registrant_promo_code_info.rb +27 -0
  24. data/lib/constantcontact/components/event_spot/registrant_section.rb +6 -6
  25. data/lib/constantcontact/components/event_spot/sale_item.rb +15 -13
  26. data/lib/constantcontact/services/event_spot_service.rb +252 -29
  27. data/lib/constantcontact/util/config.rb +12 -6
  28. data/lib/constantcontact/version.rb +1 -1
  29. data/spec/constantcontact/api_spec.rb +221 -21
  30. data/spec/constantcontact/services/event_spot_spec.rb +223 -21
  31. metadata +118 -76
  32. checksums.yaml +0 -7
  33. data/lib/constantcontact/components/event_spot/promo_code.rb +0 -26
metadata CHANGED
@@ -1,87 +1,120 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: constantcontact
3
- version: !ruby/object:Gem::Version
4
- version: 1.1.2
3
+ version: !ruby/object:Gem::Version
4
+ prerelease:
5
+ version: 1.2.0
5
6
  platform: ruby
6
- authors:
7
+ authors:
7
8
  - ConstantContact
8
- autorequire:
9
+ autorequire:
9
10
  bindir: bin
10
11
  cert_chain: []
11
-
12
- date: 2014-02-24 00:00:00 Z
13
- dependencies:
14
- - !ruby/object:Gem::Dependency
12
+ date: 2014-05-01 00:00:00.000000000 Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
15
15
  name: rest-client
16
- prerelease: false
17
- requirement: &id001 !ruby/object:Gem::Requirement
18
- requirements:
19
- - - ~>
20
- - !ruby/object:Gem::Version
21
- version: "1.6"
16
+ version_requirements: !ruby/object:Gem::Requirement
17
+ requirements:
18
+ - - "~>"
19
+ - !ruby/object:Gem::Version
20
+ version: '1.6'
21
+ - - ">="
22
+ - !ruby/object:Gem::Version
23
+ version: 1.6.7
24
+ none: false
25
+ requirement: !ruby/object:Gem::Requirement
26
+ requirements:
27
+ - - "~>"
28
+ - !ruby/object:Gem::Version
29
+ version: '1.6'
22
30
  - - ">="
23
- - !ruby/object:Gem::Version
31
+ - !ruby/object:Gem::Version
24
32
  version: 1.6.7
33
+ none: false
34
+ prerelease: false
25
35
  type: :runtime
26
- version_requirements: *id001
27
- - !ruby/object:Gem::Dependency
36
+ - !ruby/object:Gem::Dependency
28
37
  name: json
29
- prerelease: false
30
- requirement: &id002 !ruby/object:Gem::Requirement
31
- requirements:
32
- - - ~>
33
- - !ruby/object:Gem::Version
34
- version: "1.8"
38
+ version_requirements: !ruby/object:Gem::Requirement
39
+ requirements:
40
+ - - "~>"
41
+ - !ruby/object:Gem::Version
42
+ version: '1.8'
43
+ - - ">="
44
+ - !ruby/object:Gem::Version
45
+ version: 1.8.1
46
+ none: false
47
+ requirement: !ruby/object:Gem::Requirement
48
+ requirements:
49
+ - - "~>"
50
+ - !ruby/object:Gem::Version
51
+ version: '1.8'
35
52
  - - ">="
36
- - !ruby/object:Gem::Version
53
+ - !ruby/object:Gem::Version
37
54
  version: 1.8.1
55
+ none: false
56
+ prerelease: false
38
57
  type: :runtime
39
- version_requirements: *id002
40
- - !ruby/object:Gem::Dependency
58
+ - !ruby/object:Gem::Dependency
41
59
  name: mime-types
42
- prerelease: false
43
- requirement: &id003 !ruby/object:Gem::Requirement
44
- requirements:
45
- - - ~>
46
- - !ruby/object:Gem::Version
47
- version: "1.25"
60
+ version_requirements: !ruby/object:Gem::Requirement
61
+ requirements:
62
+ - - "~>"
63
+ - !ruby/object:Gem::Version
64
+ version: '1.25'
48
65
  - - ">="
49
- - !ruby/object:Gem::Version
66
+ - !ruby/object:Gem::Version
50
67
  version: 1.25.1
68
+ none: false
69
+ requirement: !ruby/object:Gem::Requirement
70
+ requirements:
71
+ - - "~>"
72
+ - !ruby/object:Gem::Version
73
+ version: '1.25'
74
+ - - ">="
75
+ - !ruby/object:Gem::Version
76
+ version: 1.25.1
77
+ none: false
78
+ prerelease: false
51
79
  type: :runtime
52
- version_requirements: *id003
53
- - !ruby/object:Gem::Dependency
80
+ - !ruby/object:Gem::Dependency
54
81
  name: rspec
82
+ version_requirements: !ruby/object:Gem::Requirement
83
+ requirements:
84
+ - - "~>"
85
+ - !ruby/object:Gem::Version
86
+ version: '2.14'
87
+ none: false
88
+ requirement: !ruby/object:Gem::Requirement
89
+ requirements:
90
+ - - "~>"
91
+ - !ruby/object:Gem::Version
92
+ version: '2.14'
93
+ none: false
55
94
  prerelease: false
56
- requirement: &id004 !ruby/object:Gem::Requirement
57
- requirements:
58
- - - ~>
59
- - !ruby/object:Gem::Version
60
- version: "2.14"
61
95
  type: :development
62
- version_requirements: *id004
63
96
  description: Ruby library for interactions with Constant Contact v2 API
64
97
  email: apisupport@constantcontact.com
65
98
  executables: []
66
-
67
99
  extensions: []
68
-
69
100
  extra_rdoc_files: []
70
-
71
- files:
72
- - .rspec
101
+ files:
102
+ - ".rspec"
73
103
  - constantcontact.gemspec
74
104
  - README.md
105
+ - lib/constantcontact.rb
75
106
  - lib/constantcontact/api.rb
107
+ - lib/constantcontact/version.rb
76
108
  - lib/constantcontact/auth/oauth2.rb
77
109
  - lib/constantcontact/auth/session_data_store.rb
110
+ - lib/constantcontact/components/component.rb
111
+ - lib/constantcontact/components/result_set.rb
78
112
  - lib/constantcontact/components/account/verified_email_address.rb
79
113
  - lib/constantcontact/components/activities/activity.rb
80
114
  - lib/constantcontact/components/activities/activity_error.rb
81
115
  - lib/constantcontact/components/activities/add_contacts.rb
82
116
  - lib/constantcontact/components/activities/add_contacts_import_data.rb
83
117
  - lib/constantcontact/components/activities/export_contacts.rb
84
- - lib/constantcontact/components/component.rb
85
118
  - lib/constantcontact/components/contacts/address.rb
86
119
  - lib/constantcontact/components/contacts/contact.rb
87
120
  - lib/constantcontact/components/contacts/contact_list.rb
@@ -95,13 +128,24 @@ files:
95
128
  - lib/constantcontact/components/email_marketing/test_send.rb
96
129
  - lib/constantcontact/components/event_spot/contact.rb
97
130
  - lib/constantcontact/components/event_spot/event.rb
131
+ - lib/constantcontact/components/event_spot/event_address.rb
132
+ - lib/constantcontact/components/event_spot/event_fee.rb
133
+ - lib/constantcontact/components/event_spot/event_item.rb
134
+ - lib/constantcontact/components/event_spot/event_item_attribute.rb
98
135
  - lib/constantcontact/components/event_spot/event_track.rb
99
- - lib/constantcontact/components/event_spot/fee.rb
100
136
  - lib/constantcontact/components/event_spot/guest.rb
137
+ - lib/constantcontact/components/event_spot/guest_section.rb
101
138
  - lib/constantcontact/components/event_spot/notification_option.rb
102
- - lib/constantcontact/components/event_spot/promo_code.rb
139
+ - lib/constantcontact/components/event_spot/online_meeting.rb
140
+ - lib/constantcontact/components/event_spot/payment_address.rb
141
+ - lib/constantcontact/components/event_spot/payment_summary.rb
142
+ - lib/constantcontact/components/event_spot/promocode.rb
103
143
  - lib/constantcontact/components/event_spot/registrant.rb
144
+ - lib/constantcontact/components/event_spot/registrant_fee.rb
104
145
  - lib/constantcontact/components/event_spot/registrant_field.rb
146
+ - lib/constantcontact/components/event_spot/registrant_order.rb
147
+ - lib/constantcontact/components/event_spot/registrant_promo_code.rb
148
+ - lib/constantcontact/components/event_spot/registrant_promo_code_info.rb
105
149
  - lib/constantcontact/components/event_spot/registrant_section.rb
106
150
  - lib/constantcontact/components/event_spot/sale_item.rb
107
151
  - lib/constantcontact/components/library/file/library_file.rb
@@ -109,7 +153,6 @@ files:
109
153
  - lib/constantcontact/components/library/info/library_summary.rb
110
154
  - lib/constantcontact/components/library/info/move_results.rb
111
155
  - lib/constantcontact/components/library/info/upload_status.rb
112
- - lib/constantcontact/components/result_set.rb
113
156
  - lib/constantcontact/components/tracking/bounce_activity.rb
114
157
  - lib/constantcontact/components/tracking/click_activity.rb
115
158
  - lib/constantcontact/components/tracking/forward_activity.rb
@@ -134,16 +177,14 @@ files:
134
177
  - lib/constantcontact/services/list_service.rb
135
178
  - lib/constantcontact/util/config.rb
136
179
  - lib/constantcontact/util/helpers.rb
137
- - lib/constantcontact/version.rb
138
- - lib/constantcontact.rb
139
180
  - spec/constantcontact/api_spec.rb
181
+ - spec/constantcontact/sdk_spec.rb
140
182
  - spec/constantcontact/auth/oauth2_spec.rb
141
183
  - spec/constantcontact/components/contacts/address_spec.rb
142
184
  - spec/constantcontact/components/contacts/contact_list_spec.rb
143
185
  - spec/constantcontact/components/contacts/contact_spec.rb
144
186
  - spec/constantcontact/components/contacts/custom_field_spec.rb
145
187
  - spec/constantcontact/components/contacts/email_address_spec.rb
146
- - spec/constantcontact/sdk_spec.rb
147
188
  - spec/constantcontact/services/activity_service_spec.rb
148
189
  - spec/constantcontact/services/base_service_spec.rb
149
190
  - spec/constantcontact/services/campaign_schedule_service_spec.rb
@@ -155,40 +196,41 @@ files:
155
196
  - spec/constantcontact/services/library_service_spec.rb
156
197
  - spec/constantcontact/services/list_service_spec.rb
157
198
  homepage: http://www.constantcontact.com
158
- licenses:
199
+ licenses:
159
200
  - MIT
160
- metadata: {}
161
-
162
- post_install_message:
201
+ post_install_message:
163
202
  rdoc_options: []
164
-
165
- require_paths:
203
+ require_paths:
166
204
  - lib
167
- required_ruby_version: !ruby/object:Gem::Requirement
168
- requirements:
169
- - &id005
170
- - ">="
171
- - !ruby/object:Gem::Version
172
- version: "0"
173
- required_rubygems_version: !ruby/object:Gem::Requirement
174
- requirements:
175
- - *id005
205
+ required_ruby_version: !ruby/object:Gem::Requirement
206
+ requirements:
207
+ - - ">="
208
+ - !ruby/object:Gem::Version
209
+ version: !binary |-
210
+ MA==
211
+ none: false
212
+ required_rubygems_version: !ruby/object:Gem::Requirement
213
+ requirements:
214
+ - - ">="
215
+ - !ruby/object:Gem::Version
216
+ version: !binary |-
217
+ MA==
218
+ none: false
176
219
  requirements: []
177
-
178
- rubyforge_project:
179
- rubygems_version: 2.0.14
180
- signing_key:
181
- specification_version: 4
220
+ rubyforge_project:
221
+ rubygems_version: 1.8.24
222
+ signing_key:
223
+ specification_version: 3
182
224
  summary: Constant Contact SDK for Ruby
183
- test_files:
225
+ test_files:
184
226
  - spec/constantcontact/api_spec.rb
227
+ - spec/constantcontact/sdk_spec.rb
185
228
  - spec/constantcontact/auth/oauth2_spec.rb
186
229
  - spec/constantcontact/components/contacts/address_spec.rb
187
230
  - spec/constantcontact/components/contacts/contact_list_spec.rb
188
231
  - spec/constantcontact/components/contacts/contact_spec.rb
189
232
  - spec/constantcontact/components/contacts/custom_field_spec.rb
190
233
  - spec/constantcontact/components/contacts/email_address_spec.rb
191
- - spec/constantcontact/sdk_spec.rb
192
234
  - spec/constantcontact/services/activity_service_spec.rb
193
235
  - spec/constantcontact/services/base_service_spec.rb
194
236
  - spec/constantcontact/services/campaign_schedule_service_spec.rb
checksums.yaml DELETED
@@ -1,7 +0,0 @@
1
- ---
2
- SHA1:
3
- metadata.gz: 55cf4d95b406c393fc99d1fdb140a3c087ad9277
4
- data.tar.gz: 4b1fcc3b1c0e97ed846d85cb4d8905dbd07fb135
5
- SHA512:
6
- metadata.gz: 4f0146bf59d55f6da897d3f6ff9cb3825a3723a8b358425f3ee172cdebef3828b2548664417bdcd3d278422be116465699ae1c9122e33ccb030d216b87c97949
7
- data.tar.gz: 58bd7d214333a2f4c55c6ddac7510a9f0c2efc90e9213e3286ccdafddd19da53feadc97950b4665141a350270d59dfa4bb4b2042c0a63ec2f5a1a3ecc5d3905c
@@ -1,26 +0,0 @@
1
- #
2
- # promo_code.rb
3
- # ConstantContact
4
- #
5
- # Copyright (c) 2013 Constant Contact. All rights reserved.
6
-
7
- module ConstantContact
8
- module Components
9
- class PromoCode < Component
10
- attr_accessor :discount_type, :code_type, :code_name, :redemption_count,
11
- :discount_scope, :discount_amount, :discount_percent
12
-
13
- # Factory method to create an event PromoCode object from a hash
14
- # @param [Hash] props - hash of properties to create object from
15
- # @return [Campaign]
16
- def self.create(props)
17
- code = PromoCode.new
18
- props.each do |key, value|
19
- key = key.to_s
20
- code.send("#{key}=", value) if code.respond_to? key
21
- end
22
- code
23
- end
24
- end
25
- end
26
- end