Class: Boldsign::Resources::Document
Overview
Document endpoints (‘/v1/document/*`) — the bulk of the BoldSign API: sending, listing, downloading, editing, reminding, authenticating, tagging, and embedded signing flows.
Instance Method Summary
collapse
-
#add_authentication(document_id, body) ⇒ Object
-
#add_tags(body) ⇒ Object
-
#behalf_list(**params) ⇒ Object
-
#cancel_editing(document_id) ⇒ Object
-
#change_access_code(document_id, body) ⇒ Object
-
#change_recipient(document_id, body) ⇒ Object
-
#create_embedded_edit_url(body) ⇒ Object
-
#create_embedded_request_url(body) ⇒ Object
-
#delete(document_id) ⇒ Object
-
#delete_tags(body) ⇒ Object
-
#download(document_id) ⇒ Object
-
#download_attachment(**params) ⇒ Object
-
#download_audit_log(document_id) ⇒ Object
-
#draft_send(body) ⇒ Object
-
#edit(document_id, body) ⇒ Object
-
#extend_expiry(document_id, body) ⇒ Object
-
#get_embedded_sign_link(**params) ⇒ Object
-
#list(**params) ⇒ Object
-
#prefill_fields(document_id, body) ⇒ Object
-
#properties(document_id) ⇒ Object
-
#remind(document_id, body = {}) ⇒ Object
-
#remove_authentication(document_id, body) ⇒ Object
-
#revoke(document_id, body = {}) ⇒ Object
-
#send_document(files: nil, **body) ⇒ Object
Send a document for signature.
-
#team_list(**params) ⇒ Object
#initialize
Instance Method Details
#add_authentication(document_id, body) ⇒ Object
70
|
# File 'lib/boldsign/resources/document.rb', line 70
def add_authentication(document_id, body); @client.patch("/v1/document/addAuthentication", body: body, params: { documentId: document_id }); end
|
66
|
# File 'lib/boldsign/resources/document.rb', line 66
def add_tags(body); @client.patch("/v1/document/addTags", body: body); end
|
#behalf_list(**params) ⇒ Object
24
|
# File 'lib/boldsign/resources/document.rb', line 24
def behalf_list(**params); @client.get("/v1/document/behalfList", params); end
|
#cancel_editing(document_id) ⇒ Object
48
|
# File 'lib/boldsign/resources/document.rb', line 48
def cancel_editing(document_id); @client.post("/v1/document/cancelEditing", params: { documentId: document_id }); end
|
#change_access_code(document_id, body) ⇒ Object
63
|
# File 'lib/boldsign/resources/document.rb', line 63
def change_access_code(document_id, body); @client.patch("/v1/document/changeAccessCode", body: body, params: { documentId: document_id }); end
|
#change_recipient(document_id, body) ⇒ Object
64
|
# File 'lib/boldsign/resources/document.rb', line 64
def change_recipient(document_id, body); @client.patch("/v1/document/changeRecipient", body: body, params: { documentId: document_id }); end
|
#create_embedded_edit_url(body) ⇒ Object
51
|
# File 'lib/boldsign/resources/document.rb', line 51
def create_embedded_edit_url(body); @client.post("/v1/document/createEmbeddedEditUrl", body: body); end
|
#create_embedded_request_url(body) ⇒ Object
50
|
# File 'lib/boldsign/resources/document.rb', line 50
def create_embedded_request_url(body); @client.post("/v1/document/createEmbeddedRequestUrl", body: body); end
|
#delete(document_id) ⇒ Object
60
|
# File 'lib/boldsign/resources/document.rb', line 60
def delete(document_id); @client.delete("/v1/document/delete", documentId: document_id); end
|
67
|
# File 'lib/boldsign/resources/document.rb', line 67
def delete_tags(body); @client.delete("/v1/document/deleteTags", body: body); end
|
#download(document_id) ⇒ Object
54
|
# File 'lib/boldsign/resources/document.rb', line 54
def download(document_id); @client.download("/v1/document/download", documentId: document_id); end
|
#download_attachment(**params) ⇒ Object
55
|
# File 'lib/boldsign/resources/document.rb', line 55
def download_attachment(**params); @client.download("/v1/document/downloadAttachment", params); end
|
#download_audit_log(document_id) ⇒ Object
56
|
# File 'lib/boldsign/resources/document.rb', line 56
def download_audit_log(document_id); @client.download("/v1/document/downloadAuditLog", documentId: document_id); end
|
#draft_send(body) ⇒ Object
46
|
# File 'lib/boldsign/resources/document.rb', line 46
def draft_send(body); @client.post("/v1/document/draftSend", body: body); end
|
#edit(document_id, body) ⇒ Object
47
|
# File 'lib/boldsign/resources/document.rb', line 47
def edit(document_id, body); @client.put("/v1/document/edit", body: body, params: { documentId: document_id }); end
|
#extend_expiry(document_id, body) ⇒ Object
61
|
# File 'lib/boldsign/resources/document.rb', line 61
def extend_expiry(document_id, body); @client.patch("/v1/document/extendExpiry", body: body, params: { documentId: document_id }); end
|
#get_embedded_sign_link(**params) ⇒ Object
52
|
# File 'lib/boldsign/resources/document.rb', line 52
def get_embedded_sign_link(**params); @client.get("/v1/document/getEmbeddedSignLink", params); end
|
#list(**params) ⇒ Object
22
|
# File 'lib/boldsign/resources/document.rb', line 22
def list(**params); @client.get("/v1/document/list", params); end
|
#prefill_fields(document_id, body) ⇒ Object
72
|
# File 'lib/boldsign/resources/document.rb', line 72
def prefill_fields(document_id, body); @client.patch("/v1/document/prefillFields", body: body, params: { documentId: document_id }); end
|
#properties(document_id) ⇒ Object
25
|
# File 'lib/boldsign/resources/document.rb', line 25
def properties(document_id); @client.get("/v1/document/properties", documentId: document_id); end
|
#remind(document_id, body = {}) ⇒ Object
59
|
# File 'lib/boldsign/resources/document.rb', line 59
def remind(document_id, body = {}); @client.post("/v1/document/remind", body: body, params: { documentId: document_id }); end
|
#remove_authentication(document_id, body) ⇒ Object
69
|
# File 'lib/boldsign/resources/document.rb', line 69
def remove_authentication(document_id, body); @client.patch("/v1/document/RemoveAuthentication", body: body, params: { documentId: document_id }); end
|
#revoke(document_id, body = {}) ⇒ Object
58
|
# File 'lib/boldsign/resources/document.rb', line 58
def revoke(document_id, body = {}); @client.post("/v1/document/revoke", body: body, params: { documentId: document_id }); end
|
#send_document(files: nil, **body) ⇒ Object
Send a document for signature.
Pass ‘files:` to upload one or more PDFs (or other supported file types) via multipart/form-data. Without `files:`, the request is sent as JSON and BoldSign must already know the file content (e.g. via Base64 in the body or by referencing an existing template).
40
41
42
43
44
|
# File 'lib/boldsign/resources/document.rb', line 40
def send_document(files: nil, **body)
return @client.post("/v1/document/send", body: body) if files.nil?
@client.post("/v1/document/send", body: multipart_send_body(body, files), multipart: true)
end
|
#team_list(**params) ⇒ Object
23
|
# File 'lib/boldsign/resources/document.rb', line 23
def team_list(**params); @client.get("/v1/document/teamlist", params); end
|