README.md in smtpapi-0.0.3 vs README.md in smtpapi-0.0.4
- old
+ new
@@ -24,28 +24,28 @@
```ruby
header = Smtpapi::Header.new
```
-### json_string
+### to_json
-This gives you back the stringified json formatted X-SMTPAPI header.
+This gives you back the stringified json formatted X-SMTPAPI header.
```ruby
header = Smtpapi::Header.new
-header.json_string
+header.to_json
```
### add_to
```ruby
header = Smtpapi::Header.new
header.add_to('you@youremail.com')
header.add_to('other@otheremail.com')
```
-### set_to
+### set_tos
```ruby
header = Smtpapi::Header.new
header.set_tos(['you@youremail.com', 'other@otheremail.com'])
```
@@ -120,18 +120,36 @@
### set_filters
```ruby
header = Smtpapi::Header.new
-filter = {
- 'footer' => {
- 'setting' => {
+filter = {
+ 'footer' => {
+ 'setting' => {
'enable' => 1,
"text/plain" => 'You can haz footers!'
}
}
-}
+}
header.set_filters(filter)
+```
+
+### set_send_all
+
+```ruby
+header = Smtpapi::Header.new
+lt = Time.local(2014, 8, 29, 17, 56, 35)
+header.set_send_all(lt)
+```
+
+### set_send_each_at
+
+```ruby
+header = Smtpapi::Header.new
+lt1 = Time.local(2014, 8, 29, 17, 56, 35)
+lt2 = Time.local(2013, 12, 31, 0, 0, 0)
+lt3 = Time.local(2015, 9, 1, 4, 5, 6)
+header.set_send_each_at([lt1, lt2, lt3])
```
## Contributing
1. Fork it ( http://github.com/sendgridjp/smtpapi-ruby/fork )