freshmail 0.1.1 → 0.1.2
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.
- checksums.yaml +4 -4
- data/lib/freshmail/api.rb +1 -1
- data/lib/freshmail/version.rb +1 -1
- metadata +1 -2
- data/README.rdoc +0 -71
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e999186c4d2df1c90745e9adad20e4210680cbfe
|
4
|
+
data.tar.gz: ea62c88720df43cbb5934890cb70b3ab37dde0cc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c95dd5df992ec4452be98e2c711006bf929ca2c13a8a0afcbea632a0f3ee01febea8544802e92aed8ed2acbbbf7c61e1b979674b3660dca72ee2afcc9a0ca88f
|
7
|
+
data.tar.gz: bd5207fd13c8fe9aa4cd2aa17b3bbdd9befd1cb97e1ec8e8a9fcdcfb30a1cd1fc9fc87b221f20f3ed5b322b4eb6a983d6d302a75a6944d1eeaeebb25c346b122
|
data/lib/freshmail/api.rb
CHANGED
data/lib/freshmail/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: freshmail
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Marcin Jan Adamczyk
|
@@ -74,7 +74,6 @@ extensions: []
|
|
74
74
|
extra_rdoc_files: []
|
75
75
|
files:
|
76
76
|
- MIT-LICENSE
|
77
|
-
- README.rdoc
|
78
77
|
- Rakefile
|
79
78
|
- lib/freshmail.rb
|
80
79
|
- lib/freshmail/api.rb
|
data/README.rdoc
DELETED
@@ -1,71 +0,0 @@
|
|
1
|
-
= Freshmail
|
2
|
-
===================
|
3
|
-
|
4
|
-
This is a Rails Gem for Freshmail REST API.
|
5
|
-
|
6
|
-
## Instalation
|
7
|
-
|
8
|
-
```console
|
9
|
-
gem install freshmail
|
10
|
-
```
|
11
|
-
|
12
|
-
or add it to your `Gemfile`:
|
13
|
-
|
14
|
-
```ruby
|
15
|
-
gem 'freshmail'
|
16
|
-
```
|
17
|
-
|
18
|
-
## Usage
|
19
|
-
|
20
|
-
Create instance of gem:
|
21
|
-
|
22
|
-
```ruby
|
23
|
-
freshmail = Freshmail::Api.new('YOUR_API_KEY', 'YOUR_API_SECRET')
|
24
|
-
```
|
25
|
-
|
26
|
-
After that, you can access Freshmail methods, for example:
|
27
|
-
|
28
|
-
```ruby
|
29
|
-
my_lists = freshmail.lists
|
30
|
-
my_first_list_hash = my_lists['lists'].first['subscriberListHash']
|
31
|
-
my_last_list_hash = my_lists['lists'].last['subscriberListHash']
|
32
|
-
|
33
|
-
freshmail.add_subscriber(email: 'test@test.net', list: my_first_list_hash, state: 1)
|
34
|
-
|
35
|
-
freshmail.batch_add_subscriber(subscribers: [{email: 'test@test.net'}, {email: 'test2@test.net'}], list: my_last_list_hash, state: 1)
|
36
|
-
|
37
|
-
freshmail.subscriber(email: 'test@test.net', list: my_first_list_hash)
|
38
|
-
freshmail.subscribers(subscribers: [{email: 'test2@test.net'}], list: my_last_list_hash)
|
39
|
-
|
40
|
-
freshmail.delete_subscriber(email: 'test@test.net', list: my_first_list_hash)
|
41
|
-
freshmail.batch_delete_subscriber(subscribers: [{email: 'test@test.net'}, {email: 'test2@test.net'}], list: my_last_list_hash)
|
42
|
-
```
|
43
|
-
|
44
|
-
Available methods:
|
45
|
-
|
46
|
-
```ruby
|
47
|
-
freshmail.ping
|
48
|
-
freshmail.mail(...)
|
49
|
-
freshmail.subscriber(...)
|
50
|
-
freshmail.subscribers(...)
|
51
|
-
freshmail.add_subscriber(...)
|
52
|
-
freshmail.batch_add_subscriber(...)
|
53
|
-
freshmail.delete_subscriber(...)
|
54
|
-
freshmail.batch_delete_subscriber(...)
|
55
|
-
freshmail.lists
|
56
|
-
freshmail.create_list(...)
|
57
|
-
freshmail.update_list(...)
|
58
|
-
freshmail.delete_list(...)
|
59
|
-
```
|
60
|
-
|
61
|
-
## TODO
|
62
|
-
|
63
|
-
Add more methods.
|
64
|
-
Add tests.
|
65
|
-
|
66
|
-
## Licence
|
67
|
-
|
68
|
-
Copyright (c) 2015 Marcin Adamczyk, released under the MIT license
|
69
|
-
|
70
|
-
|
71
|
-
*Feel free to contact me if you need help: marcin.adamczyk [--a-t--] subcom.me*
|