docusign_esign 3.1.0.rc2 → 3.2.0.rc1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -0
- data/Gemfile +1 -1
- data/Gemfile.lock +73 -0
- data/lib/docusign_esign.rb +7 -1
- data/lib/docusign_esign/api/.DS_Store +0 -0
- data/lib/docusign_esign/api/accounts_api.rb +0 -49
- data/lib/docusign_esign/api/billing_api.rb +51 -0
- data/lib/docusign_esign/api/bulk_envelopes_api.rb +1 -1
- data/lib/docusign_esign/api/envelopes_api.rb +3 -3
- data/lib/docusign_esign/models/account_billing_plan.rb +10 -1
- data/lib/docusign_esign/models/account_billing_plan_response.rb +10 -1
- data/lib/docusign_esign/models/account_identity_input_option.rb +208 -0
- data/lib/docusign_esign/models/account_identity_verification_workflow.rb +13 -1
- data/lib/docusign_esign/models/account_settings_information.rb +96 -1
- data/lib/docusign_esign/models/account_ui_settings.rb +20 -1
- data/lib/docusign_esign/models/agent.rb +11 -1
- data/lib/docusign_esign/models/carbon_copy.rb +11 -1
- data/lib/docusign_esign/models/certified_delivery.rb +11 -1
- data/lib/docusign_esign/models/connect_custom_configuration.rb +10 -1
- data/lib/docusign_esign/models/connect_event_data.rb +210 -0
- data/lib/docusign_esign/models/document.rb +11 -11
- data/lib/docusign_esign/models/document_fields_information.rb +1 -1
- data/lib/docusign_esign/models/downgrade_billing_plan_information.rb +197 -0
- data/lib/docusign_esign/models/downgrade_plan_update_response.rb +248 -0
- data/lib/docusign_esign/models/draw.rb +911 -0
- data/lib/docusign_esign/models/editor.rb +11 -1
- data/lib/docusign_esign/models/envelope.rb +11 -1
- data/lib/docusign_esign/models/envelope_definition.rb +11 -1
- data/lib/docusign_esign/models/envelope_document.rb +1 -11
- data/lib/docusign_esign/models/envelope_template.rb +11 -1
- data/lib/docusign_esign/models/event_notification.rb +10 -1
- data/lib/docusign_esign/models/in_person_signer.rb +11 -1
- data/lib/docusign_esign/models/intermediary.rb +11 -1
- data/lib/docusign_esign/models/notary_host.rb +11 -1
- data/lib/docusign_esign/models/recipient_identity_input_option.rb +210 -0
- data/lib/docusign_esign/models/recipient_identity_phone_number.rb +208 -0
- data/lib/docusign_esign/models/recipient_identity_verification.rb +13 -1
- data/lib/docusign_esign/models/seal_sign.rb +11 -1
- data/lib/docusign_esign/models/signer.rb +12 -2
- data/lib/docusign_esign/models/tab_account_settings.rb +20 -1
- data/lib/docusign_esign/models/tabs.rb +13 -1
- data/lib/docusign_esign/models/template_tabs.rb +13 -1
- data/lib/docusign_esign/models/usage_history.rb +1 -1
- data/lib/docusign_esign/models/user_information.rb +1 -1
- data/lib/docusign_esign/models/witness.rb +11 -1
- data/lib/docusign_esign/version.rb +1 -1
- data/tests/Gemfile.lock +42 -0
- data/tests/docs/private.pem +27 -0
- metadata +13 -3
- data/docusign_esign-4.1.210.gem +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 64a6b5e31dae2059aee70468222cfce6b015381c
|
4
|
+
data.tar.gz: e6970ca724c7f8e37b525cfe6f25730eced75a2a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0254416d12c087efe0ff438ffa7a067a6cf6df79ced06d7452455c054723309c61531c0f9ec0f552d483f194a666db0c29139af6f613ccf3e4605f5367a46086
|
7
|
+
data.tar.gz: 7ff2bd94fe79b65ccaeeeeb259200858b924cfbce1b6bf90552f3f5364bfcfc0d443791cc4433244c7d8c9b867f0ba22ca9940667a8baf4e361a1a733dd30fd3
|
data/CHANGELOG.md
CHANGED
@@ -3,6 +3,12 @@ All notable changes to this project will be documented in this file.
|
|
3
3
|
|
4
4
|
See [DocuSign Support Center](https://support.docusign.com/en/releasenotes/) for Product Release Notes.
|
5
5
|
|
6
|
+
## [v3.2.0-rc1] - eSignature API v2.1-20.1.00 - 2020-03-13
|
7
|
+
### Changed
|
8
|
+
- The SDK now supports version v2.1-20.1.00 of the DocuSign eSignature API.
|
9
|
+
- Update rake version to 12.3.3
|
10
|
+
- SDK Release Version updated.
|
11
|
+
|
6
12
|
## [v3.0.0] - eSignature API v2.1-19.2.02 - 2019-10-08
|
7
13
|
### BREAKING
|
8
14
|
- The SDK now supports version 19.2.02 of the DocuSign eSignature v2.1 API.
|
data/Gemfile
CHANGED
data/Gemfile.lock
ADDED
@@ -0,0 +1,73 @@
|
|
1
|
+
PATH
|
2
|
+
remote: .
|
3
|
+
specs:
|
4
|
+
docusign_esign (3.2.0.rc1)
|
5
|
+
json (~> 2.1, >= 2.1.0)
|
6
|
+
jwt (~> 1.0, >= 1.5.2)
|
7
|
+
typhoeus (~> 1.0, >= 1.0.1)
|
8
|
+
|
9
|
+
GEM
|
10
|
+
remote: https://rubygems.org/
|
11
|
+
specs:
|
12
|
+
ZenTest (4.12.0)
|
13
|
+
addressable (2.7.0)
|
14
|
+
public_suffix (>= 2.0.2, < 5.0)
|
15
|
+
autotest (4.4.6)
|
16
|
+
ZenTest (>= 4.4.1)
|
17
|
+
autotest-fsevent (0.2.16)
|
18
|
+
sys-uname
|
19
|
+
autotest-growl (0.2.16)
|
20
|
+
autotest-rails-pure (4.1.2)
|
21
|
+
crack (0.4.3)
|
22
|
+
safe_yaml (~> 1.0.0)
|
23
|
+
diff-lcs (1.3)
|
24
|
+
ethon (0.12.0)
|
25
|
+
ffi (>= 1.3.0)
|
26
|
+
ffi (1.12.2)
|
27
|
+
hashdiff (1.0.1)
|
28
|
+
json (2.3.0)
|
29
|
+
jwt (1.5.6)
|
30
|
+
public_suffix (4.0.3)
|
31
|
+
rake (12.3.3)
|
32
|
+
rspec (3.9.0)
|
33
|
+
rspec-core (~> 3.9.0)
|
34
|
+
rspec-expectations (~> 3.9.0)
|
35
|
+
rspec-mocks (~> 3.9.0)
|
36
|
+
rspec-core (3.9.1)
|
37
|
+
rspec-support (~> 3.9.1)
|
38
|
+
rspec-expectations (3.9.1)
|
39
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
40
|
+
rspec-support (~> 3.9.0)
|
41
|
+
rspec-mocks (3.9.1)
|
42
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
43
|
+
rspec-support (~> 3.9.0)
|
44
|
+
rspec-support (3.9.2)
|
45
|
+
safe_yaml (1.0.5)
|
46
|
+
sys-uname (1.2.0)
|
47
|
+
ffi (>= 1.0.0)
|
48
|
+
typhoeus (1.3.1)
|
49
|
+
ethon (>= 0.9.0)
|
50
|
+
vcr (3.0.3)
|
51
|
+
webmock (1.24.6)
|
52
|
+
addressable (>= 2.3.6)
|
53
|
+
crack (>= 0.3.2)
|
54
|
+
hashdiff
|
55
|
+
|
56
|
+
PLATFORMS
|
57
|
+
ruby
|
58
|
+
|
59
|
+
DEPENDENCIES
|
60
|
+
autotest (~> 4.4, >= 4.4.6)
|
61
|
+
autotest-fsevent (~> 0.2, >= 0.2.11)
|
62
|
+
autotest-growl (~> 0.2, >= 0.2.16)
|
63
|
+
autotest-rails-pure (~> 4.1, >= 4.1.2)
|
64
|
+
docusign_esign!
|
65
|
+
rake (~> 12.3.3)
|
66
|
+
rspec (~> 3.4, >= 3.4.0)
|
67
|
+
rspec-expectations (~> 3.8, >= 3.8.0)
|
68
|
+
rspec-mocks (~> 3.8, >= 3.8.0)
|
69
|
+
vcr (~> 3.0, >= 3.0.1)
|
70
|
+
webmock (~> 1.24, >= 1.24.3)
|
71
|
+
|
72
|
+
BUNDLED WITH
|
73
|
+
2.0.2
|
data/lib/docusign_esign.rb
CHANGED
@@ -23,6 +23,7 @@ require 'docusign_esign/models/access_code_format'
|
|
23
23
|
require 'docusign_esign/models/account_address'
|
24
24
|
require 'docusign_esign/models/account_billing_plan'
|
25
25
|
require 'docusign_esign/models/account_billing_plan_response'
|
26
|
+
require 'docusign_esign/models/account_identity_input_option'
|
26
27
|
require 'docusign_esign/models/account_identity_verification_response'
|
27
28
|
require 'docusign_esign/models/account_identity_verification_step'
|
28
29
|
require 'docusign_esign/models/account_identity_verification_workflow'
|
@@ -135,6 +136,7 @@ require 'docusign_esign/models/composite_template'
|
|
135
136
|
require 'docusign_esign/models/connect_config_results'
|
136
137
|
require 'docusign_esign/models/connect_custom_configuration'
|
137
138
|
require 'docusign_esign/models/connect_debug_log'
|
139
|
+
require 'docusign_esign/models/connect_event_data'
|
138
140
|
require 'docusign_esign/models/connect_failure_filter'
|
139
141
|
require 'docusign_esign/models/connect_failure_result'
|
140
142
|
require 'docusign_esign/models/connect_failure_results'
|
@@ -183,6 +185,9 @@ require 'docusign_esign/models/document_template_list'
|
|
183
185
|
require 'docusign_esign/models/document_update_info'
|
184
186
|
require 'docusign_esign/models/document_visibility'
|
185
187
|
require 'docusign_esign/models/document_visibility_list'
|
188
|
+
require 'docusign_esign/models/downgrade_billing_plan_information'
|
189
|
+
require 'docusign_esign/models/downgrade_plan_update_response'
|
190
|
+
require 'docusign_esign/models/draw'
|
186
191
|
require 'docusign_esign/models/e_note_configuration'
|
187
192
|
require 'docusign_esign/models/editor'
|
188
193
|
require 'docusign_esign/models/email'
|
@@ -333,6 +338,8 @@ require 'docusign_esign/models/recipient_domain'
|
|
333
338
|
require 'docusign_esign/models/recipient_email_notification'
|
334
339
|
require 'docusign_esign/models/recipient_event'
|
335
340
|
require 'docusign_esign/models/recipient_form_data'
|
341
|
+
require 'docusign_esign/models/recipient_identity_input_option'
|
342
|
+
require 'docusign_esign/models/recipient_identity_phone_number'
|
336
343
|
require 'docusign_esign/models/recipient_identity_verification'
|
337
344
|
require 'docusign_esign/models/recipient_names_response'
|
338
345
|
require 'docusign_esign/models/recipient_phone_authentication'
|
@@ -464,7 +471,6 @@ require 'docusign_esign/api/notary_api'
|
|
464
471
|
require 'docusign_esign/api/organizations_api'
|
465
472
|
require 'docusign_esign/api/power_forms_api'
|
466
473
|
require 'docusign_esign/api/signing_groups_api'
|
467
|
-
require 'docusign_esign/api/tsps_api'
|
468
474
|
require 'docusign_esign/api/templates_api'
|
469
475
|
require 'docusign_esign/api/users_api'
|
470
476
|
require 'docusign_esign/api/workspaces_api'
|
Binary file
|
@@ -1883,55 +1883,6 @@ module DocuSign_eSign
|
|
1883
1883
|
return data, status_code, headers
|
1884
1884
|
end
|
1885
1885
|
|
1886
|
-
# Returns Account available seals for specified account.
|
1887
|
-
#
|
1888
|
-
# @param account_id The external account number (int) or account ID Guid.
|
1889
|
-
# @return [AccountSeals]
|
1890
|
-
def get_seal_providers(account_id)
|
1891
|
-
data, _status_code, _headers = get_seal_providers_with_http_info(account_id)
|
1892
|
-
return data
|
1893
|
-
end
|
1894
|
-
|
1895
|
-
# Returns Account available seals for specified account.
|
1896
|
-
#
|
1897
|
-
# @param account_id The external account number (int) or account ID Guid.
|
1898
|
-
# @return [Array<(AccountSeals, Fixnum, Hash)>] AccountSeals data, response status code and response headers
|
1899
|
-
def get_seal_providers_with_http_info(account_id)
|
1900
|
-
if @api_client.config.debugging
|
1901
|
-
@api_client.config.logger.debug "Calling API: AccountsApi.get_seal_providers ..."
|
1902
|
-
end
|
1903
|
-
# verify the required parameter 'account_id' is set
|
1904
|
-
fail ArgumentError, "Missing the required parameter 'account_id' when calling AccountsApi.get_seal_providers" if account_id.nil?
|
1905
|
-
# resource path
|
1906
|
-
local_var_path = "/v2.1/accounts/{accountId}/seals".sub('{format}','json').sub('{' + 'accountId' + '}', account_id.to_s)
|
1907
|
-
|
1908
|
-
# query parameters
|
1909
|
-
query_params = {}
|
1910
|
-
|
1911
|
-
# header parameters
|
1912
|
-
header_params = {}
|
1913
|
-
# HTTP header 'Accept' (if needed)
|
1914
|
-
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
1915
|
-
|
1916
|
-
# form parameters
|
1917
|
-
form_params = {}
|
1918
|
-
|
1919
|
-
# http body (model)
|
1920
|
-
post_body = nil
|
1921
|
-
auth_names = []
|
1922
|
-
data, status_code, headers = @api_client.call_api(:GET, local_var_path,
|
1923
|
-
:header_params => header_params,
|
1924
|
-
:query_params => query_params,
|
1925
|
-
:form_params => form_params,
|
1926
|
-
:body => post_body,
|
1927
|
-
:auth_names => auth_names,
|
1928
|
-
:return_type => 'AccountSeals')
|
1929
|
-
if @api_client.config.debugging
|
1930
|
-
@api_client.config.logger.debug "API called: AccountsApi#get_seal_providers\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
1931
|
-
end
|
1932
|
-
return data, status_code, headers
|
1933
|
-
end
|
1934
|
-
|
1935
1886
|
# Gets list of supported languages for recipient language setting.
|
1936
1887
|
#
|
1937
1888
|
# @param account_id The external account number (int) or account ID Guid.
|
@@ -628,6 +628,57 @@ module DocuSign_eSign
|
|
628
628
|
return data, status_code, headers
|
629
629
|
end
|
630
630
|
|
631
|
+
# Queues downgrade billing plan request for an account.
|
632
|
+
#
|
633
|
+
# @param account_id The external account number (int) or account ID Guid.
|
634
|
+
# @param downgrade_billing_plan_information (optional parameter)
|
635
|
+
# @return [DowngradePlanUpdateResponse]
|
636
|
+
def update_downgrade_account_billing_plan(account_id, downgrade_billing_plan_information)
|
637
|
+
data, _status_code, _headers = update_downgrade_account_billing_plan_with_http_info(account_id, downgrade_billing_plan_information)
|
638
|
+
return data
|
639
|
+
end
|
640
|
+
|
641
|
+
# Queues downgrade billing plan request for an account.
|
642
|
+
#
|
643
|
+
# @param account_id The external account number (int) or account ID Guid.
|
644
|
+
# @param downgrade_billing_plan_information (optional parameter)
|
645
|
+
# @return [Array<(DowngradePlanUpdateResponse, Fixnum, Hash)>] DowngradePlanUpdateResponse data, response status code and response headers
|
646
|
+
def update_downgrade_account_billing_plan_with_http_info(account_id, downgrade_billing_plan_information)
|
647
|
+
if @api_client.config.debugging
|
648
|
+
@api_client.config.logger.debug "Calling API: BillingApi.update_downgrade_account_billing_plan ..."
|
649
|
+
end
|
650
|
+
# verify the required parameter 'account_id' is set
|
651
|
+
fail ArgumentError, "Missing the required parameter 'account_id' when calling BillingApi.update_downgrade_account_billing_plan" if account_id.nil?
|
652
|
+
# resource path
|
653
|
+
local_var_path = "/v2.1/accounts/{accountId}/billing_plan/downgrade".sub('{format}','json').sub('{' + 'accountId' + '}', account_id.to_s)
|
654
|
+
|
655
|
+
# query parameters
|
656
|
+
query_params = {}
|
657
|
+
|
658
|
+
# header parameters
|
659
|
+
header_params = {}
|
660
|
+
# HTTP header 'Accept' (if needed)
|
661
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
662
|
+
|
663
|
+
# form parameters
|
664
|
+
form_params = {}
|
665
|
+
|
666
|
+
# http body (model)
|
667
|
+
post_body = @api_client.object_to_http_body(downgrade_billing_plan_information)
|
668
|
+
auth_names = []
|
669
|
+
data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
|
670
|
+
:header_params => header_params,
|
671
|
+
:query_params => query_params,
|
672
|
+
:form_params => form_params,
|
673
|
+
:body => post_body,
|
674
|
+
:auth_names => auth_names,
|
675
|
+
:return_type => 'DowngradePlanUpdateResponse')
|
676
|
+
if @api_client.config.debugging
|
677
|
+
@api_client.config.logger.debug "API called: BillingApi#update_downgrade_account_billing_plan\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
678
|
+
end
|
679
|
+
return data, status_code, headers
|
680
|
+
end
|
681
|
+
|
631
682
|
# Updates the account billing plan.
|
632
683
|
# Updates the billing plan information, billing address, and credit card information for the specified account.
|
633
684
|
# @param account_id The external account number (int) or account ID Guid.
|
@@ -17,7 +17,7 @@ module DocuSign_eSign
|
|
17
17
|
# Specifies the number of entries to return.
|
18
18
|
attr_accessor :count
|
19
19
|
|
20
|
-
# Specifies which entries are included in the response. Multiple entries can be included by using commas in the query string (example: ?include
|
20
|
+
# Specifies which entries are included in the response. Multiple entries can be included by using commas in the query string (example: ?include=\"failed,queued\") Valid values are: * all - Returns all entries. If present, overrides all other query settings. This is the default if no query string is provided. * failed - This only returns entries with a failed status. * queued - This only returns entries with a queued status. * sent - This only returns entries with a sent status.
|
21
21
|
attr_accessor :include
|
22
22
|
|
23
23
|
# Specifies the location in the list of envelopes from which to start.
|
@@ -401,7 +401,7 @@ module DocuSign_eSign
|
|
401
401
|
end
|
402
402
|
|
403
403
|
class ListTemplatesOptions
|
404
|
-
# The possible values are: matching_applied
|
404
|
+
# The possible values are: matching_applied - This returns template matching information for the template.
|
405
405
|
attr_accessor :include
|
406
406
|
|
407
407
|
def self.default
|
@@ -1076,7 +1076,7 @@ module DocuSign_eSign
|
|
1076
1076
|
end
|
1077
1077
|
|
1078
1078
|
# Creates an envelope.
|
1079
|
-
# Creates an envelope. Using this function you can: * Create an envelope and send it. * Create an envelope from an existing template and send it. In either case, you can choose to save the envelope as a draft envelope instead of sending it by setting the request's `status` property to `created` instead of `sent`. ## Sending Envelopes Documents can be included with the Envelopes::create call itself or a template can include documents. Documents can be added by using a multi-part/form request or by using the `documentBase64` field of the [`document` object](#/definitions/document) ### Recipient Types An [`envelopeDefinition` object](#/definitions/envelopeDefinition) is used as the method's body. Envelope recipients can be defined in the envelope or in templates. The `envelopeDefinition` object's `recipients` field is an [`EnvelopeRecipients` resource object](#/definitions/EnvelopeRecipients). It includes arrays of the seven types of recipients defined by DocuSign: Recipient type | Object definition -------------- | ----------------- agent (can add name and email information for later recipients/signers) | [`agent`](#/definitions/agent) carbon copy (receives a copy of the documents) | [`carbonCopy`](#/definitions/carbonCopy) certified delivery (receives a copy of the documents and must acknowledge receipt) | [`certifiedDelivery`](#/definitions/certifiedDelivery) editor (can change recipients and document fields for later recipients/signers) | [`editor`](#/definitions/editor) in-person signer (ÃÂââÃÂìÃÂ
ÃÂhostsÃÂââÃÂìÃÂàsomeone who signs in-person) | [`inPersonSigner`](#/definitions/inPersonSigner) intermediary (can add name and email information for some later recipients/signers.) | [`intermediary`](#/definitions/intermediary) signer (signs and/or updates document fields) | [`signer`](#/definitions/signer) Additional information about the different types of recipients is available from the [`EnvelopeRecipients` resource page](../../EnvelopeRecipients) and from the [Developer Center](https://www.docusign.com/developer-center/explore/features/recipients) ### Tabs Tabs (also referred to as `tags` and as `fields` in the web sending user interface), can be defined in the `envelopeDefinition`, in templates, by transforming PDF Form Fields, or by using Composite Templates (see below). Defining tabs: the `inPersonSigner`, and `signer` recipient objects include a `tabs` field. It is an [`EnvelopeTabs` resource object](#/definitions/EnvelopeTabs). It includes arrays of the 24 different tab types available. See the [`EnvelopeTabs` resource](../../EnvelopeTabs) for more information. ## Using Templates Envelopes use specific people or groups as recipients. Templates can specify a role, eg `account_manager.` When a template is used in an envelope, the roles must be replaced with specific people or groups. When you create an envelope using a `templateId`, the different recipient type objects within the [`EnvelopeRecipients` object](#/definitions/EnvelopeRecipients) are used to assign recipients to the template's roles via the `roleName` property. The recipient objects can also override settings that were specified in the template, and set values for tab fields that were defined in the template. ### Message Lock When a template is added or applied to an envelope and the template has a locked email subject and message, that subject and message are used for the envelope and cannot be changed even if another locked template is subsequently added or applied to the envelope. The field `messageLock` is used to lock the email subject and message. If an email subject or message is entered before adding or applying a template with `messageLock` **true**, the email subject and message is overwritten with the locked email subject and message from the template. ## Envelope Status The status of sent envelopes can be determined through the DocuSign webhook system or by polling. Webhooks are highly recommended: they provide your application with the quickest updates when an envelope's status changes. DocuSign limits polling to once every 15 minutes or less frequently. When a webhook is used, DocuSign calls your application, via the URL you provide, with a notification XML message. See the [Webhook recipe](https://www.docusign.com/developer-center/recipes/webhook-status) for examples and live demos of using webhooks. ## Webhook Options The two webhook options, *eventNotification* and *Connect* use the same notification mechanism and message formats. eventNotification is used to create a webhook for a specific envelope sent via the API. Connect webhooks can be used for any envelope sent from an account, from any user, from any client. ### eventNotification Webhooks The Envelopes::create method includes an optional [eventNotification object](#definition-eventNotification) that adds a webhook to the envelope. eventNotification webhooks are available for all DocuSign accounts with API access. ### Connect Webhooks Connect can be used to create a webhook for all envelopes sent by all users in an account, either through the API or via other DocuSign clients (web, mobile, etc). Connect configurations are independent of specific envelopes. A Connect configuration includes a filter that may be used to limit the webhook to specific users, envelope statuses, etc. Connect configurations may be created and managed using the [ConnectConfigurations resource](../../Connect/ConnectConfigurations). Configurations can also be created and managed from the Administration tool accessed by selecting ÃÂââÃÂìÃÂ
ÃÂGo to AdminÃÂââÃÂìÃÂàfrom the menu next to your picture on the DocuSign web app. See the Integrations/Connect section of the Admin tool. For repeatability, and to minimize support questions, creating Connect configurations via the API is recommended, especially for ISVs. Connect is available for some DocuSign account types. Please contact DocuSign Sales for more information. ## Composite Templates The Composite Templates feature, like [compositing in film production](https://en.wikipedia.org/wiki/Compositing), enables you to *overlay* document, recipient, and tab definitions from multiple sources, including PDF Form Field definitions, templates defined on the server, and more. Each Composite Template consists of optional elements: server templates, inline templates, PDF Metadata templates, and documents. * The Composite Template ID is an optional element used to identify the composite template. It is used as a reference when adding document object information via a multi-part HTTP message. If used, the document content-disposition must include the `compositeTemplateId` to which the document should be added. If `compositeTemplateId` is not specified in the content-disposition, the document is applied based on the `documentId` only. If no document object is specified, the composite template inherits the first document. * Server Templates are server-side templates stored on the DocuSign platform. If supplied, they are overlaid into the envelope in the order of their Sequence value. * Inline Templates provide a container to add documents, recipients, tabs, and custom fields. If inline templates are supplied, they are overlaid into the envelope in the order of their Sequence value. * Document objects are optional structures that provide a container to pass in a document or form. If this object is not included, the composite template inherits the *first* document it finds from a server template or inline template, starting with the lowest sequence value. PDF Form objects are only transformed from the document object. DocuSign does not derive PDF form properties from server templates or inline templates. To instruct DocuSign to transform fields from the PDF form, set `transformPdfFields` to \"true\" for the document. See the Transform PDF Fields section for more information about process. * PDF Metadata Templates provide a container to embed design-time template information into a PDF document. DocuSign uses this information when processing the Envelope. This convention allows the document to carry the signing instructions with it, so that less information needs to be provided at run-time through an inline template or synchronized with an external structure like a server template. PDF Metadata templates are stored in the Metadata layer of a PDF in accordance with Acrobat's XMP specification. DocuSign will only find PDF Metadata templates inside documents passed in the Document object (see below). If supplied, the PDF metadata template will be overlaid into the envelope in the order of its Sequence value. ### Compositing the definitions Each Composite Template adds a new document and templates overlay into the envelope. For each Composite Template these rules are applied: * Templates are overlaid in the order of their Sequence value. * If Document is not passed into the Composite Template's `document` field, the *first* template's document (based on the template's Sequence value) is used. * Last in wins in all cases except for the document (i.e. envelope information, recipient information, secure field information). There is no special casing. For example, if you want higher security on a tab, then that needs to be specified in a later template (by sequence number) then where the tab is included. If you want higher security on a role recipient, then it needs to be in a later template then where that role recipient is specified. * Recipient matching is based on Recipient Role and Routing Order. If there are matches, the recipient information is merged together. A final pass is done on all Composite Templates, after all template overlays have been applied, to collapse recipients with the same email, username and routing order. This prevents having the same recipients at the same routing order. * If you specify in a template that a recipient is locked, once that recipient is overlaid the recipient attributes can no longer be changed. The only items that can be changed for the recipient in this case are the email, username, access code and IDCheckInformationInput. * Tab matching is based on Tab Labels, Tab Types and Documents. If a Tab Label matches but the Document is not supplied, the Tab is overlaid for all the Documents. For example, if you have a simple inline template with only one tab in it with a label and a value, the Signature, Initial, Company, Envelope ID, User Name tabs will only be matched and collapsed if they fall in the exact same X and Y locations. * roleName and tabLabel matching is case sensitive. * The defaultRecipient field enables you to specify which recipient the generated tabs from a PDF form are mapped to. You can also set PDF form generated tabs to a recipient other than the DefaultRecipient by specifying the mapping of the tab label that is created to one of the template recipients. * You can use tabLabel wild carding to map a series of tabs from the PDF form. To use this you must end a tab label with ÃÂââÃÂìÃÂ
ÃÂ\\*ÃÂââÃÂìÃÂàand then the system matches tabs that start with the label. * If no DefaultRecipient is specified, tabs must be explicitly mapped to recipients in order to be generated from the form. Unmapped form objects will not be generated into their DocuSign equivalents. (In the case of Signature/Initials, the tabs will be disregarded entirely; in the case of pdf text fields, the field data will be flattened on the Envelope document, but there will not be a corresponding DocuSign data tab.) ### Including the Document Content for Composite Templates Document content can be supplied inline, using the `documentBase64` or can be included in a multi-part HTTP message. If a multi-part message is used and there are multiple Composite Templates, the document content-disposition can include the `compositeTemplateId` to which the document should be added. Using the `compositeTemplateId` sets which documents are associated with particular composite templates. An example of this usage is: ``` --5cd3320a-5aac-4453-b3a4-cbb52a4cba5d Content-Type: application/pdf Content-Disposition: file; filename=\"eula.pdf\"; documentId=1; compositeTemplateId=\"1\" Content-Transfer-Encoding: base64 ``` ### PDF Form Field Transformation Only the following PDF Form FieldTypes will be transformed to DocuSign tabs: CheckBox, DateTime, ListBox, Numeric, Password, Radio, Signature, and Text Field Properties that will be transformed: Read Only, Required, Max Length, Positions, and Initial Data. When transforming a *PDF Form Digital Signature Field,* the following rules are used: If the PDF Field Name Contains | Then the DocuSign Tab Will be ------- | -------- DocuSignSignHere or eSignSignHere | Signature DocuSignSignHereOptional or eSignSignHereOptional | Optional Signature DocuSignInitialHere or eSignInitialHere | Initials DocuSignInitialHereOptional or eSignInitialHereOptional | Optional Initials Any other PDF Form Digital Signature Field will be transformed to a DocuSign Signature tab When transforming *PDF Form Text Fields,* the following rules are used: If the PDF Field Name Contains | Then the DocuSign Tab Will be ------- | -------- DocuSignSignHere or eSignSignHere | Signature DocuSignSignHereOptional or eSignSignHereOptional | Optional Signature DocuSignInitialHere or eSignInitialHere | Initials DocuSignInitialHereOptional or eSignInitialHereOptional | Optional Initials DocuSignEnvelopeID or eSignEnvelopeID | EnvelopeID DocuSignCompany or eSignCompany | Company DocuSignDateSigned or eSignDateSigned | Date Signed DocuSignTitle or eSignTitle | Title DocuSignFullName or eSignFullName | Full Name DocuSignSignerAttachmentOptional or eSignSignerAttachmentOptional | Optional Signer Attachment Any other PDF Form Text Field will be transformed to a DocuSign data (text) tab. PDF Form Field Names that include ÃÂââÃÂìÃÂ
ÃÂDocuSignIgnoreTransformÃÂââÃÂìÃÂàor ÃÂââÃÂìÃÂ
ÃÂeSignIgnoreTransformÃÂââÃÂìÃÂàwill not be transformed. PDF Form Date fields will be transformed to Date Signed fields if their name includes DocuSignDateSigned or eSignDateSigned. ## Template Email Subject Merge Fields This feature enables you to insert recipient name and email address merge fields into the email subject line when creating or sending from a template. The merge fields, based on the recipient's `roleName`, are added to the `emailSubject` when the template is created or when the template is used to create an envelope. After a template sender adds the name and email information for the recipient and sends the envelope, the recipient information is automatically merged into the appropriate fields in the email subject line. Both the sender and the recipients will see the information in the email subject line for any emails associated with the template. This provides an easy way for senders to organize their envelope emails without having to open an envelope to check the recipient. If merging the recipient information into the subject line causes the subject line to exceed 100 characters, then any characters over the 100 character limit are not included in the subject line. For cases where the recipient name or email is expected to be long, you should consider placing the merge field at the start of the email subject. * To add a recipient's name in the subject line add the following text in the `emailSubject` when creating the template or when sending an envelope from a template: [[<roleName>_UserName]] Example: `\"emailSubject\":\"[[Signer 1_UserName]], Please sign this NDA\",` * To add a recipient's email address in the subject line add the following text in the emailSubject when creating the template or when sending an envelope from a template: [[<roleName>_Email]] Example: `\"emailSubject\":\"[[Signer 1_Email]], Please sign this NDA\",` In both cases the <roleName> is the recipient's `roleName` in the template. For cases where another recipient (such as an Agent, Editor, or Intermediary recipient) is entering the name and email information for the recipient included in the email subject, then [[<roleName>_UserName]] or [[<roleName>_Email]] is shown in the email subject. ## Branding an envelope The following rules are used to determine the `brandId` used in an envelope: * If a `brandId` is specified in the envelope/template and that brandId is available to the account, that brand is used in the envelope. * If more than one template is used in an envelope and more than one `brandId` is specified, the first `brandId` specified is used throughout the envelope. * In cases where no brand is specified and the sender belongs to a Group; if there is only one brand associated with the Group, then that brand is used in the envelope. Otherwise, the account's default signing brand is used. * For envelopes that do not meet any of the previous criteria, the account's default signing brand is used for the envelope. ## BCC Email address feature The BCC Email address feature is designed to provide a copy of all email communications for external archiving purposes. DocuSign recommends that envelopes sent using the BCC for Email Archive feature, including the BCC Email Override option, include additional signer authentication options. To send a copy of the envelope to a recipient who does not need to sign, don't use the BCC Email field. Use a Carbon Copy or Certified Delivery Recipient type. ## Merge Recipient Roles for Draft Envelopes When an envelope with multiple templates is sent, the recipients from the templates are merged according to the template roles, and empty recipients are removed. When creating an envelope with multiple templates, but not sending it (keeping it in a created state), duplicate recipients are not merged, which could cause leave duplicate recipients in the envelope. To prevent this, the query parameter `merge_roles_on_draft` should be added when posting a draft envelope (status=created) with multiple templates. Doing this will merge template roles and remove empty recipients. ###### Note: DocuSign recommends that the `merge_roles_on_draft` query parameter be used anytime you are creating an envelope with multiple templates and keeping it in draft (created) status.
|
1079
|
+
# Creates an envelope. Using this function you can: * Create an envelope and send it. * Create an envelope from an existing template and send it. In either case, you can choose to save the envelope as a draft envelope instead of sending it by setting the request's `status` property to `created` instead of `sent`. ## Sending Envelopes Documents can be included with the Envelopes::create call itself or a template can include documents. Documents can be added by using a multi-part/form request or by using the `documentBase64` field of the [`document` object](#/definitions/document) ### Recipient Types An [`envelopeDefinition` object](#/definitions/envelopeDefinition) is used as the method's body. Envelope recipients can be defined in the envelope or in templates. The `envelopeDefinition` object's `recipients` field is an [`EnvelopeRecipients` resource object](#/definitions/EnvelopeRecipients). It includes arrays of the seven types of recipients defined by DocuSign: Recipient type | Object definition -------------- | ----------------- agent (can add name and email information for later recipients/signers) | [`agent`](#/definitions/agent) carbon copy (receives a copy of the documents) | [`carbonCopy`](#/definitions/carbonCopy) certified delivery (receives a copy of the documents and must acknowledge receipt) | [`certifiedDelivery`](#/definitions/certifiedDelivery) editor (can change recipients and document fields for later recipients/signers) | [`editor`](#/definitions/editor) in-person signer (\"hosts\" someone who signs in-person) | [`inPersonSigner`](#/definitions/inPersonSigner) intermediary (can add name and email information for some later recipients/signers.) | [`intermediary`](#/definitions/intermediary) signer (signs and/or updates document fields) | [`signer`](#/definitions/signer) Additional information about the different types of recipients is available from the [`EnvelopeRecipients` resource page](../../EnvelopeRecipients) and from the [Developer Center](https://www.docusign.com/developer-center/explore/features/recipients) ### Tabs Tabs (also referred to as `tags` and as `fields` in the web sending user interface), can be defined in the `envelopeDefinition`, in templates, by transforming PDF Form Fields, or by using Composite Templates (see below). Defining tabs: the `inPersonSigner`, and `signer` recipient objects include a `tabs` field. It is an [`EnvelopeTabs` resource object](#/definitions/EnvelopeTabs). It includes arrays of the 24 different tab types available. See the [`EnvelopeTabs` resource](../../EnvelopeTabs) for more information. ## Using Templates Envelopes use specific people or groups as recipients. Templates can specify a role, eg `account_manager.` When a template is used in an envelope, the roles must be replaced with specific people or groups. When you create an envelope using a `templateId`, the different recipient type objects within the [`EnvelopeRecipients` object](#/definitions/EnvelopeRecipients) are used to assign recipients to the template's roles via the `roleName` property. The recipient objects can also override settings that were specified in the template, and set values for tab fields that were defined in the template. ### Message Lock When a template is added or applied to an envelope and the template has a locked email subject and message, that subject and message are used for the envelope and cannot be changed even if another locked template is subsequently added or applied to the envelope. The field `messageLock` is used to lock the email subject and message. If an email subject or message is entered before adding or applying a template with `messageLock` **true**, the email subject and message is overwritten with the locked email subject and message from the template. ## Envelope Status The status of sent envelopes can be determined through the DocuSign webhook system or by polling. Webhooks are highly recommended: they provide your application with the quickest updates when an envelope's status changes. DocuSign limits polling to once every 15 minutes or less frequently. When a webhook is used, DocuSign calls your application, via the URL you provide, with a notification XML message. See the [Webhook recipe](https://www.docusign.com/developer-center/recipes/webhook-status) for examples and live demos of using webhooks. ## Webhook Options The two webhook options, *eventNotification* and *Connect* use the same notification mechanism and message formats. eventNotification is used to create a webhook for a specific envelope sent via the API. Connect webhooks can be used for any envelope sent from an account, from any user, from any client. ### eventNotification Webhooks The Envelopes::create method includes an optional [eventNotification object](#definition-eventNotification) that adds a webhook to the envelope. eventNotification webhooks are available for all DocuSign accounts with API access. ### Connect Webhooks Connect can be used to create a webhook for all envelopes sent by all users in an account, either through the API or via other DocuSign clients (web, mobile, etc). Connect configurations are independent of specific envelopes. A Connect configuration includes a filter that may be used to limit the webhook to specific users, envelope statuses, etc. Connect configurations may be created and managed using the [ConnectConfigurations resource](../../Connect/ConnectConfigurations). Configurations can also be created and managed from the Administration tool accessed by selecting \"Go to Admin\" from the menu next to your picture on the DocuSign web app. See the Integrations/Connect section of the Admin tool. For repeatability, and to minimize support questions, creating Connect configurations via the API is recommended, especially for ISVs. Connect is available for some DocuSign account types. Please contact DocuSign Sales for more information. ## Composite Templates The Composite Templates feature, like [compositing in film production](https://en.wikipedia.org/wiki/Compositing), enables you to *overlay* document, recipient, and tab definitions from multiple sources, including PDF Form Field definitions, templates defined on the server, and more. Each Composite Template consists of optional elements: server templates, inline templates, PDF Metadata templates, and documents. * The Composite Template ID is an optional element used to identify the composite template. It is used as a reference when adding document object information via a multi-part HTTP message. If used, the document content-disposition must include the `compositeTemplateId` to which the document should be added. If `compositeTemplateId` is not specified in the content-disposition, the document is applied based on the `documentId` only. If no document object is specified, the composite template inherits the first document. * Server Templates are server-side templates stored on the DocuSign platform. If supplied, they are overlaid into the envelope in the order of their Sequence value. * Inline Templates provide a container to add documents, recipients, tabs, and custom fields. If inline templates are supplied, they are overlaid into the envelope in the order of their Sequence value. * Document objects are optional structures that provide a container to pass in a document or form. If this object is not included, the composite template inherits the *first* document it finds from a server template or inline template, starting with the lowest sequence value. PDF Form objects are only transformed from the document object. DocuSign does not derive PDF form properties from server templates or inline templates. To instruct DocuSign to transform fields from the PDF form, set `transformPdfFields` to \"true\" for the document. See the Transform PDF Fields section for more information about process. * PDF Metadata Templates provide a container to embed design-time template information into a PDF document. DocuSign uses this information when processing the Envelope. This convention allows the document to carry the signing instructions with it, so that less information needs to be provided at run-time through an inline template or synchronized with an external structure like a server template. PDF Metadata templates are stored in the Metadata layer of a PDF in accordance with Acrobat's XMP specification. DocuSign will only find PDF Metadata templates inside documents passed in the Document object (see below). If supplied, the PDF metadata template will be overlaid into the envelope in the order of its Sequence value. ### Compositing the definitions Each Composite Template adds a new document and templates overlay into the envelope. For each Composite Template these rules are applied: * Templates are overlaid in the order of their Sequence value. * If Document is not passed into the Composite Template's `document` field, the *first* template's document (based on the template's Sequence value) is used. * Last in wins in all cases except for the document (i.e. envelope information, recipient information, secure field information). There is no special casing. For example, if you want higher security on a tab, then that needs to be specified in a later template (by sequence number) then where the tab is included. If you want higher security on a role recipient, then it needs to be in a later template then where that role recipient is specified. * Recipient matching is based on Recipient Role and Routing Order. If there are matches, the recipient information is merged together. A final pass is done on all Composite Templates, after all template overlays have been applied, to collapse recipients with the same email, username and routing order. This prevents having the same recipients at the same routing order. * If you specify in a template that a recipient is locked, once that recipient is overlaid the recipient attributes can no longer be changed. The only items that can be changed for the recipient in this case are the email, username, access code and IDCheckInformationInput. * Tab matching is based on Tab Labels, Tab Types and Documents. If a Tab Label matches but the Document is not supplied, the Tab is overlaid for all the Documents. For example, if you have a simple inline template with only one tab in it with a label and a value, the Signature, Initial, Company, Envelope ID, User Name tabs will only be matched and collapsed if they fall in the exact same X and Y locations. * roleName and tabLabel matching is case sensitive. * The defaultRecipient field enables you to specify which recipient the generated tabs from a PDF form are mapped to. You can also set PDF form generated tabs to a recipient other than the DefaultRecipient by specifying the mapping of the tab label that is created to one of the template recipients. * You can use tabLabel wild carding to map a series of tabs from the PDF form. To use this you must end a tab label with \"\\*\" and then the system matches tabs that start with the label. * If no DefaultRecipient is specified, tabs must be explicitly mapped to recipients in order to be generated from the form. Unmapped form objects will not be generated into their DocuSign equivalents. (In the case of Signature/Initials, the tabs will be disregarded entirely; in the case of pdf text fields, the field data will be flattened on the Envelope document, but there will not be a corresponding DocuSign data tab.) ### Including the Document Content for Composite Templates Document content can be supplied inline, using the `documentBase64` or can be included in a multi-part HTTP message. If a multi-part message is used and there are multiple Composite Templates, the document content-disposition can include the `compositeTemplateId` to which the document should be added. Using the `compositeTemplateId` sets which documents are associated with particular composite templates. An example of this usage is: ``` --5cd3320a-5aac-4453-b3a4-cbb52a4cba5d Content-Type: application/pdf Content-Disposition: file; filename=\"eula.pdf\"; documentId=1; compositeTemplateId=\"1\" Content-Transfer-Encoding: base64 ``` ### PDF Form Field Transformation Only the following PDF Form FieldTypes will be transformed to DocuSign tabs: CheckBox, DateTime, ListBox, Numeric, Password, Radio, Signature, and Text Field Properties that will be transformed: Read Only, Required, Max Length, Positions, and Initial Data. When transforming a *PDF Form Digital Signature Field,* the following rules are used: If the PDF Field Name Contains | Then the DocuSign Tab Will be ------- | -------- DocuSignSignHere or eSignSignHere | Signature DocuSignSignHereOptional or eSignSignHereOptional | Optional Signature DocuSignInitialHere or eSignInitialHere | Initials DocuSignInitialHereOptional or eSignInitialHereOptional | Optional Initials Any other PDF Form Digital Signature Field will be transformed to a DocuSign Signature tab When transforming *PDF Form Text Fields,* the following rules are used: If the PDF Field Name Contains | Then the DocuSign Tab Will be ------- | -------- DocuSignSignHere or eSignSignHere | Signature DocuSignSignHereOptional or eSignSignHereOptional | Optional Signature DocuSignInitialHere or eSignInitialHere | Initials DocuSignInitialHereOptional or eSignInitialHereOptional | Optional Initials DocuSignEnvelopeID or eSignEnvelopeID | EnvelopeID DocuSignCompany or eSignCompany | Company DocuSignDateSigned or eSignDateSigned | Date Signed DocuSignTitle or eSignTitle | Title DocuSignFullName or eSignFullName | Full Name DocuSignSignerAttachmentOptional or eSignSignerAttachmentOptional | Optional Signer Attachment Any other PDF Form Text Field will be transformed to a DocuSign data (text) tab. PDF Form Field Names that include \"DocuSignIgnoreTransform\" or \"eSignIgnoreTransform\" will not be transformed. PDF Form Date fields will be transformed to Date Signed fields if their name includes DocuSignDateSigned or eSignDateSigned. ## Template Email Subject Merge Fields This feature enables you to insert recipient name and email address merge fields into the email subject line when creating or sending from a template. The merge fields, based on the recipient's `roleName`, are added to the `emailSubject` when the template is created or when the template is used to create an envelope. After a template sender adds the name and email information for the recipient and sends the envelope, the recipient information is automatically merged into the appropriate fields in the email subject line. Both the sender and the recipients will see the information in the email subject line for any emails associated with the template. This provides an easy way for senders to organize their envelope emails without having to open an envelope to check the recipient. If merging the recipient information into the subject line causes the subject line to exceed 100 characters, then any characters over the 100 character limit are not included in the subject line. For cases where the recipient name or email is expected to be long, you should consider placing the merge field at the start of the email subject. * To add a recipient's name in the subject line add the following text in the `emailSubject` when creating the template or when sending an envelope from a template: [[<roleName>_UserName]] Example: `\"emailSubject\":\"[[Signer 1_UserName]], Please sign this NDA\",` * To add a recipient's email address in the subject line add the following text in the emailSubject when creating the template or when sending an envelope from a template: [[<roleName>_Email]] Example: `\"emailSubject\":\"[[Signer 1_Email]], Please sign this NDA\",` In both cases the <roleName> is the recipient's `roleName` in the template. For cases where another recipient (such as an Agent, Editor, or Intermediary recipient) is entering the name and email information for the recipient included in the email subject, then [[<roleName>_UserName]] or [[<roleName>_Email]] is shown in the email subject. ## Branding an envelope The following rules are used to determine the `brandId` used in an envelope: * If a `brandId` is specified in the envelope/template and that brandId is available to the account, that brand is used in the envelope. * If more than one template is used in an envelope and more than one `brandId` is specified, the first `brandId` specified is used throughout the envelope. * In cases where no brand is specified and the sender belongs to a Group; if there is only one brand associated with the Group, then that brand is used in the envelope. Otherwise, the account's default signing brand is used. * For envelopes that do not meet any of the previous criteria, the account's default signing brand is used for the envelope. ## BCC Email address feature The BCC Email address feature is designed to provide a copy of all email communications for external archiving purposes. DocuSign recommends that envelopes sent using the BCC for Email Archive feature, including the BCC Email Override option, include additional signer authentication options. To send a copy of the envelope to a recipient who does not need to sign, don't use the BCC Email field. Use a Carbon Copy or Certified Delivery Recipient type. ## Merge Recipient Roles for Draft Envelopes When an envelope with multiple templates is sent, the recipients from the templates are merged according to the template roles, and empty recipients are removed. When creating an envelope with multiple templates, but not sending it (keeping it in a created state), duplicate recipients are not merged, which could cause leave duplicate recipients in the envelope. To prevent this, the query parameter `merge_roles_on_draft` should be added when posting a draft envelope (status=created) with multiple templates. Doing this will merge template roles and remove empty recipients. ###### Note: DocuSign recommends that the `merge_roles_on_draft` query parameter be used anytime you are creating an envelope with multiple templates and keeping it in draft (created) status.
|
1080
1080
|
# @param account_id The external account number (int) or account ID Guid.
|
1081
1081
|
# @param envelope_definition (optional parameter)
|
1082
1082
|
# @param DocuSign_eSign::CreateEnvelopeOptions Options for modifying the behavior of the function.
|
@@ -1087,7 +1087,7 @@ module DocuSign_eSign
|
|
1087
1087
|
end
|
1088
1088
|
|
1089
1089
|
# Creates an envelope.
|
1090
|
-
# Creates an envelope. Using this function you can: * Create an envelope and send it. * Create an envelope from an existing template and send it. In either case, you can choose to save the envelope as a draft envelope instead of sending it by setting the request's `status` property to `created` instead of `sent`. ## Sending Envelopes Documents can be included with the Envelopes::create call itself or a template can include documents. Documents can be added by using a multi-part/form request or by using the `documentBase64` field of the [`document` object](#/definitions/document) ### Recipient Types An [`envelopeDefinition` object](#/definitions/envelopeDefinition) is used as the method's body. Envelope recipients can be defined in the envelope or in templates. The `envelopeDefinition` object's `recipients` field is an [`EnvelopeRecipients` resource object](#/definitions/EnvelopeRecipients). It includes arrays of the seven types of recipients defined by DocuSign: Recipient type | Object definition -------------- | ----------------- agent (can add name and email information for later recipients/signers) | [`agent`](#/definitions/agent) carbon copy (receives a copy of the documents) | [`carbonCopy`](#/definitions/carbonCopy) certified delivery (receives a copy of the documents and must acknowledge receipt) | [`certifiedDelivery`](#/definitions/certifiedDelivery) editor (can change recipients and document fields for later recipients/signers) | [`editor`](#/definitions/editor) in-person signer (ÃÂââÃÂìÃÂ
ÃÂhostsÃÂââÃÂìÃÂàsomeone who signs in-person) | [`inPersonSigner`](#/definitions/inPersonSigner) intermediary (can add name and email information for some later recipients/signers.) | [`intermediary`](#/definitions/intermediary) signer (signs and/or updates document fields) | [`signer`](#/definitions/signer) Additional information about the different types of recipients is available from the [`EnvelopeRecipients` resource page](../../EnvelopeRecipients) and from the [Developer Center](https://www.docusign.com/developer-center/explore/features/recipients) ### Tabs Tabs (also referred to as `tags` and as `fields` in the web sending user interface), can be defined in the `envelopeDefinition`, in templates, by transforming PDF Form Fields, or by using Composite Templates (see below). Defining tabs: the `inPersonSigner`, and `signer` recipient objects include a `tabs` field. It is an [`EnvelopeTabs` resource object](#/definitions/EnvelopeTabs). It includes arrays of the 24 different tab types available. See the [`EnvelopeTabs` resource](../../EnvelopeTabs) for more information. ## Using Templates Envelopes use specific people or groups as recipients. Templates can specify a role, eg `account_manager.` When a template is used in an envelope, the roles must be replaced with specific people or groups. When you create an envelope using a `templateId`, the different recipient type objects within the [`EnvelopeRecipients` object](#/definitions/EnvelopeRecipients) are used to assign recipients to the template's roles via the `roleName` property. The recipient objects can also override settings that were specified in the template, and set values for tab fields that were defined in the template. ### Message Lock When a template is added or applied to an envelope and the template has a locked email subject and message, that subject and message are used for the envelope and cannot be changed even if another locked template is subsequently added or applied to the envelope. The field `messageLock` is used to lock the email subject and message. If an email subject or message is entered before adding or applying a template with `messageLock` **true**, the email subject and message is overwritten with the locked email subject and message from the template. ## Envelope Status The status of sent envelopes can be determined through the DocuSign webhook system or by polling. Webhooks are highly recommended: they provide your application with the quickest updates when an envelope's status changes. DocuSign limits polling to once every 15 minutes or less frequently. When a webhook is used, DocuSign calls your application, via the URL you provide, with a notification XML message. See the [Webhook recipe](https://www.docusign.com/developer-center/recipes/webhook-status) for examples and live demos of using webhooks. ## Webhook Options The two webhook options, *eventNotification* and *Connect* use the same notification mechanism and message formats. eventNotification is used to create a webhook for a specific envelope sent via the API. Connect webhooks can be used for any envelope sent from an account, from any user, from any client. ### eventNotification Webhooks The Envelopes::create method includes an optional [eventNotification object](#definition-eventNotification) that adds a webhook to the envelope. eventNotification webhooks are available for all DocuSign accounts with API access. ### Connect Webhooks Connect can be used to create a webhook for all envelopes sent by all users in an account, either through the API or via other DocuSign clients (web, mobile, etc). Connect configurations are independent of specific envelopes. A Connect configuration includes a filter that may be used to limit the webhook to specific users, envelope statuses, etc. Connect configurations may be created and managed using the [ConnectConfigurations resource](../../Connect/ConnectConfigurations). Configurations can also be created and managed from the Administration tool accessed by selecting ÃÂââÃÂìÃÂ
ÃÂGo to AdminÃÂââÃÂìÃÂàfrom the menu next to your picture on the DocuSign web app. See the Integrations/Connect section of the Admin tool. For repeatability, and to minimize support questions, creating Connect configurations via the API is recommended, especially for ISVs. Connect is available for some DocuSign account types. Please contact DocuSign Sales for more information. ## Composite Templates The Composite Templates feature, like [compositing in film production](https://en.wikipedia.org/wiki/Compositing), enables you to *overlay* document, recipient, and tab definitions from multiple sources, including PDF Form Field definitions, templates defined on the server, and more. Each Composite Template consists of optional elements: server templates, inline templates, PDF Metadata templates, and documents. * The Composite Template ID is an optional element used to identify the composite template. It is used as a reference when adding document object information via a multi-part HTTP message. If used, the document content-disposition must include the `compositeTemplateId` to which the document should be added. If `compositeTemplateId` is not specified in the content-disposition, the document is applied based on the `documentId` only. If no document object is specified, the composite template inherits the first document. * Server Templates are server-side templates stored on the DocuSign platform. If supplied, they are overlaid into the envelope in the order of their Sequence value. * Inline Templates provide a container to add documents, recipients, tabs, and custom fields. If inline templates are supplied, they are overlaid into the envelope in the order of their Sequence value. * Document objects are optional structures that provide a container to pass in a document or form. If this object is not included, the composite template inherits the *first* document it finds from a server template or inline template, starting with the lowest sequence value. PDF Form objects are only transformed from the document object. DocuSign does not derive PDF form properties from server templates or inline templates. To instruct DocuSign to transform fields from the PDF form, set `transformPdfFields` to \"true\" for the document. See the Transform PDF Fields section for more information about process. * PDF Metadata Templates provide a container to embed design-time template information into a PDF document. DocuSign uses this information when processing the Envelope. This convention allows the document to carry the signing instructions with it, so that less information needs to be provided at run-time through an inline template or synchronized with an external structure like a server template. PDF Metadata templates are stored in the Metadata layer of a PDF in accordance with Acrobat's XMP specification. DocuSign will only find PDF Metadata templates inside documents passed in the Document object (see below). If supplied, the PDF metadata template will be overlaid into the envelope in the order of its Sequence value. ### Compositing the definitions Each Composite Template adds a new document and templates overlay into the envelope. For each Composite Template these rules are applied: * Templates are overlaid in the order of their Sequence value. * If Document is not passed into the Composite Template's `document` field, the *first* template's document (based on the template's Sequence value) is used. * Last in wins in all cases except for the document (i.e. envelope information, recipient information, secure field information). There is no special casing. For example, if you want higher security on a tab, then that needs to be specified in a later template (by sequence number) then where the tab is included. If you want higher security on a role recipient, then it needs to be in a later template then where that role recipient is specified. * Recipient matching is based on Recipient Role and Routing Order. If there are matches, the recipient information is merged together. A final pass is done on all Composite Templates, after all template overlays have been applied, to collapse recipients with the same email, username and routing order. This prevents having the same recipients at the same routing order. * If you specify in a template that a recipient is locked, once that recipient is overlaid the recipient attributes can no longer be changed. The only items that can be changed for the recipient in this case are the email, username, access code and IDCheckInformationInput. * Tab matching is based on Tab Labels, Tab Types and Documents. If a Tab Label matches but the Document is not supplied, the Tab is overlaid for all the Documents. For example, if you have a simple inline template with only one tab in it with a label and a value, the Signature, Initial, Company, Envelope ID, User Name tabs will only be matched and collapsed if they fall in the exact same X and Y locations. * roleName and tabLabel matching is case sensitive. * The defaultRecipient field enables you to specify which recipient the generated tabs from a PDF form are mapped to. You can also set PDF form generated tabs to a recipient other than the DefaultRecipient by specifying the mapping of the tab label that is created to one of the template recipients. * You can use tabLabel wild carding to map a series of tabs from the PDF form. To use this you must end a tab label with ÃÂââÃÂìÃÂ
ÃÂ\\*ÃÂââÃÂìÃÂàand then the system matches tabs that start with the label. * If no DefaultRecipient is specified, tabs must be explicitly mapped to recipients in order to be generated from the form. Unmapped form objects will not be generated into their DocuSign equivalents. (In the case of Signature/Initials, the tabs will be disregarded entirely; in the case of pdf text fields, the field data will be flattened on the Envelope document, but there will not be a corresponding DocuSign data tab.) ### Including the Document Content for Composite Templates Document content can be supplied inline, using the `documentBase64` or can be included in a multi-part HTTP message. If a multi-part message is used and there are multiple Composite Templates, the document content-disposition can include the `compositeTemplateId` to which the document should be added. Using the `compositeTemplateId` sets which documents are associated with particular composite templates. An example of this usage is: ``` --5cd3320a-5aac-4453-b3a4-cbb52a4cba5d Content-Type: application/pdf Content-Disposition: file; filename=\"eula.pdf\"; documentId=1; compositeTemplateId=\"1\" Content-Transfer-Encoding: base64 ``` ### PDF Form Field Transformation Only the following PDF Form FieldTypes will be transformed to DocuSign tabs: CheckBox, DateTime, ListBox, Numeric, Password, Radio, Signature, and Text Field Properties that will be transformed: Read Only, Required, Max Length, Positions, and Initial Data. When transforming a *PDF Form Digital Signature Field,* the following rules are used: If the PDF Field Name Contains | Then the DocuSign Tab Will be ------- | -------- DocuSignSignHere or eSignSignHere | Signature DocuSignSignHereOptional or eSignSignHereOptional | Optional Signature DocuSignInitialHere or eSignInitialHere | Initials DocuSignInitialHereOptional or eSignInitialHereOptional | Optional Initials Any other PDF Form Digital Signature Field will be transformed to a DocuSign Signature tab When transforming *PDF Form Text Fields,* the following rules are used: If the PDF Field Name Contains | Then the DocuSign Tab Will be ------- | -------- DocuSignSignHere or eSignSignHere | Signature DocuSignSignHereOptional or eSignSignHereOptional | Optional Signature DocuSignInitialHere or eSignInitialHere | Initials DocuSignInitialHereOptional or eSignInitialHereOptional | Optional Initials DocuSignEnvelopeID or eSignEnvelopeID | EnvelopeID DocuSignCompany or eSignCompany | Company DocuSignDateSigned or eSignDateSigned | Date Signed DocuSignTitle or eSignTitle | Title DocuSignFullName or eSignFullName | Full Name DocuSignSignerAttachmentOptional or eSignSignerAttachmentOptional | Optional Signer Attachment Any other PDF Form Text Field will be transformed to a DocuSign data (text) tab. PDF Form Field Names that include ÃÂââÃÂìÃÂ
ÃÂDocuSignIgnoreTransformÃÂââÃÂìÃÂàor ÃÂââÃÂìÃÂ
ÃÂeSignIgnoreTransformÃÂââÃÂìÃÂàwill not be transformed. PDF Form Date fields will be transformed to Date Signed fields if their name includes DocuSignDateSigned or eSignDateSigned. ## Template Email Subject Merge Fields This feature enables you to insert recipient name and email address merge fields into the email subject line when creating or sending from a template. The merge fields, based on the recipient's `roleName`, are added to the `emailSubject` when the template is created or when the template is used to create an envelope. After a template sender adds the name and email information for the recipient and sends the envelope, the recipient information is automatically merged into the appropriate fields in the email subject line. Both the sender and the recipients will see the information in the email subject line for any emails associated with the template. This provides an easy way for senders to organize their envelope emails without having to open an envelope to check the recipient. If merging the recipient information into the subject line causes the subject line to exceed 100 characters, then any characters over the 100 character limit are not included in the subject line. For cases where the recipient name or email is expected to be long, you should consider placing the merge field at the start of the email subject. * To add a recipient's name in the subject line add the following text in the `emailSubject` when creating the template or when sending an envelope from a template: [[<roleName>_UserName]] Example: `\"emailSubject\":\"[[Signer 1_UserName]], Please sign this NDA\",` * To add a recipient's email address in the subject line add the following text in the emailSubject when creating the template or when sending an envelope from a template: [[<roleName>_Email]] Example: `\"emailSubject\":\"[[Signer 1_Email]], Please sign this NDA\",` In both cases the <roleName> is the recipient's `roleName` in the template. For cases where another recipient (such as an Agent, Editor, or Intermediary recipient) is entering the name and email information for the recipient included in the email subject, then [[<roleName>_UserName]] or [[<roleName>_Email]] is shown in the email subject. ## Branding an envelope The following rules are used to determine the `brandId` used in an envelope: * If a `brandId` is specified in the envelope/template and that brandId is available to the account, that brand is used in the envelope. * If more than one template is used in an envelope and more than one `brandId` is specified, the first `brandId` specified is used throughout the envelope. * In cases where no brand is specified and the sender belongs to a Group; if there is only one brand associated with the Group, then that brand is used in the envelope. Otherwise, the account's default signing brand is used. * For envelopes that do not meet any of the previous criteria, the account's default signing brand is used for the envelope. ## BCC Email address feature The BCC Email address feature is designed to provide a copy of all email communications for external archiving purposes. DocuSign recommends that envelopes sent using the BCC for Email Archive feature, including the BCC Email Override option, include additional signer authentication options. To send a copy of the envelope to a recipient who does not need to sign, don't use the BCC Email field. Use a Carbon Copy or Certified Delivery Recipient type. ## Merge Recipient Roles for Draft Envelopes When an envelope with multiple templates is sent, the recipients from the templates are merged according to the template roles, and empty recipients are removed. When creating an envelope with multiple templates, but not sending it (keeping it in a created state), duplicate recipients are not merged, which could cause leave duplicate recipients in the envelope. To prevent this, the query parameter `merge_roles_on_draft` should be added when posting a draft envelope (status=created) with multiple templates. Doing this will merge template roles and remove empty recipients. ###### Note: DocuSign recommends that the `merge_roles_on_draft` query parameter be used anytime you are creating an envelope with multiple templates and keeping it in draft (created) status.
|
1090
|
+
# Creates an envelope. Using this function you can: * Create an envelope and send it. * Create an envelope from an existing template and send it. In either case, you can choose to save the envelope as a draft envelope instead of sending it by setting the request's `status` property to `created` instead of `sent`. ## Sending Envelopes Documents can be included with the Envelopes::create call itself or a template can include documents. Documents can be added by using a multi-part/form request or by using the `documentBase64` field of the [`document` object](#/definitions/document) ### Recipient Types An [`envelopeDefinition` object](#/definitions/envelopeDefinition) is used as the method's body. Envelope recipients can be defined in the envelope or in templates. The `envelopeDefinition` object's `recipients` field is an [`EnvelopeRecipients` resource object](#/definitions/EnvelopeRecipients). It includes arrays of the seven types of recipients defined by DocuSign: Recipient type | Object definition -------------- | ----------------- agent (can add name and email information for later recipients/signers) | [`agent`](#/definitions/agent) carbon copy (receives a copy of the documents) | [`carbonCopy`](#/definitions/carbonCopy) certified delivery (receives a copy of the documents and must acknowledge receipt) | [`certifiedDelivery`](#/definitions/certifiedDelivery) editor (can change recipients and document fields for later recipients/signers) | [`editor`](#/definitions/editor) in-person signer (\"hosts\" someone who signs in-person) | [`inPersonSigner`](#/definitions/inPersonSigner) intermediary (can add name and email information for some later recipients/signers.) | [`intermediary`](#/definitions/intermediary) signer (signs and/or updates document fields) | [`signer`](#/definitions/signer) Additional information about the different types of recipients is available from the [`EnvelopeRecipients` resource page](../../EnvelopeRecipients) and from the [Developer Center](https://www.docusign.com/developer-center/explore/features/recipients) ### Tabs Tabs (also referred to as `tags` and as `fields` in the web sending user interface), can be defined in the `envelopeDefinition`, in templates, by transforming PDF Form Fields, or by using Composite Templates (see below). Defining tabs: the `inPersonSigner`, and `signer` recipient objects include a `tabs` field. It is an [`EnvelopeTabs` resource object](#/definitions/EnvelopeTabs). It includes arrays of the 24 different tab types available. See the [`EnvelopeTabs` resource](../../EnvelopeTabs) for more information. ## Using Templates Envelopes use specific people or groups as recipients. Templates can specify a role, eg `account_manager.` When a template is used in an envelope, the roles must be replaced with specific people or groups. When you create an envelope using a `templateId`, the different recipient type objects within the [`EnvelopeRecipients` object](#/definitions/EnvelopeRecipients) are used to assign recipients to the template's roles via the `roleName` property. The recipient objects can also override settings that were specified in the template, and set values for tab fields that were defined in the template. ### Message Lock When a template is added or applied to an envelope and the template has a locked email subject and message, that subject and message are used for the envelope and cannot be changed even if another locked template is subsequently added or applied to the envelope. The field `messageLock` is used to lock the email subject and message. If an email subject or message is entered before adding or applying a template with `messageLock` **true**, the email subject and message is overwritten with the locked email subject and message from the template. ## Envelope Status The status of sent envelopes can be determined through the DocuSign webhook system or by polling. Webhooks are highly recommended: they provide your application with the quickest updates when an envelope's status changes. DocuSign limits polling to once every 15 minutes or less frequently. When a webhook is used, DocuSign calls your application, via the URL you provide, with a notification XML message. See the [Webhook recipe](https://www.docusign.com/developer-center/recipes/webhook-status) for examples and live demos of using webhooks. ## Webhook Options The two webhook options, *eventNotification* and *Connect* use the same notification mechanism and message formats. eventNotification is used to create a webhook for a specific envelope sent via the API. Connect webhooks can be used for any envelope sent from an account, from any user, from any client. ### eventNotification Webhooks The Envelopes::create method includes an optional [eventNotification object](#definition-eventNotification) that adds a webhook to the envelope. eventNotification webhooks are available for all DocuSign accounts with API access. ### Connect Webhooks Connect can be used to create a webhook for all envelopes sent by all users in an account, either through the API or via other DocuSign clients (web, mobile, etc). Connect configurations are independent of specific envelopes. A Connect configuration includes a filter that may be used to limit the webhook to specific users, envelope statuses, etc. Connect configurations may be created and managed using the [ConnectConfigurations resource](../../Connect/ConnectConfigurations). Configurations can also be created and managed from the Administration tool accessed by selecting \"Go to Admin\" from the menu next to your picture on the DocuSign web app. See the Integrations/Connect section of the Admin tool. For repeatability, and to minimize support questions, creating Connect configurations via the API is recommended, especially for ISVs. Connect is available for some DocuSign account types. Please contact DocuSign Sales for more information. ## Composite Templates The Composite Templates feature, like [compositing in film production](https://en.wikipedia.org/wiki/Compositing), enables you to *overlay* document, recipient, and tab definitions from multiple sources, including PDF Form Field definitions, templates defined on the server, and more. Each Composite Template consists of optional elements: server templates, inline templates, PDF Metadata templates, and documents. * The Composite Template ID is an optional element used to identify the composite template. It is used as a reference when adding document object information via a multi-part HTTP message. If used, the document content-disposition must include the `compositeTemplateId` to which the document should be added. If `compositeTemplateId` is not specified in the content-disposition, the document is applied based on the `documentId` only. If no document object is specified, the composite template inherits the first document. * Server Templates are server-side templates stored on the DocuSign platform. If supplied, they are overlaid into the envelope in the order of their Sequence value. * Inline Templates provide a container to add documents, recipients, tabs, and custom fields. If inline templates are supplied, they are overlaid into the envelope in the order of their Sequence value. * Document objects are optional structures that provide a container to pass in a document or form. If this object is not included, the composite template inherits the *first* document it finds from a server template or inline template, starting with the lowest sequence value. PDF Form objects are only transformed from the document object. DocuSign does not derive PDF form properties from server templates or inline templates. To instruct DocuSign to transform fields from the PDF form, set `transformPdfFields` to \"true\" for the document. See the Transform PDF Fields section for more information about process. * PDF Metadata Templates provide a container to embed design-time template information into a PDF document. DocuSign uses this information when processing the Envelope. This convention allows the document to carry the signing instructions with it, so that less information needs to be provided at run-time through an inline template or synchronized with an external structure like a server template. PDF Metadata templates are stored in the Metadata layer of a PDF in accordance with Acrobat's XMP specification. DocuSign will only find PDF Metadata templates inside documents passed in the Document object (see below). If supplied, the PDF metadata template will be overlaid into the envelope in the order of its Sequence value. ### Compositing the definitions Each Composite Template adds a new document and templates overlay into the envelope. For each Composite Template these rules are applied: * Templates are overlaid in the order of their Sequence value. * If Document is not passed into the Composite Template's `document` field, the *first* template's document (based on the template's Sequence value) is used. * Last in wins in all cases except for the document (i.e. envelope information, recipient information, secure field information). There is no special casing. For example, if you want higher security on a tab, then that needs to be specified in a later template (by sequence number) then where the tab is included. If you want higher security on a role recipient, then it needs to be in a later template then where that role recipient is specified. * Recipient matching is based on Recipient Role and Routing Order. If there are matches, the recipient information is merged together. A final pass is done on all Composite Templates, after all template overlays have been applied, to collapse recipients with the same email, username and routing order. This prevents having the same recipients at the same routing order. * If you specify in a template that a recipient is locked, once that recipient is overlaid the recipient attributes can no longer be changed. The only items that can be changed for the recipient in this case are the email, username, access code and IDCheckInformationInput. * Tab matching is based on Tab Labels, Tab Types and Documents. If a Tab Label matches but the Document is not supplied, the Tab is overlaid for all the Documents. For example, if you have a simple inline template with only one tab in it with a label and a value, the Signature, Initial, Company, Envelope ID, User Name tabs will only be matched and collapsed if they fall in the exact same X and Y locations. * roleName and tabLabel matching is case sensitive. * The defaultRecipient field enables you to specify which recipient the generated tabs from a PDF form are mapped to. You can also set PDF form generated tabs to a recipient other than the DefaultRecipient by specifying the mapping of the tab label that is created to one of the template recipients. * You can use tabLabel wild carding to map a series of tabs from the PDF form. To use this you must end a tab label with \"\\*\" and then the system matches tabs that start with the label. * If no DefaultRecipient is specified, tabs must be explicitly mapped to recipients in order to be generated from the form. Unmapped form objects will not be generated into their DocuSign equivalents. (In the case of Signature/Initials, the tabs will be disregarded entirely; in the case of pdf text fields, the field data will be flattened on the Envelope document, but there will not be a corresponding DocuSign data tab.) ### Including the Document Content for Composite Templates Document content can be supplied inline, using the `documentBase64` or can be included in a multi-part HTTP message. If a multi-part message is used and there are multiple Composite Templates, the document content-disposition can include the `compositeTemplateId` to which the document should be added. Using the `compositeTemplateId` sets which documents are associated with particular composite templates. An example of this usage is: ``` --5cd3320a-5aac-4453-b3a4-cbb52a4cba5d Content-Type: application/pdf Content-Disposition: file; filename=\"eula.pdf\"; documentId=1; compositeTemplateId=\"1\" Content-Transfer-Encoding: base64 ``` ### PDF Form Field Transformation Only the following PDF Form FieldTypes will be transformed to DocuSign tabs: CheckBox, DateTime, ListBox, Numeric, Password, Radio, Signature, and Text Field Properties that will be transformed: Read Only, Required, Max Length, Positions, and Initial Data. When transforming a *PDF Form Digital Signature Field,* the following rules are used: If the PDF Field Name Contains | Then the DocuSign Tab Will be ------- | -------- DocuSignSignHere or eSignSignHere | Signature DocuSignSignHereOptional or eSignSignHereOptional | Optional Signature DocuSignInitialHere or eSignInitialHere | Initials DocuSignInitialHereOptional or eSignInitialHereOptional | Optional Initials Any other PDF Form Digital Signature Field will be transformed to a DocuSign Signature tab When transforming *PDF Form Text Fields,* the following rules are used: If the PDF Field Name Contains | Then the DocuSign Tab Will be ------- | -------- DocuSignSignHere or eSignSignHere | Signature DocuSignSignHereOptional or eSignSignHereOptional | Optional Signature DocuSignInitialHere or eSignInitialHere | Initials DocuSignInitialHereOptional or eSignInitialHereOptional | Optional Initials DocuSignEnvelopeID or eSignEnvelopeID | EnvelopeID DocuSignCompany or eSignCompany | Company DocuSignDateSigned or eSignDateSigned | Date Signed DocuSignTitle or eSignTitle | Title DocuSignFullName or eSignFullName | Full Name DocuSignSignerAttachmentOptional or eSignSignerAttachmentOptional | Optional Signer Attachment Any other PDF Form Text Field will be transformed to a DocuSign data (text) tab. PDF Form Field Names that include \"DocuSignIgnoreTransform\" or \"eSignIgnoreTransform\" will not be transformed. PDF Form Date fields will be transformed to Date Signed fields if their name includes DocuSignDateSigned or eSignDateSigned. ## Template Email Subject Merge Fields This feature enables you to insert recipient name and email address merge fields into the email subject line when creating or sending from a template. The merge fields, based on the recipient's `roleName`, are added to the `emailSubject` when the template is created or when the template is used to create an envelope. After a template sender adds the name and email information for the recipient and sends the envelope, the recipient information is automatically merged into the appropriate fields in the email subject line. Both the sender and the recipients will see the information in the email subject line for any emails associated with the template. This provides an easy way for senders to organize their envelope emails without having to open an envelope to check the recipient. If merging the recipient information into the subject line causes the subject line to exceed 100 characters, then any characters over the 100 character limit are not included in the subject line. For cases where the recipient name or email is expected to be long, you should consider placing the merge field at the start of the email subject. * To add a recipient's name in the subject line add the following text in the `emailSubject` when creating the template or when sending an envelope from a template: [[<roleName>_UserName]] Example: `\"emailSubject\":\"[[Signer 1_UserName]], Please sign this NDA\",` * To add a recipient's email address in the subject line add the following text in the emailSubject when creating the template or when sending an envelope from a template: [[<roleName>_Email]] Example: `\"emailSubject\":\"[[Signer 1_Email]], Please sign this NDA\",` In both cases the <roleName> is the recipient's `roleName` in the template. For cases where another recipient (such as an Agent, Editor, or Intermediary recipient) is entering the name and email information for the recipient included in the email subject, then [[<roleName>_UserName]] or [[<roleName>_Email]] is shown in the email subject. ## Branding an envelope The following rules are used to determine the `brandId` used in an envelope: * If a `brandId` is specified in the envelope/template and that brandId is available to the account, that brand is used in the envelope. * If more than one template is used in an envelope and more than one `brandId` is specified, the first `brandId` specified is used throughout the envelope. * In cases where no brand is specified and the sender belongs to a Group; if there is only one brand associated with the Group, then that brand is used in the envelope. Otherwise, the account's default signing brand is used. * For envelopes that do not meet any of the previous criteria, the account's default signing brand is used for the envelope. ## BCC Email address feature The BCC Email address feature is designed to provide a copy of all email communications for external archiving purposes. DocuSign recommends that envelopes sent using the BCC for Email Archive feature, including the BCC Email Override option, include additional signer authentication options. To send a copy of the envelope to a recipient who does not need to sign, don't use the BCC Email field. Use a Carbon Copy or Certified Delivery Recipient type. ## Merge Recipient Roles for Draft Envelopes When an envelope with multiple templates is sent, the recipients from the templates are merged according to the template roles, and empty recipients are removed. When creating an envelope with multiple templates, but not sending it (keeping it in a created state), duplicate recipients are not merged, which could cause leave duplicate recipients in the envelope. To prevent this, the query parameter `merge_roles_on_draft` should be added when posting a draft envelope (status=created) with multiple templates. Doing this will merge template roles and remove empty recipients. ###### Note: DocuSign recommends that the `merge_roles_on_draft` query parameter be used anytime you are creating an envelope with multiple templates and keeping it in draft (created) status.
|
1091
1091
|
# @param account_id The external account number (int) or account ID Guid.
|
1092
1092
|
# @param envelope_definition (optional parameter)
|
1093
1093
|
# @param DocuSign_eSign::CreateEnvelopeOptions Options for modifying the behavior of the function.
|
@@ -26,6 +26,8 @@ module DocuSign_eSign
|
|
26
26
|
# Specifies the ISO currency code for the account.
|
27
27
|
attr_accessor :currency_code
|
28
28
|
|
29
|
+
attr_accessor :downgrade_plan_information
|
30
|
+
|
29
31
|
# When set to **true**, then customer support is provided as part of the account plan.
|
30
32
|
attr_accessor :enable_support
|
31
33
|
|
@@ -82,6 +84,7 @@ module DocuSign_eSign
|
|
82
84
|
:'can_cancel_renewal' => :'canCancelRenewal',
|
83
85
|
:'can_upgrade' => :'canUpgrade',
|
84
86
|
:'currency_code' => :'currencyCode',
|
87
|
+
:'downgrade_plan_information' => :'downgradePlanInformation',
|
85
88
|
:'enable_support' => :'enableSupport',
|
86
89
|
:'included_seats' => :'includedSeats',
|
87
90
|
:'incremental_seats' => :'incrementalSeats',
|
@@ -108,6 +111,7 @@ module DocuSign_eSign
|
|
108
111
|
:'can_cancel_renewal' => :'String',
|
109
112
|
:'can_upgrade' => :'String',
|
110
113
|
:'currency_code' => :'String',
|
114
|
+
:'downgrade_plan_information' => :'DowngradePlanUpdateResponse',
|
111
115
|
:'enable_support' => :'String',
|
112
116
|
:'included_seats' => :'String',
|
113
117
|
:'incremental_seats' => :'String',
|
@@ -153,6 +157,10 @@ module DocuSign_eSign
|
|
153
157
|
self.currency_code = attributes[:'currencyCode']
|
154
158
|
end
|
155
159
|
|
160
|
+
if attributes.has_key?(:'downgradePlanInformation')
|
161
|
+
self.downgrade_plan_information = attributes[:'downgradePlanInformation']
|
162
|
+
end
|
163
|
+
|
156
164
|
if attributes.has_key?(:'enableSupport')
|
157
165
|
self.enable_support = attributes[:'enableSupport']
|
158
166
|
end
|
@@ -245,6 +253,7 @@ module DocuSign_eSign
|
|
245
253
|
can_cancel_renewal == o.can_cancel_renewal &&
|
246
254
|
can_upgrade == o.can_upgrade &&
|
247
255
|
currency_code == o.currency_code &&
|
256
|
+
downgrade_plan_information == o.downgrade_plan_information &&
|
248
257
|
enable_support == o.enable_support &&
|
249
258
|
included_seats == o.included_seats &&
|
250
259
|
incremental_seats == o.incremental_seats &&
|
@@ -272,7 +281,7 @@ module DocuSign_eSign
|
|
272
281
|
# Calculates hash code according to all attributes.
|
273
282
|
# @return [Fixnum] Hash code
|
274
283
|
def hash
|
275
|
-
[add_ons, can_cancel_renewal, can_upgrade, currency_code, enable_support, included_seats, incremental_seats, is_downgrade, other_discount_percent, payment_cycle, payment_method, per_seat_price, plan_classification, plan_feature_sets, plan_id, plan_name, renewal_status, seat_discounts, support_incident_fee, support_plan_fee].hash
|
284
|
+
[add_ons, can_cancel_renewal, can_upgrade, currency_code, downgrade_plan_information, enable_support, included_seats, incremental_seats, is_downgrade, other_discount_percent, payment_cycle, payment_method, per_seat_price, plan_classification, plan_feature_sets, plan_id, plan_name, renewal_status, seat_discounts, support_incident_fee, support_plan_fee].hash
|
276
285
|
end
|
277
286
|
|
278
287
|
# Builds the object from hash
|
@@ -25,6 +25,8 @@ module DocuSign_eSign
|
|
25
25
|
|
26
26
|
attr_accessor :direct_debit_processor_information
|
27
27
|
|
28
|
+
attr_accessor :downgrade_plan_information
|
29
|
+
|
28
30
|
#
|
29
31
|
attr_accessor :payment_method
|
30
32
|
|
@@ -44,6 +46,7 @@ module DocuSign_eSign
|
|
44
46
|
:'billing_plan' => :'billingPlan',
|
45
47
|
:'credit_card_information' => :'creditCardInformation',
|
46
48
|
:'direct_debit_processor_information' => :'directDebitProcessorInformation',
|
49
|
+
:'downgrade_plan_information' => :'downgradePlanInformation',
|
47
50
|
:'payment_method' => :'paymentMethod',
|
48
51
|
:'payment_processor_information' => :'paymentProcessorInformation',
|
49
52
|
:'referral_information' => :'referralInformation',
|
@@ -59,6 +62,7 @@ module DocuSign_eSign
|
|
59
62
|
:'billing_plan' => :'AccountBillingPlan',
|
60
63
|
:'credit_card_information' => :'CreditCardInformation',
|
61
64
|
:'direct_debit_processor_information' => :'DirectDebitProcessorInformation',
|
65
|
+
:'downgrade_plan_information' => :'DowngradePlanUpdateResponse',
|
62
66
|
:'payment_method' => :'String',
|
63
67
|
:'payment_processor_information' => :'PaymentProcessorInformation',
|
64
68
|
:'referral_information' => :'ReferralInformation',
|
@@ -94,6 +98,10 @@ module DocuSign_eSign
|
|
94
98
|
self.direct_debit_processor_information = attributes[:'directDebitProcessorInformation']
|
95
99
|
end
|
96
100
|
|
101
|
+
if attributes.has_key?(:'downgradePlanInformation')
|
102
|
+
self.downgrade_plan_information = attributes[:'downgradePlanInformation']
|
103
|
+
end
|
104
|
+
|
97
105
|
if attributes.has_key?(:'paymentMethod')
|
98
106
|
self.payment_method = attributes[:'paymentMethod']
|
99
107
|
end
|
@@ -137,6 +145,7 @@ module DocuSign_eSign
|
|
137
145
|
billing_plan == o.billing_plan &&
|
138
146
|
credit_card_information == o.credit_card_information &&
|
139
147
|
direct_debit_processor_information == o.direct_debit_processor_information &&
|
148
|
+
downgrade_plan_information == o.downgrade_plan_information &&
|
140
149
|
payment_method == o.payment_method &&
|
141
150
|
payment_processor_information == o.payment_processor_information &&
|
142
151
|
referral_information == o.referral_information &&
|
@@ -152,7 +161,7 @@ module DocuSign_eSign
|
|
152
161
|
# Calculates hash code according to all attributes.
|
153
162
|
# @return [Fixnum] Hash code
|
154
163
|
def hash
|
155
|
-
[billing_address, billing_address_is_credit_card_address, billing_plan, credit_card_information, direct_debit_processor_information, payment_method, payment_processor_information, referral_information, successor_plans].hash
|
164
|
+
[billing_address, billing_address_is_credit_card_address, billing_plan, credit_card_information, direct_debit_processor_information, downgrade_plan_information, payment_method, payment_processor_information, referral_information, successor_plans].hash
|
156
165
|
end
|
157
166
|
|
158
167
|
# Builds the object from hash
|
@@ -0,0 +1,208 @@
|
|
1
|
+
=begin
|
2
|
+
#DocuSign REST API
|
3
|
+
|
4
|
+
#The DocuSign REST API provides you with a powerful, convenient, and simple Web services API for interacting with DocuSign.
|
5
|
+
|
6
|
+
OpenAPI spec version: v2.1
|
7
|
+
Contact: devcenter@docusign.com
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
|
10
|
+
=end
|
11
|
+
|
12
|
+
require 'date'
|
13
|
+
|
14
|
+
module DocuSign_eSign
|
15
|
+
|
16
|
+
class AccountIdentityInputOption
|
17
|
+
#
|
18
|
+
attr_accessor :is_required
|
19
|
+
|
20
|
+
#
|
21
|
+
attr_accessor :option_name
|
22
|
+
|
23
|
+
#
|
24
|
+
attr_accessor :value_type
|
25
|
+
|
26
|
+
|
27
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
28
|
+
def self.attribute_map
|
29
|
+
{
|
30
|
+
:'is_required' => :'isRequired',
|
31
|
+
:'option_name' => :'optionName',
|
32
|
+
:'value_type' => :'valueType'
|
33
|
+
}
|
34
|
+
end
|
35
|
+
|
36
|
+
# Attribute type mapping.
|
37
|
+
def self.swagger_types
|
38
|
+
{
|
39
|
+
:'is_required' => :'BOOLEAN',
|
40
|
+
:'option_name' => :'String',
|
41
|
+
:'value_type' => :'String'
|
42
|
+
}
|
43
|
+
end
|
44
|
+
|
45
|
+
# Initializes the object
|
46
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
47
|
+
def initialize(attributes = {})
|
48
|
+
return unless attributes.is_a?(Hash)
|
49
|
+
|
50
|
+
# convert string to symbol for hash key
|
51
|
+
attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
|
52
|
+
|
53
|
+
if attributes.has_key?(:'isRequired')
|
54
|
+
self.is_required = attributes[:'isRequired']
|
55
|
+
end
|
56
|
+
|
57
|
+
if attributes.has_key?(:'optionName')
|
58
|
+
self.option_name = attributes[:'optionName']
|
59
|
+
end
|
60
|
+
|
61
|
+
if attributes.has_key?(:'valueType')
|
62
|
+
self.value_type = attributes[:'valueType']
|
63
|
+
end
|
64
|
+
|
65
|
+
end
|
66
|
+
|
67
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
68
|
+
# @return Array for valid properies with the reasons
|
69
|
+
def list_invalid_properties
|
70
|
+
invalid_properties = Array.new
|
71
|
+
return invalid_properties
|
72
|
+
end
|
73
|
+
|
74
|
+
# Check to see if the all the properties in the model are valid
|
75
|
+
# @return true if the model is valid
|
76
|
+
def valid?
|
77
|
+
return true
|
78
|
+
end
|
79
|
+
|
80
|
+
# Checks equality by comparing each attribute.
|
81
|
+
# @param [Object] Object to be compared
|
82
|
+
def ==(o)
|
83
|
+
return true if self.equal?(o)
|
84
|
+
self.class == o.class &&
|
85
|
+
is_required == o.is_required &&
|
86
|
+
option_name == o.option_name &&
|
87
|
+
value_type == o.value_type
|
88
|
+
end
|
89
|
+
|
90
|
+
# @see the `==` method
|
91
|
+
# @param [Object] Object to be compared
|
92
|
+
def eql?(o)
|
93
|
+
self == o
|
94
|
+
end
|
95
|
+
|
96
|
+
# Calculates hash code according to all attributes.
|
97
|
+
# @return [Fixnum] Hash code
|
98
|
+
def hash
|
99
|
+
[is_required, option_name, value_type].hash
|
100
|
+
end
|
101
|
+
|
102
|
+
# Builds the object from hash
|
103
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
104
|
+
# @return [Object] Returns the model itself
|
105
|
+
def build_from_hash(attributes)
|
106
|
+
return nil unless attributes.is_a?(Hash)
|
107
|
+
self.class.swagger_types.each_pair do |key, type|
|
108
|
+
if type =~ /\AArray<(.*)>/i
|
109
|
+
# check to ensure the input is an array given that the the attribute
|
110
|
+
# is documented as an array but the input is not
|
111
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
112
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } )
|
113
|
+
end
|
114
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
115
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
116
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
117
|
+
end
|
118
|
+
|
119
|
+
self
|
120
|
+
end
|
121
|
+
|
122
|
+
# Deserializes the data based on type
|
123
|
+
# @param string type Data type
|
124
|
+
# @param string value Value to be deserialized
|
125
|
+
# @return [Object] Deserialized data
|
126
|
+
def _deserialize(type, value)
|
127
|
+
case type.to_sym
|
128
|
+
when :DateTime
|
129
|
+
DateTime.parse(value)
|
130
|
+
when :Date
|
131
|
+
Date.parse(value)
|
132
|
+
when :String
|
133
|
+
value.to_s
|
134
|
+
when :Integer
|
135
|
+
value.to_i
|
136
|
+
when :Float
|
137
|
+
value.to_f
|
138
|
+
when :BOOLEAN
|
139
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
140
|
+
true
|
141
|
+
else
|
142
|
+
false
|
143
|
+
end
|
144
|
+
when :Object
|
145
|
+
# generic object (usually a Hash), return directly
|
146
|
+
value
|
147
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
148
|
+
inner_type = Regexp.last_match[:inner_type]
|
149
|
+
value.map { |v| _deserialize(inner_type, v) }
|
150
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
151
|
+
k_type = Regexp.last_match[:k_type]
|
152
|
+
v_type = Regexp.last_match[:v_type]
|
153
|
+
{}.tap do |hash|
|
154
|
+
value.each do |k, v|
|
155
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
156
|
+
end
|
157
|
+
end
|
158
|
+
else # model
|
159
|
+
temp_model = DocuSign_eSign.const_get(type).new
|
160
|
+
temp_model.build_from_hash(value)
|
161
|
+
end
|
162
|
+
end
|
163
|
+
|
164
|
+
# Returns the string representation of the object
|
165
|
+
# @return [String] String presentation of the object
|
166
|
+
def to_s
|
167
|
+
to_hash.to_s
|
168
|
+
end
|
169
|
+
|
170
|
+
# to_body is an alias to to_hash (backward compatibility)
|
171
|
+
# @return [Hash] Returns the object in the form of hash
|
172
|
+
def to_body
|
173
|
+
to_hash
|
174
|
+
end
|
175
|
+
|
176
|
+
# Returns the object in the form of hash
|
177
|
+
# @return [Hash] Returns the object in the form of hash
|
178
|
+
def to_hash
|
179
|
+
hash = {}
|
180
|
+
self.class.attribute_map.each_pair do |attr, param|
|
181
|
+
value = self.send(attr)
|
182
|
+
next if value.nil?
|
183
|
+
hash[param] = _to_hash(value)
|
184
|
+
end
|
185
|
+
hash
|
186
|
+
end
|
187
|
+
|
188
|
+
# Outputs non-array value in the form of hash
|
189
|
+
# For object, use to_hash. Otherwise, just return the value
|
190
|
+
# @param [Object] value Any valid value
|
191
|
+
# @return [Hash] Returns the value in the form of hash
|
192
|
+
def _to_hash(value)
|
193
|
+
if value.is_a?(Array)
|
194
|
+
value.compact.map{ |v| _to_hash(v) }
|
195
|
+
elsif value.is_a?(Hash)
|
196
|
+
{}.tap do |hash|
|
197
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
198
|
+
end
|
199
|
+
elsif value.respond_to? :to_hash
|
200
|
+
value.to_hash
|
201
|
+
else
|
202
|
+
value
|
203
|
+
end
|
204
|
+
end
|
205
|
+
|
206
|
+
end
|
207
|
+
|
208
|
+
end
|