signwell_sdk 0.0.1.pre.alpha.1
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 +7 -0
- data/.ignore +2 -0
- data/CHANGELOG.md +24 -0
- data/README.md +398 -0
- data/SECURITY.md +23 -0
- data/lib/signwell_sdk/client.rb +72 -0
- data/lib/signwell_sdk/errors.rb +228 -0
- data/lib/signwell_sdk/file_part.rb +58 -0
- data/lib/signwell_sdk/internal/transport/base_client.rb +573 -0
- data/lib/signwell_sdk/internal/transport/pooled_net_requester.rb +210 -0
- data/lib/signwell_sdk/internal/type/array_of.rb +168 -0
- data/lib/signwell_sdk/internal/type/base_model.rb +531 -0
- data/lib/signwell_sdk/internal/type/base_page.rb +55 -0
- data/lib/signwell_sdk/internal/type/boolean.rb +77 -0
- data/lib/signwell_sdk/internal/type/converter.rb +327 -0
- data/lib/signwell_sdk/internal/type/enum.rb +156 -0
- data/lib/signwell_sdk/internal/type/file_input.rb +111 -0
- data/lib/signwell_sdk/internal/type/hash_of.rb +188 -0
- data/lib/signwell_sdk/internal/type/request_parameters.rb +42 -0
- data/lib/signwell_sdk/internal/type/union.rb +243 -0
- data/lib/signwell_sdk/internal/type/unknown.rb +81 -0
- data/lib/signwell_sdk/internal/util.rb +920 -0
- data/lib/signwell_sdk/internal.rb +20 -0
- data/lib/signwell_sdk/models/attachment_request_info.rb +34 -0
- data/lib/signwell_sdk/models/checkbox_group_info.rb +66 -0
- data/lib/signwell_sdk/models/checkbox_validation.rb +18 -0
- data/lib/signwell_sdk/models/copied_contact_info.rb +34 -0
- data/lib/signwell_sdk/models/date_format.rb +20 -0
- data/lib/signwell_sdk/models/field_type.rb +29 -0
- data/lib/signwell_sdk/models/file_info.rb +26 -0
- data/lib/signwell_sdk/models/label_info.rb +26 -0
- data/lib/signwell_sdk/models/text_validation.rb +25 -0
- data/lib/signwell_sdk/models/v1/api_application_delete_params.rb +16 -0
- data/lib/signwell_sdk/models/v1/api_application_retrieve_params.rb +16 -0
- data/lib/signwell_sdk/models/v1/attachment_request.rb +38 -0
- data/lib/signwell_sdk/models/v1/bulk_send_create_params.rb +107 -0
- data/lib/signwell_sdk/models/v1/bulk_send_list_params.rb +55 -0
- data/lib/signwell_sdk/models/v1/bulk_send_retrieve_csv_template_params.rb +39 -0
- data/lib/signwell_sdk/models/v1/bulk_send_retrieve_documents_params.rb +32 -0
- data/lib/signwell_sdk/models/v1/bulk_send_retrieve_params.rb +16 -0
- data/lib/signwell_sdk/models/v1/bulk_send_validate_csv_params.rb +39 -0
- data/lib/signwell_sdk/models/v1/checkbox_group.rb +80 -0
- data/lib/signwell_sdk/models/v1/copied_contact.rb +26 -0
- data/lib/signwell_sdk/models/v1/document.rb +543 -0
- data/lib/signwell_sdk/models/v1/document_create_from_template_params.rb +740 -0
- data/lib/signwell_sdk/models/v1/document_create_from_template_response.rb +500 -0
- data/lib/signwell_sdk/models/v1/document_create_params.rb +620 -0
- data/lib/signwell_sdk/models/v1/document_delete_params.rb +16 -0
- data/lib/signwell_sdk/models/v1/document_file.rb +34 -0
- data/lib/signwell_sdk/models/v1/document_list_params.rb +32 -0
- data/lib/signwell_sdk/models/v1/document_list_response.rb +50 -0
- data/lib/signwell_sdk/models/v1/document_remind_params.rb +49 -0
- data/lib/signwell_sdk/models/v1/document_retrieve_completed_pdf_params.rb +55 -0
- data/lib/signwell_sdk/models/v1/document_retrieve_completed_pdf_response.rb +22 -0
- data/lib/signwell_sdk/models/v1/document_retrieve_params.rb +16 -0
- data/lib/signwell_sdk/models/v1/document_send_params.rb +198 -0
- data/lib/signwell_sdk/models/v1/document_template.rb +503 -0
- data/lib/signwell_sdk/models/v1/document_template_create_params.rb +599 -0
- data/lib/signwell_sdk/models/v1/document_template_delete_params.rb +16 -0
- data/lib/signwell_sdk/models/v1/document_template_list_params.rb +32 -0
- data/lib/signwell_sdk/models/v1/document_template_list_response.rb +50 -0
- data/lib/signwell_sdk/models/v1/document_template_retrieve_params.rb +16 -0
- data/lib/signwell_sdk/models/v1/document_template_update_params.rb +162 -0
- data/lib/signwell_sdk/models/v1/hook_create_params.rb +32 -0
- data/lib/signwell_sdk/models/v1/hook_delete_params.rb +16 -0
- data/lib/signwell_sdk/models/v1/hook_list_params.rb +16 -0
- data/lib/signwell_sdk/models/v1/label.rb +22 -0
- data/lib/signwell_sdk/models/v1/template_checkbox_group.rb +80 -0
- data/lib/signwell_sdk/models/v1_me_params.rb +14 -0
- data/lib/signwell_sdk/models.rb +63 -0
- data/lib/signwell_sdk/request_options.rb +77 -0
- data/lib/signwell_sdk/resources/v1/api_applications.rb +59 -0
- data/lib/signwell_sdk/resources/v1/bulk_sends.rb +198 -0
- data/lib/signwell_sdk/resources/v1/document_templates.rb +204 -0
- data/lib/signwell_sdk/resources/v1/documents.rb +372 -0
- data/lib/signwell_sdk/resources/v1/hooks.rb +78 -0
- data/lib/signwell_sdk/resources/v1.rb +47 -0
- data/lib/signwell_sdk/version.rb +5 -0
- data/lib/signwell_sdk.rb +107 -0
- data/manifest.yaml +17 -0
- data/rbi/signwell_sdk/client.rbi +49 -0
- data/rbi/signwell_sdk/errors.rbi +205 -0
- data/rbi/signwell_sdk/file_part.rbi +37 -0
- data/rbi/signwell_sdk/internal/transport/base_client.rbi +302 -0
- data/rbi/signwell_sdk/internal/transport/pooled_net_requester.rbi +84 -0
- data/rbi/signwell_sdk/internal/type/array_of.rbi +104 -0
- data/rbi/signwell_sdk/internal/type/base_model.rbi +308 -0
- data/rbi/signwell_sdk/internal/type/base_page.rbi +43 -0
- data/rbi/signwell_sdk/internal/type/boolean.rbi +58 -0
- data/rbi/signwell_sdk/internal/type/converter.rbi +216 -0
- data/rbi/signwell_sdk/internal/type/enum.rbi +82 -0
- data/rbi/signwell_sdk/internal/type/file_input.rbi +59 -0
- data/rbi/signwell_sdk/internal/type/hash_of.rbi +104 -0
- data/rbi/signwell_sdk/internal/type/request_parameters.rbi +31 -0
- data/rbi/signwell_sdk/internal/type/union.rbi +128 -0
- data/rbi/signwell_sdk/internal/type/unknown.rbi +58 -0
- data/rbi/signwell_sdk/internal/util.rbi +487 -0
- data/rbi/signwell_sdk/internal.rbi +18 -0
- data/rbi/signwell_sdk/models/attachment_request_info.rbi +52 -0
- data/rbi/signwell_sdk/models/checkbox_group_info.rbi +89 -0
- data/rbi/signwell_sdk/models/checkbox_validation.rbi +27 -0
- data/rbi/signwell_sdk/models/copied_contact_info.rbi +50 -0
- data/rbi/signwell_sdk/models/date_format.rbi +26 -0
- data/rbi/signwell_sdk/models/field_type.rbi +41 -0
- data/rbi/signwell_sdk/models/file_info.rbi +36 -0
- data/rbi/signwell_sdk/models/label_info.rbi +40 -0
- data/rbi/signwell_sdk/models/text_validation.rbi +44 -0
- data/rbi/signwell_sdk/models/v1/api_application_delete_params.rbi +34 -0
- data/rbi/signwell_sdk/models/v1/api_application_retrieve_params.rbi +34 -0
- data/rbi/signwell_sdk/models/v1/attachment_request.rbi +59 -0
- data/rbi/signwell_sdk/models/v1/bulk_send_create_params.rbi +160 -0
- data/rbi/signwell_sdk/models/v1/bulk_send_list_params.rbi +92 -0
- data/rbi/signwell_sdk/models/v1/bulk_send_retrieve_csv_template_params.rbi +67 -0
- data/rbi/signwell_sdk/models/v1/bulk_send_retrieve_documents_params.rbi +62 -0
- data/rbi/signwell_sdk/models/v1/bulk_send_retrieve_params.rbi +34 -0
- data/rbi/signwell_sdk/models/v1/bulk_send_validate_csv_params.rbi +64 -0
- data/rbi/signwell_sdk/models/v1/checkbox_group.rbi +121 -0
- data/rbi/signwell_sdk/models/v1/copied_contact.rbi +41 -0
- data/rbi/signwell_sdk/models/v1/document.rbi +833 -0
- data/rbi/signwell_sdk/models/v1/document_create_from_template_params.rbi +1270 -0
- data/rbi/signwell_sdk/models/v1/document_create_from_template_response.rbi +856 -0
- data/rbi/signwell_sdk/models/v1/document_create_params.rbi +1019 -0
- data/rbi/signwell_sdk/models/v1/document_delete_params.rbi +34 -0
- data/rbi/signwell_sdk/models/v1/document_file.rbi +55 -0
- data/rbi/signwell_sdk/models/v1/document_list_params.rbi +62 -0
- data/rbi/signwell_sdk/models/v1/document_list_response.rbi +71 -0
- data/rbi/signwell_sdk/models/v1/document_remind_params.rbi +107 -0
- data/rbi/signwell_sdk/models/v1/document_retrieve_completed_pdf_params.rbi +123 -0
- data/rbi/signwell_sdk/models/v1/document_retrieve_completed_pdf_response.rbi +34 -0
- data/rbi/signwell_sdk/models/v1/document_retrieve_params.rbi +34 -0
- data/rbi/signwell_sdk/models/v1/document_send_params.rbi +307 -0
- data/rbi/signwell_sdk/models/v1/document_template.rbi +830 -0
- data/rbi/signwell_sdk/models/v1/document_template_create_params.rbi +1050 -0
- data/rbi/signwell_sdk/models/v1/document_template_delete_params.rbi +34 -0
- data/rbi/signwell_sdk/models/v1/document_template_list_params.rbi +62 -0
- data/rbi/signwell_sdk/models/v1/document_template_list_response.rbi +71 -0
- data/rbi/signwell_sdk/models/v1/document_template_retrieve_params.rbi +34 -0
- data/rbi/signwell_sdk/models/v1/document_template_update_params.rbi +257 -0
- data/rbi/signwell_sdk/models/v1/hook_create_params.rbi +59 -0
- data/rbi/signwell_sdk/models/v1/hook_delete_params.rbi +34 -0
- data/rbi/signwell_sdk/models/v1/hook_list_params.rbi +34 -0
- data/rbi/signwell_sdk/models/v1/label.rbi +29 -0
- data/rbi/signwell_sdk/models/v1/template_checkbox_group.rbi +121 -0
- data/rbi/signwell_sdk/models/v1_me_params.rbi +27 -0
- data/rbi/signwell_sdk/models.rbi +25 -0
- data/rbi/signwell_sdk/request_options.rbi +59 -0
- data/rbi/signwell_sdk/resources/v1/api_applications.rbi +45 -0
- data/rbi/signwell_sdk/resources/v1/bulk_sends.rbi +173 -0
- data/rbi/signwell_sdk/resources/v1/document_templates.rbi +276 -0
- data/rbi/signwell_sdk/resources/v1/documents.rbi +527 -0
- data/rbi/signwell_sdk/resources/v1/hooks.rbi +52 -0
- data/rbi/signwell_sdk/resources/v1.rbi +32 -0
- data/rbi/signwell_sdk/version.rbi +5 -0
- data/sig/signwell_sdk/client.rbs +26 -0
- data/sig/signwell_sdk/errors.rbs +117 -0
- data/sig/signwell_sdk/file_part.rbs +21 -0
- data/sig/signwell_sdk/internal/transport/base_client.rbs +133 -0
- data/sig/signwell_sdk/internal/transport/pooled_net_requester.rbs +48 -0
- data/sig/signwell_sdk/internal/type/array_of.rbs +48 -0
- data/sig/signwell_sdk/internal/type/base_model.rbs +102 -0
- data/sig/signwell_sdk/internal/type/base_page.rbs +24 -0
- data/sig/signwell_sdk/internal/type/boolean.rbs +26 -0
- data/sig/signwell_sdk/internal/type/converter.rbs +79 -0
- data/sig/signwell_sdk/internal/type/enum.rbs +32 -0
- data/sig/signwell_sdk/internal/type/file_input.rbs +25 -0
- data/sig/signwell_sdk/internal/type/hash_of.rbs +48 -0
- data/sig/signwell_sdk/internal/type/request_parameters.rbs +19 -0
- data/sig/signwell_sdk/internal/type/union.rbs +52 -0
- data/sig/signwell_sdk/internal/type/unknown.rbs +26 -0
- data/sig/signwell_sdk/internal/util.rbs +185 -0
- data/sig/signwell_sdk/internal.rbs +9 -0
- data/sig/signwell_sdk/models/attachment_request_info.rbs +19 -0
- data/sig/signwell_sdk/models/checkbox_group_info.rbs +52 -0
- data/sig/signwell_sdk/models/checkbox_validation.rbs +16 -0
- data/sig/signwell_sdk/models/copied_contact_info.rbs +21 -0
- data/sig/signwell_sdk/models/date_format.rbs +22 -0
- data/sig/signwell_sdk/models/field_type.rbs +42 -0
- data/sig/signwell_sdk/models/file_info.rbs +15 -0
- data/sig/signwell_sdk/models/label_info.rbs +19 -0
- data/sig/signwell_sdk/models/text_validation.rbs +34 -0
- data/sig/signwell_sdk/models/v1/api_application_delete_params.rbs +17 -0
- data/sig/signwell_sdk/models/v1/api_application_retrieve_params.rbs +17 -0
- data/sig/signwell_sdk/models/v1/attachment_request.rbs +26 -0
- data/sig/signwell_sdk/models/v1/bulk_send_create_params.rbs +89 -0
- data/sig/signwell_sdk/models/v1/bulk_send_list_params.rbs +51 -0
- data/sig/signwell_sdk/models/v1/bulk_send_retrieve_csv_template_params.rbs +32 -0
- data/sig/signwell_sdk/models/v1/bulk_send_retrieve_documents_params.rbs +34 -0
- data/sig/signwell_sdk/models/v1/bulk_send_retrieve_params.rbs +17 -0
- data/sig/signwell_sdk/models/v1/bulk_send_validate_csv_params.rbs +30 -0
- data/sig/signwell_sdk/models/v1/checkbox_group.rbs +69 -0
- data/sig/signwell_sdk/models/v1/copied_contact.rbs +19 -0
- data/sig/signwell_sdk/models/v1/document.rbs +563 -0
- data/sig/signwell_sdk/models/v1/document_create_from_template_params.rbs +570 -0
- data/sig/signwell_sdk/models/v1/document_create_from_template_response.rbs +518 -0
- data/sig/signwell_sdk/models/v1/document_create_params.rbs +473 -0
- data/sig/signwell_sdk/models/v1/document_delete_params.rbs +17 -0
- data/sig/signwell_sdk/models/v1/document_file.rbs +32 -0
- data/sig/signwell_sdk/models/v1/document_list_params.rbs +34 -0
- data/sig/signwell_sdk/models/v1/document_list_response.rbs +47 -0
- data/sig/signwell_sdk/models/v1/document_remind_params.rbs +48 -0
- data/sig/signwell_sdk/models/v1/document_retrieve_completed_pdf_params.rbs +57 -0
- data/sig/signwell_sdk/models/v1/document_retrieve_completed_pdf_response.rbs +15 -0
- data/sig/signwell_sdk/models/v1/document_retrieve_params.rbs +17 -0
- data/sig/signwell_sdk/models/v1/document_send_params.rbs +160 -0
- data/sig/signwell_sdk/models/v1/document_template.rbs +530 -0
- data/sig/signwell_sdk/models/v1/document_template_create_params.rbs +459 -0
- data/sig/signwell_sdk/models/v1/document_template_delete_params.rbs +17 -0
- data/sig/signwell_sdk/models/v1/document_template_list_params.rbs +34 -0
- data/sig/signwell_sdk/models/v1/document_template_list_response.rbs +47 -0
- data/sig/signwell_sdk/models/v1/document_template_retrieve_params.rbs +17 -0
- data/sig/signwell_sdk/models/v1/document_template_update_params.rbs +132 -0
- data/sig/signwell_sdk/models/v1/hook_create_params.rbs +32 -0
- data/sig/signwell_sdk/models/v1/hook_delete_params.rbs +17 -0
- data/sig/signwell_sdk/models/v1/hook_list_params.rbs +17 -0
- data/sig/signwell_sdk/models/v1/label.rbs +15 -0
- data/sig/signwell_sdk/models/v1/template_checkbox_group.rbs +69 -0
- data/sig/signwell_sdk/models/v1_me_params.rbs +14 -0
- data/sig/signwell_sdk/models.rbs +23 -0
- data/sig/signwell_sdk/request_options.rbs +36 -0
- data/sig/signwell_sdk/resources/v1/api_applications.rbs +19 -0
- data/sig/signwell_sdk/resources/v1/bulk_sends.rbs +55 -0
- data/sig/signwell_sdk/resources/v1/document_templates.rbs +71 -0
- data/sig/signwell_sdk/resources/v1/documents.rbs +130 -0
- data/sig/signwell_sdk/resources/v1/hooks.rbs +22 -0
- data/sig/signwell_sdk/resources/v1.rbs +19 -0
- data/sig/signwell_sdk/version.rbs +3 -0
- metadata +298 -0
|
@@ -0,0 +1,527 @@
|
|
|
1
|
+
# typed: strong
|
|
2
|
+
|
|
3
|
+
module SignwellSDK
|
|
4
|
+
module Resources
|
|
5
|
+
class V1
|
|
6
|
+
class Documents
|
|
7
|
+
# Creates and optionally sends a new document for signing. If `draft` is set to
|
|
8
|
+
# true the document will not be sent.
|
|
9
|
+
sig do
|
|
10
|
+
params(
|
|
11
|
+
files: T::Array[SignwellSDK::V1::DocumentFile::OrHash],
|
|
12
|
+
recipients:
|
|
13
|
+
T::Array[
|
|
14
|
+
SignwellSDK::V1::DocumentCreateParams::Recipient::OrHash
|
|
15
|
+
],
|
|
16
|
+
allow_decline: T::Boolean,
|
|
17
|
+
allow_reassign: T::Boolean,
|
|
18
|
+
api_application_id: String,
|
|
19
|
+
apply_signing_order: T::Boolean,
|
|
20
|
+
attachment_requests:
|
|
21
|
+
T::Array[SignwellSDK::V1::AttachmentRequest::OrHash],
|
|
22
|
+
checkbox_groups: T::Array[SignwellSDK::V1::CheckboxGroup::OrHash],
|
|
23
|
+
copied_contacts: T::Array[SignwellSDK::V1::CopiedContact::OrHash],
|
|
24
|
+
custom_requester_email: String,
|
|
25
|
+
custom_requester_name: String,
|
|
26
|
+
decline_redirect_url: String,
|
|
27
|
+
draft: T::Boolean,
|
|
28
|
+
embedded_signing: T::Boolean,
|
|
29
|
+
embedded_signing_notifications: T::Boolean,
|
|
30
|
+
expires_in: Integer,
|
|
31
|
+
fields:
|
|
32
|
+
T::Array[
|
|
33
|
+
T::Array[SignwellSDK::V1::DocumentCreateParams::Field::OrHash]
|
|
34
|
+
],
|
|
35
|
+
labels: T::Array[SignwellSDK::V1::Label::OrHash],
|
|
36
|
+
language: String,
|
|
37
|
+
message: String,
|
|
38
|
+
metadata: T::Hash[Symbol, String],
|
|
39
|
+
name: String,
|
|
40
|
+
redirect_url: String,
|
|
41
|
+
reminders: T::Boolean,
|
|
42
|
+
subject: String,
|
|
43
|
+
test_mode: T::Boolean,
|
|
44
|
+
text_tags: T::Boolean,
|
|
45
|
+
with_signature_page: T::Boolean,
|
|
46
|
+
request_options: SignwellSDK::RequestOptions::OrHash
|
|
47
|
+
).returns(SignwellSDK::V1::Document)
|
|
48
|
+
end
|
|
49
|
+
def create(
|
|
50
|
+
# Document files can be uploaded by specifying a file URL or base64 string. Either
|
|
51
|
+
# `file_url` or `file_base64` must be present (not both). Valid file types are:
|
|
52
|
+
# .pdf, .doc, .docx, .pages, .ppt, .pptx, .key, .xls, .xlsx, .numbers, .jpg,
|
|
53
|
+
# .jpeg, .png, .tiff, .tif, .webp, .html, and .htm
|
|
54
|
+
files:,
|
|
55
|
+
# Document recipients are people that must complete and/or sign a document.
|
|
56
|
+
recipients:,
|
|
57
|
+
# Whether to allow recipients the option to decline signing a document. If
|
|
58
|
+
# multiple signers are involved in a document, any single recipient can cancel the
|
|
59
|
+
# entire document signing process by declining to sign.
|
|
60
|
+
allow_decline: nil,
|
|
61
|
+
# In some cases a signer is not the right person to sign and may need to reassign
|
|
62
|
+
# their signing responsibilities to another person. This feature allows them to
|
|
63
|
+
# reassign the document to someone else.
|
|
64
|
+
allow_reassign: nil,
|
|
65
|
+
# Unique identifier for API Application settings to use. API Applications are
|
|
66
|
+
# optional and mainly used when isolating OAuth apps or for more control over
|
|
67
|
+
# embedded API settings
|
|
68
|
+
api_application_id: nil,
|
|
69
|
+
# When set to `true` recipients will sign one at a time in the order of the
|
|
70
|
+
# `recipients` collection of this request.
|
|
71
|
+
apply_signing_order: nil,
|
|
72
|
+
# Attachments that a recipient must upload to complete the signing process.
|
|
73
|
+
# Attachment requests are shown after all document fields have been completed.
|
|
74
|
+
attachment_requests: nil,
|
|
75
|
+
# Checkbox fields that are placed on a document can be grouped with selection
|
|
76
|
+
# requirements. At least 2 checkbox fields in an array of fields must be assigned
|
|
77
|
+
# to the same recipient.
|
|
78
|
+
checkbox_groups: nil,
|
|
79
|
+
# Copied contacts are emailed the final document once it has been completed by all
|
|
80
|
+
# recipients.
|
|
81
|
+
copied_contacts: nil,
|
|
82
|
+
# Sets the custom requester email for the document. When set, this is the email
|
|
83
|
+
# used for all email communications, signing notifications, and in the audit file.
|
|
84
|
+
custom_requester_email: nil,
|
|
85
|
+
# Sets the custom requester name for the document. When set, this is the name used
|
|
86
|
+
# for all email communications, signing notifications, and in the audit file.
|
|
87
|
+
custom_requester_name: nil,
|
|
88
|
+
# A URL that recipients are redirected to if the document is declined.
|
|
89
|
+
decline_redirect_url: nil,
|
|
90
|
+
# Whether the document can still be updated before sending a signature request. If
|
|
91
|
+
# set to `false` the document is sent for signing as part of this request.
|
|
92
|
+
# Defaults to `false`.
|
|
93
|
+
draft: nil,
|
|
94
|
+
# When set to `true` it enables embedded signing in your website/web application.
|
|
95
|
+
# Embedded functionality works with an iFrame and email authentication is
|
|
96
|
+
# disabled. :embedded_signinig defaults to `false`.
|
|
97
|
+
embedded_signing: nil,
|
|
98
|
+
# On embedding signing, document owners (and CC'd contacts) do not get a
|
|
99
|
+
# notification email when documents have been completed. Setting this param to
|
|
100
|
+
# `true` will send out those final completed notifications. Default is `false`
|
|
101
|
+
embedded_signing_notifications: nil,
|
|
102
|
+
# Number of days before the signature request expires. Defaults to the account
|
|
103
|
+
# expiration setting or template expiration (if the document is created from a
|
|
104
|
+
# template).
|
|
105
|
+
expires_in: nil,
|
|
106
|
+
# Document fields placed on a document for collecting data or signatures from
|
|
107
|
+
# recipients. At least one field must be present in the Create Document request if
|
|
108
|
+
# `draft` is `false` (unless adding a signature page by using
|
|
109
|
+
# `with_signature_page`). Field data should be sent as a 2-dimensional JSON array.
|
|
110
|
+
# One array of fields is needed for each file in the files array. An array of
|
|
111
|
+
# fields can be empty if you have a file that does not contain any fields.
|
|
112
|
+
fields: nil,
|
|
113
|
+
# Labels can be used to organize documents in a way that can make it easy to find
|
|
114
|
+
# using the document search in SignWell. A document can have multiple labels.
|
|
115
|
+
labels: nil,
|
|
116
|
+
# Sets the language for all recipients on the document and updates all recipient
|
|
117
|
+
# side interactions including the document email and the document itself. Accepted
|
|
118
|
+
# languages: English, Français, Español, Deutsch, Polski, Português, Dansk,
|
|
119
|
+
# Nederlands, Italiano, Русский, Svenska, العربية, Ελληνικά, Türkçe, Slovenčina.
|
|
120
|
+
# Defaults to English. Language should be sent in ISO 639-1 format: en, fr, es,
|
|
121
|
+
# de, pl, pt, da, nl, it, ru, sv, ar, el, tr, sk.
|
|
122
|
+
language: nil,
|
|
123
|
+
# Email message for the signature request that recipients will see. Defaults to
|
|
124
|
+
# the default system message or a template message (if the document is created
|
|
125
|
+
# from a template).
|
|
126
|
+
message: nil,
|
|
127
|
+
# Optional key-value data that can be associated with the document. If set, will
|
|
128
|
+
# be available every time the document data is returned.
|
|
129
|
+
metadata: nil,
|
|
130
|
+
# The name of the document.
|
|
131
|
+
name: nil,
|
|
132
|
+
# A URL that recipients are redirected to after successfully signing a document.
|
|
133
|
+
redirect_url: nil,
|
|
134
|
+
# Whether to send signing reminders to recipients. Reminders are sent on day 3,
|
|
135
|
+
# day 6, and day 10 if set to `true`. Defaults to `true`.
|
|
136
|
+
reminders: nil,
|
|
137
|
+
# Email subject for the signature request that recipients will see. Defaults to
|
|
138
|
+
# the default system subject or a template subject (if the document is created
|
|
139
|
+
# from a template).
|
|
140
|
+
subject: nil,
|
|
141
|
+
# Set to `true` to enable Test Mode. Documents created with Test Mode do not count
|
|
142
|
+
# towards API billing and are not legally binding. Defaults to `false`
|
|
143
|
+
test_mode: nil,
|
|
144
|
+
# An alternative way (if you can’t use the recommended way) of placing fields in
|
|
145
|
+
# specific locations of your document by using special text tags. Useful when
|
|
146
|
+
# changing the content of your files changes the location of fields. See API
|
|
147
|
+
# documentation for “Text Tags” for details. Defaults to false.
|
|
148
|
+
text_tags: nil,
|
|
149
|
+
# When set to `true` the document will have a signature page added to the end, and
|
|
150
|
+
# all signers will be required to add their signature on that page.
|
|
151
|
+
with_signature_page: nil,
|
|
152
|
+
request_options: {}
|
|
153
|
+
)
|
|
154
|
+
end
|
|
155
|
+
|
|
156
|
+
# Returns a document and all associated document data. Supply the unique document
|
|
157
|
+
# ID from either a document creation request or Document page URL.
|
|
158
|
+
sig do
|
|
159
|
+
params(
|
|
160
|
+
id: String,
|
|
161
|
+
request_options: SignwellSDK::RequestOptions::OrHash
|
|
162
|
+
).returns(SignwellSDK::V1::Document)
|
|
163
|
+
end
|
|
164
|
+
def retrieve(
|
|
165
|
+
# Unique identifier for a document.
|
|
166
|
+
id,
|
|
167
|
+
request_options: {}
|
|
168
|
+
)
|
|
169
|
+
end
|
|
170
|
+
|
|
171
|
+
# Returns a paginated list of documents for the authenticated account.
|
|
172
|
+
sig do
|
|
173
|
+
params(
|
|
174
|
+
limit: Integer,
|
|
175
|
+
page: Integer,
|
|
176
|
+
request_options: SignwellSDK::RequestOptions::OrHash
|
|
177
|
+
).returns(SignwellSDK::Models::V1::DocumentListResponse)
|
|
178
|
+
end
|
|
179
|
+
def list(
|
|
180
|
+
# The number of documents to fetch. Defaults to 10, max is 50.
|
|
181
|
+
limit: nil,
|
|
182
|
+
# The page number for pagination. Defaults to the first page.
|
|
183
|
+
page: nil,
|
|
184
|
+
request_options: {}
|
|
185
|
+
)
|
|
186
|
+
end
|
|
187
|
+
|
|
188
|
+
# Deletes a document. Deleting a document will also cancel document signing (if in
|
|
189
|
+
# progress). Supply the unique document ID from either a Create Document request
|
|
190
|
+
# or document page URL.
|
|
191
|
+
sig do
|
|
192
|
+
params(
|
|
193
|
+
id: String,
|
|
194
|
+
request_options: SignwellSDK::RequestOptions::OrHash
|
|
195
|
+
).void
|
|
196
|
+
end
|
|
197
|
+
def delete(
|
|
198
|
+
# Unique identifier for a document.
|
|
199
|
+
id,
|
|
200
|
+
request_options: {}
|
|
201
|
+
)
|
|
202
|
+
end
|
|
203
|
+
|
|
204
|
+
# Creates and optionally sends a new document for signing. If `draft` is set to
|
|
205
|
+
# true the document will not be sent.
|
|
206
|
+
sig do
|
|
207
|
+
params(
|
|
208
|
+
recipients:
|
|
209
|
+
T::Array[
|
|
210
|
+
SignwellSDK::V1::DocumentCreateFromTemplateParams::Recipient::OrHash
|
|
211
|
+
],
|
|
212
|
+
allow_decline: T::Boolean,
|
|
213
|
+
allow_reassign: T::Boolean,
|
|
214
|
+
api_application_id: String,
|
|
215
|
+
apply_signing_order: T::Boolean,
|
|
216
|
+
attachment_requests:
|
|
217
|
+
T::Array[SignwellSDK::V1::AttachmentRequest::OrHash],
|
|
218
|
+
checkbox_groups: T::Array[SignwellSDK::V1::CheckboxGroup::OrHash],
|
|
219
|
+
copied_contacts: T::Array[SignwellSDK::V1::CopiedContact::OrHash],
|
|
220
|
+
custom_requester_email: String,
|
|
221
|
+
custom_requester_name: String,
|
|
222
|
+
decline_redirect_url: String,
|
|
223
|
+
draft: T::Boolean,
|
|
224
|
+
embedded_signing: T::Boolean,
|
|
225
|
+
embedded_signing_notifications: T::Boolean,
|
|
226
|
+
expires_in: Integer,
|
|
227
|
+
fields:
|
|
228
|
+
T::Array[
|
|
229
|
+
T::Array[
|
|
230
|
+
SignwellSDK::V1::DocumentCreateFromTemplateParams::Field::OrHash
|
|
231
|
+
]
|
|
232
|
+
],
|
|
233
|
+
files:
|
|
234
|
+
T::Array[
|
|
235
|
+
SignwellSDK::V1::DocumentCreateFromTemplateParams::File::OrHash
|
|
236
|
+
],
|
|
237
|
+
labels: T::Array[SignwellSDK::V1::Label::OrHash],
|
|
238
|
+
language: String,
|
|
239
|
+
message: String,
|
|
240
|
+
metadata: T::Hash[Symbol, String],
|
|
241
|
+
name: String,
|
|
242
|
+
redirect_url: String,
|
|
243
|
+
reminders: T::Boolean,
|
|
244
|
+
subject: String,
|
|
245
|
+
template_fields:
|
|
246
|
+
T::Array[
|
|
247
|
+
SignwellSDK::V1::DocumentCreateFromTemplateParams::TemplateField::OrHash
|
|
248
|
+
],
|
|
249
|
+
template_id: String,
|
|
250
|
+
template_ids: T::Array[String],
|
|
251
|
+
test_mode: T::Boolean,
|
|
252
|
+
text_tags: T::Boolean,
|
|
253
|
+
with_signature_page: T::Boolean,
|
|
254
|
+
request_options: SignwellSDK::RequestOptions::OrHash
|
|
255
|
+
).returns(SignwellSDK::Models::V1::DocumentCreateFromTemplateResponse)
|
|
256
|
+
end
|
|
257
|
+
def create_from_template(
|
|
258
|
+
# Document recipients are people that must complete and/or sign a document.
|
|
259
|
+
# Recipients of the document must be assigned to a placeholder of the template.
|
|
260
|
+
# Recipients will inherit all placeholder fields and settings.
|
|
261
|
+
recipients:,
|
|
262
|
+
# Whether to allow recipients the option to decline signing a document. If
|
|
263
|
+
# multiple signers are involved in a document, any single recipient can cancel the
|
|
264
|
+
# entire document signing process by declining to sign.
|
|
265
|
+
allow_decline: nil,
|
|
266
|
+
# In some cases a signer is not the right person to sign and may need to reassign
|
|
267
|
+
# their signing responsibilities to another person. This feature allows them to
|
|
268
|
+
# reassign the document to someone else.
|
|
269
|
+
allow_reassign: nil,
|
|
270
|
+
# Unique identifier for API Application settings to use. API Applications are
|
|
271
|
+
# optional and mainly used when isolating OAuth apps or for more control over
|
|
272
|
+
# embedded API settings
|
|
273
|
+
api_application_id: nil,
|
|
274
|
+
# When set to `true` recipients will sign one at a time in the order of the
|
|
275
|
+
# `recipients` collection of this request.
|
|
276
|
+
apply_signing_order: nil,
|
|
277
|
+
# Attachments that a recipient must upload to complete the signing process.
|
|
278
|
+
# Attachment requests are shown after all document fields have been completed.
|
|
279
|
+
attachment_requests: nil,
|
|
280
|
+
# Checkbox fields that are placed on a document can be grouped with selection
|
|
281
|
+
# requirements. At least 2 checkbox fields in an array of fields must be assigned
|
|
282
|
+
# to the same recipient.
|
|
283
|
+
checkbox_groups: nil,
|
|
284
|
+
# Copied contacts are emailed the final document once it has been completed by all
|
|
285
|
+
# recipients.
|
|
286
|
+
copied_contacts: nil,
|
|
287
|
+
# Sets the custom requester email for the document. When set, this is the email
|
|
288
|
+
# used for all email communications, signing notifications, and in the audit file.
|
|
289
|
+
custom_requester_email: nil,
|
|
290
|
+
# Sets the custom requester name for the document. When set, this is the name used
|
|
291
|
+
# for all email communications, signing notifications, and in the audit file.
|
|
292
|
+
custom_requester_name: nil,
|
|
293
|
+
# A URL that recipients are redirected to if the document is declined.
|
|
294
|
+
decline_redirect_url: nil,
|
|
295
|
+
# Whether the document can still be updated before sending a signature request. If
|
|
296
|
+
# set to `false` the document is sent for signing as part of this request.
|
|
297
|
+
# Defaults to `false`.
|
|
298
|
+
draft: nil,
|
|
299
|
+
# When set to `true` it enables embedded signing in your website/web application.
|
|
300
|
+
# Embedded functionality works with an iFrame and email authentication is
|
|
301
|
+
# disabled. :embedded_signinig defaults to `false`.
|
|
302
|
+
embedded_signing: nil,
|
|
303
|
+
# On embedding signing, document owners (and CC'd contacts) do not get a
|
|
304
|
+
# notification email when documents have been completed. Setting this param to
|
|
305
|
+
# `true` will send out those final completed notifications. Default is `false`
|
|
306
|
+
embedded_signing_notifications: nil,
|
|
307
|
+
# Number of days before the signature request expires. Defaults to the account
|
|
308
|
+
# expiration setting or template expiration (if the document is created from a
|
|
309
|
+
# template).
|
|
310
|
+
expires_in: nil,
|
|
311
|
+
# Fields to be added to any appended files (not existing files). Document fields
|
|
312
|
+
# placed on a document for collecting data or signatures from recipients. Field
|
|
313
|
+
# data should be sent as a 2-dimensional JSON array. One array of fields is needed
|
|
314
|
+
# for each file in the files array. An array of fields can be empty if you have a
|
|
315
|
+
# file that does not contain any fields.
|
|
316
|
+
fields: nil,
|
|
317
|
+
files: nil,
|
|
318
|
+
# Labels can be used to organize documents in a way that can make it easy to find
|
|
319
|
+
# using the document search in SignWell. A document can have multiple labels.
|
|
320
|
+
# Updating labels on a document will replace any existing labels for that
|
|
321
|
+
# document.
|
|
322
|
+
labels: nil,
|
|
323
|
+
# Sets the language for all recipients on the document and updates all recipient
|
|
324
|
+
# side interactions including the document email and the document itself. Accepted
|
|
325
|
+
# languages: English, Français, Español, Deutsch, Polski, Português, Dansk,
|
|
326
|
+
# Nederlands, Italiano, Русский, Svenska, العربية, Ελληνικά, Türkçe, Slovenčina.
|
|
327
|
+
# Defaults to English. Language should be sent in ISO 639-1 format: en, fr, es,
|
|
328
|
+
# de, pl, pt, da, nl, it, ru, sv, ar, el, tr, sk.
|
|
329
|
+
language: nil,
|
|
330
|
+
# Email message for the signature request that recipients will see. Defaults to
|
|
331
|
+
# the default system message or a template message (if the document is created
|
|
332
|
+
# from a template).
|
|
333
|
+
message: nil,
|
|
334
|
+
# Optional key-value data that can be associated with the document. If set, will
|
|
335
|
+
# be available every time the document data is returned.
|
|
336
|
+
metadata: nil,
|
|
337
|
+
# The name of the document.
|
|
338
|
+
name: nil,
|
|
339
|
+
# A URL that recipients are redirected to after successfully signing a document.
|
|
340
|
+
redirect_url: nil,
|
|
341
|
+
# Whether to send signing reminders to recipients. Reminders are sent on day 3,
|
|
342
|
+
# day 6, and day 10 if set to `true`. Defaults to `true`.
|
|
343
|
+
reminders: nil,
|
|
344
|
+
# Email subject for the signature request that recipients will see. Defaults to
|
|
345
|
+
# the default system subject or a template subject (if the document is created
|
|
346
|
+
# from a template).
|
|
347
|
+
subject: nil,
|
|
348
|
+
# Fields of your template(s) that you can prepopulate with values. Signature and
|
|
349
|
+
# Initials fields cannot be signed through the API.
|
|
350
|
+
template_fields: nil,
|
|
351
|
+
# Use when you have to create a document from a single template. Either
|
|
352
|
+
# :template_id or :template_ids must be present in the request, not both.
|
|
353
|
+
template_id: nil,
|
|
354
|
+
# Use when you have to create a document from multiple templates. Either
|
|
355
|
+
# :template_id or :template_ids must be present in the request, not both.
|
|
356
|
+
template_ids: nil,
|
|
357
|
+
# Set to `true` to enable Test Mode. Documents created with Test Mode do not count
|
|
358
|
+
# towards API billing and are not legally binding. Defaults to `false`
|
|
359
|
+
test_mode: nil,
|
|
360
|
+
# An alternative way (if you can’t use the recommended way) of placing fields in
|
|
361
|
+
# specific locations of your document by using special text tags. Useful when
|
|
362
|
+
# changing the content of your files changes the location of fields. See API
|
|
363
|
+
# documentation for “Text Tags” for details. Defaults to false.
|
|
364
|
+
text_tags: nil,
|
|
365
|
+
# When set to `true` the document will have a signature page added to the end, and
|
|
366
|
+
# all signers will be required to add their signature on that page.
|
|
367
|
+
with_signature_page: nil,
|
|
368
|
+
request_options: {}
|
|
369
|
+
)
|
|
370
|
+
end
|
|
371
|
+
|
|
372
|
+
# Sends a reminder email to recipients that have not signed yet.
|
|
373
|
+
sig do
|
|
374
|
+
params(
|
|
375
|
+
id: String,
|
|
376
|
+
recipients:
|
|
377
|
+
T::Array[
|
|
378
|
+
SignwellSDK::V1::DocumentRemindParams::Recipient::OrHash
|
|
379
|
+
],
|
|
380
|
+
request_options: SignwellSDK::RequestOptions::OrHash
|
|
381
|
+
).void
|
|
382
|
+
end
|
|
383
|
+
def remind(
|
|
384
|
+
# Unique identifier for a document.
|
|
385
|
+
id,
|
|
386
|
+
# Optional list if recipients within the document to send a reminder email to. If
|
|
387
|
+
# none are specified, all recipients that have not signed yet will receive a
|
|
388
|
+
# reminder email.
|
|
389
|
+
recipients: nil,
|
|
390
|
+
request_options: {}
|
|
391
|
+
)
|
|
392
|
+
end
|
|
393
|
+
|
|
394
|
+
# Gets a completed document PDF or ZIP file. Supply the unique document ID from
|
|
395
|
+
# either a document creation request or document page URL.
|
|
396
|
+
sig do
|
|
397
|
+
params(
|
|
398
|
+
id: String,
|
|
399
|
+
audit_page: T::Boolean,
|
|
400
|
+
file_format:
|
|
401
|
+
SignwellSDK::V1::DocumentRetrieveCompletedPdfParams::FileFormat::OrSymbol,
|
|
402
|
+
url_only: T::Boolean,
|
|
403
|
+
request_options: SignwellSDK::RequestOptions::OrHash
|
|
404
|
+
).returns(
|
|
405
|
+
SignwellSDK::Models::V1::DocumentRetrieveCompletedPdfResponse
|
|
406
|
+
)
|
|
407
|
+
end
|
|
408
|
+
def retrieve_completed_pdf(
|
|
409
|
+
# Unique identifier for a completed document.
|
|
410
|
+
id,
|
|
411
|
+
# Whether to include the audit page as part of the document. Defaults to `true`
|
|
412
|
+
audit_page: nil,
|
|
413
|
+
# Format of the file to be downloaded. Supported formats are 'pdf' and 'zip'.
|
|
414
|
+
file_format: nil,
|
|
415
|
+
# Whether to return the URL of the completed PDF or the actual PDF content.
|
|
416
|
+
# Defaults to `false`.
|
|
417
|
+
url_only: nil,
|
|
418
|
+
request_options: {}
|
|
419
|
+
)
|
|
420
|
+
end
|
|
421
|
+
|
|
422
|
+
# Updates a draft document and sends it to be signed by recipients.
|
|
423
|
+
sig do
|
|
424
|
+
params(
|
|
425
|
+
id: String,
|
|
426
|
+
allow_decline: T::Boolean,
|
|
427
|
+
allow_reassign: T::Boolean,
|
|
428
|
+
api_application_id: String,
|
|
429
|
+
apply_signing_order: T::Boolean,
|
|
430
|
+
checkbox_groups: T::Array[SignwellSDK::V1::CheckboxGroup::OrHash],
|
|
431
|
+
custom_requester_email: String,
|
|
432
|
+
custom_requester_name: String,
|
|
433
|
+
decline_redirect_url: String,
|
|
434
|
+
embedded_signing: T::Boolean,
|
|
435
|
+
embedded_signing_notifications: T::Boolean,
|
|
436
|
+
expires_in: Integer,
|
|
437
|
+
labels: T::Array[SignwellSDK::V1::Label::OrHash],
|
|
438
|
+
message: String,
|
|
439
|
+
metadata: T::Hash[Symbol, String],
|
|
440
|
+
name: String,
|
|
441
|
+
redirect_url: String,
|
|
442
|
+
reminders: T::Boolean,
|
|
443
|
+
subject: String,
|
|
444
|
+
test_mode: T::Boolean,
|
|
445
|
+
request_options: SignwellSDK::RequestOptions::OrHash
|
|
446
|
+
).returns(SignwellSDK::V1::Document)
|
|
447
|
+
end
|
|
448
|
+
def send_(
|
|
449
|
+
# Unique identifier for a document.
|
|
450
|
+
id,
|
|
451
|
+
# Whether to allow recipients the option to decline signing a document. If
|
|
452
|
+
# multiple signers are involved in a document, any single recipient can cancel the
|
|
453
|
+
# entire document signing process by declining to sign.
|
|
454
|
+
allow_decline: nil,
|
|
455
|
+
# In some cases a signer is not the right person to sign and may need to reassign
|
|
456
|
+
# their signing responsibilities to another person. This feature allows them to
|
|
457
|
+
# reassign the document to someone else.
|
|
458
|
+
allow_reassign: nil,
|
|
459
|
+
# Unique identifier for API Application settings to use. API Applications are
|
|
460
|
+
# optional and mainly used when isolating OAuth apps or for more control over
|
|
461
|
+
# embedded API settings
|
|
462
|
+
api_application_id: nil,
|
|
463
|
+
# When set to `true` recipients will sign one at a time in the order of the
|
|
464
|
+
# `recipients` collection of this request.
|
|
465
|
+
apply_signing_order: nil,
|
|
466
|
+
# Checkbox fields that are placed on a document can be grouped with selection
|
|
467
|
+
# requirements. At least 2 checkbox fields in an array of fields must be assigned
|
|
468
|
+
# to the same recipient.
|
|
469
|
+
checkbox_groups: nil,
|
|
470
|
+
# Sets the custom requester email for the document. When set, this is the email
|
|
471
|
+
# used for all email communications, signing notifications, and in the audit file.
|
|
472
|
+
custom_requester_email: nil,
|
|
473
|
+
# Sets the custom requester name for the document. When set, this is the name used
|
|
474
|
+
# for all email communications, signing notifications, and in the audit file.
|
|
475
|
+
custom_requester_name: nil,
|
|
476
|
+
# A URL that recipients are redirected to if the document is declined.
|
|
477
|
+
decline_redirect_url: nil,
|
|
478
|
+
# When set to `true` it enables embedded signing in your website/web application.
|
|
479
|
+
# Embedded functionality works with an iFrame and email authentication is
|
|
480
|
+
# disabled. :embedded_signinig defaults to `false`.
|
|
481
|
+
embedded_signing: nil,
|
|
482
|
+
# On embedding signing, document owners (and CC'd contacts) do not get a
|
|
483
|
+
# notification email when documents have been completed. Setting this param to
|
|
484
|
+
# `true` will send out those final completed notifications. Default is `false`
|
|
485
|
+
embedded_signing_notifications: nil,
|
|
486
|
+
# Number of days before the signature request expires. Defaults to the account
|
|
487
|
+
# expiration setting or template expiration (if the document is created from a
|
|
488
|
+
# template).
|
|
489
|
+
expires_in: nil,
|
|
490
|
+
# Labels can be used to organize documents in a way that can make it easy to find
|
|
491
|
+
# using the document search in SignWell. A document can have multiple labels.
|
|
492
|
+
# Updating labels on a document will replace any existing labels for that
|
|
493
|
+
# document.
|
|
494
|
+
labels: nil,
|
|
495
|
+
# Email message for the signature request that recipients will see. Defaults to
|
|
496
|
+
# the default system message or a template message (if the document is created
|
|
497
|
+
# from a template).
|
|
498
|
+
message: nil,
|
|
499
|
+
# Optional key-value data that can be associated with the document. If set, will
|
|
500
|
+
# be available every time the document data is returned.
|
|
501
|
+
metadata: nil,
|
|
502
|
+
# The name of the document.
|
|
503
|
+
name: nil,
|
|
504
|
+
# A URL that recipients are redirected to after successfully signing a document.
|
|
505
|
+
redirect_url: nil,
|
|
506
|
+
# Whether to send signing reminders to recipients. Reminders are sent on day 3,
|
|
507
|
+
# day 6, and day 10 if set to `true`. Defaults to `true`.
|
|
508
|
+
reminders: nil,
|
|
509
|
+
# Email subject for the signature request that recipients will see. Defaults to
|
|
510
|
+
# the default system subject or a template subject (if the document is created
|
|
511
|
+
# from a template).
|
|
512
|
+
subject: nil,
|
|
513
|
+
# Set to `true` to enable Test Mode. Documents created with Test Mode do not count
|
|
514
|
+
# towards API billing and are not legally binding. Defaults to `false`
|
|
515
|
+
test_mode: nil,
|
|
516
|
+
request_options: {}
|
|
517
|
+
)
|
|
518
|
+
end
|
|
519
|
+
|
|
520
|
+
# @api private
|
|
521
|
+
sig { params(client: SignwellSDK::Client).returns(T.attached_class) }
|
|
522
|
+
def self.new(client:)
|
|
523
|
+
end
|
|
524
|
+
end
|
|
525
|
+
end
|
|
526
|
+
end
|
|
527
|
+
end
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
# typed: strong
|
|
2
|
+
|
|
3
|
+
module SignwellSDK
|
|
4
|
+
module Resources
|
|
5
|
+
class V1
|
|
6
|
+
class Hooks
|
|
7
|
+
# Register a callback URL that we will post document events to.
|
|
8
|
+
sig do
|
|
9
|
+
params(
|
|
10
|
+
callback_url: String,
|
|
11
|
+
api_application_id: String,
|
|
12
|
+
request_options: SignwellSDK::RequestOptions::OrHash
|
|
13
|
+
).void
|
|
14
|
+
end
|
|
15
|
+
def create(
|
|
16
|
+
# URL that we will post document events to.
|
|
17
|
+
callback_url:,
|
|
18
|
+
# Unique identifier for the API Application.
|
|
19
|
+
api_application_id: nil,
|
|
20
|
+
request_options: {}
|
|
21
|
+
)
|
|
22
|
+
end
|
|
23
|
+
|
|
24
|
+
# List all the webhooks in the account.
|
|
25
|
+
sig do
|
|
26
|
+
params(request_options: SignwellSDK::RequestOptions::OrHash).void
|
|
27
|
+
end
|
|
28
|
+
def list(request_options: {})
|
|
29
|
+
end
|
|
30
|
+
|
|
31
|
+
# Deletes a registered callback URL that we are posting document events to.
|
|
32
|
+
sig do
|
|
33
|
+
params(
|
|
34
|
+
id: String,
|
|
35
|
+
request_options: SignwellSDK::RequestOptions::OrHash
|
|
36
|
+
).void
|
|
37
|
+
end
|
|
38
|
+
def delete(
|
|
39
|
+
# Unique identifier for a webhook.
|
|
40
|
+
id,
|
|
41
|
+
request_options: {}
|
|
42
|
+
)
|
|
43
|
+
end
|
|
44
|
+
|
|
45
|
+
# @api private
|
|
46
|
+
sig { params(client: SignwellSDK::Client).returns(T.attached_class) }
|
|
47
|
+
def self.new(client:)
|
|
48
|
+
end
|
|
49
|
+
end
|
|
50
|
+
end
|
|
51
|
+
end
|
|
52
|
+
end
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
# typed: strong
|
|
2
|
+
|
|
3
|
+
module SignwellSDK
|
|
4
|
+
module Resources
|
|
5
|
+
class V1
|
|
6
|
+
sig { returns(SignwellSDK::Resources::V1::Documents) }
|
|
7
|
+
attr_reader :documents
|
|
8
|
+
|
|
9
|
+
sig { returns(SignwellSDK::Resources::V1::DocumentTemplates) }
|
|
10
|
+
attr_reader :document_templates
|
|
11
|
+
|
|
12
|
+
sig { returns(SignwellSDK::Resources::V1::APIApplications) }
|
|
13
|
+
attr_reader :api_applications
|
|
14
|
+
|
|
15
|
+
sig { returns(SignwellSDK::Resources::V1::Hooks) }
|
|
16
|
+
attr_reader :hooks
|
|
17
|
+
|
|
18
|
+
sig { returns(SignwellSDK::Resources::V1::BulkSends) }
|
|
19
|
+
attr_reader :bulk_sends
|
|
20
|
+
|
|
21
|
+
# Retrieves the account information associated with the API key being used.
|
|
22
|
+
sig { params(request_options: SignwellSDK::RequestOptions::OrHash).void }
|
|
23
|
+
def me(request_options: {})
|
|
24
|
+
end
|
|
25
|
+
|
|
26
|
+
# @api private
|
|
27
|
+
sig { params(client: SignwellSDK::Client).returns(T.attached_class) }
|
|
28
|
+
def self.new(client:)
|
|
29
|
+
end
|
|
30
|
+
end
|
|
31
|
+
end
|
|
32
|
+
end
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
module SignwellSDK
|
|
2
|
+
class Client < SignwellSDK::Internal::Transport::BaseClient
|
|
3
|
+
DEFAULT_MAX_RETRIES: 2
|
|
4
|
+
|
|
5
|
+
DEFAULT_TIMEOUT_IN_SECONDS: Float
|
|
6
|
+
|
|
7
|
+
DEFAULT_INITIAL_RETRY_DELAY: Float
|
|
8
|
+
|
|
9
|
+
DEFAULT_MAX_RETRY_DELAY: Float
|
|
10
|
+
|
|
11
|
+
attr_reader api_key: String
|
|
12
|
+
|
|
13
|
+
attr_reader v1: SignwellSDK::Resources::V1
|
|
14
|
+
|
|
15
|
+
private def auth_headers: -> ::Hash[String, String]
|
|
16
|
+
|
|
17
|
+
def initialize: (
|
|
18
|
+
?api_key: String?,
|
|
19
|
+
?base_url: String?,
|
|
20
|
+
?max_retries: Integer,
|
|
21
|
+
?timeout: Float,
|
|
22
|
+
?initial_retry_delay: Float,
|
|
23
|
+
?max_retry_delay: Float
|
|
24
|
+
) -> void
|
|
25
|
+
end
|
|
26
|
+
end
|