panda_doc 0.3.1 → 0.3.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 2f95c9c2752d6b0bdeffecd9f8b6669d06ca6b31
4
- data.tar.gz: b04ffe46de32eed2ca87f0e13dca926a2f1b4ad6
3
+ metadata.gz: b975a1fcc43d92ed3f46914b421d874673f440a3
4
+ data.tar.gz: 8ed163be41e3cad83d7ed887606e0a4b743e47aa
5
5
  SHA512:
6
- metadata.gz: 00d186c0446b3f9dbd5b1510251004e433e54511183c1ee65ae43d366a2e396e56ee4f6c774be2ac339e106ec70f353d6a88734982a2764cef6331f3c539c030
7
- data.tar.gz: a9401c21796993eee4206a246f9a0a2958753e625e97017e5cb53a409af9ccf67bb701d569a6c195a34cf28da88ca1f8683b985cc828131e001fcad5585d4fbb
6
+ metadata.gz: 9e5684b13155e8ec17a5f2d4591995dc3a71708af1b990de6c8c1ab805fa084a67c818b01f0000c168b7166cf85a0ca81de5a2fc8ebb8c56ac90ed745301c0a3
7
+ data.tar.gz: ce967a20524e3a8271f80eb46828830ed143f09ce2f8bdd9b33e61c8a1594474d8bcc3d7c313301b7429048331f54aaabb9e1a758cc1982527a6ef2aeaa1abe0
@@ -4,6 +4,21 @@ All notable changes to this project will be documented in this file.
4
4
 
5
5
  ## [Unreleased]
6
6
 
7
+ ## [0.3.2][] (2016-04-15)
8
+
9
+ New:
10
+
11
+ - Add Document.find("uuid") shortcut to retreive document info.
12
+
13
+ ```ruby
14
+ document = PandaDoc::Document.find("uuid")
15
+ document.status
16
+ => "uploaded"
17
+
18
+ docuemnt.name
19
+ => "Document Name"
20
+ ```
21
+
7
22
  ## [0.3.1][] (2016-03-04)
8
23
 
9
24
  New:
@@ -71,7 +86,8 @@ Fixes:
71
86
 
72
87
  - Initial release
73
88
 
74
- [Unreleased]: https://github.com/opti/panda_doc/compare/v0.3.1...HEAD
89
+ [Unreleased]: https://github.com/opti/panda_doc/compare/v0.3.2...HEAD
90
+ [0.3.2]: https://github.com/opti/panda_doc/compare/v0.3.1...v0.3.2
75
91
  [0.3.1]: https://github.com/opti/panda_doc/compare/v0.3.0...v0.3.1
76
92
  [0.3.0]: https://github.com/opti/panda_doc/compare/v0.2.0...v0.3.0
77
93
  [0.2.0]: https://github.com/opti/panda_doc/compare/v0.1.0...v0.2.0
data/README.md CHANGED
@@ -41,7 +41,7 @@ Every response wrapped into a ruby object with values coerced in corresponding t
41
41
  #### Creating a document
42
42
 
43
43
  ```ruby
44
- PandaDoc::Document.create(
44
+ document = PandaDoc::Document.create(
45
45
  name: "Sample Document",
46
46
  url: "url_to_a_document",
47
47
  recipients: [
@@ -90,13 +90,22 @@ document = PandaDoc::Document.create(
90
90
  )
91
91
  ```
92
92
 
93
+ #### Getting a document status
94
+
95
+ ```ruby
96
+ document = PandaDoc::Document.find("UUID")
97
+
98
+ document.status # => "draft"
99
+ document.updated_at # => <DateTime: 2016-02-03T17:41:00-08:00>
100
+ ```
101
+
93
102
  #### Sending a document
94
103
 
95
104
  ```ruby
96
105
  PandaDoc::Document.send("UUID", message: "A message to include into the email")
97
106
  ```
98
107
 
99
- #### Ccreating a View Session
108
+ #### Creating a View Session
100
109
 
101
110
  ```ruby
102
111
  session = PandaDoc::Document.session("UUID",
@@ -10,6 +10,10 @@ module PandaDoc
10
10
  respond(ApiClient.request(:post, "/documents/#{uuid}/send", data))
11
11
  end
12
12
 
13
+ def find(uuid)
14
+ respond(ApiClient.request(:get, "/documents/#{uuid}"))
15
+ end
16
+
13
17
  def session(uuid, **data)
14
18
  respond(
15
19
  ApiClient.request(:post, "/documents/#{uuid}/session", data),
@@ -1,3 +1,3 @@
1
1
  module PandaDoc
2
- VERSION = "0.3.1"
2
+ VERSION = "0.3.2"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: panda_doc
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.1
4
+ version: 0.3.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Igor Pstyga
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-03-05 00:00:00.000000000 Z
11
+ date: 2016-04-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday