live_paper 0.0.3 → 0.0.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 7d1a4537b26f97c14a9a85ad86bb0680769a2b84
4
- data.tar.gz: 7c37a4ad99ede53b4d38122c85be5cb8f7488fc4
3
+ metadata.gz: b91be1f07200bdb505c4bbf6cbb2b807e8db92dd
4
+ data.tar.gz: 6e2d6543c8d6d814bfd6305a528ce004615712f8
5
5
  SHA512:
6
- metadata.gz: 22cbb4d1c481deae3e21f557136b93f24bb645cf240b009a982d1ef46dc11ee085424ca539a736368616f8706c7bb1cdb1e98ed074adc4ae0289494677a3387f
7
- data.tar.gz: b601b2205e65d33bc71fd1a5df53d7d6a48c91cc265dd70be9a77a83f5f3948a4a44742f6b260e4fe0b8bf438d9e99da897ad90568111edec3ca16c7e1511fc9
6
+ metadata.gz: f772a5e16a230689b1d20b0ce5203e97e34c163af48a6d2745fb0ba154efa7f44951ab7e9cb7464829e448252b6666b11ace4d01f5a635cef7c4b5f9c6359095
7
+ data.tar.gz: 9532f9968d5a35178791c516f99331030484a817c7b465a263ffd0d7cd27257ac70730ca42441870d35361576267148c743ac71afd7d86cc1a8dc0e5b86820bf
data/README.md CHANGED
@@ -30,7 +30,7 @@ In order to obtain access credentials register here: https://link.livepaperdeve
30
30
  Live Paper gem requires an authentication hash with :id and :secret. Obtain your credentials from the registration link above.
31
31
 
32
32
  ```ruby
33
- lp = LivePaper.auth id: "your client id", secret: "your client secret"
33
+ lp = LivePaper.auth 'id': "your client id", 'secret': "your client secret"
34
34
  ```
35
35
 
36
36
 
@@ -54,8 +54,8 @@ qr_bytes = lp.qr_bytes('http://www.amazon.com')
54
54
 
55
55
  ```ruby
56
56
  wm_bytes = lp.watermark_bytes("http://www.hp.com",
57
- "https://www.google.com/images/srpr/logo11w.png")
58
- File.open("watermark.jpg", "w") { |f| f.write(wm_bytes) }
57
+ "http://www.letsstartsmall.com/ITSE2313_WebAuthoring/images/unit3/jpg_example1.jpg")
58
+ File.open("watermark.jpg", "w:UTF-8") { |f| f.write(wm_bytes.force_encoding("UTF-8")) }
59
59
  ```
60
60
 
61
61
  > Note: Version 1 of the API only supports returning image bytes. Version 2 may host publicly accessible images.
@@ -1,3 +1,3 @@
1
1
  module LivePaper
2
- VERSION = "0.0.3"
2
+ VERSION = "0.0.4"
3
3
  end
data/lib/live_paper.rb CHANGED
@@ -89,9 +89,9 @@ module LivePaper
89
89
  def trigger(type="shorturl", options={})
90
90
  body = {
91
91
  trigger: {
92
- name: "foo",
92
+ name: "trigger",
93
93
  type: type,
94
- expiryDate: Time.now + (365 * 24 * 60 *60)
94
+ expiryDate: Time.now + (365 * 24 * 60 * 60)
95
95
  }.merge(options)
96
96
  }
97
97
  create_resource('trigger', body)
@@ -100,7 +100,7 @@ module LivePaper
100
100
  def url_payoff(dest)
101
101
  body = {
102
102
  payoff: {
103
- name: "foo",
103
+ name: "payoff",
104
104
  URL: dest
105
105
  }
106
106
  }
@@ -110,7 +110,7 @@ module LivePaper
110
110
  def link(trigger, payoff)
111
111
  body = {
112
112
  link: {
113
- name: "mud",
113
+ name: "link",
114
114
  payoffId: payoff["id"],
115
115
  triggerId: trigger["id"]
116
116
  }
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: live_paper
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mike Whitmarsh